Re: NSToolbar(item) quirk
Re: NSToolbar(item) quirk
- Subject: Re: NSToolbar(item) quirk
- From: Ed <email@hidden>
- Date: Sat, 5 Feb 2005 10:19:15 +0000
Hi Scott,
Yes, each is being updated by a local values. Each of the myDocument's
has a NSTextView IBOutlet, myTextView, that links to the
MyDocument.nib. In the check, that TextView's selectedRange: is
tested, if it is 0, then return false, if it is greater than, return
true. Is it possible, perhaps, that if the test on the active window
returns true, as all have the same identifier, that all the windows
are updating (oddly) based on that text? I'm about to write the code I
suggested above to see how that goes (once I get some memory
management stuff sorted out with loading a file).
ed
On Sat, 5 Feb 2005 03:35:54 -0500, Scott Anguish <email@hidden> wrote:
>
> On Feb 4, 2005, at 9:43 AM, Ed wrote:
>
> > Thanks for the replies.
> > Scott : Yup, I have myDocument class set as delegate… bad idea?
> >
>
> no. it sounded like something higher up teh chain was getting the
> validate message...
>
> > Heinrich : That is how I do it, I believe (on a school computer, don't
> > have my code).
> > My validation function is :
> > - (BOOL)validateToolbarItem:(NSToolbarItem*)toolbarItem
> > Would making my ToolbarItem (let's say quoteItem) a global variable,
> > and then when returning the toolbarItem in ...itemForIdentifier:..
> > supply the global variable instead of a dynamically created item each
> > time allow me to get around this problem, or would all of the items
> > STILL be updated at the same time?
>
> they are being updated based on some local value to the current
> document, rignt? not by a global by accident?
>
>
_______________________________________________
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