Skip to content
This repository was archived by the owner on Nov 9, 2017. It is now read-only.

Commit

Permalink
Fixed iOS compilation issues
Browse files Browse the repository at this point in the history
  • Loading branch information
whs committed May 5, 2016
1 parent bc84162 commit 6165bf5
Show file tree
Hide file tree
Showing 6 changed files with 60 additions and 34 deletions.
22 changes: 11 additions & 11 deletions components/Layout/view.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,34 +18,34 @@ var styles = StyleSheet.create({
item: {
flex: 1,
padding: 10,
height: 50,
justifyContent: 'center',
},
});

export default class ImagePicker extends Component {
render(){
let current = this.props.route.slide.layout;
return (
<View style={{flexDirection: 'column'}}>
<View style={{flexDirection: 'column', flex: 1}}>
<NavBar style={NavBarStyle}>
<NavButton onPress={this._onPreviousButton}><Image style={NavBarStyle.navIcon} source={require('../ic_navigate_before_white.png')} /></NavButton>
<NavTitle style={NavBarStyle.title}>Layout</NavTitle>
<NavGroup />
</NavBar>
<View style={styles.row}>
<TouchableFeedback onPress={this.onChoose(0)}><View style={styles.item}><Text>Top left</Text></View></TouchableFeedback>
<TouchableFeedback onPress={this.onChoose(1)}><View style={styles.item}><Text style={{textAlign: 'center'}}>Top center</Text></View></TouchableFeedback>
<TouchableFeedback onPress={this.onChoose(2)}><View style={styles.item}><Text style={{textAlign: 'right'}}>Top right</Text></View></TouchableFeedback>
<TouchableFeedback style={styles.item} onPress={this.onChoose(0)}><View style={styles.item}><Text>Top left</Text></View></TouchableFeedback>
<TouchableFeedback style={styles.item} onPress={this.onChoose(1)}><View style={styles.item}><Text style={{textAlign: 'center'}}>Top center</Text></View></TouchableFeedback>
<TouchableFeedback style={styles.item} onPress={this.onChoose(2)}><View style={styles.item}><Text style={{textAlign: 'right'}}>Top right</Text></View></TouchableFeedback>
</View>
<View style={styles.row}>
<TouchableFeedback onPress={this.onChoose(3)}><View style={styles.item}><Text>Middle left</Text></View></TouchableFeedback>
<TouchableFeedback onPress={this.onChoose(4)}><View style={styles.item}><Text style={{textAlign: 'center'}}>Middle center</Text></View></TouchableFeedback>
<TouchableFeedback onPress={this.onChoose(5)}><View style={styles.item}><Text style={{textAlign: 'right'}}>Middle right</Text></View></TouchableFeedback>
<TouchableFeedback style={styles.item} onPress={this.onChoose(3)}><View style={styles.item}><Text>Middle left</Text></View></TouchableFeedback>
<TouchableFeedback style={styles.item} onPress={this.onChoose(4)}><View style={styles.item}><Text style={{textAlign: 'center'}}>Middle center</Text></View></TouchableFeedback>
<TouchableFeedback style={styles.item} onPress={this.onChoose(5)}><View style={styles.item}><Text style={{textAlign: 'right'}}>Middle right</Text></View></TouchableFeedback>
</View>
<View style={styles.row}>
<TouchableFeedback onPress={this.onChoose(6)}><View style={styles.item}><Text>Bottom left</Text></View></TouchableFeedback>
<TouchableFeedback onPress={this.onChoose(7)}><View style={styles.item}><Text style={{textAlign: 'center'}}>Bottom center</Text></View></TouchableFeedback>
<TouchableFeedback onPress={this.onChoose(8)}><View style={styles.item}><Text style={{textAlign: 'right'}}>Bottom right</Text></View></TouchableFeedback>
<TouchableFeedback style={styles.item} onPress={this.onChoose(6)}><View style={styles.item}><Text>Bottom left</Text></View></TouchableFeedback>
<TouchableFeedback style={styles.item} onPress={this.onChoose(7)}><View style={styles.item}><Text style={{textAlign: 'center'}}>Bottom center</Text></View></TouchableFeedback>
<TouchableFeedback style={styles.item} onPress={this.onChoose(8)}><View style={styles.item}><Text style={{textAlign: 'right'}}>Bottom right</Text></View></TouchableFeedback>
</View>
</View>
)
Expand Down
4 changes: 2 additions & 2 deletions components/Slide/view.js
Original file line number Diff line number Diff line change
Expand Up @@ -102,12 +102,12 @@ export default class Slide extends Component {
<TextInput style={[styles.text1, styles.textEdit, {
color: this.props.slide.text1Color,
textAlign: textAlign,
width: size.width - 30,
height: 40,
}]} key="text1" value={this.state.text1} underlineColorAndroid="transparent" onChangeText={(text) => this.setState({text1: text})} />,
<TextInput style={[styles.text2, styles.textEdit, {
color: this.props.slide.text2Color,
textAlign: textAlign,
width: size.width - 30,
height: 40,
}]} key="text2" value={this.state.text2} underlineColorAndroid="transparent" onChangeText={(text) => this.setState({text2: text})} />
];
}else{
Expand Down
1 change: 1 addition & 0 deletions ios/Koan Deck
61 changes: 43 additions & 18 deletions ios/koandeck.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@
13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; };
13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; };
146834051AC3E58100842450 /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 146834041AC3E56700842450 /* libReact.a */; };
32904D0CFE024B09A25077CC /* libRealmReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 25CCC9171028478882ACD222 /* libRealmReact.a */; };
44639F57D9634963BEB36B6A /* libc++.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = BDB100F5F46A4FC1ACD8E370 /* libc++.tbd */; };
7DC7FF86D2DA46A6842754F1 /* libz.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = 98659FC36D8042E2964D4BF1 /* libz.tbd */; };
832341BD1AAA6AB300B99B32 /* libRCTText.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 832341B51AAA6A8300B99B32 /* libRCTText.a */; };
BEBFD3F81CA9504500B2BAD7 /* Orientation.m in Sources */ = {isa = PBXBuildFile; fileRef = BEBFD3F71CA9504500B2BAD7 /* Orientation.m */; };
32904D0CFE024B09A25077CC /* libRealmReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 25CCC9171028478882ACD222 /* libRealmReact.a */; };
44639F57D9634963BEB36B6A /* libc++.tbd in Resources */ = {isa = PBXBuildFile; fileRef = BDB100F5F46A4FC1ACD8E370 /* libc++.tbd */; };
7DC7FF86D2DA46A6842754F1 /* libz.tbd in Resources */ = {isa = PBXBuildFile; fileRef = 98659FC36D8042E2964D4BF1 /* libz.tbd */; };
/* End PBXBuildFile section */

