use a material design
allows resetting the emulator
This commit is contained in:
@@ -1,21 +1,58 @@
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:keepScreenOn="true"
|
||||
android:orientation="vertical"
|
||||
tools:context="com.vsmartcard.remotesmartcardreader.app.MainActivity">
|
||||
android:fitsSystemWindows="true"
|
||||
tools:context="com.vsmartcard.smartcardemulator.MainActivity">
|
||||
|
||||
<ScrollView
|
||||
<android.support.design.widget.AppBarLayout
|
||||
android:id="@+id/app_bar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:id="@+id/scrollView">
|
||||
<TextView
|
||||
android:layout_height="@dimen/app_bar_height"
|
||||
android:fitsSystemWindows="true"
|
||||
android:theme="@style/AppTheme.AppBarOverlay">
|
||||
|
||||
<android.support.design.widget.CollapsingToolbarLayout
|
||||
android:id="@+id/toolbar_layout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:textAppearance="?android:attr/textAppearanceSmall"
|
||||
android:id="@+id/textViewLog"
|
||||
android:typeface="monospace" />
|
||||
</ScrollView>
|
||||
android:fitsSystemWindows="true"
|
||||
app:contentScrim="?attr/colorPrimary"
|
||||
app:layout_scrollFlags="scroll|exitUntilCollapsed">
|
||||
|
||||
</LinearLayout>
|
||||
<android.support.v7.widget.Toolbar
|
||||
android:id="@+id/toolbar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="?attr/actionBarSize"
|
||||
app:layout_collapseMode="pin"
|
||||
app:popupTheme="@style/AppTheme.PopupOverlay" />
|
||||
|
||||
</android.support.design.widget.CollapsingToolbarLayout>
|
||||
</android.support.design.widget.AppBarLayout>
|
||||
|
||||
<android.support.v4.widget.NestedScrollView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_behavior="@string/appbar_scrolling_view_behavior"
|
||||
tools:context="com.vsmartcard.remotesmartcardreader.app.MainActivity"
|
||||
tools:showIn="@layout/activity_main">
|
||||
<TextView
|
||||
android:layout_margin="@dimen/text_margin"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:id="@+id/textViewLog" />
|
||||
</android.support.v4.widget.NestedScrollView>
|
||||
|
||||
<android.support.design.widget.FloatingActionButton
|
||||
android:id="@+id/fab"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_margin="@dimen/fab_margin"
|
||||
android:src="@mipmap/ic_reset"
|
||||
app:layout_anchor="@id/app_bar"
|
||||
app:layout_anchorGravity="bottom|end" />
|
||||
|
||||
</android.support.design.widget.CoordinatorLayout>
|
||||
BIN
ACardEmulator/app/src/main/res/mipmap-hdpi/ic_reset.png
Normal file
BIN
ACardEmulator/app/src/main/res/mipmap-hdpi/ic_reset.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 598 B |
BIN
ACardEmulator/app/src/main/res/mipmap-mdpi/ic_reset.png
Normal file
BIN
ACardEmulator/app/src/main/res/mipmap-mdpi/ic_reset.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 390 B |
BIN
ACardEmulator/app/src/main/res/mipmap-xhdpi/ic_reset.png
Normal file
BIN
ACardEmulator/app/src/main/res/mipmap-xhdpi/ic_reset.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 842 B |
BIN
ACardEmulator/app/src/main/res/mipmap-xxhdpi/ic_reset.png
Normal file
BIN
ACardEmulator/app/src/main/res/mipmap-xxhdpi/ic_reset.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.5 KiB |
BIN
ACardEmulator/app/src/main/res/mipmap-xxxhdpi/ic_reset.png
Normal file
BIN
ACardEmulator/app/src/main/res/mipmap-xxxhdpi/ic_reset.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.3 KiB |
6
ACardEmulator/app/src/main/res/values/colors.xml
Normal file
6
ACardEmulator/app/src/main/res/values/colors.xml
Normal file
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<color name="colorPrimary">#3F51B5</color>
|
||||
<color name="colorPrimaryDark">#303F9F</color>
|
||||
<color name="colorAccent">#fdd017</color>
|
||||
</resources>
|
||||
@@ -1,6 +1,5 @@
|
||||
<resources>
|
||||
<!-- Default screen margins, per the Android Design guidelines. -->
|
||||
<dimen name="activity_horizontal_margin">16dp</dimen>
|
||||
<dimen name="activity_vertical_margin">16dp</dimen>
|
||||
|
||||
</resources>
|
||||
<dimen name="app_bar_height">180dp</dimen>
|
||||
<dimen name="fab_margin">16dp</dimen>
|
||||
<dimen name="text_margin">16dp</dimen>
|
||||
</resources>
|
||||
|
||||
@@ -3,6 +3,18 @@
|
||||
<!-- Base application theme. -->
|
||||
<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">
|
||||
<!-- Customize your theme here. -->
|
||||
<item name="colorPrimary">@color/colorPrimary</item>
|
||||
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
|
||||
<item name="colorAccent">@color/colorAccent</item>
|
||||
</style>
|
||||
|
||||
<style name="AppTheme.NoActionBar">
|
||||
<item name="windowActionBar">false</item>
|
||||
<item name="windowNoTitle">true</item>
|
||||
</style>
|
||||
|
||||
<style name="AppTheme.AppBarOverlay" parent="ThemeOverlay.AppCompat.Dark.ActionBar" />
|
||||
|
||||
<style name="AppTheme.PopupOverlay" parent="ThemeOverlay.AppCompat.Light" />
|
||||
|
||||
</resources>
|
||||
|
||||
Reference in New Issue
Block a user