From 839c5df887352651857067341632111dbe549d05 Mon Sep 17 00:00:00 2001 From: Siqi LIU Date: Sun, 15 Sep 2013 22:28:52 +0200 Subject: ad-hoc bug fixes to handle different notes format on Linux/OSX Change-Id: Ie7a229464fc51242291a87bf4a79c1c999a50124 --- ios/iosremote/en.lproj/iPad_autosize.storyboard | 2 -- ios/iosremote/iosremote.xcodeproj/project.pbxproj | 6 +++--- ios/iosremote/iosremote/AppDelegate.m | 2 +- ios/iosremote/iosremote/Communication/Client.m | 3 +-- .../iosremote/Communication/CommandInterpreter.m | 6 ++---- ios/iosremote/iosremote/Communication/SlideShow.m | 1 - ios/iosremote/iosremote/Timer.m | 5 ++++- ios/iosremote/iosremote/WTcontrol~ipad.png | Bin 105364 -> 146037 bytes ios/iosremote/iosremote/WTcontrol~iphone.png | Bin 245786 -> 253574 bytes .../iosremote/en.lproj/iPhone_autoSize.storyboard | 2 +- .../en.lproj/iPhone_autoSize_old.storyboard | 2 +- .../iosremote/fr.lproj/iPhone_autoSize.storyboard | 2 +- .../fr.lproj/iPhone_autoSize_old.storyboard | 2 +- .../zh-Hans.lproj/iPhone_autoSize.storyboard | 2 +- .../zh-Hans.lproj/iPhone_autoSize_old.storyboard | 2 +- 15 files changed, 17 insertions(+), 20 deletions(-) (limited to 'ios') diff --git a/ios/iosremote/en.lproj/iPad_autosize.storyboard b/ios/iosremote/en.lproj/iPad_autosize.storyboard index e7f2114217da..bbb392b64dec 100644 --- a/ios/iosremote/en.lproj/iPad_autosize.storyboard +++ b/ios/iosremote/en.lproj/iPad_autosize.storyboard @@ -648,9 +648,7 @@ - - diff --git a/ios/iosremote/iosremote.xcodeproj/project.pbxproj b/ios/iosremote/iosremote.xcodeproj/project.pbxproj index 301596815948..6459209cb1a1 100644 --- a/ios/iosremote/iosremote.xcodeproj/project.pbxproj +++ b/ios/iosremote/iosremote.xcodeproj/project.pbxproj @@ -1197,7 +1197,7 @@ 57C6E417175E06E800E8BC5F /* Release */ = { isa = XCBuildConfiguration; buildSettings = { - CODE_SIGN_IDENTITY = "iPhone Distribution"; + CODE_SIGN_IDENTITY = "iPhone Distribution: Siqi Liu (ECNT5P5MTW)"; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution: Siqi Liu (ECNT5P5MTW)"; GCC_PRECOMPILE_PREFIX_HEADER = YES; GCC_PREFIX_HEADER = "iosremote/iosremote-Prefix.pch"; @@ -1209,8 +1209,8 @@ "\"$(SRCROOT)/TestFlightSDK1.2.6\"", ); PRODUCT_NAME = "$(TARGET_NAME)"; - PROVISIONING_PROFILE = ""; - "PROVISIONING_PROFILE[sdk=iphoneos*]" = "475E6C52-939A-4B08-B811-6E62C19FE6A1"; + PROVISIONING_PROFILE = "AC7C4315-5B31-4056-8955-9B861DCF5F75"; + "PROVISIONING_PROFILE[sdk=iphoneos*]" = "AC7C4315-5B31-4056-8955-9B861DCF5F75"; SDKROOT = iphoneos; TARGETED_DEVICE_FAMILY = "1,2"; WRAPPER_EXTENSION = app; diff --git a/ios/iosremote/iosremote/AppDelegate.m b/ios/iosremote/iosremote/AppDelegate.m index 2b8f5eaa38c5..2a8937dc6bda 100644 --- a/ios/iosremote/iosremote/AppDelegate.m +++ b/ios/iosremote/iosremote/AppDelegate.m @@ -69,7 +69,7 @@ blue:((float)(rgbValue & 0xFF))/255.0 alpha:1.0] kCountDownTimerAutoStart = [[NSUserDefaults standardUserDefaults] boolForKey:@"TIMER_AUTO_START"]; kCountDownTimerVibration = [[NSUserDefaults standardUserDefaults] boolForKey:@"TIMER_VIBRATION"]; - NSLog(@"Setting kDefaultTimerWidget to %d", kDefaultTimerWidget); + NSLog(@"Setting kCountDownTimerDefaultDuration to %d", kCountDownTimerDefaultDuration); } - (void)applicationWillResignActive:(UIApplication *)application diff --git a/ios/iosremote/iosremote/Communication/Client.m b/ios/iosremote/iosremote/Communication/Client.m index 70aead015b35..6ab1954f9191 100644 --- a/ios/iosremote/iosremote/Communication/Client.m +++ b/ios/iosremote/iosremote/Communication/Client.m @@ -207,6 +207,7 @@ int count = 0; backgroundQueue = dispatch_queue_create("com.libreoffice.iosremote", DISPATCH_QUEUE_CONCURRENT); dispatch_async(backgroundQueue, ^(void) { NSArray *commands = [str componentsSeparatedByString:@"\n"]; + NSLog(@"Commands: %@", commands); [self.receiver parse:commands]; }); data = nil; @@ -223,9 +224,7 @@ int count = 0; if(self.inputStream == nil && self.outputStream == nil) return; [self stopConnectionTimeoutTimer]; -// NSLog(@"stream status i:%u o:%u", self.inputStream.streamStatus, self.outputStream.streamStatus); if ([self.inputStream streamStatus] != NSStreamStatusClosed) { -// NSLog(@"ci"); [self.inputStream close]; } else [self.inputStream removeFromRunLoop:[NSRunLoop currentRunLoop] forMode:NSDefaultRunLoopMode]; diff --git a/ios/iosremote/iosremote/Communication/CommandInterpreter.m b/ios/iosremote/iosremote/Communication/CommandInterpreter.m index 0eca4cd7199a..1a853edb1dd6 100644 --- a/ios/iosremote/iosremote/Communication/CommandInterpreter.m +++ b/ios/iosremote/iosremote/Communication/CommandInterpreter.m @@ -35,6 +35,7 @@ dispatch_queue_t backgroundQueue; // Received a set of instructions from server. - (void) parse:(NSArray*)command{ +// NSLog(@"Command : %@", command); uint marker = 0; if ([command count] == 0) { return; @@ -47,7 +48,6 @@ dispatch_queue_t backgroundQueue; marker = 2; } else if ([instruction isEqualToString:STATUS_PAIRING_PAIRED]){ -// NSLog(@"Paired command: %@", command); [[NSNotificationCenter defaultCenter] postNotificationName:STATUS_PAIRING_PAIRED object:nil]; marker = 2; @@ -86,7 +86,6 @@ dispatch_queue_t backgroundQueue; [[NSNotificationCenter defaultCenter] postNotificationName:MSG_SLIDE_CHANGED object:nil]; marker = 3; } else if ([instruction isEqualToString:@"slide_preview"]){ -// NSLog(@"Interpreter: slide_preview"); backgroundQueue = dispatch_queue_create("com.libreoffice.iosremote", NULL); dispatch_async(backgroundQueue, ^(void) { uint slideNumber = [[command objectAtIndex:1] integerValue]; @@ -96,13 +95,12 @@ dispatch_queue_t backgroundQueue; }); marker = 4; } else if ([instruction isEqualToString:@"slide_notes"]){ -// NSLog(@"Interpreter: slide_notes"); backgroundQueue = dispatch_queue_create("com.libreoffice.iosremote", NULL); uint slideNumber = [[command objectAtIndex:1] integerValue]; NSMutableString *notes = [[NSMutableString alloc] init]; for (int i = 2; i"]) { + if ([notes hasSuffix:@""] || [notes hasSuffix:@""]) { marker = i+2; break; } diff --git a/ios/iosremote/iosremote/Communication/SlideShow.m b/ios/iosremote/iosremote/Communication/SlideShow.m index 988af3ae4b6e..70d838e64506 100644 --- a/ios/iosremote/iosremote/Communication/SlideShow.m +++ b/ios/iosremote/iosremote/Communication/SlideShow.m @@ -147,7 +147,6 @@ NSString *sTitle; } - (void) putNotes: (NSString *)notes AtIndex: (uint) index{ -// NSLog(@"Put note into %u", index); [self.notesDictionary setObject:notes forKey:[NSNumber numberWithUnsignedInt:index]]; [[NSNotificationCenter defaultCenter] postNotificationName:@"storage_update_ready" object:nil diff --git a/ios/iosremote/iosremote/Timer.m b/ios/iosremote/iosremote/Timer.m index 3dc83e5a087b..5e7754857341 100644 --- a/ios/iosremote/iosremote/Timer.m +++ b/ios/iosremote/iosremote/Timer.m @@ -37,6 +37,7 @@ int vibrationCount; self.state = TIMER_STATE_CLEARED; self.set = NO; secondsLeft = kCountDownTimerDefaultDuration * 60; + initSecondsLeft = secondsLeft; return self; } @@ -54,6 +55,7 @@ int vibrationCount; self.timeLabel = timeLabel; [self setupActions]; + [self clear]; return self; } @@ -63,8 +65,9 @@ int vibrationCount; self.clearButton = (UIButton *)[[cell viewWithTag:9] viewWithTag:3]; self.setTimeButton = (UIButton *)[[cell viewWithTag:9] viewWithTag:4]; self.timeLabel = (UILabel *)[[cell viewWithTag:9] viewWithTag:1]; - + [self setupActions]; + [self clear]; } - (void) setupActions diff --git a/ios/iosremote/iosremote/WTcontrol~ipad.png b/ios/iosremote/iosremote/WTcontrol~ipad.png index 76de002faf93..7b97a6d532c5 100644 Binary files a/ios/iosremote/iosremote/WTcontrol~ipad.png and b/ios/iosremote/iosremote/WTcontrol~ipad.png differ diff --git a/ios/iosremote/iosremote/WTcontrol~iphone.png b/ios/iosremote/iosremote/WTcontrol~iphone.png index 0aa3dcf94a7b..139de227a311 100644 Binary files a/ios/iosremote/iosremote/WTcontrol~iphone.png and b/ios/iosremote/iosremote/WTcontrol~iphone.png differ diff --git a/ios/iosremote/iosremote/en.lproj/iPhone_autoSize.storyboard b/ios/iosremote/iosremote/en.lproj/iPhone_autoSize.storyboard index 4aa3253f8f1b..c0a604af9ff0 100644 --- a/ios/iosremote/iosremote/en.lproj/iPhone_autoSize.storyboard +++ b/ios/iosremote/iosremote/en.lproj/iPhone_autoSize.storyboard @@ -1,7 +1,7 @@ - + diff --git a/ios/iosremote/iosremote/en.lproj/iPhone_autoSize_old.storyboard b/ios/iosremote/iosremote/en.lproj/iPhone_autoSize_old.storyboard index 4aa3253f8f1b..c0a604af9ff0 100644 --- a/ios/iosremote/iosremote/en.lproj/iPhone_autoSize_old.storyboard +++ b/ios/iosremote/iosremote/en.lproj/iPhone_autoSize_old.storyboard @@ -1,7 +1,7 @@ - + diff --git a/ios/iosremote/iosremote/fr.lproj/iPhone_autoSize.storyboard b/ios/iosremote/iosremote/fr.lproj/iPhone_autoSize.storyboard index 82f9b94af373..832c7ae9f0e0 100644 --- a/ios/iosremote/iosremote/fr.lproj/iPhone_autoSize.storyboard +++ b/ios/iosremote/iosremote/fr.lproj/iPhone_autoSize.storyboard @@ -1,7 +1,7 @@ - + diff --git a/ios/iosremote/iosremote/fr.lproj/iPhone_autoSize_old.storyboard b/ios/iosremote/iosremote/fr.lproj/iPhone_autoSize_old.storyboard index 82f9b94af373..832c7ae9f0e0 100644 --- a/ios/iosremote/iosremote/fr.lproj/iPhone_autoSize_old.storyboard +++ b/ios/iosremote/iosremote/fr.lproj/iPhone_autoSize_old.storyboard @@ -1,7 +1,7 @@ - + diff --git a/ios/iosremote/iosremote/zh-Hans.lproj/iPhone_autoSize.storyboard b/ios/iosremote/iosremote/zh-Hans.lproj/iPhone_autoSize.storyboard index 1418c5a9ba82..81dd61476688 100644 --- a/ios/iosremote/iosremote/zh-Hans.lproj/iPhone_autoSize.storyboard +++ b/ios/iosremote/iosremote/zh-Hans.lproj/iPhone_autoSize.storyboard @@ -1,7 +1,7 @@ - + diff --git a/ios/iosremote/iosremote/zh-Hans.lproj/iPhone_autoSize_old.storyboard b/ios/iosremote/iosremote/zh-Hans.lproj/iPhone_autoSize_old.storyboard index 1418c5a9ba82..81dd61476688 100644 --- a/ios/iosremote/iosremote/zh-Hans.lproj/iPhone_autoSize_old.storyboard +++ b/ios/iosremote/iosremote/zh-Hans.lproj/iPhone_autoSize_old.storyboard @@ -1,7 +1,7 @@ - + -- cgit