summaryrefslogtreecommitdiff
path: root/ios
diff options
context:
space:
mode:
authorsiqi <me@siqi.fr>2013-06-04 13:41:55 +0200
committersiqi <me@siqi.fr>2013-06-04 13:49:13 +0200
commitee96b94dfb5f7957524f7b3e20eeed44de005b97 (patch)
tree28551f245f6b3a40e180cafeb48d4334e1e398a6 /ios
parentc40c00c1a3f33b1bda30342f2efa1b08626134d5 (diff)
initial commit
Diffstat (limited to 'ios')
-rw-r--r--ios/iosremote/Communication/.DS_Storebin0 -> 6148 bytes
-rw-r--r--ios/iosremote/Communication/Client.h24
-rw-r--r--ios/iosremote/Communication/Client.m139
-rw-r--r--ios/iosremote/Communication/CommunicationManager.h13
-rw-r--r--ios/iosremote/Communication/CommunicationManager.m13
-rw-r--r--ios/iosremote/Communication/Receiver.h13
-rw-r--r--ios/iosremote/Communication/Receiver.m13
-rw-r--r--ios/iosremote/Communication/Server.h23
-rw-r--r--ios/iosremote/Communication/Server.m36
-rw-r--r--ios/iosremote/iosremote.xcodeproj/project.pbxproj320
-rw-r--r--ios/iosremote/iosremote/Default-568h@2x.pngbin0 -> 18594 bytes
-rw-r--r--ios/iosremote/iosremote/Default.pngbin0 -> 6540 bytes
-rw-r--r--ios/iosremote/iosremote/Default@2x.pngbin0 -> 16107 bytes
-rw-r--r--ios/iosremote/iosremote/en.lproj/InfoPlist.strings2
-rw-r--r--ios/iosremote/iosremote/en.lproj/MainStoryboard_iPad.storyboard26
-rw-r--r--ios/iosremote/iosremote/en.lproj/MainStoryboard_iPhone.storyboard26
-rw-r--r--ios/iosremote/iosremote/iosremote-Info.plist49
-rw-r--r--ios/iosremote/iosremote/iosremote-Prefix.pch14
-rw-r--r--ios/iosremote/iosremote/libreoffice_sdremoteAppDelegate.h15
-rw-r--r--ios/iosremote/iosremote/libreoffice_sdremoteAppDelegate.m46
-rw-r--r--ios/iosremote/iosremote/libreoffice_sdremoteViewController.h13
-rw-r--r--ios/iosremote/iosremote/libreoffice_sdremoteViewController.m29
-rw-r--r--ios/iosremote/iosremote/main.m18
23 files changed, 832 insertions, 0 deletions
diff --git a/ios/iosremote/Communication/.DS_Store b/ios/iosremote/Communication/.DS_Store
new file mode 100644
index 000000000000..bbb5276d7d0d
--- /dev/null
+++ b/ios/iosremote/Communication/.DS_Store
Binary files differ
diff --git a/ios/iosremote/Communication/Client.h b/ios/iosremote/Communication/Client.h
new file mode 100644
index 000000000000..3827b2f33a8a
--- /dev/null
+++ b/ios/iosremote/Communication/Client.h
@@ -0,0 +1,24 @@
+//
+// Client.h
+//
+//
+// Created by Liu Siqi on 6/3/13.
+// Copyright (c) 2013 libreoffice. All rights reserved.
+//
+
+#import <Foundation/Foundation.h>
+#import "Server.h"
+#import "CommunicationManager.h"
+#import "Receiver.h"
+
+@interface Client : NSObject
+
+-(void) connect;
+
+- (id) initWithServer:(Server*)server
+ managedBy:(CommunicationManager*)manager
+ interpretedBy:(Receiver*)receiver;
+
+-(void)stream:(NSStream *)stream handleEvent:(NSStreamEvent)eventCode;
+
+@end \ No newline at end of file
diff --git a/ios/iosremote/Communication/Client.m b/ios/iosremote/Communication/Client.m
new file mode 100644
index 000000000000..b90c9d983a47
--- /dev/null
+++ b/ios/iosremote/Communication/Client.m
@@ -0,0 +1,139 @@
+//
+// Client.m
+// sdremote
+//
+// Created by Liu Siqi on 6/3/13.
+// Copyright (c) 2013 libreoffice. All rights reserved.
+//
+
+#import "Client.h"
+#import "Server.h"
+#import "Receiver.h"
+#import "CommunicationManager.h"
+
+@interface Client() <NSStreamDelegate>
+
+@property (nonatomic, strong) NSInputStream* mInputStream;
+@property (nonatomic, strong) NSOutputStream* mOutputStream;
+
+@property (nonatomic, strong) NSString* mPin;
+@property (nonatomic, strong) NSString* mName;
+@property uint mPort;
+
+@property (nonatomic, weak) Server* mServer;
+@property (nonatomic, weak) Receiver* mReceiver;
+@property (nonatomic, weak) CommunicationManager* mComManager;
+
+@property (nonatomic, retain) NSMutableData* mData;
+
+@property BOOL mReady;
+
+@end
+
+
+
+@implementation Client
+
+@synthesize mInputStream = _mInputStream;
+@synthesize mOutputStream = _mOutputStream;
+@synthesize mPin = _mPin;
+@synthesize mName = _mName;
+@synthesize mServer = _mServer;
+@synthesize mComManager = _mComManager;
+@synthesize mData = _mData;
+@synthesize mReady = _mReady;
+
+NSString * const CHARSET = @"UTF-8";
+
+- (id) initWithServer:(Server*)server
+ managedBy:(CommunicationManager*)manager
+ interpretedBy:(Receiver*)receiver
+{
+ self.mPin = @"";
+ self.mName = server.serverName;
+ self.mComManager = manager;
+ self.mReceiver = receiver;
+ // hardcoded here to test the communication TODO
+ self.mPort = 1599;
+
+ return self;
+}
+
+- (void)streamOpenWithIp:(NSString *)ip withPortNumber:(uint)portNumber
+{
+ NSLog(@"Connecting to %@:%u", ip, portNumber);
+ CFReadStreamRef readStream;
+ CFWriteStreamRef writeStream;
+ CFStreamCreatePairWithSocketToHost(kCFAllocatorDefault, (__bridge CFStringRef)ip, portNumber, &readStream, &writeStream);
+
+ if(readStream && writeStream)
+ {
+ CFReadStreamSetProperty(readStream, kCFStreamPropertyShouldCloseNativeSocket, kCFBooleanTrue);
+ CFWriteStreamSetProperty(writeStream, kCFStreamPropertyShouldCloseNativeSocket, kCFBooleanTrue);
+
+ //Setup mInputStream
+ self.mInputStream = (__bridge NSInputStream *)readStream;
+ [self.mInputStream setDelegate:self];
+ [self.mInputStream scheduleInRunLoop:[NSRunLoop currentRunLoop] forMode:NSDefaultRunLoopMode];
+ [self.mInputStream open];
+
+ //Setup outputstream
+ self.mOutputStream = (__bridge NSOutputStream *)writeStream;
+ [self.mOutputStream setDelegate:self];
+ [self.mOutputStream scheduleInRunLoop:[NSRunLoop currentRunLoop] forMode:NSDefaultRunLoopMode];
+ [self.mOutputStream open];
+ }
+ NSLog(@"Connected");
+}
+
+- (void) sendCommand:(NSString *)aCommand
+{
+ // UTF-8 as speficied in specification
+ NSData * data = [aCommand dataUsingEncoding:NSUTF8StringEncoding];
+
+ [self.mOutputStream write:(uint8_t *)[data bytes] maxLength:[data length]];
+}
+
+- (void)stream:(NSStream *)stream handleEvent:(NSStreamEvent)eventCode {
+
+ switch(eventCode) {
+ case NSStreamEventHasBytesAvailable:
+ {
+ if(!self.mData) {
+ self.mData = [NSMutableData data];
+ }
+ uint8_t buf[1024];
+ unsigned int len = 0;
+ len = [(NSInputStream *)stream read:buf maxLength:1024];
+ if(len) {
+ [self.mData appendBytes:(const void *)buf length:len];
+ int bytesRead = 0;
+ // bytesRead is an instance variable of type NSNumber.
+ bytesRead += len;
+ } else {
+ NSLog(@"No data but received event for whatever reasons!");
+ }
+
+ NSString *str = [[NSString alloc] initWithData:self.mData
+ encoding:NSUTF8StringEncoding];
+ NSLog(@"Data Received: %@", str);
+
+ self.mData = nil;
+ } break;
+ default:
+ {
+
+ }
+
+ }
+}
+
+
+- (void) connect
+{
+ [self streamOpenWithIp:self.mServer.serverAddress withPortNumber:self.mPort];
+}
+
+
+
+@end
diff --git a/ios/iosremote/Communication/CommunicationManager.h b/ios/iosremote/Communication/CommunicationManager.h
new file mode 100644
index 000000000000..d649e3c55beb
--- /dev/null
+++ b/ios/iosremote/Communication/CommunicationManager.h
@@ -0,0 +1,13 @@
+//
+// CommunicationManager.h
+// sdremote
+//
+// Created by Liu Siqi on 6/3/13.
+// Copyright (c) 2013 libreoffice. All rights reserved.
+//
+
+#import <Foundation/Foundation.h>
+
+@interface CommunicationManager : NSObject
+
+@end
diff --git a/ios/iosremote/Communication/CommunicationManager.m b/ios/iosremote/Communication/CommunicationManager.m
new file mode 100644
index 000000000000..c91b2f5e2ae6
--- /dev/null
+++ b/ios/iosremote/Communication/CommunicationManager.m
@@ -0,0 +1,13 @@
+//
+// CommunicationManager.m
+// sdremote
+//
+// Created by Liu Siqi on 6/3/13.
+// Copyright (c) 2013 libreoffice. All rights reserved.
+//
+
+#import "CommunicationManager.h"
+
+@implementation CommunicationManager
+
+@end
diff --git a/ios/iosremote/Communication/Receiver.h b/ios/iosremote/Communication/Receiver.h
new file mode 100644
index 000000000000..9889ec749577
--- /dev/null
+++ b/ios/iosremote/Communication/Receiver.h
@@ -0,0 +1,13 @@
+//
+// Receiver.h
+// sdremote
+//
+// Created by Liu Siqi on 6/3/13.
+// Copyright (c) 2013 libreoffice. All rights reserved.
+//
+
+#import <Foundation/Foundation.h>
+
+@interface Receiver : NSObject
+
+@end
diff --git a/ios/iosremote/Communication/Receiver.m b/ios/iosremote/Communication/Receiver.m
new file mode 100644
index 000000000000..30a48c675d68
--- /dev/null
+++ b/ios/iosremote/Communication/Receiver.m
@@ -0,0 +1,13 @@
+//
+// Receiver.m
+// sdremote
+//
+// Created by Liu Siqi on 6/3/13.
+// Copyright (c) 2013 libreoffice. All rights reserved.
+//
+
+#import "Receiver.h"
+
+@implementation Receiver
+
+@end
diff --git a/ios/iosremote/Communication/Server.h b/ios/iosremote/Communication/Server.h
new file mode 100644
index 000000000000..1cf483dd64b0
--- /dev/null
+++ b/ios/iosremote/Communication/Server.h
@@ -0,0 +1,23 @@
+//
+// Server.h
+// sdremote
+//
+// Created by Liu Siqi on 6/3/13.
+// Copyright (c) 2013 libreoffice. All rights reserved.
+//
+
+#import <Foundation/Foundation.h>
+
+typedef enum protocol {NETWORK} Protocol_t;
+
+@interface Server : NSObject
+
+@property (nonatomic) Protocol_t protocol;
+@property (nonatomic, strong) NSString* serverName;
+@property (nonatomic, strong) NSString* serverAddress;
+
+- (id)initWithProtocol:(Protocol_t)protocal
+ atAddress:(NSString*) address
+ ofName:(NSString*) name;
+
+@end
diff --git a/ios/iosremote/Communication/Server.m b/ios/iosremote/Communication/Server.m
new file mode 100644
index 000000000000..d7bf1adcf00c
--- /dev/null
+++ b/ios/iosremote/Communication/Server.m
@@ -0,0 +1,36 @@
+//
+// Server.m
+// sdremote
+//
+// Created by Liu Siqi on 6/3/13.
+// Copyright (c) 2013 libreoffice. All rights reserved.
+//
+
+#import "Server.h"
+
+@interface Server()
+
+@end
+
+@implementation Server
+
+@synthesize protocol = _protocol;
+@synthesize serverName = _serverName;
+@synthesize serverAddress = _serverAddress;
+
+- (id)initWithProtocol:(Protocol_t)protocal
+ atAddress:(NSString*) address
+ ofName:(NSString*) name
+{
+ self = [self init];
+ self.protocol = protocal;
+ self.serverAddress = address;
+ self.serverName = name;
+ return self;
+}
+
+- (NSString *)description{
+ return [NSString stringWithFormat:@"Server: Name:%@ Addr:%@", self.serverName, self.serverAddress];
+}
+
+@end
diff --git a/ios/iosremote/iosremote.xcodeproj/project.pbxproj b/ios/iosremote/iosremote.xcodeproj/project.pbxproj
new file mode 100644
index 000000000000..4a2aaa50217e
--- /dev/null
+++ b/ios/iosremote/iosremote.xcodeproj/project.pbxproj
@@ -0,0 +1,320 @@
+// !$*UTF8*$!
+{
+ archiveVersion = 1;
+ classes = {
+ };
+ objectVersion = 46;
+ objects = {
+
+/* Begin PBXBuildFile section */
+ 57C6E3F3175E06E800E8BC5F /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 57C6E3F2175E06E800E8BC5F /* UIKit.framework */; };
+ 57C6E3F5175E06E800E8BC5F /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 57C6E3F4175E06E800E8BC5F /* Foundation.framework */; };
+ 57C6E3F7175E06E800E8BC5F /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 57C6E3F6175E06E800E8BC5F /* CoreGraphics.framework */; };
+ 57C6E3FD175E06E800E8BC5F /* InfoPlist.strings in Resources */ = {isa = PBXBuildFile; fileRef = 57C6E3FB175E06E800E8BC5F /* InfoPlist.strings */; };
+ 57C6E3FF175E06E800E8BC5F /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 57C6E3FE175E06E800E8BC5F /* main.m */; };
+ 57C6E403175E06E800E8BC5F /* libreoffice_sdremoteAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 57C6E402175E06E800E8BC5F /* libreoffice_sdremoteAppDelegate.m */; };
+ 57C6E405175E06E800E8BC5F /* Default.png in Resources */ = {isa = PBXBuildFile; fileRef = 57C6E404175E06E800E8BC5F /* Default.png */; };
+ 57C6E407175E06E800E8BC5F /* Default@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 57C6E406175E06E800E8BC5F /* Default@2x.png */; };
+ 57C6E409175E06E800E8BC5F /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 57C6E408175E06E800E8BC5F /* Default-568h@2x.png */; };
+ 57C6E40C175E06E800E8BC5F /* MainStoryboard_iPhone.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 57C6E40A175E06E800E8BC5F /* MainStoryboard_iPhone.storyboard */; };
+ 57C6E40F175E06E800E8BC5F /* MainStoryboard_iPad.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 57C6E40D175E06E800E8BC5F /* MainStoryboard_iPad.storyboard */; };
+ 57C6E412175E06E800E8BC5F /* libreoffice_sdremoteViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 57C6E411175E06E800E8BC5F /* libreoffice_sdremoteViewController.m */; };
+/* End PBXBuildFile section */
+
+/* Begin PBXFileReference section */
+ 57C6E3EF175E06E800E8BC5F /* iosremote.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = iosremote.app; sourceTree = BUILT_PRODUCTS_DIR; };
+ 57C6E3F2175E06E800E8BC5F /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
+ 57C6E3F4175E06E800E8BC5F /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
+ 57C6E3F6175E06E800E8BC5F /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
+ 57C6E3FA175E06E800E8BC5F /* iosremote-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "iosremote-Info.plist"; sourceTree = "<group>"; };
+ 57C6E3FC175E06E800E8BC5F /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = "<group>"; };
+ 57C6E3FE175E06E800E8BC5F /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; };
+ 57C6E400175E06E800E8BC5F /* iosremote-Prefix.pch */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "iosremote-Prefix.pch"; sourceTree = "<group>"; };
+ 57C6E401175E06E800E8BC5F /* libreoffice_sdremoteAppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = libreoffice_sdremoteAppDelegate.h; sourceTree = "<group>"; };
+ 57C6E402175E06E800E8BC5F /* libreoffice_sdremoteAppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = libreoffice_sdremoteAppDelegate.m; sourceTree = "<group>"; };
+ 57C6E404175E06E800E8BC5F /* Default.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = Default.png; sourceTree = "<group>"; };
+ 57C6E406175E06E800E8BC5F /* Default@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default@2x.png"; sourceTree = "<group>"; };
+ 57C6E408175E06E800E8BC5F /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = "<group>"; };
+ 57C6E40B175E06E800E8BC5F /* en */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = en; path = en.lproj/MainStoryboard_iPhone.storyboard; sourceTree = "<group>"; };
+ 57C6E40E175E06E800E8BC5F /* en */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = en; path = en.lproj/MainStoryboard_iPad.storyboard; sourceTree = "<group>"; };
+ 57C6E410175E06E800E8BC5F /* libreoffice_sdremoteViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = libreoffice_sdremoteViewController.h; sourceTree = "<group>"; };
+ 57C6E411175E06E800E8BC5F /* libreoffice_sdremoteViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = libreoffice_sdremoteViewController.m; sourceTree = "<group>"; };
+/* End PBXFileReference section */
+
+/* Begin PBXFrameworksBuildPhase section */
+ 57C6E3EC175E06E800E8BC5F /* Frameworks */ = {
+ isa = PBXFrameworksBuildPhase;
+ buildActionMask = 2147483647;
+ files = (
+ 57C6E3F3175E06E800E8BC5F /* UIKit.framework in Frameworks */,
+ 57C6E3F5175E06E800E8BC5F /* Foundation.framework in Frameworks */,
+ 57C6E3F7175E06E800E8BC5F /* CoreGraphics.framework in Frameworks */,
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ };
+/* End PBXFrameworksBuildPhase section */
+
+/* Begin PBXGroup section */
+ 57C6E3E6175E06E800E8BC5F = {
+ isa = PBXGroup;
+ children = (
+ 57C6E3F8175E06E800E8BC5F /* iosremote */,
+ 57C6E3F1175E06E800E8BC5F /* Frameworks */,
+ 57C6E3F0175E06E800E8BC5F /* Products */,
+ );
+ sourceTree = "<group>";
+ };
+ 57C6E3F0175E06E800E8BC5F /* Products */ = {
+ isa = PBXGroup;
+ children = (
+ 57C6E3EF175E06E800E8BC5F /* iosremote.app */,
+ );
+ name = Products;
+ sourceTree = "<group>";
+ };
+ 57C6E3F1175E06E800E8BC5F /* Frameworks */ = {
+ isa = PBXGroup;
+ children = (
+ 57C6E3F2175E06E800E8BC5F /* UIKit.framework */,
+ 57C6E3F4175E06E800E8BC5F /* Foundation.framework */,
+ 57C6E3F6175E06E800E8BC5F /* CoreGraphics.framework */,
+ );
+ name = Frameworks;
+ sourceTree = "<group>";
+ };
+ 57C6E3F8175E06E800E8BC5F /* iosremote */ = {
+ isa = PBXGroup;
+ children = (
+ 57C6E401175E06E800E8BC5F /* libreoffice_sdremoteAppDelegate.h */,
+ 57C6E402175E06E800E8BC5F /* libreoffice_sdremoteAppDelegate.m */,
+ 57C6E40A175E06E800E8BC5F /* MainStoryboard_iPhone.storyboard */,
+ 57C6E40D175E06E800E8BC5F /* MainStoryboard_iPad.storyboard */,
+ 57C6E410175E06E800E8BC5F /* libreoffice_sdremoteViewController.h */,
+ 57C6E411175E06E800E8BC5F /* libreoffice_sdremoteViewController.m */,
+ 57C6E3F9175E06E800E8BC5F /* Supporting Files */,
+ );
+ path = iosremote;
+ sourceTree = "<group>";
+ };
+ 57C6E3F9175E06E800E8BC5F /* Supporting Files */ = {
+ isa = PBXGroup;
+ children = (
+ 57C6E3FA175E06E800E8BC5F /* iosremote-Info.plist */,
+ 57C6E3FB175E06E800E8BC5F /* InfoPlist.strings */,
+ 57C6E3FE175E06E800E8BC5F /* main.m */,
+ 57C6E400175E06E800E8BC5F /* iosremote-Prefix.pch */,
+ 57C6E404175E06E800E8BC5F /* Default.png */,
+ 57C6E406175E06E800E8BC5F /* Default@2x.png */,
+ 57C6E408175E06E800E8BC5F /* Default-568h@2x.png */,
+ );
+ name = "Supporting Files";
+ sourceTree = "<group>";
+ };
+/* End PBXGroup section */
+
+/* Begin PBXNativeTarget section */
+ 57C6E3EE175E06E800E8BC5F /* iosremote */ = {
+ isa = PBXNativeTarget;
+ buildConfigurationList = 57C6E415175E06E800E8BC5F /* Build configuration list for PBXNativeTarget "iosremote" */;
+ buildPhases = (
+ 57C6E3EB175E06E800E8BC5F /* Sources */,
+ 57C6E3EC175E06E800E8BC5F /* Frameworks */,
+ 57C6E3ED175E06E800E8BC5F /* Resources */,
+ );
+ buildRules = (
+ );
+ dependencies = (
+ );
+ name = iosremote;
+ productName = iosremote;
+ productReference = 57C6E3EF175E06E800E8BC5F /* iosremote.app */;
+ productType = "com.apple.product-type.application";
+ };
+/* End PBXNativeTarget section */
+
+/* Begin PBXProject section */
+ 57C6E3E7175E06E800E8BC5F /* Project object */ = {
+ isa = PBXProject;
+ attributes = {
+ CLASSPREFIX = libreoffice.sdremote;
+ LastUpgradeCheck = 0460;
+ ORGANIZATIONNAME = libreoffice;
+ };
+ buildConfigurationList = 57C6E3EA175E06E800E8BC5F /* Build configuration list for PBXProject "iosremote" */;
+ compatibilityVersion = "Xcode 3.2";
+ developmentRegion = English;
+ hasScannedForEncodings = 0;
+ knownRegions = (
+ en,
+ );
+ mainGroup = 57C6E3E6175E06E800E8BC5F;
+ productRefGroup = 57C6E3F0175E06E800E8BC5F /* Products */;
+ projectDirPath = "";
+ projectRoot = "";
+ targets = (
+ 57C6E3EE175E06E800E8BC5F /* iosremote */,
+ );
+ };
+/* End PBXProject section */
+
+/* Begin PBXResourcesBuildPhase section */
+ 57C6E3ED175E06E800E8BC5F /* Resources */ = {
+ isa = PBXResourcesBuildPhase;
+ buildActionMask = 2147483647;
+ files = (
+ 57C6E3FD175E06E800E8BC5F /* InfoPlist.strings in Resources */,
+ 57C6E405175E06E800E8BC5F /* Default.png in Resources */,
+ 57C6E407175E06E800E8BC5F /* Default@2x.png in Resources */,
+ 57C6E409175E06E800E8BC5F /* Default-568h@2x.png in Resources */,
+ 57C6E40C175E06E800E8BC5F /* MainStoryboard_iPhone.storyboard in Resources */,
+ 57C6E40F175E06E800E8BC5F /* MainStoryboard_iPad.storyboard in Resources */,
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ };
+/* End PBXResourcesBuildPhase section */
+
+/* Begin PBXSourcesBuildPhase section */
+ 57C6E3EB175E06E800E8BC5F /* Sources */ = {
+ isa = PBXSourcesBuildPhase;
+ buildActionMask = 2147483647;
+ files = (
+ 57C6E3FF175E06E800E8BC5F /* main.m in Sources */,
+ 57C6E403175E06E800E8BC5F /* libreoffice_sdremoteAppDelegate.m in Sources */,
+ 57C6E412175E06E800E8BC5F /* libreoffice_sdremoteViewController.m in Sources */,
+ );
+ runOnlyForDeploymentPostprocessing = 0;
+ };
+/* End PBXSourcesBuildPhase section */
+
+/* Begin PBXVariantGroup section */
+ 57C6E3FB175E06E800E8BC5F /* InfoPlist.strings */ = {
+ isa = PBXVariantGroup;
+ children = (
+ 57C6E3FC175E06E800E8BC5F /* en */,
+ );
+ name = InfoPlist.strings;
+ sourceTree = "<group>";
+ };
+ 57C6E40A175E06E800E8BC5F /* MainStoryboard_iPhone.storyboard */ = {
+ isa = PBXVariantGroup;
+ children = (
+ 57C6E40B175E06E800E8BC5F /* en */,
+ );
+ name = MainStoryboard_iPhone.storyboard;
+ sourceTree = "<group>";
+ };
+ 57C6E40D175E06E800E8BC5F /* MainStoryboard_iPad.storyboard */ = {
+ isa = PBXVariantGroup;
+ children = (
+ 57C6E40E175E06E800E8BC5F /* en */,
+ );
+ name = MainStoryboard_iPad.storyboard;
+ sourceTree = "<group>";
+ };
+/* End PBXVariantGroup section */
+
+/* Begin XCBuildConfiguration section */
+ 57C6E413175E06E800E8BC5F /* Debug */ = {
+ isa = XCBuildConfiguration;
+ buildSettings = {
+ ALWAYS_SEARCH_USER_PATHS = NO;
+ CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
+ CLANG_CXX_LIBRARY = "libc++";
+ CLANG_ENABLE_OBJC_ARC = YES;
+ CLANG_WARN_CONSTANT_CONVERSION = YES;
+ CLANG_WARN_EMPTY_BODY = YES;
+ CLANG_WARN_ENUM_CONVERSION = YES;
+ CLANG_WARN_INT_CONVERSION = YES;
+ CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
+ "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
+ COPY_PHASE_STRIP = NO;
+ GCC_C_LANGUAGE_STANDARD = gnu99;
+ GCC_DYNAMIC_NO_PIC = NO;
+ GCC_OPTIMIZATION_LEVEL = 0;
+ GCC_PREPROCESSOR_DEFINITIONS = (
+ "DEBUG=1",
+ "$(inherited)",
+ );
+ GCC_SYMBOLS_PRIVATE_EXTERN = NO;
+ GCC_WARN_ABOUT_RETURN_TYPE = YES;
+ GCC_WARN_UNINITIALIZED_AUTOS = YES;
+ GCC_WARN_UNUSED_VARIABLE = YES;
+ IPHONEOS_DEPLOYMENT_TARGET = 6.1;
+ ONLY_ACTIVE_ARCH = YES;
+ SDKROOT = iphoneos;
+ TARGETED_DEVICE_FAMILY = "1,2";
+ };
+ name = Debug;
+ };
+ 57C6E414175E06E800E8BC5F /* Release */ = {
+ isa = XCBuildConfiguration;
+ buildSettings = {
+ ALWAYS_SEARCH_USER_PATHS = NO;
+ CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
+ CLANG_CXX_LIBRARY = "libc++";
+ CLANG_ENABLE_OBJC_ARC = YES;
+ CLANG_WARN_CONSTANT_CONVERSION = YES;
+ CLANG_WARN_EMPTY_BODY = YES;
+ CLANG_WARN_ENUM_CONVERSION = YES;
+ CLANG_WARN_INT_CONVERSION = YES;
+ CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
+ "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
+ COPY_PHASE_STRIP = YES;
+ GCC_C_LANGUAGE_STANDARD = gnu99;
+ GCC_WARN_ABOUT_RETURN_TYPE = YES;
+ GCC_WARN_UNINITIALIZED_AUTOS = YES;
+ GCC_WARN_UNUSED_VARIABLE = YES;
+ IPHONEOS_DEPLOYMENT_TARGET = 6.1;
+ OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
+ SDKROOT = iphoneos;
+ TARGETED_DEVICE_FAMILY = "1,2";
+ VALIDATE_PRODUCT = YES;
+ };
+ name = Release;
+ };
+ 57C6E416175E06E800E8BC5F /* Debug */ = {
+ isa = XCBuildConfiguration;
+ buildSettings = {
+ GCC_PRECOMPILE_PREFIX_HEADER = YES;
+ GCC_PREFIX_HEADER = "iosremote/iosremote-Prefix.pch";
+ INFOPLIST_FILE = "iosremote/iosremote-Info.plist";
+ PRODUCT_NAME = "$(TARGET_NAME)";
+ WRAPPER_EXTENSION = app;
+ };
+ name = Debug;
+ };
+ 57C6E417175E06E800E8BC5F /* Release */ = {
+ isa = XCBuildConfiguration;
+ buildSettings = {
+ GCC_PRECOMPILE_PREFIX_HEADER = YES;
+ GCC_PREFIX_HEADER = "iosremote/iosremote-Prefix.pch";
+ INFOPLIST_FILE = "iosremote/iosremote-Info.plist";
+ PRODUCT_NAME = "$(TARGET_NAME)";
+ WRAPPER_EXTENSION = app;
+ };
+ name = Release;
+ };
+/* End XCBuildConfiguration section */
+
+/* Begin XCConfigurationList section */
+ 57C6E3EA175E06E800E8BC5F /* Build configuration list for PBXProject "iosremote" */ = {
+ isa = XCConfigurationList;
+ buildConfigurations = (
+ 57C6E413175E06E800E8BC5F /* Debug */,
+ 57C6E414175E06E800E8BC5F /* Release */,
+ );
+ defaultConfigurationIsVisible = 0;
+ defaultConfigurationName = Release;
+ };
+ 57C6E415175E06E800E8BC5F /* Build configuration list for PBXNativeTarget "iosremote" */ = {
+ isa = XCConfigurationList;
+ buildConfigurations = (
+ 57C6E416175E06E800E8BC5F /* Debug */,
+ 57C6E417175E06E800E8BC5F /* Release */,
+ );
+ defaultConfigurationIsVisible = 0;
+ };
+/* End XCConfigurationList section */
+ };
+ rootObject = 57C6E3E7175E06E800E8BC5F /* Project object */;
+}
diff --git a/ios/iosremote/iosremote/Default-568h@2x.png b/ios/iosremote/iosremote/Default-568h@2x.png
new file mode 100644
index 000000000000..0891b7aabfcf
--- /dev/null
+++ b/ios/iosremote/iosremote/Default-568h@2x.png
Binary files differ
diff --git a/ios/iosremote/iosremote/Default.png b/ios/iosremote/iosremote/Default.png
new file mode 100644
index 000000000000..4c8ca6f693f9
--- /dev/null
+++ b/ios/iosremote/iosremote/Default.png
Binary files differ
diff --git a/ios/iosremote/iosremote/Default@2x.png b/ios/iosremote/iosremote/Default@2x.png
new file mode 100644
index 000000000000..35b84cffeb4d
--- /dev/null
+++ b/ios/iosremote/iosremote/Default@2x.png
Binary files differ
diff --git a/ios/iosremote/iosremote/en.lproj/InfoPlist.strings b/ios/iosremote/iosremote/en.lproj/InfoPlist.strings
new file mode 100644
index 000000000000..477b28ff8f86
--- /dev/null
+++ b/ios/iosremote/iosremote/en.lproj/InfoPlist.strings
@@ -0,0 +1,2 @@
+/* Localized versions of Info.plist keys */
+
diff --git a/ios/iosremote/iosremote/en.lproj/MainStoryboard_iPad.storyboard b/ios/iosremote/iosremote/en.lproj/MainStoryboard_iPad.storyboard
new file mode 100644
index 000000000000..683f452fa7c3
--- /dev/null
+++ b/ios/iosremote/iosremote/en.lproj/MainStoryboard_iPad.storyboard
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="2.0" toolsVersion="2519" systemVersion="12A206j" targetRuntime="iOS.CocoaTouch.iPad" propertyAccessControl="none" useAutolayout="YES" initialViewController="2">
+ <dependencies>
+ <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="1856"/>
+ </dependencies>
+ <scenes>
+ <!--class Prefix:identifier View Controller-->
+ <scene sceneID="4">
+ <objects>
+ <viewController id="2" customClass="libreoffice_sdremoteViewController" sceneMemberID="viewController">
+ <view key="view" contentMode="scaleToFill" id="5">
+ <rect key="frame" x="0.0" y="20" width="768" height="1004"/>
+ <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
+ <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
+ </view>
+ </viewController>
+ <placeholder placeholderIdentifier="IBFirstResponder" id="3" sceneMemberID="firstResponder"/>
+ </objects>
+ </scene>
+ </scenes>
+ <simulatedMetricsContainer key="defaultSimulatedMetrics">
+ <simulatedStatusBarMetrics key="statusBar" statusBarStyle="blackTranslucent"/>
+ <simulatedOrientationMetrics key="orientation"/>
+ <simulatedScreenMetrics key="destination"/>
+ </simulatedMetricsContainer>
+</document> \ No newline at end of file
diff --git a/ios/iosremote/iosremote/en.lproj/MainStoryboard_iPhone.storyboard b/ios/iosremote/iosremote/en.lproj/MainStoryboard_iPhone.storyboard
new file mode 100644
index 000000000000..dd21c3188b1f
--- /dev/null
+++ b/ios/iosremote/iosremote/en.lproj/MainStoryboard_iPhone.storyboard
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="2.0" toolsVersion="2519" systemVersion="12A206j" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" initialViewController="2">
+ <dependencies>
+ <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="1856"/>
+ </dependencies>
+ <scenes>
+ <!--class Prefix:identifier View Controller-->
+ <scene sceneID="5">
+ <objects>
+ <viewController id="2" customClass="libreoffice_sdremoteViewController" sceneMemberID="viewController">
+ <view key="view" contentMode="scaleToFill" id="3">
+ <rect key="frame" x="0.0" y="20" width="320" height="460"/>
+ <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
+ <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
+ </view>
+ </viewController>
+ <placeholder placeholderIdentifier="IBFirstResponder" id="4" sceneMemberID="firstResponder"/>
+ </objects>
+ </scene>
+ </scenes>
+ <simulatedMetricsContainer key="defaultSimulatedMetrics">
+ <simulatedStatusBarMetrics key="statusBar"/>
+ <simulatedOrientationMetrics key="orientation"/>
+ <simulatedScreenMetrics key="destination" type="retina4"/>
+ </simulatedMetricsContainer>
+</document> \ No newline at end of file
diff --git a/ios/iosremote/iosremote/iosremote-Info.plist b/ios/iosremote/iosremote/iosremote-Info.plist
new file mode 100644
index 000000000000..f2b1ca676dd1
--- /dev/null
+++ b/ios/iosremote/iosremote/iosremote-Info.plist
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+<plist version="1.0">
+<dict>
+ <key>CFBundleDevelopmentRegion</key>
+ <string>en</string>
+ <key>CFBundleDisplayName</key>
+ <string>${PRODUCT_NAME}</string>
+ <key>CFBundleExecutable</key>
+ <string>${EXECUTABLE_NAME}</string>
+ <key>CFBundleIdentifier</key>
+ <string>org.libreoffice.${PRODUCT_NAME:rfc1034identifier}</string>
+ <key>CFBundleInfoDictionaryVersion</key>
+ <string>6.0</string>
+ <key>CFBundleName</key>
+ <string>${PRODUCT_NAME}</string>
+ <key>CFBundlePackageType</key>
+ <string>APPL</string>
+ <key>CFBundleShortVersionString</key>
+ <string>1.0</string>
+ <key>CFBundleSignature</key>
+ <string>????</string>
+ <key>CFBundleVersion</key>
+ <string>1.0</string>
+ <key>LSRequiresIPhoneOS</key>
+ <true/>
+ <key>UIMainStoryboardFile</key>
+ <string>MainStoryboard_iPhone</string>
+ <key>UIMainStoryboardFile~ipad</key>
+ <string>MainStoryboard_iPad</string>
+ <key>UIRequiredDeviceCapabilities</key>
+ <array>
+ <string>armv7</string>
+ </array>
+ <key>UISupportedInterfaceOrientations</key>
+ <array>
+ <string>UIInterfaceOrientationPortrait</string>
+ <string>UIInterfaceOrientationLandscapeLeft</string>
+ <string>UIInterfaceOrientationLandscapeRight</string>
+ </array>
+ <key>UISupportedInterfaceOrientations~ipad</key>
+ <array>
+ <string>UIInterfaceOrientationPortrait</string>
+ <string>UIInterfaceOrientationPortraitUpsideDown</string>
+ <string>UIInterfaceOrientationLandscapeLeft</string>
+ <string>UIInterfaceOrientationLandscapeRight</string>
+ </array>
+</dict>
+</plist>
diff --git a/ios/iosremote/iosremote/iosremote-Prefix.pch b/ios/iosremote/iosremote/iosremote-Prefix.pch
new file mode 100644
index 000000000000..b60bc65760ce
--- /dev/null
+++ b/ios/iosremote/iosremote/iosremote-Prefix.pch
@@ -0,0 +1,14 @@
+//
+// Prefix header for all source files of the 'iosremote' target in the 'iosremote' project
+//
+
+#import <Availability.h>
+
+#ifndef __IPHONE_5_0
+#warning "This project uses features only available in iOS SDK 5.0 and later."
+#endif
+
+#ifdef __OBJC__
+ #import <UIKit/UIKit.h>
+ #import <Foundation/Foundation.h>
+#endif
diff --git a/ios/iosremote/iosremote/libreoffice_sdremoteAppDelegate.h b/ios/iosremote/iosremote/libreoffice_sdremoteAppDelegate.h
new file mode 100644
index 000000000000..1507d06e0a0f
--- /dev/null
+++ b/ios/iosremote/iosremote/libreoffice_sdremoteAppDelegate.h
@@ -0,0 +1,15 @@
+//
+// libreoffice_sdremoteAppDelegate.h
+// iosremote
+//
+// Created by Liu Siqi on 6/4/13.
+// Copyright (c) 2013 libreoffice. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+@interface libreoffice_sdremoteAppDelegate : UIResponder <UIApplicationDelegate>
+
+@property (strong, nonatomic) UIWindow *window;
+
+@end
diff --git a/ios/iosremote/iosremote/libreoffice_sdremoteAppDelegate.m b/ios/iosremote/iosremote/libreoffice_sdremoteAppDelegate.m
new file mode 100644
index 000000000000..eab546142124
--- /dev/null
+++ b/ios/iosremote/iosremote/libreoffice_sdremoteAppDelegate.m
@@ -0,0 +1,46 @@
+//
+// libreoffice_sdremoteAppDelegate.m
+// iosremote
+//
+// Created by Liu Siqi on 6/4/13.
+// Copyright (c) 2013 libreoffice. All rights reserved.
+//
+
+#import "libreoffice_sdremoteAppDelegate.h"
+
+@implementation libreoffice_sdremoteAppDelegate
+
+- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
+{
+ // Override point for customization after application launch.
+ return YES;
+}
+
+- (void)applicationWillResignActive:(UIApplication *)application
+{
+ // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state.
+ // Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game.
+}
+
+- (void)applicationDidEnterBackground:(UIApplication *)application
+{
+ // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later.
+ // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
+}
+
+- (void)applicationWillEnterForeground:(UIApplication *)application
+{
+ // Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background.
+}
+
+- (void)applicationDidBecomeActive:(UIApplication *)application
+{
+ // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
+}
+
+- (void)applicationWillTerminate:(UIApplication *)application
+{
+ // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
+}
+
+@end
diff --git a/ios/iosremote/iosremote/libreoffice_sdremoteViewController.h b/ios/iosremote/iosremote/libreoffice_sdremoteViewController.h
new file mode 100644
index 000000000000..695964bd8610
--- /dev/null
+++ b/ios/iosremote/iosremote/libreoffice_sdremoteViewController.h
@@ -0,0 +1,13 @@
+//
+// libreoffice_sdremoteViewController.h
+// iosremote
+//
+// Created by Liu Siqi on 6/4/13.
+// Copyright (c) 2013 libreoffice. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+@interface libreoffice_sdremoteViewController : UIViewController
+
+@end
diff --git a/ios/iosremote/iosremote/libreoffice_sdremoteViewController.m b/ios/iosremote/iosremote/libreoffice_sdremoteViewController.m
new file mode 100644
index 000000000000..d6af7fe90a6d
--- /dev/null
+++ b/ios/iosremote/iosremote/libreoffice_sdremoteViewController.m
@@ -0,0 +1,29 @@
+//
+// libreoffice_sdremoteViewController.m
+// iosremote
+//
+// Created by Liu Siqi on 6/4/13.
+// Copyright (c) 2013 libreoffice. All rights reserved.
+//
+
+#import "libreoffice_sdremoteViewController.h"
+
+@interface libreoffice_sdremoteViewController ()
+
+@end
+
+@implementation libreoffice_sdremoteViewController
+
+- (void)viewDidLoad
+{
+ [super viewDidLoad];
+ // Do any additional setup after loading the view, typically from a nib.
+}
+
+- (void)didReceiveMemoryWarning
+{
+ [super didReceiveMemoryWarning];
+ // Dispose of any resources that can be recreated.
+}
+
+@end
diff --git a/ios/iosremote/iosremote/main.m b/ios/iosremote/iosremote/main.m
new file mode 100644
index 000000000000..126838a75b05
--- /dev/null
+++ b/ios/iosremote/iosremote/main.m
@@ -0,0 +1,18 @@
+//
+// main.m
+// iosremote
+//
+// Created by Liu Siqi on 6/4/13.
+// Copyright (c) 2013 libreoffice. All rights reserved.
+//
+
+#import <UIKit/UIKit.h>
+
+#import "libreoffice_sdremoteAppDelegate.h"
+
+int main(int argc, char *argv[])
+{
+ @autoreleasepool {
+ return UIApplicationMain(argc, argv, nil, NSStringFromClass([libreoffice_sdremoteAppDelegate class]));
+ }
+}