Re: HUD Windows
Re: HUD Windows
- Subject: Re: HUD Windows
- From: Jeremy <email@hidden>
- Date: Tue, 22 Jan 2008 18:19:34 -0500
Scott,
Yes I am fairly sure they are connected. I had saved and closed the
MainMenu.nib file within IB before building it again (and then checked
it before rebuilding it). Is there anything that I could do to confirm
this more than that?
Jeremy
"How would a car function if it were designed like a computer?
Occasionally, executing a maneuver would cause your car to stop and
fail and you would have to re-install the engine, and the airbag
system would say, 'Are you sure?' before going off." - Katie Hafner
On Jan 22, 2008, at 6:16 PM, Scott F Bayes wrote:
Hi Jeremy,
Are you *sure* your IBOutlets are non-nil? In IB it's easy to
accidentally leave them unconnected. Compounding this, you can send
any message to nil without getting an error or exception (either
good or bad, depending on your worldview).
ScottB
On Jan 23, 2008, at 08:06 , Jeremy wrote:
Ok, now I feel stupid with the B. But ok. I thought I got what you
are saying, band I am looking at my book, and it doesn't seem to be
helping me out much. I am not getting any warnings at all for this
code:
- (void)showLyrics:(id)sender
{
[lyricsWindow setTitle:[NSString stringWithFormat:@"%@ Lyrics",
[[iTunes currentTrack] name]]];
[lyricsText setTitle:[[iTunes currentTrack] lyrics]];
[window showWindow:lyricsWindow];
[lyricsWindow makeKeyWindow];
}
But what is boggling my mind, is why it isn't working. And
lyricsWindow is an IBOutlet id that has the HUD window attached to
it. lyricsText is an IBOutlet with the text box attached to it. So,
any help would actually help me out! A bunch.
Jeremy
"How would a car function if it were designed like a computer?
Occasionally, executing a maneuver would cause your car to stop and
fail and you would have to re-install the engine, and the airbag
system would say, 'Are you sure?' before going off." - Katie Hafner
On Jan 22, 2008, at 4:47 PM, Kyle Sluder wrote:
On Jan 22, 2008 4:18 PM, Jeremy <email@hidden> wrote:
I have an IBOutlet id lyricsText; which is connected to a text
field
within a HUB Panel Window. I have the HUB hidden by default
within the
MainMenu.nib file. I would like to (on command) open up the HUB
window, change it's title, and change the text of lyricsText. Now I
feel stupid asking, but can anyone help me out?
First, it's HUD, not HUB. ;-)
Secondly, this is what one would typically use an NSWindowController
to do. What you're describing is really easy to do (-[NSWindow
makeKeyAndOrderFront:], -[NSWindow setTitle:], -[NSTextField
setTitle:]), and is made even easier with an NSWindowController
subclass.
I suggest re-reading the model-view-controller conceptual
documentation, and then read about NSWindowController.
--Kyle Sluder
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden