NSToolbar messing with strings?
NSToolbar messing with strings?
- Subject: NSToolbar messing with strings?
- From: Jeremy Dronfield <email@hidden>
- Date: Mon, 29 Jul 2002 18:01:18 +0100
I'm getting a couple of odd little behaviour patterns with my NSToolbar,
and I can't tell whether they're the result of faulty programming or PB
compiler bugs. I'm working on a simple notepad app, with a toolbar. The
toolbar code is in a category attached to the app's main controller
class, and its setup method is called in the controller's -awakeFromNib.
The issues are these:
1. At compile, I get a warning "SKNotepad does not respond to
-setupToolbar", but only the FIRST TIME. When I build again (without
running), the warning goes away, and the app runs just fine, complete
with functioning toolbar. Is this a PB bug, or is there some declaration
or definition I should be putting in my controller's header file?
2. The toolbar has an item which inserts the current date/time in the
visible note. Sometimes - only sometimes - clicking it causes the app to
throw a sig 10 or 11, caused by an "invalid" string. Somehow, strings
within the program are getting invalidated more or less at random: the
date string to be inserted; the date formatting string; even the
WindowNibName. And the invalidation isn't always consistent; sometimes a
few of them survive. I've checked all my ivars, and there's nothing
wrong with them that I can see. It's a little difficult getting a clear
pattern, because the app only throws this error about 1 in 20 times
(highly variable) the toolbar button is clicked - the rest of the time,
it happily inserts its date string in the text view.
Any suggestions?
- Jeremy.
_______________________________________________
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.