• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Custom binding problem...can't figure out how to trigger a notification on set
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Custom binding problem...can't figure out how to trigger a notification on set


  • Subject: Custom binding problem...can't figure out how to trigger a notification on set
  • From: "E. Wing" <email@hidden>
  • Date: Fri, 29 Sep 2006 00:12:02 -0700

Hello, I have a simple bindings problem I'm hoping somebody can help
me with. I have condensed down my problem into a simple example
program which I have posted here:
http://www.geocities.com/ewing2121/NotificationProblem.tgz

Basically, I have a custom view object with a property I want to bind.
In this case, it is color. I wish to bind my color property to the
NSColorWell widget.

My problem is that the bindings seem to only work in one direction. I
can change the color wheel from the NSColorWell and my view object
changes appropriately. But if I set my view object's color directly,
the NSColorWell does not seem to get the notification that I changed
the view color so it does update itself.

I don't know what I'm supposed to do to 'trigger' this notification.
Can some body tell me where I'm going wrong?

The example program has a custom view that paints the entire view the
specified color. If you click on the NSColorWell, you should be able
to change the view colors. If you click on the buttons labeled with
different color names, they change the view color, but the NSColorWell
will not change to keep in sync.

Thanks,
Eric
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Custom binding problem...can't figure out how to trigger a notification on set
      • From: Mike Abdullah <email@hidden>
  • Prev by Date: Re: Pixel Size
  • Next by Date: Re: Drag From iTunes in NSView just like iWeb did
  • Previous by thread: Custom reading and writing keyed archives
  • Next by thread: Re: Custom binding problem...can't figure out how to trigger a notification on set
  • Index(es):
    • Date
    • Thread