Commit 406661e3 authored by Max Lv's avatar Max Lv

Refine the layout

parent c87930b2
......@@ -44,7 +44,7 @@
<LinearLayout android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginTop="8dp"
android:layout_marginTop="4dp"
android:id="@+id/details">
<TextView android:id="@+id/address"
android:layout_width="match_parent"
......@@ -54,7 +54,7 @@
android:layout_weight="1"
android:maxLines="1"
android:ellipsize="end"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textAppearance="?android:attr/textAppearanceSmall"
android:textColor="?android:attr/textColorSecondary"/>
<TextView android:id="@+id/traffic"
android:layout_width="match_parent"
......@@ -64,7 +64,7 @@
android:layout_weight="1"
android:maxLines="1"
android:ellipsize="end"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textAppearance="?android:attr/textAppearanceSmall"
android:textColor="?android:attr/textColorSecondary"/>
</LinearLayout>
</LinearLayout>
......
......@@ -66,4 +66,5 @@ class GlobalConfigFragment extends PreferenceFragment {
progressDialog = null
}
}
}
......@@ -335,7 +335,11 @@ class MainActivity extends Activity with ServiceBoundContext with Drawer.OnDrawe
}
private def displayFragment(fragment: ToolbarFragment) {
getFragmentManager.beginTransaction().replace(R.id.content, fragment).commitAllowingStateLoss()
val transaction = getFragmentManager.beginTransaction().replace(R.id.content, fragment)
if (fragment != profilesFragment)
transaction.addToBackStack(null).commitAllowingStateLoss()
else
transaction.commitAllowingStateLoss()
drawer.closeDrawer()
}
......
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