/* Begin PBXContainerItemProxy section */
Expand Down Expand Up @@ -97,6 +97,13 @@
remoteGlobalIDString = 58B5119B1A9E6C1200147676;
remoteInfo = RCTText;
};
BEED3EC01CDBB89000464277 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = D1B66430C7024040B4FA45FA /* RealmReact.xcodeproj */;
proxyType = 2;
remoteGlobalIDString = F60690131CA2766F0003FB26;
remoteInfo = RealmReact;
};
/* End PBXContainerItemProxy section */

/* Begin PBXFileReference section */
Expand All @@ -118,14 +125,14 @@
13B07FB61A68108700A75B9A /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = koandeck/Info.plist; sourceTree = "<group>"; };
13B07FB71A68108700A75B9A /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = koandeck/main.m; sourceTree = "<group>"; };
146833FF1AC3E56700842450 /* React.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = React.xcodeproj; path = "../node_modules/react-native/React/React.xcodeproj"; sourceTree = "<group>"; };
25CCC9171028478882ACD222 /* libRealmReact.a */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = archive.ar; path = libRealmReact.a; sourceTree = "<group>"; };
78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTLinking.xcodeproj; path = "../node_modules/react-native/Libraries/LinkingIOS/RCTLinking.xcodeproj"; sourceTree = "<group>"; };
832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTText.xcodeproj; path = "../node_modules/react-native/Libraries/Text/RCTText.xcodeproj"; sourceTree = "<group>"; };
98659FC36D8042E2964D4BF1 /* libz.tbd */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libz.tbd; path = usr/lib/libz.tbd; sourceTree = SDKROOT; };
BDB100F5F46A4FC1ACD8E370 /* libc++.tbd */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = "libc++.tbd"; path = "usr/lib/libc++.tbd"; sourceTree = SDKROOT; };
BEBFD3F61CA9504500B2BAD7 /* Orientation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Orientation.h; sourceTree = "<group>"; };
BEBFD3F71CA9504500B2BAD7 /* Orientation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = Orientation.m; sourceTree = "<group>"; };
D1B66430C7024040B4FA45FA /* RealmReact.xcodeproj */ = {isa = PBXFileReference; name = "RealmReact.xcodeproj"; path = "../node_modules/realm/react-native/ios/RealmReact.xcodeproj"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = wrapper.pb-project; explicitFileType = undefined; includeInIndex = 0; };
25CCC9171028478882ACD222 /* libRealmReact.a */ = {isa = PBXFileReference; name = "libRealmReact.a"; path = "libRealmReact.a"; sourceTree = "<group>"; fileEncoding = undefined; lastKnownFileType = archive.ar; explicitFileType = undefined; includeInIndex = 0; };
BDB100F5F46A4FC1ACD8E370 /* libc++.tbd */ = {isa = PBXFileReference; name = "libc++.tbd"; path = "usr/lib/libc++.tbd"; sourceTree = SDKROOT; fileEncoding = undefined; lastKnownFileType = sourcecode.text-based-dylib-definition; explicitFileType = undefined; includeInIndex = 0; };
98659FC36D8042E2964D4BF1 /* libz.tbd */ = {isa = PBXFileReference; name = "libz.tbd"; path = "usr/lib/libz.tbd"; sourceTree = SDKROOT; fileEncoding = undefined; lastKnownFileType = sourcecode.text-based-dylib-definition; explicitFileType = undefined; includeInIndex = 0; };
D1B66430C7024040B4FA45FA /* RealmReact.xcodeproj */ = {isa = PBXFileReference; explicitFileType = undefined; fileEncoding = 9; includeInIndex = 0; lastKnownFileType = "wrapper.pb-project"; name = RealmReact.xcodeproj; path = "../node_modules/realm/react-native/ios/RealmReact.xcodeproj"; sourceTree = "<group>"; };
/* End PBXFileReference section */

