Changeset 204909 in webkit


Ignore:
Timestamp:
Aug 24, 2016, 11:35:48 AM (9 years ago)
Author:
mitz@apple.com
Message:

Add a convenience function for creating a WKFrameHandleRef from a WKFrameRef without going through WKFrameInfoRef
https://bugs.webkit.org/show_bug.cgi?id=161152

Reviewed by Anders Carlsson.

Source/WebKit2:

  • UIProcess/API/C/WKFrame.cpp:

(WKFrameCreateFrameHandle): Added. Creates a handle with the frame’s frameID.

  • UIProcess/API/C/WKFrame.h:

Tools:

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
  • TestWebKitAPI/Tests/WebKit2/FrameHandle.cpp: Added.

(TestWebKitAPI::didFinishLoadForFrame):
(TestWebKitAPI::TEST):

Location:
trunk
Files:
1 added
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit2/ChangeLog

    r204905 r204909  
     12016-08-24  Dan Bernstein  <mitz@apple.com>
     2
     3        Add a convenience function for creating a WKFrameHandleRef from a WKFrameRef without going through WKFrameInfoRef
     4        https://bugs.webkit.org/show_bug.cgi?id=161152
     5
     6        Reviewed by Anders Carlsson.
     7
     8        * UIProcess/API/C/WKFrame.cpp:
     9        (WKFrameCreateFrameHandle): Added. Creates a handle with the frame’s frameID.
     10        * UIProcess/API/C/WKFrame.h:
     11
    1122016-08-24  Dan Bernstein  <mitz@apple.com>
    213
  • trunk/Source/WebKit2/UIProcess/API/C/WKFrame.cpp

    r190806 r204909  
    2828
    2929#include "APIData.h"
     30#include "APIFrameHandle.h"
    3031#include "APIFrameInfo.h"
    3132#include "WKAPICast.h"
     
    127128}
    128129
     130WKFrameHandleRef WKFrameCreateFrameHandle(WKFrameRef frameRef)
     131{
     132    return toAPI(&API::FrameHandle::create(toImpl(frameRef)->frameID()).leakRef());
     133}
     134
    129135WKFrameInfoRef WKFrameCreateFrameInfo(WKFrameRef frameRef)
    130136{
  • trunk/Source/WebKit2/UIProcess/API/C/WKFrame.h

    r190806 r204909  
    6969WK_EXPORT bool WKFrameIsFrameSet(WKFrameRef frame);
    7070
     71WK_EXPORT WKFrameHandleRef WKFrameCreateFrameHandle(WKFrameRef frame);
    7172WK_EXPORT WKFrameInfoRef WKFrameCreateFrameInfo(WKFrameRef frame);
    7273
  • trunk/Tools/ChangeLog

    r204906 r204909  
     12016-08-24  Dan Bernstein  <mitz@apple.com>
     2
     3        Add a convenience function for creating a WKFrameHandleRef from a WKFrameRef without going through WKFrameInfoRef
     4        https://bugs.webkit.org/show_bug.cgi?id=161152
     5
     6        Reviewed by Anders Carlsson.
     7
     8        * TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
     9        * TestWebKitAPI/Tests/WebKit2/FrameHandle.cpp: Added.
     10        (TestWebKitAPI::didFinishLoadForFrame):
     11        (TestWebKitAPI::TEST):
     12
    1132016-08-24  Nan Wang  <n_wang@apple.com>
    214
  • trunk/Tools/TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj

    r204614 r204909  
    6969                33E79E06137B5FD900E32D99 /* mouse-move-listener.html in Copy Resources */ = {isa = PBXBuildFile; fileRef = 33E79E05137B5FCE00E32D99 /* mouse-move-listener.html */; };
    7070                375E0E171D66674400EFEC2C /* WKNSNumber.mm in Sources */ = {isa = PBXBuildFile; fileRef = 375E0E151D66674400EFEC2C /* WKNSNumber.mm */; };
     71                376C8C061D6E197C007D2BB9 /* FrameHandle.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 376C8C041D6E197C007D2BB9 /* FrameHandle.cpp */; };
    7172                378E64771632655E00B6C676 /* InjectedBundleFrameHitTest_Bundle.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 378E64751632655D00B6C676 /* InjectedBundleFrameHitTest_Bundle.cpp */; };
    7273                378E64791632707400B6C676 /* link-with-title.html in Copy Resources */ = {isa = PBXBuildFile; fileRef = 378E647816326FDF00B6C676 /* link-with-title.html */; };
     
    746747                3751AF7A169518F800764319 /* DOMNodeFromJSObject.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = DOMNodeFromJSObject.mm; sourceTree = "<group>"; };
    747748                375E0E151D66674400EFEC2C /* WKNSNumber.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WKNSNumber.mm; sourceTree = "<group>"; };
     749                376C8C041D6E197C007D2BB9 /* FrameHandle.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = FrameHandle.cpp; sourceTree = "<group>"; };
    748750                3776BC62150946BC0043A66D /* DeviceScaleFactorInDashboardRegions.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = DeviceScaleFactorInDashboardRegions.mm; sourceTree = "<group>"; };
    749751                378E64711632646D00B6C676 /* InjectedBundleFrameHitTest.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = InjectedBundleFrameHitTest.cpp; sourceTree = "<group>"; };
     
    15201522                                C51AFB98169F49FF009CCF66 /* FindMatches.mm */,
    15211523                                1ADBEFAD130C689C00D61D19 /* ForceRepaint.cpp */,
     1524                                376C8C041D6E197C007D2BB9 /* FrameHandle.cpp */,
    15221525                                BCBD370F125AA2EB00D2C29F /* FrameMIMETypeHTML.cpp */,
    15231526                                BCBD3760125ABCFE00D2C29F /* FrameMIMETypePNG.cpp */,
     
    22692272                                7CCE7F031A411AE600447C4C /* NewFirstVisuallyNonEmptyLayoutFails.cpp in Sources */,
    22702273                                7CCE7F041A411AE600447C4C /* NewFirstVisuallyNonEmptyLayoutForImages.cpp in Sources */,
     2274                                376C8C061D6E197C007D2BB9 /* FrameHandle.cpp in Sources */,
    22712275                                7CCE7F051A411AE600447C4C /* NewFirstVisuallyNonEmptyLayoutFrames.cpp in Sources */,
    22722276                                7CCE7F251A411AF600447C4C /* OpenAndCloseWindow.mm in Sources */,
Note: See TracChangeset for help on using the changeset viewer.