Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSSegmentedControl temporary click only?



On Jun 2, 2004, at 1:46 PM, Matt Ball wrote:

I've made an NSSegmentedControl which acts as a back/forward button. Everything works, except when I click it, the segment stays selected. I want the click to be temporary. I though that putting something like [navSegmentedControl setSelectedSegment:nil]; at the end of the segmentedControl's action would do it, but it doesn't work. Does anyone have any tips?


Look at this in the NSSegmentCell

typedef enum {
NSSegmentSwitchTrackingSelectOne = 0, // only one button can be selected
NSSegmentSwitchTrackingSelectAny = 1, // any button can be selected
NSSegmentSwitchTrackingMomentary = 2 // only selected while tracking
} NSSegmentSwitchTracking;


Grab the cell from the control then set the SegmentSwitchTracking from there

vince
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


References: 
 >NSSegmentedControl temporary click only? (From: Matt Ball <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.