Changeset 42562 in webkit


Ignore:
Timestamp:
Apr 15, 2009 3:46:34 PM (15 years ago)
Author:
kevino@webkit.org
Message:

Reviewed by Kevin Ollivier.

Implement support for wxWebViewNewWindowEvent.

https://bugs.webkit.org/show_bug.cgi?id=19043

Location:
trunk/WebKit/wx
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebKit/wx/ChangeLog

    r42230 r42562  
     12009-04-15  Robin Dunn  <robin@alldunn.com>
     2
     3        Reviewed by Kevin Ollivier.
     4       
     5        Implement support for wxWebViewNewWindowEvent.
     6       
     7        https://bugs.webkit.org/show_bug.cgi?id=19043
     8
     9        * WebKitSupport/FrameLoaderClientWx.cpp:
     10        (WebCore::FrameLoaderClientWx::dispatchDecidePolicyForNewWindowAction):
     11
    1122009-04-04  Kevin Ollivier  <kevino@theolliviers.com>
    213
  • trunk/WebKit/wx/WebKitSupport/FrameLoaderClientWx.cpp

    r42229 r42562  
    691691}
    692692
    693 void FrameLoaderClientWx::dispatchDecidePolicyForNewWindowAction(FramePolicyFunction function, const NavigationAction&, const ResourceRequest&, PassRefPtr<FormState>, const String&)
     693void FrameLoaderClientWx::dispatchDecidePolicyForNewWindowAction(FramePolicyFunction function, const NavigationAction&, const ResourceRequest& request, PassRefPtr<FormState>, const String& targetName)
    694694{
    695695    if (!m_frame)
    696696        return;
    697697
    698     notImplemented();
     698    if (m_webView) {
     699        wxWebViewNewWindowEvent wkEvent(m_webView);
     700        wkEvent.SetURL(request.url().string());
     701        wkEvent.SetTargetName(targetName);
     702        if (m_webView->GetEventHandler()->ProcessEvent(wkEvent)) {
     703            // if the app handles and doesn't skip the event,
     704            // from WebKit's perspective treat it as blocked / ignored
     705            (m_frame->loader()->*function)(PolicyIgnore);
     706            return;
     707        }
     708    }
     709   
    699710    (m_frame->loader()->*function)(PolicyUse);
    700711}
Note: See TracChangeset for help on using the changeset viewer.