diff options
author | Philipp Hofer <philipp.hofer@protonmail.com> | 2020-11-09 18:55:36 +0100 |
---|---|---|
committer | Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> | 2020-11-16 12:29:44 +0100 |
commit | 03e79e8ab515e061fbfc435e6660e1f57b4f460d (patch) | |
tree | 6faf6bc44939164e798bc687b9ae50264134f135 /apple_remote | |
parent | cb0630df7f32232bb3c51c464c28dcc66cdf7729 (diff) |
tdf#123936 Formatting files in module apple_remote with clang-format
Change-Id: Ifd469bf8348c3f35222a2cfae13c66bc444ec1b6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105489
Tested-by: Jenkins
Reviewed-by: Christian Lohmaier <lohmaier+LibreOffice@googlemail.com>
Diffstat (limited to 'apple_remote')
-rw-r--r-- | apple_remote/source/AppleRemote.h | 3 | ||||
-rw-r--r-- | apple_remote/source/GlobalKeyboardDevice.h | 16 | ||||
-rw-r--r-- | apple_remote/source/HIDRemoteControlDevice.h | 21 | ||||
-rw-r--r-- | apple_remote/source/KeyspanFrontRowControl.h | 4 | ||||
-rw-r--r-- | apple_remote/source/MultiClickRemoteBehavior.h | 32 | ||||
-rw-r--r-- | apple_remote/source/RemoteControlContainer.h | 7 |
6 files changed, 44 insertions, 39 deletions
diff --git a/apple_remote/source/AppleRemote.h b/apple_remote/source/AppleRemote.h index f80431bfacbf..a4d6337a641b 100644 --- a/apple_remote/source/AppleRemote.h +++ b/apple_remote/source/AppleRemote.h @@ -36,7 +36,8 @@ /* Interacts with the Apple Remote Control HID device The class is not thread safe */ -@interface AppleRemote : HIDRemoteControlDevice { +@interface AppleRemote : HIDRemoteControlDevice +{ } @end diff --git a/apple_remote/source/GlobalKeyboardDevice.h b/apple_remote/source/GlobalKeyboardDevice.h index 752b1eecf8c2..97f3eec7ebcb 100644 --- a/apple_remote/source/GlobalKeyboardDevice.h +++ b/apple_remote/source/GlobalKeyboardDevice.h @@ -33,23 +33,23 @@ #import <Carbon/Carbon.h> - /* This class registers for a number of global keyboard shortcuts to simulate a remote control */ -@interface GlobalKeyboardDevice : RemoteControl { - +@interface GlobalKeyboardDevice : RemoteControl +{ NSMutableDictionary* hotKeyRemoteEventMapping; EventHandlerRef eventHandlerRef; - } -- (void) mapRemoteButton: (RemoteControlEventIdentifier) remoteButtonIdentifier defaultKeycode: (unsigned int) defaultKeycode defaultModifiers: (unsigned int) defaultModifiers; - -- (BOOL)registerHotKeyCode: (unsigned int) keycode modifiers: (unsigned int) modifiers remoteEventIdentifier: (RemoteControlEventIdentifier) identifier; - +- (void)mapRemoteButton:(RemoteControlEventIdentifier)remoteButtonIdentifier + defaultKeycode:(unsigned int)defaultKeycode + defaultModifiers:(unsigned int)defaultModifiers; +- (BOOL)registerHotKeyCode:(unsigned int)keycode + modifiers:(unsigned int)modifiers + remoteEventIdentifier:(RemoteControlEventIdentifier)identifier; @end diff --git a/apple_remote/source/HIDRemoteControlDevice.h b/apple_remote/source/HIDRemoteControlDevice.h index 3f56870579c7..cf81fac85612 100644 --- a/apple_remote/source/HIDRemoteControlDevice.h +++ b/apple_remote/source/HIDRemoteControlDevice.h @@ -36,12 +36,13 @@ /* Base class for HID based remote control devices */ -@interface HIDRemoteControlDevice : RemoteControl { +@interface HIDRemoteControlDevice : RemoteControl +{ IOHIDDeviceInterface** hidDeviceInterface; // see IOKit/hid/IOHIDLib.h - IOHIDQueueInterface** queue; // IOKit/hid/IOHIDLib.h - NSMutableArray* allCookies; - NSMutableDictionary* cookieToButtonMapping; - CFRunLoopSourceRef eventSource; + IOHIDQueueInterface** queue; // IOKit/hid/IOHIDLib.h + NSMutableArray* allCookies; + NSMutableDictionary* cookieToButtonMapping; + CFRunLoopSourceRef eventSource; BOOL fixSecureEventInputBug; BOOL openInExclusiveMode; @@ -54,15 +55,15 @@ // may already be received which are put on a backlog. As soon as your main thread // has some spare time this backlog is processed and may flood your delegate with calls. // Backlog processing is turned off by default. -- (BOOL) processesBacklog; -- (void) setProcessesBacklog: (BOOL) value; +- (BOOL)processesBacklog; +- (void)setProcessesBacklog:(BOOL)value; // methods that should be overwritten by subclasses -- (void) setCookieMappingInDictionary: (NSMutableDictionary*) cookieToButtonMapping; +- (void)setCookieMappingInDictionary:(NSMutableDictionary*)cookieToButtonMapping; -- (void) sendRemoteButtonEvent: (RemoteControlEventIdentifier) event pressedDown: (BOOL) pressedDown; +- (void)sendRemoteButtonEvent:(RemoteControlEventIdentifier)event pressedDown:(BOOL)pressedDown; -+ (BOOL) isRemoteAvailable; ++ (BOOL)isRemoteAvailable; @end diff --git a/apple_remote/source/KeyspanFrontRowControl.h b/apple_remote/source/KeyspanFrontRowControl.h index c75e86b08629..e7f8971fb47d 100644 --- a/apple_remote/source/KeyspanFrontRowControl.h +++ b/apple_remote/source/KeyspanFrontRowControl.h @@ -36,8 +36,8 @@ /* Interacts with the Keyspan FrontRow Remote Control HID device The class is not thread safe */ -@interface KeyspanFrontRowControl : HIDRemoteControlDevice { - +@interface KeyspanFrontRowControl : HIDRemoteControlDevice +{ } @end diff --git a/apple_remote/source/MultiClickRemoteBehavior.h b/apple_remote/source/MultiClickRemoteBehavior.h index 6a59c1f61442..a6d671d5285d 100644 --- a/apple_remote/source/MultiClickRemoteBehavior.h +++ b/apple_remote/source/MultiClickRemoteBehavior.h @@ -29,14 +29,14 @@ * *****************************************************************************/ - #import <apple_remote/RemoteControl.h> /** A behavior that adds multiclick and hold events on top of a device. Events are generated and send to a delegate */ -@interface MultiClickRemoteBehavior : NSObject { +@interface MultiClickRemoteBehavior : NSObject +{ id delegate; // state for simulating plus/minus hold @@ -53,17 +53,17 @@ unsigned int eventClickCount; } -- (id) init; +- (id)init; // Delegates are not retained -- (void) setDelegate: (id) delegate; -- (id) delegate; +- (void)setDelegate:(id)delegate; +- (id)delegate; // Simulating hold events does deactivate sending of individual requests for pressed down/released. // Instead special hold events are being triggered when the user is pressing and holding a button for a small period. // Simulation is activated only for those buttons and remote control that do not have a separate event already -- (BOOL) simulateHoldEvent; -- (void) setSimulateHoldEvent: (BOOL) value; +- (BOOL)simulateHoldEvent; +- (void)setSimulateHoldEvent:(BOOL)value; // click counting makes it possible to recognize if the user has pressed a button repeatedly // click counting does delay each event as it has to wait if there is another event (second click) @@ -71,24 +71,26 @@ // of the user and the call of your delegate method // click counting can be enabled individually for specific buttons. Use the property clickCountEnableButtons to // set the buttons for which click counting shall be enabled -- (BOOL) clickCountingEnabled; -- (void) setClickCountingEnabled: (BOOL) value; +- (BOOL)clickCountingEnabled; +- (void)setClickCountingEnabled:(BOOL)value; -- (unsigned int) clickCountEnabledButtons; -- (void) setClickCountEnabledButtons: (unsigned int)value; +- (unsigned int)clickCountEnabledButtons; +- (void)setClickCountEnabledButtons:(unsigned int)value; // the maximum time difference till which clicks are recognized as multi clicks -- (NSTimeInterval) maximumClickCountTimeDifference; -- (void) setMaximumClickCountTimeDifference: (NSTimeInterval) timeDiff; +- (NSTimeInterval)maximumClickCountTimeDifference; +- (void)setMaximumClickCountTimeDifference:(NSTimeInterval)timeDiff; @end /* * Method definitions for the delegate of the MultiClickRemoteBehavior class */ -@interface NSObject(MultiClickRemoteBehaviorDelegate) +@interface NSObject (MultiClickRemoteBehaviorDelegate) -- (void) remoteButton: (RemoteControlEventIdentifier)buttonIdentifier pressedDown: (BOOL) pressedDown clickCount: (unsigned int) count; +- (void)remoteButton:(RemoteControlEventIdentifier)buttonIdentifier + pressedDown:(BOOL)pressedDown + clickCount:(unsigned int)count; @end diff --git a/apple_remote/source/RemoteControlContainer.h b/apple_remote/source/RemoteControlContainer.h index c3361f45ebcc..93b1ab8ea8e6 100644 --- a/apple_remote/source/RemoteControlContainer.h +++ b/apple_remote/source/RemoteControlContainer.h @@ -31,12 +31,13 @@ #import <apple_remote/RemoteControl.h> -@interface RemoteControlContainer : RemoteControl { +@interface RemoteControlContainer : RemoteControl +{ NSMutableArray* remoteControls; } -- (BOOL) instantiateAndAddRemoteControlDeviceWithClass: (Class) clazz; -- (unsigned int) count; +- (BOOL)instantiateAndAddRemoteControlDeviceWithClass:(Class)clazz; +- (unsigned int)count; @end |