/* Begin PBXFrameworksBuildPhase section */
Expand All @@ -144,8 +151,8 @@
00C302EA1ABCBA2D00DB3ED1 /* libRCTVibration.a in Frameworks */,
139FDEF61B0652A700C62182 /* libRCTWebSocket.a in Frameworks */,
32904D0CFE024B09A25077CC /* libRealmReact.a in Frameworks */,
44639F57D9634963BEB36B6A /* libc++.tbd in Resources */,
7DC7FF86D2DA46A6842754F1 /* libz.tbd in Resources */,
44639F57D9634963BEB36B6A /* libc++.tbd in Frameworks */,
7DC7FF86D2DA46A6842754F1 /* libz.tbd in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand Down Expand Up @@ -312,14 +319,21 @@
path = RCTOrientation;
sourceTree = "<group>";
};
BEED3EB31CDBB89000464277 /* Products */ = {
isa = PBXGroup;
children = (
BEED3EC11CDBB89000464277 /* libRealmReact.a */,
);
name = Products;
sourceTree = "<group>";
};
CB785603E47A489DA53253EE /* Frameworks */ = {
isa = PBXGroup;
children = (
BDB100F5F46A4FC1ACD8E370 /* libc++.tbd */,
98659FC36D8042E2964D4BF1 /* libz.tbd */,
);
name = Frameworks;
path = "";
sourceTree = "<group>";
};
/* End PBXGroup section */
Expand Down Expand Up @@ -409,6 +423,10 @@
ProductGroup = 146834001AC3E56700842450 /* Products */;
ProjectRef = 146833FF1AC3E56700842450 /* React.xcodeproj */;
},
{
ProductGroup = BEED3EB31CDBB89000464277 /* Products */;
ProjectRef = D1B66430C7024040B4FA45FA /* RealmReact.xcodeproj */;
},
);
projectRoot = "";
targets = (
Expand Down Expand Up @@ -488,6 +506,13 @@
remoteRef = 832341B41AAA6A8300B99B32 /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
BEED3EC11CDBB89000464277 /* libRealmReact.a */ = {
isa = PBXReferenceProxy;
fileType = archive.ar;
path = libRealmReact.a;
remoteRef = BEED3EC01CDBB89000464277 /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
/* End PBXReferenceProxy section */

/* Begin PBXResourcesBuildPhase section */
Expand Down Expand Up @@ -559,14 +584,14 @@
);
INFOPLIST_FILE = koandeck/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
OTHER_LDFLAGS = "-ObjC";
PRODUCT_BUNDLE_IDENTIFIER = th.in.whs.koandeck;
PRODUCT_NAME = "Koan Deck";
TARGETED_DEVICE_FAMILY = "1,2";
LIBRARY_SEARCH_PATHS = (
"$(inherited)",
"\"$(SRCROOT)/Koan Deck\"",
);
OTHER_LDFLAGS = "-ObjC";
PRODUCT_BUNDLE_IDENTIFIER = th.in.whs.koandeck;
PRODUCT_NAME = "Koan Deck";
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Debug;
};
Expand All @@ -583,14 +608,14 @@
);
INFOPLIST_FILE = koandeck/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
OTHER_LDFLAGS = "-ObjC";
PRODUCT_BUNDLE_IDENTIFIER = th.in.whs.koandeck;
PRODUCT_NAME = "Koan Deck";
TARGETED_DEVICE_FAMILY = "1,2";
LIBRARY_SEARCH_PATHS = (
"$(inherited)",
"\"$(SRCROOT)/Koan Deck\"",
);
OTHER_LDFLAGS = "-ObjC";
PRODUCT_BUNDLE_IDENTIFIER = th.in.whs.koandeck;
PRODUCT_NAME = "Koan Deck";
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Release;
};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
</AdditionalOptions>
</TestAction>
<LaunchAction
buildConfiguration = "Release"
buildConfiguration = "Debug"
selectedDebuggerIdentifier = ""
selectedLauncherIdentifier = "Xcode.IDEFoundation.Launcher.PosixSpawn"
launchStyle = "0"
Expand Down
4 changes: 2 additions & 2 deletions ios/koandeck/AppDelegate.m
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(
* on the same Wi-Fi network.
*/

// jsCodeLocation = [NSURL URLWithString:@"http://ushio.local:8081/index.ios.bundle?platform=ios&dev=true"];
jsCodeLocation = [NSURL URLWithString:@"http://ushio.local:8081/index.ios.bundle?platform=ios&dev=true"];

/**
* OPTION 2
Expand All @@ -41,7 +41,7 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(
* simulator in the "Release" build configuration.
*/

jsCodeLocation = [[NSBundle mainBundle] URLForResource:@"main" withExtension:@"jsbundle"];
// jsCodeLocation = [[NSBundle mainBundle] URLForResource:@"main" withExtension:@"jsbundle"];

RCTRootView *rootView = [[RCTRootView alloc] initWithBundleURL:jsCodeLocation
moduleName:@"koandeck"
Expand Down

0 comments on commit 6165bf5

Please sign in to comment.