|
@@ -7,6 +7,7 @@ import {
|
7
|
7
|
Alert,
|
8
|
8
|
Platform
|
9
|
9
|
} from 'react-native';
|
|
10
|
+import {Navigation} from 'react-native-navigation';
|
10
|
11
|
|
11
|
12
|
export default class FirstTabScreen extends Component {
|
12
|
13
|
static navigatorButtons = {
|
|
@@ -26,14 +27,14 @@ export default class FirstTabScreen extends Component {
|
26
|
27
|
]
|
27
|
28
|
};
|
28
|
29
|
static navigatorStyle = {
|
29
|
|
- navBarBackgroundColor: '#4dbce9',
|
30
|
|
- navBarTextColor: '#ffff00',
|
31
|
|
- navBarSubtitleTextColor: '#ff0000',
|
32
|
|
- navBarButtonColor: '#ffffff',
|
33
|
|
- statusBarTextColorScheme: 'light',
|
34
|
|
- tabBarBackgroundColor: '#4dbce9',
|
35
|
|
- tabBarButtonColor: '#ffffff',
|
36
|
|
- tabBarSelectedButtonColor: '#ffff00'
|
|
30
|
+ navBarBackgroundColor: '#4dbce9',
|
|
31
|
+ navBarTextColor: '#ffff00',
|
|
32
|
+ navBarSubtitleTextColor: '#ff0000',
|
|
33
|
+ navBarButtonColor: '#ffffff',
|
|
34
|
+ statusBarTextColorScheme: 'light',
|
|
35
|
+ tabBarBackgroundColor: '#4dbce9',
|
|
36
|
+ tabBarButtonColor: '#ffffff',
|
|
37
|
+ tabBarSelectedButtonColor: '#ffff00'
|
37
|
38
|
};
|
38
|
39
|
|
39
|
40
|
constructor(props) {
|
|
@@ -85,6 +86,10 @@ export default class FirstTabScreen extends Component {
|
85
|
86
|
<Text style={styles.button}>Show In-App Notification</Text>
|
86
|
87
|
</TouchableOpacity> : false
|
87
|
88
|
}
|
|
89
|
+
|
|
90
|
+ <TouchableOpacity onPress={ this.onStartSingleScreenApp.bind(this) }>
|
|
91
|
+ <Text style={styles.button}>Show Single Screen App</Text>
|
|
92
|
+ </TouchableOpacity>
|
88
|
93
|
</View>
|
89
|
94
|
);
|
90
|
95
|
}
|
|
@@ -124,6 +129,14 @@ export default class FirstTabScreen extends Component {
|
124
|
129
|
screen: "example.NotificationScreen"
|
125
|
130
|
});
|
126
|
131
|
}
|
|
132
|
+
|
|
133
|
+ onStartSingleScreenApp() {
|
|
134
|
+ Navigation.startSingleScreenApp({
|
|
135
|
+ screen: {
|
|
136
|
+ screen: 'example.FirstTabScreen'
|
|
137
|
+ }
|
|
138
|
+ });
|
|
139
|
+ }
|
127
|
140
|
}
|
128
|
141
|
|
129
|
142
|
const styles = StyleSheet.create({
|