Pulsing buttons

  • I've done a fair amount of searching and reading, but I can't seem to
    find out how these are done.  Can anyone point me at some sample code?
  • On 05/12/2007, at 1:57 PM, Timothy Reaves wrote:

    > I've done a fair amount of searching and reading, but I can't seem
    > to find out how these are done.  Can anyone point me at some sample
    > code?

    Do you just mean normal Aqua buttons? Set the key equivalent to the
    Return key in IB and the button will automagically start pulsing.

    For custom buttons I guess you'd need to set up a timer to handle
    regular redraw of the cell.

    --
    Rob Keniger
  • On Dec 4, 2007, at 8:08 PM, Rob Keniger wrote:

    >
    > On 05/12/2007, at 1:57 PM, Timothy Reaves wrote:
    >
    >> I've done a fair amount of searching and reading, but I can't seem
    >> to find out how these are done.  Can anyone point me at some sample
    >> code?
    >
    >
    > Do you just mean normal Aqua buttons? Set the key equivalent to the
    > Return key in IB and the button will automagically start pulsing.
    >
    > For custom buttons I guess you'd need to set up a timer to handle
    > regular redraw of the cell.

    Ya, I mean normal ones.  But that doesn't seem to do it.  Is it only
    one button type?  Or any NSButton subclass?
  • On 05/12/2007, at 2:11 PM, Timothy Reaves wrote:

    > Ya, I mean normal ones.  But that doesn't seem to do it.  Is it only
    > one button type?  Or any NSButton subclass?

    In IB 3 I added a "Push Button" (standard Aqua button) to a window and
    set the key equivalent to the Return key in the Inspector. Works here.

    To be honest I can't remember how the UI works in IB 2, I've been
    using IB3 for so long.

    --
    Rob Keniger
  • On Dec 4, 2007, at 8:16 PM, Rob Keniger wrote:

    >
    > On 05/12/2007, at 2:11 PM, Timothy Reaves wrote:
    >
    >> Ya, I mean normal ones.  But that doesn't seem to do it.  Is it
    >> only one button type?  Or any NSButton subclass?
    >
    >
    > In IB 3 I added a "Push Button" (standard Aqua button) to a window
    > and set the key equivalent to the Return key in the Inspector. Works
    > here.
    >
    > To be honest I can't remember how the UI works in IB 2, I've been
    > using IB3 for so long.
    >

    O.K.  It does not work for all buttons.

    What I'm wanting is a round, colored, pulsing status indicator.  Like
    you see in some of the system apps.
  • Hi Timothy,

    I think that Core Animation would help here if you can require 10.5

    You can attach filters to views that you can then animate. The sample
    code for 'MenuApplication Sample Code' which is part of the CA head
    start code has a great example. It puts a blur filter on a layer and
    then animates the intensity. Same approach can be used with layer
    backed views.

    HTH,

    -bd-
    http://bill.dudney.net/roller/objc

    On Dec 4, 2007, at 9:19 PM, Timothy Reaves wrote:

    >
    > On Dec 4, 2007, at 8:16 PM, Rob Keniger wrote:
    >
    >>
    >> On 05/12/2007, at 2:11 PM, Timothy Reaves wrote:
    >>
    >>> Ya, I mean normal ones.  But that doesn't seem to do it.  Is it
    >>> only one button type?  Or any NSButton subclass?
    >>
    >>
    >> In IB 3 I added a "Push Button" (standard Aqua button) to a window
    >> and set the key equivalent to the Return key in the Inspector.
    >> Works here.
    >>
    >> To be honest I can't remember how the UI works in IB 2, I've been
    >> using IB3 for so long.
    >>
    >
    >
    > O.K.  It does not work for all buttons.
    >
    > What I'm wanting is a round, colored, pulsing status indicator.
    > Like you see in some of the system apps.
  • Which system apps have round, pulsing status indicators again?

    ________________________________

    From: cocoa-dev-bounces+jstiles=<blizzard.com...> on behalf of Timothy Reaves
    Sent: Tue 12/4/2007 8:19 PM
    To: Cocoa Dev
    Subject: Re: Pulsing buttons

    On Dec 4, 2007, at 8:16 PM, Rob Keniger wrote:

    >
    > On 05/12/2007, at 2:11 PM, Timothy Reaves wrote:
    >
    >> Ya, I mean normal ones.  But that doesn't seem to do it.  Is it
    >> only one button type?  Or any NSButton subclass?
    >
    >
    > In IB 3 I added a "Push Button" (standard Aqua button) to a window
    > and set the key equivalent to the Return key in the Inspector. Works
    > here.
    >
    > To be honest I can't remember how the UI works in IB 2, I've been
    > using IB3 for so long.
    >

    O.K.  It does not work for all buttons.

    What I'm wanting is a round, colored, pulsing status indicator.  Like
    you see in some of the system apps.
previous month december 2007 next month
MTWTFSS
          1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30
31            
Go to today