Changeset 116418 in webkit


Ignore:
Timestamp:
May 8, 2012 7:02:35 AM (12 years ago)
Author:
commit-queue@webkit.org
Message:

[Blackberry] remove m_isRequestedByPlugin in ResourceRequest
https://bugs.webkit.org/show_bug.cgi?id=84559

Patch by Chris Guan <chris.guan@torchmobile.com.cn> on 2012-05-08
Reviewed by Antonio Gomes.

Source/WebCore:

ResourceRequest is a network level abstraction, and it should
not know anything about web concepts such as plug-ins, and Blackberry
does not need m_isRequestedByPlugin any longer, So clean up all related
code.

Tested on a website of http://edition.cnn.com, a new window should be
opened only when user has a singe tap gesture on a plugin element.

  • platform/network/blackberry/ResourceRequest.h:

(WebCore::ResourceRequest::ResourceRequest):
(ResourceRequest):
(CrossThreadResourceRequestData):

  • platform/network/blackberry/ResourceRequestBlackBerry.cpp:

(WebCore::ResourceRequest::doPlatformCopyData):
(WebCore::ResourceRequest::doPlatformAdopt):

Source/WebKit/blackberry:

  • WebCoreSupport/FrameLoaderClientBlackBerry.cpp:

(WebCore::FrameLoaderClientBlackBerry::dispatchDecidePolicyForNewWindowAction):

Location:
trunk/Source
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r116408 r116418  
     12012-05-08  Chris Guan  <chris.guan@torchmobile.com.cn>
     2
     3        [Blackberry] remove m_isRequestedByPlugin in ResourceRequest
     4        https://bugs.webkit.org/show_bug.cgi?id=84559
     5
     6        Reviewed by Antonio Gomes.
     7
     8        ResourceRequest is a network level abstraction, and it should
     9        not know anything about web concepts such as plug-ins, and Blackberry
     10        does not need m_isRequestedByPlugin any longer, So clean up all related
     11        code.
     12
     13        Tested on a website of http://edition.cnn.com, a new window should be
     14        opened only when user has a singe tap gesture on a plugin element.
     15
     16        * platform/network/blackberry/ResourceRequest.h:
     17        (WebCore::ResourceRequest::ResourceRequest):
     18        (ResourceRequest):
     19        (CrossThreadResourceRequestData):
     20        * platform/network/blackberry/ResourceRequestBlackBerry.cpp:
     21        (WebCore::ResourceRequest::doPlatformCopyData):
     22        (WebCore::ResourceRequest::doPlatformAdopt):
     23
    1242012-05-03  Alexander Pavlov  <apavlov@chromium.org>
    225
  • trunk/Source/WebCore/platform/network/blackberry/ResourceRequest.h

    r116265 r116418  
    5656        , m_isXMLHTTPRequest(false)
    5757        , m_mustHandleInternally(false)
    58         , m_isRequestedByPlugin(false)
    5958        , m_forceDownload(false)
    6059        , m_targetType(TargetIsUnspecified)
     
    6665        , m_isXMLHTTPRequest(false)
    6766        , m_mustHandleInternally(false)
    68         , m_isRequestedByPlugin(false)
    6967        , m_forceDownload(false)
    7068        , m_targetType(TargetIsUnspecified)
     
    7674        , m_isXMLHTTPRequest(false)
    7775        , m_mustHandleInternally(false)
    78         , m_isRequestedByPlugin(false)
    7976        , m_forceDownload(false)
    8077        , m_targetType(TargetIsUnspecified)
     
    8784        , m_isXMLHTTPRequest(false)
    8885        , m_mustHandleInternally(false)
    89         , m_isRequestedByPlugin(false)
    9086        , m_forceDownload(false)
    9187        , m_targetType(TargetIsUnspecified)
     
    107103    void setIsXMLHTTPRequest(bool isXMLHTTPRequest) { m_isXMLHTTPRequest = isXMLHTTPRequest; }
    108104    bool isXMLHTTPRequest() const { return m_isXMLHTTPRequest; }
    109 
    110     void setIsRequestedByPlugin(bool isRequestedByPlugin) { m_isRequestedByPlugin = isRequestedByPlugin; }
    111     bool isRequestedByPlugin() const { return m_isRequestedByPlugin; }
    112105
    113106    // Marks requests which must be handled by webkit even if LinksHandledExternally is set.
     
    139132    bool m_isXMLHTTPRequest;
    140133    bool m_mustHandleInternally;
    141     bool m_isRequestedByPlugin;
    142134    bool m_forceDownload;
    143135    TargetType m_targetType;
     
    157149    bool m_isXMLHTTPRequest;
    158150    bool m_mustHandleInternally;
    159     bool m_isRequestedByPlugin;
    160151    bool m_forceDownload;
    161152    ResourceRequest::TargetType m_targetType;
  • trunk/Source/WebCore/platform/network/blackberry/ResourceRequestBlackBerry.cpp

    r116265 r116418  
    239239    data->m_isXMLHTTPRequest = m_isXMLHTTPRequest;
    240240    data->m_mustHandleInternally = m_mustHandleInternally;
    241     data->m_isRequestedByPlugin = m_isRequestedByPlugin;
    242241    data->m_forceDownload = m_forceDownload;
    243242    data->m_targetType = m_targetType;
     
    253252    m_isXMLHTTPRequest = data->m_isXMLHTTPRequest;
    254253    m_mustHandleInternally = data->m_mustHandleInternally;
    255     m_isRequestedByPlugin = data->m_isRequestedByPlugin;
    256254    m_forceDownload = data->m_forceDownload;
    257255    m_targetType = data->m_targetType;
  • trunk/Source/WebKit/blackberry/ChangeLog

    r116400 r116418  
     12012-05-08  Chris Guan  <chris.guan@torchmobile.com.cn>
     2
     3        [Blackberry] remove m_isRequestedByPlugin in ResourceRequest
     4        https://bugs.webkit.org/show_bug.cgi?id=84559
     5
     6        Reviewed by Antonio Gomes.
     7
     8        * WebCoreSupport/FrameLoaderClientBlackBerry.cpp:
     9        (WebCore::FrameLoaderClientBlackBerry::dispatchDecidePolicyForNewWindowAction):
     10
    1112012-05-08  Jonathan Dong  <jonathan.dong@torchmobile.com.cn>
    212
  • trunk/Source/WebKit/blackberry/WebCoreSupport/FrameLoaderClientBlackBerry.cpp

    r116265 r116418  
    277277void FrameLoaderClientBlackBerry::dispatchDecidePolicyForNewWindowAction(FramePolicyFunction function, const NavigationAction&, const ResourceRequest& request, PassRefPtr<FormState>, const String& frameName)
    278278{
    279     if (request.isRequestedByPlugin() && ScriptController::processingUserGesture() && !m_webPagePrivate->m_pluginMayOpenNewTab)
     279    if (ScriptController::processingUserGesture() && !m_webPagePrivate->m_pluginMayOpenNewTab) {
    280280        (m_frame->loader()->policyChecker()->*function)(PolicyIgnore);
     281        return;
     282    }
    281283
    282284    // A new window can never be a fragment scroll.
Note: See TracChangeset for help on using the changeset viewer.