summaryrefslogtreecommitdiff
path: root/apple_remote
diff options
context:
space:
mode:
authorDouglas Mencken <dougmencken@gmail.com>2016-03-03 06:57:58 -0500
committerStephan Bergmann <sbergman@redhat.com>2016-03-07 15:36:38 +0000
commit487ba71c9ea30fe3b77dfc15e86d67f44c7cc79a (patch)
treea96d493116c29a11afd14dc5ee610cb5a648dec2 /apple_remote
parent884151214add5b476bffb8c6037a92db3ca9d0b1 (diff)
apple_remote: fix “variable set but not used” for non-debug builds
Change-Id: I038fd0bee0e983a91557226aaba1dcff56512ccb Reviewed-on: https://gerrit.libreoffice.org/22856 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'apple_remote')
-rw-r--r--apple_remote/source/RemoteMainController.m8
1 files changed, 5 insertions, 3 deletions
diff --git a/apple_remote/source/RemoteMainController.m b/apple_remote/source/RemoteMainController.m
index 82dd05512d25..1972c5fc523f 100644
--- a/apple_remote/source/RemoteMainController.m
+++ b/apple_remote/source/RemoteMainController.m
@@ -102,15 +102,15 @@
- (void) remoteButton: (RemoteControlEventIdentifier)buttonIdentifier pressedDown: (BOOL) pressedDown clickCount: (unsigned int)clickCount
{
(void)clickCount;
- NSString* pressed = @"";
#ifdef DEBUG
+ NSString* pressed = @"";
NSString* buttonName = nil;
#endif
if (pressedDown)
{
+#ifdef DEBUG
pressed = @"(AppleRemoteMainController: button pressed)";
-#ifdef DEBUG
switch(buttonIdentifier)
{
case kRemoteButtonPlus: buttonName = @"Volume up"; break; // MEDIA_COMMAND_VOLUME_UP ( see include/vcl/commandevent.hxx )
@@ -134,14 +134,16 @@
}
else // not pressed
{
+#ifdef DEBUG
pressed = @"(AppleRemoteMainController: button released)";
+#endif
}
#ifdef DEBUG
//NSLog(@"Button %@ pressed %@", buttonName, pressed);
NSString* clickCountString = @"";
if (clickCount > 1) clickCountString = [NSString stringWithFormat: @"%d clicks", clickCount];
- NSString* feedbackString = [NSString stringWithFormat:@"(Value:%4d) %@ %@ %@",buttonIdentifier, buttonName, pressed, clickCountString];
+ NSString* feedbackString = [NSString stringWithFormat:@"(Value:%4d) %@ %@ %@", buttonIdentifier, buttonName, pressed, clickCountString];
// print out events
NSLog(@"%@", feedbackString);