Skip to content

Commit 3bb000d

Browse files
author
Pavlo Aksonov
committed
fix example
1 parent c6c002d commit 3bb000d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+41
-47
lines changed

example/.buckconfig

100644100755
File mode changed.

example/.flowconfig

100644100755
File mode changed.

example/.gitignore

100644100755
File mode changed.

example/.watchmanconfig

100644100755
File mode changed.

example/ExtraScreen.js

100644100755
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ var {
1616
TextInput
1717
} = ReactNative;
1818

19-
var Controllers = require('react-native-controllers');
19+
var Controllers = require('react-native-ios-controllers');
2020
const {NavigationToolBarIOS} = Controllers;
2121
var {height, width} = Dimensions.get('window');
2222

example/FavoritesScreen.js

100644100755
Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ var {
1414
NativeAppEventEmitter
1515
} = ReactNative;
1616

17-
var Controllers = require('react-native-controllers');
17+
var Controllers = require('react-native-ios-controllers');
1818

1919
var FavoritesScreen = React.createClass({
2020

@@ -45,9 +45,7 @@ var FavoritesScreen = React.createClass({
4545
</TouchableOpacity>
4646
}
4747

48-
<TouchableOpacity onPress={ ()=> Controllers.CubeBarControllerIOS("main").switchTo({
49-
tabIndex: 0
50-
}) }>
48+
<TouchableOpacity onPress={ this.onButtonClick.bind(this, 'plain') }>
5149
<Text style={styles.button}>Push Plain Screen</Text>
5250
</TouchableOpacity>
5351

example/LightBox.js

100644100755
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ var {
1111
Dimensions
1212
} = ReactNative;
1313

14-
var Controllers = require('react-native-controllers');
14+
var Controllers = require('react-native-ios-controllers');
1515
var {
1616
Modal,
1717
} = Controllers;

example/ModalScreen.js

100644100755
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ var {
1010
TouchableOpacity
1111
} = ReactNative;
1212

13-
var Controllers = require('react-native-controllers');
13+
var Controllers = require('react-native-ios-controllers');
1414
var {
1515
Modal,
1616
ControllerRegistry

example/MoreDrawerOptionsScreen.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ var {
1313

1414
require('./LightBox');
1515

16-
var Controllers = require('react-native-controllers');
16+
var Controllers = require('react-native-ios-controllers');
1717
var {
1818
Modal,
1919
ControllerRegistry,

example/MovieListScreen.js

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ var {
1313
require('./LightBox');
1414
require('./Notification');
1515

16-
var Controllers = require('react-native-controllers');
16+
var Controllers = require('react-native-ios-controllers');
1717
var {
1818
Modal,
1919
ControllerRegistry,
@@ -106,10 +106,7 @@ var MovieListScreen = React.createClass({
106106
There's a right and a left side menu in this example. Control the side menu animation using the options below:
107107
</Text>
108108

109-
<TouchableOpacity onPress={ ()=> Controllers.CubeBarControllerIOS("main").switchTo({
110-
tabIndex: 1
111-
})}>
112-
109+
<TouchableOpacity onPress={ this.onButtonClick.bind(this, Constants.MMDRAWER_DOOR) } >
113110
<Text style={styles.button}>Door</Text>
114111
</TouchableOpacity>
115112

example/Notification.js

100644100755
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ var {
1212
Dimensions
1313
} = ReactNative;
1414

15-
var Controllers = require('react-native-controllers');
15+
var Controllers = require('react-native-ios-controllers');
1616
var {
1717
Notification,
1818
} = Controllers;

example/PushedModalScreen.js

100644100755
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ var {
1010
TouchableOpacity
1111
} = ReactNative;
1212

13-
var Controllers = require('react-native-controllers');
13+
var Controllers = require('react-native-ios-controllers');
1414
var {
1515
Modal
1616
} = Controllers;

example/PushedScreen.js

100644100755
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ var {
1010
TouchableOpacity
1111
} = ReactNative;
1212

13-
var Controllers = require('react-native-controllers');
13+
var Controllers = require('react-native-ios-controllers');
1414

1515
var PushedScreen = React.createClass({
1616

example/README.md

100644100755
File mode changed.

example/SearchScreen.js

100644100755
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ var {
1111
TouchableOpacity
1212
} = ReactNative;
1313

14-
var Controllers = require('react-native-controllers');
14+
var Controllers = require('react-native-ios-controllers');
1515
var { Modal } = Controllers;
1616

1717
var badgeCounter = 1;

example/SideMenu.js

100644100755
File mode changed.

example/StyledTabScreen.js

100644100755
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ var {
99
View
1010
} = ReactNative;
1111

12-
var Controllers = require('react-native-controllers');
12+
var Controllers = require('react-native-ios-controllers');
1313
var {
1414
Modal,
1515
ControllerRegistry

example/android/app/BUCK

100644100755
File mode changed.

example/android/app/build.gradle

100644100755
File mode changed.

example/android/app/proguard-rules.pro

100644100755
File mode changed.

example/android/app/react.gradle

100644100755
File mode changed.

example/android/app/src/main/AndroidManifest.xml

100644100755
File mode changed.

example/android/app/src/main/java/com/controllersexample/MainActivity.java

100644100755
File mode changed.

example/android/app/src/main/java/com/controllersexample/MainApplication.java

100644100755
File mode changed.

example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png

100644100755
File mode changed.

example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png

100644100755
File mode changed.

example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png

100644100755
File mode changed.

example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png

100644100755
File mode changed.

example/android/app/src/main/res/values/strings.xml

100644100755
File mode changed.

example/android/app/src/main/res/values/styles.xml

100644100755
File mode changed.

example/android/build.gradle

100644100755
File mode changed.

example/android/gradle.properties

100644100755
File mode changed.

example/android/gradle/wrapper/gradle-wrapper.jar

100644100755
File mode changed.

example/android/gradle/wrapper/gradle-wrapper.properties

100644100755
File mode changed.

example/android/gradlew.bat

100644100755
File mode changed.

example/android/settings.gradle

100644100755
File mode changed.

example/img/colors.png

100644100755
File mode changed.

example/img/[email protected]

100644100755
File mode changed.

example/img/[email protected]

100644100755
File mode changed.

example/img/[email protected]

100644100755
File mode changed.

example/img/[email protected]

100644100755
File mode changed.

example/img/[email protected]

100644100755
File mode changed.

example/img/[email protected]

100644100755
File mode changed.

example/img/[email protected]

100644100755
File mode changed.

example/img/[email protected]

100644100755
File mode changed.

example/img/[email protected]

100644100755
File mode changed.

example/index.android.js

100644100755
File mode changed.

example/index.ios.js

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,14 @@
11
'use strict';
22

3-
var Controllers = require('react-native-controllers');
3+
var Controllers = require('react-native-ios-controllers');
44

55
var React = Controllers.hijackReact();
66
var {
77
ControllerRegistry,
88
TabBarControllerIOS,
99
NavigationControllerIOS,
1010
ViewControllerIOS,
11-
DrawerControllerIOS,
12-
CubeBarControllerIOS,
11+
DrawerControllerIOS
1312
} = React;
1413

1514
// require all top level react components you refer to in the layout
@@ -32,31 +31,31 @@ var MoviesApp = Controllers.createClass({
3231
type="MMDrawer"
3332
animationType="slide"
3433
style={{contentOverlayColor:'#162D3D55'}}>
35-
<CubeBarControllerIOS id="main">
36-
<CubeBarControllerIOS.Item title="Movies" icon={require('./img/home.png')} selectedIcon={require('./img/home_selected.png')}>
34+
<TabBarControllerIOS id="main">
35+
<TabBarControllerIOS.Item title="Movies" icon={require('./img/home.png')} selectedIcon={require('./img/home_selected.png')}>
3736
<NavigationControllerIOS
3837
title="Red Title"
3938
component="MovieListScreen"
4039
id="movies_nav"
4140
style={{navBarTextColor: '#ff0000', drawUnderNavBar: false, drawUnderTabBar: true}}
4241
/>
43-
</CubeBarControllerIOS.Item>
44-
<CubeBarControllerIOS.Item title="Favorites" icon={require('./img/star.png')} selectedIcon={require('./img/star_selected.png')}>
42+
</TabBarControllerIOS.Item>
43+
<TabBarControllerIOS.Item title="Favorites" icon={require('./img/star.png')} selectedIcon={require('./img/star_selected.png')}>
4544
<NavigationControllerIOS
4645
title="Favorites"
4746
component="FavoritesScreen"
4847
id="favorites_nav"
4948
passProps={{hidePop: true}}
5049
style={{drawUnderNavBar: true, navBarTranslucent: true}}
5150
/>
52-
</CubeBarControllerIOS.Item>
53-
<CubeBarControllerIOS.Item title="Search" icon={require('./img/discover.png')} selectedIcon={require('./img/discover_selected.png')}>
51+
</TabBarControllerIOS.Item>
52+
<TabBarControllerIOS.Item title="Search" icon={require('./img/discover.png')} selectedIcon={require('./img/discover_selected.png')}>
5453
<ViewControllerIOS
5554
component="SearchScreen"
5655
style={{ drawUnderTabBar: true }}
5756
/>
58-
</CubeBarControllerIOS.Item>
59-
</CubeBarControllerIOS>
57+
</TabBarControllerIOS.Item>
58+
</TabBarControllerIOS>
6059
</DrawerControllerIOS>
6160
);
6261
}

example/ios/ControllersExample.xcodeproj/project.pbxproj

100644100755
Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; };
2323
146834051AC3E58100842450 /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 146834041AC3E56700842450 /* libReact.a */; };
2424
832341BD1AAA6AB300B99B32 /* libRCTText.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 832341B51AAA6A8300B99B32 /* libRCTText.a */; };
25-
CC8006F21C7FBB6B00A9E411 /* libReactNativeControllers.a in Frameworks */ = {isa = PBXBuildFile; fileRef = CC8006F11C7FBB3E00A9E411 /* libReactNativeControllers.a */; };
25+
874DDD941D7D75B00047A28E /* libReactNativeControllers.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 874DDD931D7D75880047A28E /* libReactNativeControllers.a */; };
2626
D82DBFAB1C886D4200E0E3BC /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 146834041AC3E56700842450 /* libReact.a */; };
2727
/* End PBXBuildFile section */
2828

@@ -104,9 +104,9 @@
104104
remoteGlobalIDString = 58B5119B1A9E6C1200147676;
105105
remoteInfo = RCTText;
106106
};
107-
CC8006F01C7FBB3E00A9E411 /* PBXContainerItemProxy */ = {
107+
874DDD921D7D75880047A28E /* PBXContainerItemProxy */ = {
108108
isa = PBXContainerItemProxy;
109-
containerPortal = CC8006E21C7FBB3E00A9E411 /* ReactNativeControllers.xcodeproj */;
109+
containerPortal = 874DDD8E1D7D75880047A28E /* ReactNativeControllers.xcodeproj */;
110110
proxyType = 2;
111111
remoteGlobalIDString = D8AFADBD1BEE6F3F00A4592D;
112112
remoteInfo = ReactNativeControllers;
@@ -135,7 +135,7 @@
135135
146833FF1AC3E56700842450 /* React.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = React.xcodeproj; path = "../node_modules/react-native/React/React.xcodeproj"; sourceTree = "<group>"; };
136136
78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTLinking.xcodeproj; path = "../node_modules/react-native/Libraries/LinkingIOS/RCTLinking.xcodeproj"; sourceTree = "<group>"; };
137137
832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTText.xcodeproj; path = "../node_modules/react-native/Libraries/Text/RCTText.xcodeproj"; sourceTree = "<group>"; };
138-
CC8006E21C7FBB3E00A9E411 /* ReactNativeControllers.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = ReactNativeControllers.xcodeproj; path = "../node_modules/react-native-controllers/ios/ReactNativeControllers.xcodeproj"; sourceTree = "<group>"; };
138+
874DDD8E1D7D75880047A28E /* ReactNativeControllers.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = ReactNativeControllers.xcodeproj; path = "../node_modules/react-native-ios-controllers/ios/ReactNativeControllers.xcodeproj"; sourceTree = "<group>"; };
139139
/* End PBXFileReference section */
140140

141141
/* Begin PBXFrameworksBuildPhase section */
@@ -151,7 +151,7 @@
151151
isa = PBXFrameworksBuildPhase;
152152
buildActionMask = 2147483647;
153153
files = (
154-
CC8006F21C7FBB6B00A9E411 /* libReactNativeControllers.a in Frameworks */,
154+
874DDD941D7D75B00047A28E /* libReactNativeControllers.a in Frameworks */,
155155
146834051AC3E58100842450 /* libReact.a in Frameworks */,
156156
00C302E51ABCBA2D00DB3ED1 /* libRCTActionSheet.a in Frameworks */,
157157
00C302E71ABCBA2D00DB3ED1 /* libRCTGeolocation.a in Frameworks */,
@@ -274,7 +274,7 @@
274274
832341AE1AAA6A7D00B99B32 /* Libraries */ = {
275275
isa = PBXGroup;
276276
children = (
277-
CC8006E21C7FBB3E00A9E411 /* ReactNativeControllers.xcodeproj */,
277+
874DDD8E1D7D75880047A28E /* ReactNativeControllers.xcodeproj */,
278278
146833FF1AC3E56700842450 /* React.xcodeproj */,
279279
00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */,
280280
00C302B51ABCB90400DB3ED1 /* RCTGeolocation.xcodeproj */,
@@ -318,10 +318,10 @@
318318
name = Products;
319319
sourceTree = "<group>";
320320
};
321-
CC8006E31C7FBB3E00A9E411 /* Products */ = {
321+
874DDD8F1D7D75880047A28E /* Products */ = {
322322
isa = PBXGroup;
323323
children = (
324-
CC8006F11C7FBB3E00A9E411 /* libReactNativeControllers.a */,
324+
874DDD931D7D75880047A28E /* libReactNativeControllers.a */,
325325
);
326326
name = Products;
327327
sourceTree = "<group>";
@@ -433,8 +433,8 @@
433433
ProjectRef = 146833FF1AC3E56700842450 /* React.xcodeproj */;
434434
},
435435
{
436-
ProductGroup = CC8006E31C7FBB3E00A9E411 /* Products */;
437-
ProjectRef = CC8006E21C7FBB3E00A9E411 /* ReactNativeControllers.xcodeproj */;
436+
ProductGroup = 874DDD8F1D7D75880047A28E /* Products */;
437+
ProjectRef = 874DDD8E1D7D75880047A28E /* ReactNativeControllers.xcodeproj */;
438438
},
439439
);
440440
projectRoot = "";
@@ -516,11 +516,11 @@
516516
remoteRef = 832341B41AAA6A8300B99B32 /* PBXContainerItemProxy */;
517517
sourceTree = BUILT_PRODUCTS_DIR;
518518
};
519-
CC8006F11C7FBB3E00A9E411 /* libReactNativeControllers.a */ = {
519+
874DDD931D7D75880047A28E /* libReactNativeControllers.a */ = {
520520
isa = PBXReferenceProxy;
521521
fileType = archive.ar;
522522
path = libReactNativeControllers.a;
523-
remoteRef = CC8006F01C7FBB3E00A9E411 /* PBXContainerItemProxy */;
523+
remoteRef = 874DDD921D7D75880047A28E /* PBXContainerItemProxy */;
524524
sourceTree = BUILT_PRODUCTS_DIR;
525525
};
526526
/* End PBXReferenceProxy section */
@@ -648,7 +648,7 @@
648648
"$(inherited)",
649649
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include,
650650
"$(SRCROOT)/../node_modules/react-native/React/**",
651-
"$(SRCROOT)/../node_modules/react-native-controllers/ios/**",
651+
"$(SRCROOT)/../node_modules/react-native-ios-controllers/ios/**",
652652
);
653653
INFOPLIST_FILE = ControllersExample/Info.plist;
654654
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
@@ -669,7 +669,7 @@
669669
"$(inherited)",
670670
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include,
671671
"$(SRCROOT)/../node_modules/react-native/React/**",
672-
"$(SRCROOT)/../node_modules/react-native-controllers/ios/**",
672+
"$(SRCROOT)/../node_modules/react-native-ios-controllers/ios/**",
673673
);
674674
INFOPLIST_FILE = ControllersExample/Info.plist;
675675
IPHONEOS_DEPLOYMENT_TARGET = 8.0;

example/ios/ControllersExample.xcodeproj/xcshareddata/xcschemes/ControllersExample.xcscheme

100644100755
File mode changed.

example/ios/ControllersExample/AppDelegate.h

100644100755
File mode changed.

example/ios/ControllersExample/AppDelegate.m

100644100755
File mode changed.

example/ios/ControllersExample/Base.lproj/LaunchScreen.xib

100644100755
File mode changed.

example/ios/ControllersExample/Images.xcassets/AppIcon.appiconset/Contents.json

100644100755
File mode changed.

example/ios/ControllersExample/Info.plist

100644100755
File mode changed.

example/ios/ControllersExample/main.m

100644100755
File mode changed.

example/ios/ControllersExampleTests/ControllersExampleTests.m

100644100755
File mode changed.

example/ios/ControllersExampleTests/Info.plist

100644100755
File mode changed.

example/package.json

100644100755
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@
88
"dependencies": {
99
"react-native": "0.31.0",
1010
"react": "15.2.1",
11-
"react-native-controllers": "file:../"
11+
"react-native-ios-controllers": "file:../"
1212
}
1313
}

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"type": "git",
88
"url": "git+https://github.com/aksonov/react-native-controllers.git"
99
},
10-
"version": "2.1.2.0",
10+
"version": "2.1.2",
1111
"description": "React Native iOS Controllers (fork of react-native-controllers)",
1212
"nativePackage": true,
1313
"bugs": {
@@ -18,8 +18,8 @@
1818
"author": "Tal Kol <[email protected]>",
1919
"license": "MIT",
2020
"peerDependencies": {
21-
"react-native": ">=0.25.1",
22-
"react": ">=0.14.5"
21+
"react-native": "0.31.0",
22+
"react": "15.2.1"
2323
},
2424
"directories": {
2525
"example": "example"

0 commit comments

Comments
 (0)