Browse Source

添加布局样式文件。

liuyuqi-dellpc 6 years ago
parent
commit
bcdd9467da

+ 223 - 19
app/src/main/res/layout/activity_main.xml

@@ -1,19 +1,223 @@
-<?xml version="1.0" encoding="utf-8"?>
-<android.support.constraint.ConstraintLayout
-    xmlns:android="http://schemas.android.com/apk/res/android"
-    xmlns:tools="http://schemas.android.com/tools"
-    xmlns:app="http://schemas.android.com/apk/res-auto"
-    android:layout_width="match_parent"
-    android:layout_height="match_parent"
-    tools:context="me.yoqi.app.wxredpacket.activities.MainActivity">
-
-    <TextView
-        android:layout_width="wrap_content"
-        android:layout_height="wrap_content"
-        android:text="Hello World!"
-        app:layout_constraintBottom_toBottomOf="parent"
-        app:layout_constraintLeft_toLeftOf="parent"
-        app:layout_constraintRight_toRightOf="parent"
-        app:layout_constraintTop_toTopOf="parent" />
-
-</android.support.constraint.ConstraintLayout>
+<RelativeLayout 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"
+                tools:context=".MainActivity"
+                android:background="#fff">
+    <ImageView
+            android:layout_width="fill_parent"
+            android:layout_height="0dp"
+            android:id="@+id/main_action_bar_placeholder"
+            android:layout_alignParentTop="true"
+            android:background="#E46C62"/>
+    <LinearLayout
+            android:orientation="vertical"
+            android:layout_width="match_parent"
+            android:layout_height="fill_parent"
+            android:id="@+id/layout_header"
+            android:layout_above="@+id/layout_control"
+            android:background="#E46C62"
+            android:layout_marginBottom="12dp">
+        <TextView
+                android:layout_width="fill_parent"
+                android:layout_height="wrap_content"
+                android:id="@+id/textView"
+                android:text="@string/app_name"
+                android:textColor="#fff"
+                android:gravity="center_vertical|center_horizontal"
+                android:textSize="28dp"
+                android:layout_marginTop="40dp"
+                android:textIsSelectable="false"/>
+        <TextView android:layout_width="fill_parent"
+                  android:layout_height="wrap_content"
+                  android:id="@+id/textView5"
+                  android:text="@string/app_version"
+                  android:textColor="#fff"
+                  android:gravity="center_vertical|center_horizontal"
+                  android:layout_marginTop="4dp"/>
+    </LinearLayout>
+    <ImageView
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:background="@mipmap/bg_snow"
+            android:id="@+id/main_bg_snow"
+            android:layout_alignBottom="@id/layout_header"/>
+    <LinearLayout android:id="@+id/layout_control"
+                  android:orientation="horizontal"
+                  android:layout_width="match_parent"
+                  android:layout_height="110dp"
+                  android:layout_above="@+id/layout_uber"
+                  android:layout_marginLeft="12dp"
+                  android:layout_marginRight="12dp"
+                  android:layout_marginTop="8dp"
+                  android:layout_marginBottom="8dp">
+        <LinearLayout style="?android:attr/borderlessButtonStyle"
+                      android:id="@+id/layout_control_community"
+                      android:layout_width="fill_parent"
+                      android:layout_height="fill_parent"
+                      android:background="#ffffff"
+                      android:textColor="#858585"
+                      android:layout_above="@+id/layout_uber"
+                      android:textSize="20dp"
+                      android:orientation="vertical"
+                      android:layout_weight="0.35"
+                      android:layout_marginRight="5dp"
+                      android:onClick="openGitHub">
+            <ImageView
+                    android:layout_width="24dp"
+                    android:layout_height="24dp"
+                    android:id="@+id/imageView"
+                    android:src="@mipmap/ic_community"
+                    android:layout_margin="10dp"/>
+            <TextView
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:text="@string/community"
+                    android:id="@+id/textView2"
+                    android:layout_margin="5dp"
+                    android:textColor="#858585" android:textSize="16sp" android:textStyle="bold"/>
+        </LinearLayout>
+        <LinearLayout
+                android:id="@+id/layout_control_accessibility"
+                android:layout_width="fill_parent"
+                android:layout_height="fill_parent"
+                android:onClick="openAccessibility"
+                android:background="#ffffff"
+                android:textColor="#858585"
+                style="?android:attr/borderlessButtonStyle"
+                android:layout_above="@+id/layout_uber"
+                android:textSize="20dp"
+                android:orientation="vertical"
+                android:layout_weight="0.3"
+                android:layout_marginRight="5dp"
+                android:layout_marginLeft="5dp">
+            <ImageView android:layout_width="32dp"
+                       android:layout_height="32dp"
+                       android:id="@+id/layout_control_accessibility_icon"
+                       android:layout_marginBottom="6dp"
+                       android:layout_marginTop="6dp"
+                       android:background="@mipmap/ic_start"/>
+            <TextView android:layout_width="wrap_content"
+                      android:layout_height="wrap_content"
+                      android:text="@string/service_on"
+                      android:id="@+id/layout_control_accessibility_text"
+                      android:layout_margin="5dp"
+                      android:textColor="#dfaa6a" android:textStyle="bold" android:textSize="16sp"/>
+        </LinearLayout>
+        <LinearLayout style="?android:attr/borderlessButtonStyle"
+                      android:id="@+id/layout_control_settings"
+                      android:layout_width="fill_parent"
+                      android:layout_height="fill_parent"
+                      android:background="#ffffff"
+                      android:textColor="#858585"
+                      android:layout_above="@+id/layout_uber"
+                      android:textSize="20dp"
+                      android:orientation="vertical"
+                      android:layout_weight="0.35"
+                      android:layout_marginLeft="5dp"
+                      android:onClick="openSettings">
+            <ImageView android:layout_width="24dp"
+                       android:layout_height="24dp"
+                       android:id="@+id/imageView4"
+                       android:layout_margin="10dp"
+                       android:src="@mipmap/ic_settings"/>
+            <TextView android:layout_width="wrap_content"
+                      android:layout_height="wrap_content"
+                      android:text="@string/settings"
+                      android:id="@+id/textView3"
+                      android:layout_margin="5dp"
+                      android:textColor="#858585" android:textSize="16sp" android:textStyle="bold"/>
+        </LinearLayout>
+    </LinearLayout>
+    <LinearLayout
+            android:id="@+id/layout_uber"
+            android:orientation="horizontal"
+            android:layout_width="match_parent"
+            android:layout_height="72dp"
+            android:layout_marginLeft="12dp"
+            android:layout_marginRight="12dp"
+            android:background="#ffffff"
+            android:layout_marginTop="8dp"
+            android:layout_alignParentBottom="false"
+            android:layout_above="@+id/linearLayout2"
+            android:layout_marginBottom="8dp"
+            android:onClick="openUber">
+        <ImageView
+                android:layout_width="60dp"
+                android:layout_height="60dp"
+                android:id="@+id/icon_uber"
+                android:src="@mipmap/ic_uber"
+                android:layout_marginLeft="8dp"
+                android:layout_marginRight="10dp"
+                android:layout_gravity="center_vertical"
+                android:layout_marginBottom="2dp"/>
+        <LinearLayout
+                android:orientation="vertical"
+                android:layout_width="match_parent"
+                android:layout_height="wrap_content"
+                android:id="@+id/layout_uber_text"
+                android:layout_gravity="center_vertical">
+            <TextView
+                    android:layout_width="wrap_content"
+                    android:layout_height="wrap_content"
+                    android:text="@string/uber_ad_title"
+                    android:id="@+id/label_uber_text"
+                    android:layout_margin="2dp"
+                    android:textColor="#858585"/>
+            <TextView android:layout_width="wrap_content"
+                      android:layout_height="wrap_content"
+                      android:text="@string/uber_ad_text"
+                      android:id="@+id/label_uber_link"
+                      android:layout_margin="2dp"
+                      android:textColor="#dfaa6a" android:textStyle="bold"/>
+        </LinearLayout>
+    </LinearLayout>
+    <LinearLayout android:id="@+id/linearLayout2"
+                  android:orientation="horizontal"
+                  android:layout_width="match_parent"
+                  android:layout_height="40dp"
+                  android:layout_marginLeft="12dp"
+                  android:layout_marginRight="12dp"
+                  android:background="#ffffff"
+                  android:layout_marginTop="8dp"
+                  android:layout_marginBottom="24dp"
+                  android:onClick="openGitHub"
+                  android:layout_alignParentBottom="true">
+        <ImageView android:layout_width="20dp"
+                   android:layout_height="20dp"
+                   android:id="@+id/imageView2"
+                   android:src="@mipmap/ic_github"
+                   android:layout_marginLeft="15dp"
+                   android:layout_marginRight="5dp"
+                   android:layout_gravity="center_vertical"/>
+        <TextView android:layout_width="wrap_content"
+                  android:layout_height="wrap_content"
+                  android:text="@string/github_1"
+                  android:id="@+id/textView6"
+                  android:layout_margin="2dp"
+                  android:textColor="#858585"
+                  android:layout_gravity="center_vertical"/>
+        <TextView android:layout_width="wrap_content"
+                  android:layout_height="wrap_content"
+                  android:text="@string/star_1"
+                  android:id="@+id/textView7"
+                  android:textColor="#dfaa6a"
+                  android:layout_gravity="center_vertical"
+                  android:paddingBottom="1dp"/>
+        <TextView android:layout_width="wrap_content"
+                  android:layout_height="wrap_content"
+                  android:id="@+id/textView8"
+                  android:text="@string/star_2"
+                  android:textColor="#dfaa6a"
+                  android:layout_gravity="center_vertical"
+                  android:layout_marginLeft="2dp"
+                  android:layout_marginRight="2dp" android:textStyle="bold"/>
+        <TextView android:layout_width="wrap_content"
+                  android:layout_height="wrap_content"
+                  android:text="@string/github_2"
+                  android:id="@+id/textView9"
+                  android:layout_margin="2dp"
+                  android:textColor="#858585"
+                  android:layout_gravity="center_vertical"/>
+    </LinearLayout>
+</RelativeLayout>

