Commit 765e8977 authored by yangwu.jia's avatar yangwu.jia

Page name modification

parent 608d0df3
......@@ -36,22 +36,13 @@
<activity
android:name=".FlutterPageActivity"
android:theme="@style/Theme.AppCompat"
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|layoutDirection|fontScale|screenLayout|density"
android:hardwareAccelerated="true"
android:windowSoftInputMode="adjustResize"/>
<activity
android:name="com.idlefish.flutterboost.containers.NewBoostFlutterActivity"
android:theme="@style/Theme.AppCompat"
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|layoutDirection|fontScale|screenLayout|density"
android:hardwareAccelerated="true"
android:windowSoftInputMode="adjustResize" >
<!--<meta-data android:name="io.flutter.embedding.android.SplashScreenDrawable" android:resource="@drawable/avd_hide_password"/>-->
<!--<meta-data android:name="io.flutter.embedding.android.SplashScreenDrawable" android:resource="@drawable/page_loading"/>-->
</activity>
<activity
......@@ -66,5 +57,6 @@
android:theme="@style/Theme.AppCompat"
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|layoutDirection|fontScale|screenLayout|density"
android:windowSoftInputMode="adjustResize"/>
</application>
</manifest>
......@@ -12,9 +12,12 @@ import java.util.Map;
public class PageRouter {
public final static Map<String, String> pageName = new HashMap<String, String>() {{
put("sample://first", "first");
put("sample://second", "second");
put("sample://tab", "tab");
put("first", "first");
put("second", "second");
put("tab", "tab");
put("sample://flutterPage", "flutterPage");
}};
......
......@@ -14,7 +14,7 @@ class FirstRouteWidget extends StatelessWidget {
child: Text('Open second route'),
onPressed: () {
print("open second page!");
FlutterBoost.singleton.open("sample://second").then((Map value) {
FlutterBoost.singleton.open("second").then((Map value) {
print(
"call me when page is finished. did recieve second route result $value");
});
......@@ -59,7 +59,7 @@ class TabRouteWidget extends StatelessWidget {
body: Center(
child: RaisedButton(
onPressed: () {
FlutterBoost.singleton.open("sample://second");
FlutterBoost.singleton.open("second");
},
child: Text('Open second route'),
),
......@@ -147,7 +147,7 @@ class _FlutterRouteWidgetState extends State<FlutterRouteWidget> {
///后面的参数会在native的IPlatform.startActivity方法回调中拼接到url的query部分。
///例如:sample://nativePage?aaa=bbb
onTap: () => FlutterBoost.singleton
.open("sample://first", urlParams: {
.open("first", urlParams: {
"query": {"aaa": "bbb"}
}),
),
......@@ -164,7 +164,7 @@ class _FlutterRouteWidgetState extends State<FlutterRouteWidget> {
///后面的参数会在native的IPlatform.startActivity方法回调中拼接到url的query部分。
///例如:sample://nativePage?aaa=bbb
onTap: () => FlutterBoost.singleton
.open("sample://second", urlParams: {
.open("second", urlParams: {
"query": {"aaa": "bbb"}
}),
),
......@@ -181,7 +181,7 @@ class _FlutterRouteWidgetState extends State<FlutterRouteWidget> {
///后面的参数会在native的IPlatform.startActivity方法回调中拼接到url的query部分。
///例如:sample://nativePage?aaa=bbb
onTap: () => FlutterBoost.singleton
.open("sample://tab", urlParams: {
.open("tab", urlParams: {
"query": {"aaa": "bbb"}
}),
),
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment