• 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
Re: WebView's mainframe returns nil during WindowDidLoad?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: WebView's mainframe returns nil during WindowDidLoad?


  • Subject: Re: WebView's mainframe returns nil during WindowDidLoad?
  • From: "Theodore H. Smith" <email@hidden>
  • Date: Fri, 6 Jan 2006 18:31:47 +0000


On 6 Jan 2006, at 18:29, Theodore H. Smith wrote:


This code within my NSWindowController:

- (void)windowDidLoad {
id mf = [MyWebView mainFrame];
[mf loadRequest: [NSURLRequest requestWithURL:[NSURL URLWithString:@"http://apple.com/";]]];
}


Here, mf is nil.

Is there some kind of event I can put code into, so that I can get a WebView to have a default page loaded? As it is, I can't use windowDidLoad for this event.

I should have said, that the exact same code, called from an NSButton, works. (Although a little slow.)


What seems to be happening, is that MyWebView's mainframe is getting instantiated, after windowDidLoad.

Seems like I'm looking for windowControlsDidLoad ??

_______________________________________________
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


References: 
 >WebView's mainframe returns nil during WindowDidLoad? (From: "Theodore H. Smith" <email@hidden>)

  • Prev by Date: Re: -observeValueForKeyPath:ofObject:change:context: only defined for abstract class.
  • Next by Date: Radix Cocoa Class: Int Binary Value to Char String Using Primitive Operators
  • Previous by thread: WebView's mainframe returns nil during WindowDidLoad?
  • Next by thread: Radix Cocoa Class: Int Binary Value to Char String Using Primitive Operators
  • Index(es):
    • Date
    • Thread