+ 42 - 0
app/src/main/res/layout/activity_preferences.xml

@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="utf-8"?>
+
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+              xmlns:tools="http://schemas.android.com/tools"
+              android:orientation="vertical"
+              android:layout_width="match_parent"
+              android:layout_height="match_parent">
+
+    <RelativeLayout android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:background="#E46C62"
+                    tools:context=".SettingsActivity"
+    >
+        <TextView android:layout_width="wrap_content" android:layout_height="54dp"
+                  android:id="@+id/settings_bar"
+                  android:text="@string/preference" android:textColor="#fff"
+                  android:gravity="left|center_vertical|center_horizontal"
+                  android:elegantTextHeight="false" android:textSize="18sp"
+                  android:layout_toRightOf="@+id/preference_back"
+        />
+        <ImageView
+                android:layout_width="40dp"
+                android:layout_height="match_parent"
+                android:id="@+id/preference_back"
+                android:layout_marginLeft="4dp"
+                android:layout_marginRight="4dp"
+                android:clickable="true" android:onClick="performBack"
+                android:layout_alignBottom="@+id/settings_bar"
+                android:src="@mipmap/ic_back" android:padding="10dp"/>
+        <ImageView android:layout_width="40dp" android:layout_height="match_parent" android:id="@+id/imageView3"
+                   android:clickable="true"
+                   android:onClick="enterAccessibilityPage"
+                   android:layout_alignParentRight="true"
+                   android:layout_marginRight="10dp" android:layout_marginLeft="8dp"
+                   android:padding="8dp" android:src="@mipmap/ic_refresh"
+                   android:layout_alignBottom="@+id/settings_bar"/>
+    </RelativeLayout>
+    <FrameLayout android:layout_width="match_parent"
+              android:layout_height="match_parent"
+              android:id="@+id/preferences_fragment"
+              tools:layout="@android:layout/simple_list_item_1"/>
+</LinearLayout>

