Changeset 263878 in webkit
- Timestamp:
- Jul 2, 2020, 6:05:35 PM (6 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 3 added
- 3 edited
-
ChangeLog (modified) (1 diff)
-
WebCore.xcodeproj/project.pbxproj (modified) (4 diffs)
-
platform/gamepad/cocoa/GameControllerGamepadProvider.mm (modified) (2 diffs)
-
platform/gamepad/cocoa/GameControllerSPI.h (added)
-
platform/gamepad/cocoa/GameControllerSoftLink.h (added)
-
platform/gamepad/cocoa/GameControllerSoftLink.mm (added)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r263860 r263878 1 2020-07-02 Brady Eidson <beidson@apple.com> 2 3 GameController.framework soft linking refactoring 4 https://bugs.webkit.org/show_bug.cgi?id=213909 5 6 Reviewed by Tim Horton. 7 8 No new tests (No behavior changes) 9 10 * WebCore.xcodeproj/project.pbxproj: 11 * platform/gamepad/cocoa/GameControllerGamepadProvider.mm: 12 (WebCore::GameControllerGamepadProvider::startMonitoringGamepads): 13 * platform/gamepad/cocoa/GameControllerSPI.h: Added. 14 * platform/gamepad/cocoa/GameControllerSoftLink.h: Added. 15 * platform/gamepad/cocoa/GameControllerSoftLink.mm: Added. 16 1 17 2020-07-02 Simon Fraser <simon.fraser@apple.com> 2 18 -
trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj
r263788 r263878 1409 1409 512DD8FC0D91E6AF000F89EE /* ArchiveResource.h in Headers */ = {isa = PBXBuildFile; fileRef = 512DD8F20D91E6AF000F89EE /* ArchiveResource.h */; settings = {ATTRIBUTES = (Private, ); }; }; 1410 1410 512DD8FD0D91E6AF000F89EE /* ArchiveFactory.h in Headers */ = {isa = PBXBuildFile; fileRef = 512DD8F30D91E6AF000F89EE /* ArchiveFactory.h */; }; 1411 5130F2F624AEA60A00E1D0A0 /* GameControllerSoftLink.mm in Sources */ = {isa = PBXBuildFile; fileRef = 5130F2F424AEA60300E1D0A0 /* GameControllerSoftLink.mm */; }; 1411 1412 51327D6011A33A2B004F9D65 /* SinkDocument.h in Headers */ = {isa = PBXBuildFile; fileRef = 51327D5E11A33A2B004F9D65 /* SinkDocument.h */; }; 1412 1413 513F14540AB634C400094DDF /* IconLoader.h in Headers */ = {isa = PBXBuildFile; fileRef = 513F14520AB634C400094DDF /* IconLoader.h */; }; … … 8224 8225 512DD8F30D91E6AF000F89EE /* ArchiveFactory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ArchiveFactory.h; sourceTree = "<group>"; }; 8225 8226 512F1A771C07EA0D00908239 /* IDBGetResult.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = IDBGetResult.cpp; sourceTree = "<group>"; }; 8227 5130F2F224AEA60200E1D0A0 /* GameControllerSoftLink.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GameControllerSoftLink.h; sourceTree = "<group>"; }; 8228 5130F2F424AEA60300E1D0A0 /* GameControllerSoftLink.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = GameControllerSoftLink.mm; sourceTree = "<group>"; }; 8229 5130F2F524AEA60300E1D0A0 /* GameControllerSPI.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GameControllerSPI.h; sourceTree = "<group>"; }; 8226 8230 51327D5E11A33A2B004F9D65 /* SinkDocument.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SinkDocument.h; sourceTree = "<group>"; }; 8227 8231 51327D5F11A33A2B004F9D65 /* SinkDocument.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = SinkDocument.cpp; sourceTree = "<group>"; }; … … 19712 19716 51E398FE1D6E474B009C8831 /* GameControllerGamepadProvider.h */, 19713 19717 51E398FF1D6E474B009C8831 /* GameControllerGamepadProvider.mm */, 19718 5130F2F224AEA60200E1D0A0 /* GameControllerSoftLink.h */, 19719 5130F2F424AEA60300E1D0A0 /* GameControllerSoftLink.mm */, 19720 5130F2F524AEA60300E1D0A0 /* GameControllerSPI.h */, 19714 19721 ); 19715 19722 path = cocoa; … … 34916 34923 DE5F84331FA186E9006DB63A /* UnifiedSource330.cpp in Sources */, 34917 34924 DE5F84341FA186E9006DB63A /* UnifiedSource331.cpp in Sources */, 34925 5130F2F624AEA60A00E1D0A0 /* GameControllerSoftLink.mm in Sources */, 34918 34926 DE5F84351FA186E9006DB63A /* UnifiedSource332.cpp in Sources */, 34919 34927 DE5F84361FA186E9006DB63A /* UnifiedSource333.cpp in Sources */, -
trunk/Source/WebCore/platform/gamepad/cocoa/GameControllerGamepadProvider.mm
r248846 r263878 30 30 31 31 #import "GameControllerGamepad.h" 32 #import "GameControllerSoftLink.h" 32 33 #import "GamepadProviderClient.h" 33 34 #import "Logging.h" 34 35 #import <GameController/GameController.h> 35 36 #import <wtf/NeverDestroyed.h> 36 #import <wtf/SoftLinking.h>37 38 SOFT_LINK_FRAMEWORK_OPTIONAL(GameController)39 SOFT_LINK_CLASS_OPTIONAL(GameController, GCController);40 SOFT_LINK_CONSTANT_MAY_FAIL(GameController, GCControllerDidConnectNotification, NSString *)41 SOFT_LINK_CONSTANT_MAY_FAIL(GameController, GCControllerDidDisconnectNotification, NSString *)42 37 43 38 namespace WebCore { … … 107 102 return; 108 103 109 if (canLoad GCControllerDidConnectNotification()) {110 m_connectObserver = [[NSNotificationCenter defaultCenter] addObserverForName:get GCControllerDidConnectNotification() object:nil queue:nil usingBlock:^(NSNotification *notification) {104 if (canLoad_GameController_GCControllerDidConnectNotification()) { 105 m_connectObserver = [[NSNotificationCenter defaultCenter] addObserverForName:get_GameController_GCControllerDidConnectNotification() object:nil queue:nil usingBlock:^(NSNotification *notification) { 111 106 GameControllerGamepadProvider::singleton().controllerDidConnect(notification.object, ConnectionVisibility::Visible); 112 107 }]; 113 108 } 114 109 115 if (canLoad GCControllerDidDisconnectNotification()) {116 m_disconnectObserver = [[NSNotificationCenter defaultCenter] addObserverForName:get GCControllerDidDisconnectNotification() object:nil queue:nil usingBlock:^(NSNotification *notification) {110 if (canLoad_GameController_GCControllerDidDisconnectNotification()) { 111 m_disconnectObserver = [[NSNotificationCenter defaultCenter] addObserverForName:get_GameController_GCControllerDidDisconnectNotification() object:nil queue:nil usingBlock:^(NSNotification *notification) { 117 112 GameControllerGamepadProvider::singleton().controllerDidDisconnect(notification.object); 118 113 }];
Note:
See TracChangeset
for help on using the changeset viewer.