Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
Frame load interrupted
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Frame load interrupted

I've got a bit of a complex situation that I'm not sure how to work
around. In my app, I have a window that I must have modal. In that
window, I display a WebView. In order to have the WebView work correctly
in a modal dialog, I have a loop that sits in a loop calling [NSApp
nextEventMatching:...], and catching events passed to my window. In the
content I'm displaying, I have a javascript that ends up calling to open new windows. When I click on one of those links,
none of my WebPolicyDelegate methods get called. In fact, nothing gets
called at all and no window is displayed. At first I thought I might be
swallowing some pertinent event that was preventing the window from
popping up, but I changed my modal event loop to send ALL events and it
doesn't change the behavior. Anyone have any idea what might be
happening? The javascript looks something like this:

function OpenWindow(inURL) {
	mywin =,null,'toolbar=no,location=no,scrollbars=yes,resizable=

And the HTML that calls this is:

<A href="javascript:OpenWindow('/my/relative/URL')" target="">

Finally, my event loop looks like this:

While(!gWebViewClosed && (event = [NSApp
nextEventMatchingMaske:NSAnyEventMask untilDate:distantDate
inMode:NSDefaultRunLoopMode dequeue:YES]))
	[NSApp sendEvent:event];

Neither decidePolicyForNewWindowAction nor
decidePolicyForNavigationAction are called. I have a feeling I'm missing
something obvious but I can't figure out what!

Thanks in advance,

Josh Ferguson

Do not post admin requests to the list. They will be ignored.
Webkitsdk-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

Visit the Apple Store online or at retail locations.

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.