+ 47 - 0
app/src/main/res/layout/activity_webview.xml

@@ -0,0 +1,47 @@
+<?xml version="1.0" encoding="utf-8"?>
+
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+              xmlns:tools="http://schemas.android.com/tools"
+              android:orientation="vertical"
+              android:layout_width="match_parent"
+              android:layout_height="match_parent" tools:context=".activities.WebViewActivity">
+
+    <RelativeLayout android:layout_width="match_parent"
+                    android:layout_height="wrap_content"
+                    android:background="#E46C62"
+                    tools:context=".WebViewActivity"
+    >
+        <TextView android:layout_width="wrap_content" android:layout_height="54dp"
+                  android:id="@+id/webview_bar"
+                  android:text="@string/app_name"
+                  android:gravity="left|center_vertical|center_horizontal"
+                  android:elegantTextHeight="false" android:textSize="18sp"
+                  android:layout_toRightOf="@+id/webview_back"
+                  android:textColor="#fff"/>
+        <ImageView
+                android:layout_width="40dp"
+                android:layout_height="fill_parent"
+                android:id="@+id/webview_back"
+                android:layout_marginLeft="4dp"
+                android:layout_marginRight="4dp"
+                android:clickable="true" android:onClick="performBack"
+                android:layout_alignBottom="@+id/webview_bar"
+                android:src="@mipmap/ic_back" android:layout_alignParentBottom="false"
+                android:layout_alignParentTop="false" android:layout_alignParentLeft="true"
+                android:cropToPadding="false" android:padding="10dp"/>
+        <ImageView
+                android:layout_width="40dp"
+                android:layout_height="fill_parent"
+                android:id="@+id/webview_outlink"
+                android:layout_marginRight="10dp"
+                android:clickable="true" android:onClick="openLink"
+                android:layout_alignBottom="@+id/webview_bar"
+                android:src="@mipmap/ic_open_in_browser" android:layout_alignParentRight="true"
+                android:layout_marginLeft="8dp" android:padding="8dp"/>
+    </RelativeLayout>
+    <WebView
+            android:layout_width="match_parent"
+            android:layout_height="match_parent"
+            android:id="@+id/webView"
+            android:layout_gravity="center_horizontal"/>
+</LinearLayout>

