Changeset 154640 in webkit


Ignore:
Timestamp:
Aug 26, 2013 2:34:58 PM (11 years ago)
Author:
ap@apple.com
Message:

WebKitTestRunner needs to protect the user's pasteboard contents while running
https://bugs.webkit.org/show_bug.cgi?id=81419
<rdar://problem/11066794>

Reviewed by Darin Adler.

Mostly a copy/paste of DRT code.

Tested manually by making sure that editing/pasteboard/copy-image-with-alt-text.html
doesn't interfere with my clipboard while being run in a loop.

  • WebKitTestRunner/WebKitTestRunner.xcodeproj/project.pbxproj:
  • WebKitTestRunner/mac/PoseAsClass.h: Added.
  • WebKitTestRunner/mac/PoseAsClass.mm: Added.
  • WebKitTestRunner/mac/TestControllerMac.mm: (WTR::TestController::platformInitialize): (WTR::TestController::platformDestroy):
  • WebKitTestRunner/mac/WebKitTestRunnerPasteboard.h: Added.
  • WebKitTestRunner/mac/WebKitTestRunnerPasteboard.mm: Added.
Location:
trunk/Tools
Files:
4 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Tools/ChangeLog

    r154601 r154640  
     12013-08-26  Alexey Proskuryakov  <ap@apple.com>
     2
     3        WebKitTestRunner needs to protect the user's pasteboard contents while running
     4        https://bugs.webkit.org/show_bug.cgi?id=81419
     5        <rdar://problem/11066794>
     6
     7        Reviewed by Darin Adler.
     8
     9        Mostly a copy/paste of DRT code.
     10
     11        Tested manually by making sure that editing/pasteboard/copy-image-with-alt-text.html
     12        doesn't interfere with my clipboard while being run in a loop.
     13
     14        * WebKitTestRunner/WebKitTestRunner.xcodeproj/project.pbxproj:
     15        * WebKitTestRunner/mac/PoseAsClass.h: Added.
     16        * WebKitTestRunner/mac/PoseAsClass.mm: Added.
     17        * WebKitTestRunner/mac/TestControllerMac.mm:
     18        (WTR::TestController::platformInitialize):
     19        (WTR::TestController::platformDestroy):
     20        * WebKitTestRunner/mac/WebKitTestRunnerPasteboard.h: Added.
     21        * WebKitTestRunner/mac/WebKitTestRunnerPasteboard.mm: Added.
     22
    1232013-08-26  Zan Dobersek  <zdobersek@igalia.com>
    224
  • trunk/Tools/WebKitTestRunner/WebKitTestRunner.xcodeproj/project.pbxproj

    r150090 r154640  
    8787                C0CE720B1247C93300BC0EC4 /* TestRunnerMac.mm in Sources */ = {isa = PBXBuildFile; fileRef = C0CE720A1247C93300BC0EC4 /* TestRunnerMac.mm */; };
    8888                E1BA671E1742DA6A00C20251 /* Carbon.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = E1BA671D1742DA5A00C20251 /* Carbon.framework */; };
     89                E1C642C317CBCC7300D66A3C /* PoseAsClass.mm in Sources */ = {isa = PBXBuildFile; fileRef = E1C642C117CBCC7300D66A3C /* PoseAsClass.mm */; };
     90                E1C642C617CBCD4C00D66A3C /* WebKitTestRunnerPasteboard.mm in Sources */ = {isa = PBXBuildFile; fileRef = E1C642C417CBCD4C00D66A3C /* WebKitTestRunnerPasteboard.mm */; };
    8991/* End PBXBuildFile section */
    9092
     
    221223                C0CE720A1247C93300BC0EC4 /* TestRunnerMac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = TestRunnerMac.mm; path = mac/TestRunnerMac.mm; sourceTree = "<group>"; };
    222224                E1BA671D1742DA5A00C20251 /* Carbon.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Carbon.framework; path = System/Library/Frameworks/Carbon.framework; sourceTree = SDKROOT; };
     225                E1C642C117CBCC7300D66A3C /* PoseAsClass.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = PoseAsClass.mm; sourceTree = "<group>"; };
     226                E1C642C217CBCC7300D66A3C /* PoseAsClass.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = PoseAsClass.h; sourceTree = "<group>"; };
     227                E1C642C417CBCD4C00D66A3C /* WebKitTestRunnerPasteboard.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WebKitTestRunnerPasteboard.mm; sourceTree = "<group>"; };
     228                E1C642C517CBCD4C00D66A3C /* WebKitTestRunnerPasteboard.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebKitTestRunnerPasteboard.h; sourceTree = "<group>"; };
    223229/* End PBXFileReference section */
    224230
     
    417423                                BC7933FF118F7C84005EA8E2 /* main.mm */,
    418424                                BC7934E711906846005EA8E2 /* PlatformWebViewMac.mm */,
     425                                E1C642C117CBCC7300D66A3C /* PoseAsClass.mm */,
     426                                E1C642C217CBCC7300D66A3C /* PoseAsClass.h */,
    419427                                BC8C795B11D2785D004535A1 /* TestControllerMac.mm */,
     428                                E1C642C417CBCD4C00D66A3C /* WebKitTestRunnerPasteboard.mm */,
     429                                E1C642C517CBCD4C00D66A3C /* WebKitTestRunnerPasteboard.h */,
    420430                        );
    421431                        path = mac;
     
    603613                        files = (
    604614                                5322FB4313FDA0CD0041ABCC /* CyclicRedundancyCheck.cpp in Sources */,
     615                                E1C642C317CBCC7300D66A3C /* PoseAsClass.mm in Sources */,
    605616                                5670B8281386FCA5002EB355 /* EventSenderProxy.mm in Sources */,
    606617                                26D758E7160BECDD00268472 /* GeolocationProviderMock.cpp in Sources */,
    607618                                BC793400118F7C84005EA8E2 /* main.mm in Sources */,
    608619                                5322FB4613FDA0EA0041ABCC /* PixelDumpSupport.cpp in Sources */,
     620                                E1C642C617CBCD4C00D66A3C /* WebKitTestRunnerPasteboard.mm in Sources */,
    609621                                BC7934E811906846005EA8E2 /* PlatformWebViewMac.mm in Sources */,
    610622                                BC793431118F7F19005EA8E2 /* TestController.cpp in Sources */,
  • trunk/Tools/WebKitTestRunner/mac/TestControllerMac.mm

    r135496 r154640  
    2828
    2929#import "PlatformWebView.h"
     30#import "PoseAsClass.h"
     31#import "WebKitTestRunnerPasteboard.h"
    3032#import <WebKit2/WKStringCF.h>
    3133#import <mach-o/dyld.h>
     
    3941void TestController::platformInitialize()
    4042{
     43    poseAsClass("WebKitTestRunnerPasteboard", "NSPasteboard");
    4144}
    4245
    4346void TestController::platformDestroy()
    4447{
     48    [WebKitTestRunnerPasteboard releaseLocalPasteboards];
    4549}
    4650
Note: See TracChangeset for help on using the changeset viewer.