feature: reset app data

This commit is contained in:
imkiva
2018-09-10 23:13:06 +08:00
parent c92a4905fe
commit 01333a9343
10 changed files with 61 additions and 49 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 898 B

View File

@ -298,51 +298,80 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="center" android:layout_gravity="center"
android:layout_marginBottom="8dp" android:layout_marginBottom="8dp"
android:visibility="gone"
app:cardBackgroundColor="@color/list_download_item_color_dark" app:cardBackgroundColor="@color/list_download_item_color_dark"
app:cardUseCompatPadding="true"> app:cardUseCompatPadding="true">
<LinearLayout <LinearLayout
android:id="@+id/about_reset_app_view"
android:layout_width="fill_parent" android:layout_width="fill_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:background="?android:attr/selectableItemBackground" android:layout_marginBottom="8dp"
android:clickable="true" android:orientation="vertical">
android:focusable="true"
android:gravity="center_vertical"
android:minHeight="48dp"
android:orientation="horizontal"
android:paddingLeft="16dp"
android:paddingRight="16dp">
<ImageView
android:layout_width="24dp"
android:layout_height="24dp"
android:src="@drawable/ic_info" />
<LinearLayout <LinearLayout
android:layout_width="fill_parent" android:layout_width="fill_parent"
android:layout_height="wrap_content" android:layout_height="72dp"
android:layout_marginLeft="32dp" android:orientation="horizontal"
android:layout_marginStart="32dp" android:padding="16dp">
android:orientation="vertical"
android:paddingBottom="8dp" <ImageView
android:paddingTop="8dp"> android:layout_width="48dp"
android:layout_height="48dp"
android:layout_gravity="center_vertical"
android:scaleType="centerCrop"
android:src="@mipmap/ic_danger" />
<TextView <TextView
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="@string/about_reset_label" android:layout_gravity="center_vertical"
android:textAppearance="@style/TextAppearance.AppCompat.Subhead" /> android:paddingLeft="16dp"
android:paddingRight="16dp"
<TextView android:text="@string/app_name"
android:layout_width="wrap_content" android:textAppearance="@style/TextAppearance.AppCompat.Headline" />
android:layout_height="wrap_content"
android:text="@string/about_reset_label_desc"
android:textAppearance="@style/TextAppearance.AppCompat.Caption" />
</LinearLayout> </LinearLayout>
<LinearLayout
android:id="@+id/about_reset_app_view"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="?android:attr/selectableItemBackground"
android:clickable="true"
android:focusable="true"
android:gravity="center_vertical"
android:minHeight="48dp"
android:orientation="horizontal"
android:paddingLeft="16dp"
android:paddingRight="16dp">
<ImageView
android:layout_width="24dp"
android:layout_height="24dp"
android:src="@drawable/ic_info" />
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="32dp"
android:layout_marginStart="32dp"
android:orientation="vertical"
android:paddingBottom="8dp"
android:paddingTop="8dp">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/about_reset_label"
android:textAppearance="@style/TextAppearance.AppCompat.Subhead" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/about_reset_label_desc"
android:textAppearance="@style/TextAppearance.AppCompat.Caption" />
</LinearLayout>
</LinearLayout>
</LinearLayout> </LinearLayout>
</android.support.v7.widget.CardView> </android.support.v7.widget.CardView>

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

View File

@ -162,6 +162,7 @@
<string name="error_new_source_url">URL 不能为空</string> <string name="error_new_source_url">URL 不能为空</string>
<string name="error_new_source_repo">仓库 不能为空</string> <string name="error_new_source_repo">仓库 不能为空</string>
<string name="sorry_for_development">本功能仍在开发中,所以只能在 DEBUG 构建版本下使用。\n若想尝鲜请尝试联系开发者来成为测试者。</string> <string name="sorry_for_development">本功能仍在开发中,所以只能在 DEBUG 构建版本下使用。\n若想尝鲜请尝试联系开发者来成为测试者。</string>
<string name="dangerous_zone">危险区域</string>
<string-array name="color_item_names"> <string-array name="color_item_names">
<item>背景色</item> <item>背景色</item>

View File

@ -166,6 +166,7 @@
<string name="error_new_source_url">URL cannot be empty</string> <string name="error_new_source_url">URL cannot be empty</string>
<string name="error_new_source_repo">Repo cannot be empty</string> <string name="error_new_source_repo">Repo cannot be empty</string>
<string name="sorry_for_development">This feature is still under development so it is only available on DEBUG builds.\n</string> <string name="sorry_for_development">This feature is still under development so it is only available on DEBUG builds.\n</string>
<string name="dangerous_zone">Dangerous Zone</string>
<string name="default_source_url">http://193.112.47.241</string> <string name="default_source_url">http://193.112.47.241</string>

View File

@ -37,25 +37,6 @@
android:targetPackage="io.neoterm" /> android:targetPackage="io.neoterm" />
</Preference> </Preference>
<!--
<Preference
android:icon="@drawable/ic_guide_white_36dp"
android:key="@string/discovery"
android:title="@string/discovery">
<intent
android:targetClass="io.neotermshowConfirmDialogetup.SetupActivity"
android:targetPackage="io.neoterm" />
</Preference>
-->
<!--<Preference-->
<!--android:icon="@drawable/ic_info_white_36dp"-->
<!--android:title="@string/faq" >-->
<!--<intent-->
<!--android:targetClass="io.neoterm.ui.support.HelpActivity"-->
<!--android:targetPackage="io.neoterm" />-->
<!--</Preference>-->
<Preference <Preference
android:icon="@drawable/ic_info_white_36dp" android:icon="@drawable/ic_info_white_36dp"
android:title="@string/about" > android:title="@string/about" >