+ 23 - 0
app/src/main/res/layout/preference_category.xml

@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+              android:layout_width="match_parent"
+              android:layout_height="wrap_content"
+              android:paddingLeft="16dp"
+              android:paddingRight="?android:attr/scrollbarSize">
+    <RelativeLayout
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:paddingTop="10dp"
+            android:layout_marginRight="10dp"
+            android:layout_weight="1">
+
+        <TextView android:id="@+android:id/title"
+                  android:layout_width="wrap_content"
+                  android:layout_height="wrap_content"
+                  android:singleLine="true"
+                  android:ellipsize="marquee"
+                  android:textColor="#E46C62"
+                  android:textSize="14sp"
+                  android:fadingEdge="horizontal"/>
+    </RelativeLayout>
+</LinearLayout>

+ 47 - 0
app/src/main/res/layout/preference_checkbox.xml

@@ -0,0 +1,47 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+              android:layout_width="match_parent"
+              android:layout_height="wrap_content"
+              android:gravity="center_vertical"
+              android:paddingLeft="16dp"
+              android:paddingRight="?android:attr/scrollbarSize">
+
+
+
+    <RelativeLayout
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:layout_marginRight="6dp"
+            android:layout_marginTop="12dp"
+            android:layout_marginBottom="12dp"
+            android:layout_weight="1">
+
+        <TextView android:id="@+android:id/title"
+                  android:layout_width="wrap_content"
+                  android:layout_height="wrap_content"
+                  android:singleLine="true"
+                  android:ellipsize="marquee"
+                  android:textColor="#666666"
+                  android:textSize="16sp"
+                  android:fadingEdge="horizontal" />
+
+        <TextView android:id="@+android:id/summary"
+                  android:layout_width="wrap_content"
+                  android:layout_height="wrap_content"
+                  android:layout_below="@android:id/title"
+                  android:layout_alignLeft="@android:id/title"
+                  android:textColor="#999"
+                  android:textSize="14sp"
+                  android:maxLines="4" />
+
+    </RelativeLayout>
+
+    <!-- Preference should place its actual preference widget here. -->
+    <LinearLayout android:id="@+android:id/widget_frame"
+                  android:layout_width="wrap_content"
+                  android:layout_height="match_parent"
+                  android:layout_marginRight="6dp"
+                  android:gravity="center"
+                  android:orientation="vertical" />
+
+</LinearLayout>

+ 17 - 0
app/src/main/res/layout/preference_seekbar.xml

@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="utf-8"?>
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+              android:orientation="vertical"
+              android:layout_width="match_parent"
+              android:layout_height="match_parent">
+
+    <SeekBar
+            android:layout_width="match_parent"
+            android:layout_height="wrap_content"
+            android:id="@+id/delay_seekBar" android:layout_margin="20dp" android:max="10"/>
+    <TextView
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:text="延迟0秒拆开红包"
+            android:id="@+id/pref_seekbar_textview" android:textColor="#666666" android:textSize="16sp"
+            android:layout_marginLeft="32dp" android:layout_marginRight="32dp" android:layout_marginBottom="20dp"/>
+</LinearLayout>

BIN
app/src/main/res/mipmap-mdpi/bg_snow.png


BIN
app/src/main/res/mipmap-mdpi/bg_snow_2.png


BIN
app/src/main/res/mipmap-mdpi/ic_back.png


BIN
app/src/main/res/mipmap-mdpi/ic_community.png


BIN
app/src/main/res/mipmap-mdpi/ic_github.png


BIN
app/src/main/res/mipmap-mdpi/ic_launcher.png


BIN
app/src/main/res/mipmap-mdpi/ic_open_in_browser.png


BIN
app/src/main/res/mipmap-mdpi/ic_refresh.png


BIN
app/src/main/res/mipmap-mdpi/ic_settings.png


BIN
app/src/main/res/mipmap-mdpi/ic_start.png


BIN
app/src/main/res/mipmap-mdpi/ic_stop.png


BIN
app/src/main/res/mipmap-mdpi/ic_uber.jpg


BIN
app/src/main/res/mipmap-mdpi/open.png


+ 58 - 0
app/src/main/res/values-en/strings.xml

@@ -0,0 +1,58 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources>
+    <string name="app_name">wxRedPacket</string>
+    <string name="app_version">v1.0</string>
+    <string name="app_description">∠( ᐛ 」∠)_ Instructions ∠( ᐛ 」∠)_\n\n ○ Turn on the Accessibility switch\n ○ Go back to WeChat\n ○ Wait for money comes in\n\n Please submit your feedback on GitHub Issues Page~\n https://github.com/geeeeeeeeek/WeChatLuckyMoney</string>
+    <string name="preference">Preferences</string>
+    <string name="update_error">An error occurred. Please manually update from GitHub Release Page. (ฅ´ω`ฅ)</string>
+    <string name="update_new_seg1">New version found.(</string>
+    <string name="update_new_seg2">)Preparing download for you. ( /) V (\\ )</string>
+    <string name="update_new_seg3">)Please go to Settings to finish update. (ฅ´ω`ฅ)</string>
+    <string name="update_already_latest">You\'re using the latest version! (❁´▽`❁)</string>
+    <string name="service_off">Turn Off</string>
+    <string name="service_on">Turn On</string>
+    <string name="pref_watch_exclude_words_summary">Skip red packets with these phrases (separated by space)</string>
+    <string name="pref_comment_words_summary">Randomly choose reply from these phrases (separated by space)</string>
+    <string name="url_github_issues">https://github.com/geeeeeeeeek/WeChatLuckyMoney/issues</string>
+    <string name="home_banner_ad_unit_id">ca-app-pub-8428619221469478/4736153346</string>
+    <string name="webview_banner_ad_unit_id">ca-app-pub-8428619221469478/4163694548</string>
+    <string name="community">Community</string>
+    <string name="settings">Settings</string>
+    <string name="uber_ad_title">Your first trip is free up to ¥12</string>
+    <string name="uber_ad_text">Get Free Ride Now</string>
+    <string name="github_1"/>
+    <string name="github_2">this app on GitHub to support us</string>
+    <string name="star_2">Star</string>
+    <string name="star_1">★</string>
+    <string name="turn_on_toast">Click 「WeChat Lucky Money」&#160;</string>
+    <string name="turn_on_error_toast">An error occurred. Please manually open System Settings > Accessibility > WeChat Lucky Money. (ฅ´ω`ฅ)</string>
+    <string name="webview_github_title">Project Homepage on GitHub</string>
+    <string name="webview_uber_title">Uber Free Trip</string>
+    <string name="download_backend">Downloading…</string>
+    <string name="download_redirect">Redirecting to download page…</string>
+    <string name="download_hint">Download Uber by clicking \"普通下载\"</string>
+    <string name="watch_options">Watch Level</string>
+    <string name="watch_notifications">Watch system notifications</string>
+    <string name="watch_notifications_hint">Enter chat when a red packet is detected from WeChat notifications</string>
+    <string name="watch_list">Watch chat list</string>
+    <string name="watch_list_hint">Enter chat when a red packet is detected from chat list</string>
+    <string name="anti_block_options">Anti-block Options</string>
+    <string name="auto_open_packets">Open red packets automatically</string>
+    <string name="open_with_delay">Open red packets with a delay</string>
+    <string name="open_self">Open red packets I gave out</string>
+    <string name="skip_phrases">Skip red packets by words in the message</string>
+    <string name="about">About</string>
+    <string name="check_new_version">Check for updates</string>
+    <string name="help_and_feedback">Help and feedback</string>
+    <string name="help_hint">Submit issues on GitHub homepage</string>
+    <string name="labs">Labs</string>
+    <string name="snatch_on_lockscreen">Snatch red packets on lock screen</string>
+    <string name="snatch_on_lockscreen_hint">Will keep the app active in backend for 30 min. Please proceed with caution, since this might greatly increase your battery usage.</string>
+    <string name="auto_reply">Auto reply</string>
+    <string name="checking_new_version">Checking for updates…</string>
+    <string name="delay_instantly">Instantly&#160;</string>
+    <string name="delay_delay">Delay for&#160;</string>
+    <string name="delay_open">open red packets.</string>
+    <string name="delay_sec">&#160;seconds&#160;</string>
+    <string name="delay_then">and then&#160;</string>
+</resources>

+ 5 - 0
app/src/main/res/values-w820dp/dimens.xml

@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="utf-8"?>
+<resources>
+    <dimen name="activity_horizontal_margin">16dp</dimen>
+    <dimen name="activity_vertical_margin">16dp</dimen>
+</resources>

+ 56 - 1
app/src/main/res/values/strings.xml

@@ -1,3 +1,58 @@
 <resources>
-    <string name="app_name">wxRedPacket</string>
+    <string name="app_name">微信红包</string>
+    <string name="app_version">v1.0</string>
+    <string name="app_description">∠( ᐛ 」∠)_使用指南∠( ᐛ 」∠)_\n\n ○ 狠戳插件开关\n ○ 回到微信聊天\n ○ 坐等红包进账\n\n 遇到问题, 欢迎通过 GitHub Issue 反馈~\n https://github.com/geeeeeeeeek/WeChatLuckyMoney</string>
+    <string name="preference">偏好设置</string>
+    <string name="update_error">遇到一些问题,请前往GitHub手动更新喵(ฅ´ω`ฅ)</string>
+    <string name="update_new_seg1">发现新版本(</string>
+    <string name="update_new_seg2">),正在为您准备下载( /) V (\\ )</string>
+    <string name="update_new_seg3">),请进入设置完成更新(ฅ´ω`ฅ)</string>
+    <string name="update_already_latest">已经是最新版本了(❁´▽`❁)</string>
+    <string name="service_off">关闭插件</string>
+    <string name="service_on">开启插件</string>
+    <string name="pref_watch_exclude_words_summary">不拆开包含这些文字的红包(空格间隔)</string>
+    <string name="pref_comment_words_summary">随机选择下列感谢语(空格间隔)</string>
+    <string name="url_github_issues">https://github.com/geeeeeeeeek/WeChatLuckyMoney/issues</string>
+    <string name="home_banner_ad_unit_id">ca-app-pub-8428619221469478/4736153346</string>
+    <string name="webview_banner_ad_unit_id">ca-app-pub-8428619221469478/4163694548</string>
+    <string name="community">社区</string>
+    <string name="settings">设置</string>
+    <string name="uber_ad_title">首次乘车可获得 ¥12 优惠</string>
+    <string name="uber_ad_text">立即获得免费乘车机会</string>
+    <string name="github_1">在 GitHub 上</string>
+    <string name="github_2">本项目,支持应用开源</string>
+    <string name="star_2">Star</string>
+    <string name="star_1">★</string>
+    <string name="turn_on_toast">点击「微信红包」</string>
+    <string name="turn_on_error_toast">遇到一些问题,请手动打开系统设置>无障碍服务>微信红包(ฅ´ω`ฅ)</string>
+    <string name="webview_github_title">GitHub 项目主页</string>
+    <string name="webview_uber_title">Uber 优惠乘车</string>
+    <string name="download_backend">正在后台下载</string>
+    <string name="download_redirect">正在前往下载页面</string>
+    <string name="download_hint">点击\"普通下载\"获取 Uber</string>
+    <string name="watch_options">监视选项</string>
+    <string name="watch_notifications">监视系统通知</string>
+    <string name="watch_notifications_hint">读取新消息通知中的红包提示并进入聊天页</string>
+    <string name="watch_list">监视聊天列表</string>
+    <string name="watch_list_hint">读取聊天列表中的红包提示并进入聊天页</string>
+    <string name="anti_block_options">防封号选项</string>
+    <string name="auto_open_packets">自动拆开红包</string>
+    <string name="open_with_delay">延时拆开红包</string>
+    <string name="open_self">拆开自己发的红包</string>
+    <string name="skip_phrases">屏蔽红包文字</string>
+    <string name="about">关于应用</string>
+    <string name="check_new_version">检查新版本</string>
+    <string name="help_and_feedback">帮助与反馈</string>
+    <string name="help_hint">前往GitHub项目主页提交issue</string>
+    <string name="labs">实验功能</string>
+    <string name="snatch_on_lockscreen">息屏抢红包</string>
+    <string name="snatch_on_lockscreen_hint">保持30分钟后台活跃,可能会极大增加电量消耗,请谨慎使用</string>
+    <string name="auto_reply">拆开红包后自动回复</string>
+    <string name="checking_new_version">正在检查新版本……</string>
+    <string name="delay_instantly">立即</string>
+    <string name="delay_delay">延迟</string>
+    <string name="delay_open">拆开红包</string>
+    <string name="delay_sec">秒</string>
+    <string name="delay_then">然后</string>
+    <string name="cc">ss</string>
 </resources>

+ 11 - 0
app/src/main/res/xml/accessible_service_config.xml

@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="utf-8"?>
+<accessibility-service
+    xmlns:android="http://schemas.android.com/apk/res/android"
+    android:description="@string/app_description"
+    android:accessibilityEventTypes="typeWindowStateChanged|typeWindowContentChanged|typeNotificationStateChanged"
+    android:accessibilityFeedbackType="feedbackAllMask"
+    android:packageNames="com.tencent.mm"
+    android:notificationTimeout="10"
+    android:settingsActivity="xyz.monkeytong.hongbao.activities.SettingsActivity"
+    android:accessibilityFlags="flagDefault"
+    android:canRetrieveWindowContent="true"/>

+ 35 - 0
app/src/main/res/xml/comment_preferences.xml

@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="utf-8"?>
+<PreferenceScreen xmlns:tools="http://schemas.android.com/tools"
+                  xmlns:android="http://schemas.android.com/apk/res/android"
+                  tools:context=".SettingsActivity"
+                  android:icon="@null">
+    <PreferenceCategory
+            android:title="自动回复(Android 5.0以上系统)"
+            android:layout="@layout/preference_category">
+        <CheckBoxPreference
+                android:key="pref_comment_switch"
+                android:title="开启自动回复"
+                android:summary="在拆开其他人的红包后发送自动回复"
+                android:defaultValue="false"
+                android:layout="@layout/preference_checkbox"/>
+    </PreferenceCategory>
+    <PreferenceCategory
+            android:title="回复选项"
+            android:layout="@layout/preference_category">
+        <xyz.monkeytong.hongbao.activities.SeekBarPreference
+                android:key="pref_comment_delay"
+                android:title="延时发送回复"
+                pref_kind="pref_comment_delay"
+                android:layout="@layout/preference_checkbox"/>
+        <CheckBoxPreference
+                android:key="pref_comment_at"
+                android:title="\@发红包的人"
+                android:layout="@layout/preference_checkbox"
+                android:defaultValue="false"/>
+        <EditTextPreference
+                android:key="pref_comment_words"
+                android:title="自定义回复内容"
+                android:summary="@string/pref_comment_words_summary"
+                android:layout="@layout/preference_checkbox"/>
+    </PreferenceCategory>
+</PreferenceScreen>

+ 70 - 0
app/src/main/res/xml/general_preferences.xml

@@ -0,0 +1,70 @@
+<?xml version="1.0" encoding="utf-8"?>
+<PreferenceScreen xmlns:tools="http://schemas.android.com/tools"
+                  xmlns:android="http://schemas.android.com/apk/res/android"
+                  tools:context=".SettingsActivity"
+                  android:icon="@null">
+    <PreferenceCategory
+            android:title="@string/watch_options"
+            android:layout="@layout/preference_category">
+        <CheckBoxPreference
+                android:key="pref_watch_notification"
+                android:title="@string/watch_notifications"
+                android:summary="@string/watch_notifications_hint"
+                android:defaultValue="true"
+                android:layout="@layout/preference_checkbox"/>
+        <CheckBoxPreference
+                android:key="pref_watch_list"
+                android:title="@string/watch_list"
+                android:summary="@string/watch_list_hint"
+                android:layout="@layout/preference_checkbox"
+                android:defaultValue="false"/>
+    </PreferenceCategory>
+    <PreferenceCategory
+            android:title="@string/anti_block_options"
+            android:layout="@layout/preference_category">
+        <CheckBoxPreference
+                android:key="pref_watch_chat"
+                android:title="@string/auto_open_packets"
+                android:layout="@layout/preference_checkbox"
+                android:defaultValue="true"/>
+        <xyz.monkeytong.hongbao.activities.SeekBarPreference
+                android:key="pref_open_delay"
+                android:title="@string/open_with_delay"
+                pref_kind="pref_open_delay"
+                android:layout="@layout/preference_checkbox"/>
+        <CheckBoxPreference
+                android:key="pref_watch_self"
+                android:title="@string/open_self"
+                android:layout="@layout/preference_checkbox"
+                android:defaultValue="true"/>
+        <EditTextPreference
+                android:key="pref_watch_exclude_words"
+                android:title="@string/skip_phrases"
+                android:summary="@string/pref_watch_exclude_words_summary"
+                android:layout="@layout/preference_checkbox"/>
+    </PreferenceCategory>
+    <PreferenceCategory
+            android:title="@string/about"
+            android:layout="@layout/preference_category">
+        <Preference
+                android:key="pref_etc_check_update"
+                android:title="@string/check_new_version"
+                android:summary="http://dwz.cn/WeChatLuckyMoney"
+                android:layout="@layout/preference_checkbox"/>
+        <Preference
+                android:key="pref_etc_issue"
+                android:title="@string/help_and_feedback"
+                android:summary="@string/help_hint"
+                android:layout="@layout/preference_checkbox"/>
+    </PreferenceCategory>
+    <PreferenceCategory
+            android:title="@string/labs"
+            android:layout="@layout/preference_category">
+        <CheckBoxPreference
+                android:key="pref_watch_on_lock"
+                android:title="@string/snatch_on_lockscreen"
+                android:summary="@string/snatch_on_lockscreen_hint"
+                android:layout="@layout/preference_checkbox"
+                android:defaultValue="false"/>
+    </PreferenceCategory>
+</PreferenceScreen>

+ 7 - 0
app/src/main/res/xml/provider_paths.xml

@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="utf-8"?>
+<paths xmlns:android="http://schemas.android.com/apk/res/android">
+    <!-- /storage/emulated/0/Download/${applicationId}/.beta/apk-->
+    <external-path name="beta_external_path" path="Download/"/>
+    <!--/storage/emulated/0/Android/data/${applicationId}/files/apk/-->
+    <external-path name="beta_external_files_path" path="Android/data/"/>
+</paths>