optimize memory and image size. remove unnecessary language file
BIN
app/src/main/res/drawable/ic_add_file.png
Normal file
|
After Width: | Height: | Size: 2.6 KiB |
|
Before Width: | Height: | Size: 4.7 KiB |
|
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 806 B |
|
Before Width: | Height: | Size: 2.2 KiB After Width: | Height: | Size: 989 B |
BIN
app/src/main/res/drawable/ic_ali_record.png
Normal file
|
After Width: | Height: | Size: 1014 B |
|
Before Width: | Height: | Size: 2.3 KiB After Width: | Height: | Size: 952 B |
BIN
app/src/main/res/drawable/ic_ali_run.png
Normal file
|
After Width: | Height: | Size: 2.0 KiB |
|
Before Width: | Height: | Size: 5.0 KiB After Width: | Height: | Size: 1.9 KiB |
|
Before Width: | Height: | Size: 5.1 KiB |
BIN
app/src/main/res/drawable/ic_android_eat_js_64.png
Normal file
|
After Width: | Height: | Size: 3.3 KiB |
|
Before Width: | Height: | Size: 4.7 KiB After Width: | Height: | Size: 2.1 KiB |
|
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.8 KiB |
|
Before Width: | Height: | Size: 3.2 KiB |
|
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 1.3 KiB |
BIN
app/src/main/res/drawable/ic_import.png
Normal file
|
After Width: | Height: | Size: 2.3 KiB |
|
Before Width: | Height: | Size: 17 KiB After Width: | Height: | Size: 713 B |
|
Before Width: | Height: | Size: 3.8 KiB After Width: | Height: | Size: 905 B |
|
Before Width: | Height: | Size: 3.9 KiB After Width: | Height: | Size: 2.7 KiB |
|
Before Width: | Height: | Size: 24 KiB |
|
Before Width: | Height: | Size: 2.0 KiB |
|
Before Width: | Height: | Size: 20 KiB After Width: | Height: | Size: 1.1 KiB |
BIN
app/src/main/res/drawable/ic_robot_64.png
Normal file
|
After Width: | Height: | Size: 1.5 KiB |
|
Before Width: | Height: | Size: 2.8 KiB |
BIN
app/src/main/res/drawable/ic_speech_bubble.png
Normal file
|
After Width: | Height: | Size: 1.6 KiB |
|
Before Width: | Height: | Size: 6.7 KiB |
|
Before Width: | Height: | Size: 120 KiB |
BIN
app/src/main/res/drawable/side_menu_bg.webp
Normal file
|
After Width: | Height: | Size: 3.5 KiB |
|
Before Width: | Height: | Size: 22 KiB |
|
Before Width: | Height: | Size: 9.5 KiB After Width: | Height: | Size: 12 KiB |
@@ -20,7 +20,7 @@
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_margin="16dp"
|
||||
android:src="@drawable/ic_developer_512"/>
|
||||
android:src="@drawable/ic_developer"/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
|
||||
@@ -89,11 +89,11 @@
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="60dp"
|
||||
android:padding="10dp"
|
||||
android:src="@drawable/ic_add_file_green"/>
|
||||
android:src="@drawable/ic_add_file"/>
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorTextView
|
||||
android:layout_width="match_parent"
|
||||
@@ -114,7 +114,7 @@
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="60dp"
|
||||
android:padding="10dp"
|
||||
@@ -140,11 +140,11 @@
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="60dp"
|
||||
android:padding="10dp"
|
||||
android:src="@drawable/ic_folder_open_outline_green"/>
|
||||
android:src="@drawable/ic_import"/>
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorTextView
|
||||
android:layout_width="match_parent"
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
android:id="@+id/content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="16dp"
|
||||
android:paddingLeft="3dp"
|
||||
android:textIsSelectable="true"
|
||||
android:textSize="14sp"
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
android:paddingLeft="24dp"
|
||||
android:paddingTop="16dp">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:src="@drawable/ic_ali_rename"/>
|
||||
@@ -43,7 +43,7 @@
|
||||
android:paddingLeft="24dp"
|
||||
android:paddingTop="16dp">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:layout_width="24dp"
|
||||
android:layout_height="24dp"
|
||||
android:src="@drawable/ic_ali_delete"/>
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
android:paddingLeft="24dp"
|
||||
android:paddingTop="16dp">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:src="@drawable/ic_ali_rename"/>
|
||||
@@ -43,7 +43,7 @@
|
||||
android:paddingLeft="24dp"
|
||||
android:paddingTop="16dp">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:src="@drawable/ic_ali_open"/>
|
||||
@@ -69,7 +69,7 @@
|
||||
android:paddingLeft="24dp"
|
||||
android:paddingTop="16dp">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:src="@drawable/ic_ali_shortcut"/>
|
||||
@@ -95,7 +95,7 @@
|
||||
android:paddingLeft="24dp"
|
||||
android:paddingTop="16dp">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:layout_width="24dp"
|
||||
android:layout_height="24dp"
|
||||
android:src="@drawable/ic_ali_delete"/>
|
||||
|
||||
@@ -63,8 +63,8 @@
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="40dp"
|
||||
android:baselineAligned="false"
|
||||
android:layout_gravity="bottom">
|
||||
android:layout_gravity="bottom"
|
||||
android:baselineAligned="false">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/setting"
|
||||
@@ -75,7 +75,7 @@
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:padding="6dp"
|
||||
@@ -98,7 +98,7 @@
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="40dp"
|
||||
android:padding="6dp"
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:id="@+id/icon"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
@@ -20,7 +20,7 @@
|
||||
android:textColor="@android:color/primary_text_light"/>
|
||||
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:id="@+id/expand_hint"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="20dp"
|
||||
|
||||
@@ -1,197 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<android.support.v4.widget.DrawerLayout 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:id="@+id/drawer_layout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
tools:context="com.stardust.scriptdroid.ui.main.MainActivity">
|
||||
|
||||
|
||||
<android.support.design.widget.CoordinatorLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/app_bar_bg"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="128.5dp"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/toolbar_bg"/>
|
||||
|
||||
<android.support.design.widget.AppBarLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@android:color/transparent"
|
||||
android:clipToPadding="false"
|
||||
android:paddingTop="24dp"
|
||||
android:theme="@style/AppTheme.AppBarOverlay"
|
||||
app:elevation="0dp">
|
||||
|
||||
|
||||
<android.support.v7.widget.Toolbar
|
||||
android:id="@+id/toolbar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="?attr/actionBarSize"
|
||||
android:title="@string/_app_name"
|
||||
app:popupTheme="@style/AppTheme.PopupOverlay">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/add"
|
||||
android:layout_width="?android:attr/actionBarSize"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="right"
|
||||
android:foreground="?selectableItemBackgroundBorderless"
|
||||
android:padding="12dp"
|
||||
android:src="@drawable/ic_add_white_48dp"/>
|
||||
|
||||
</android.support.v7.widget.Toolbar>
|
||||
|
||||
</android.support.design.widget.AppBarLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
app:layout_behavior="@string/appbar_scrolling_view_behavior">
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"/>
|
||||
|
||||
<com.ashokvarma.bottomnavigation.BottomNavigationBar
|
||||
android:id="@+id/bottom_navigation_bar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<com.stardust.widget.SlidingUpPanel
|
||||
android:id="@+id/bottom_menu"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="160dp"
|
||||
android:background="@android:color/white"
|
||||
android:baselineAligned="false"
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal">
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/create_new_file"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:background="?attr/selectableItemBackgroundBorderless"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="60dp"
|
||||
android:padding="10dp"
|
||||
android:src="@drawable/ic_add_file_green"/>
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorTextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:text="@string/text_new_file"
|
||||
android:textColor="@color/colorPrimary"
|
||||
android:textSize="16sp"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/import_from_file"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:background="?attr/selectableItemBackgroundBorderless"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="60dp"
|
||||
android:padding="10dp"
|
||||
android:src="@drawable/ic_folder_open_outline_green"/>
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorTextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:text="@string/text_import_from_file"
|
||||
android:textColor="@color/colorPrimary"
|
||||
android:textSize="16sp"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/record"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:background="?attr/selectableItemBackgroundBorderless"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical"
|
||||
android:visibility="gone">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="60dp"
|
||||
android:padding="10dp"
|
||||
android:src="@drawable/ic_video_record"/>
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorTextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:text="@string/text_script_record"
|
||||
android:textColor="@color/colorPrimary"
|
||||
android:textSize="16sp"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/root_record"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:background="?attr/selectableItemBackgroundBorderless"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical"
|
||||
android:visibility="gone">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="60dp"
|
||||
android:padding="10dp"
|
||||
android:src="@drawable/ic_video_record"/>
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorTextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:text="@string/text_root_script_record"
|
||||
android:textColor="@color/colorPrimary"
|
||||
android:textSize="16sp"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</com.stardust.widget.SlidingUpPanel>
|
||||
|
||||
</android.support.design.widget.CoordinatorLayout>
|
||||
|
||||
</android.support.v4.widget.DrawerLayout>
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_margin="16dp"
|
||||
@@ -35,7 +35,7 @@
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_margin="16dp"
|
||||
@@ -57,7 +57,7 @@
|
||||
android:background="?selectableItemBackground"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:id="@+id/icon_assist_service"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_margin="16dp"
|
||||
@@ -35,11 +35,11 @@
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_margin="16dp"
|
||||
android:src="@drawable/ic_js"/>
|
||||
android:src="@drawable/ic_speech_bubble"/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
@@ -56,7 +56,7 @@
|
||||
android:background="?selectableItemBackground"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:id="@+id/icon_service"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
@@ -90,13 +90,13 @@
|
||||
android:background="?selectableItemBackground"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:id="@+id/icon_assist_service"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:layout_margin="16dp"
|
||||
android:src="@drawable/ic_robot_head_green"/>
|
||||
android:src="@drawable/ic_robot_64"/>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
@@ -124,7 +124,7 @@
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<com.stardust.theme.widget.ThemeColorImageView
|
||||
<com.stardust.theme.widget.ThemeColorImageViewCompat
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_margin="16dp"
|
||||
@@ -138,4 +138,4 @@
|
||||
android:textColor="@android:color/primary_text_light"/>
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
17
app/src/main/res/layout/paint_layout.xml
Normal file
@@ -0,0 +1,17 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="600dp"
|
||||
android:layout_height="600dp">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="center"
|
||||
android:padding="200dp"
|
||||
android:src="@drawable/ic_android_eat_js"/>
|
||||
|
||||
<com.stardust.scriptdroid.ui.settings.PaintView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"/>
|
||||
|
||||
</FrameLayout>
|
||||
@@ -45,11 +45,11 @@
|
||||
android:orientation="vertical">
|
||||
|
||||
<ImageView
|
||||
android:layout_width="32dp"
|
||||
android:layout_height="32dp"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_gravity="center"
|
||||
android:contentDescription="@string/_app_name"
|
||||
android:src="@drawable/ic_play"/>
|
||||
android:src="@drawable/ic_ali_run"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
@@ -174,6 +174,10 @@
|
||||
<string name="text_force_stop">强制停止</string>
|
||||
<string name="text_execution_finished" formatted="false">\n------------\n[%s]运行结束,用时%f秒</string>
|
||||
<string name="text_record_format_error">录制格式错误</string>
|
||||
<string name="text_again">又</string>
|
||||
<string name="text_again_and_again">又双</string>
|
||||
<string name="text_again_and_again_again">又双叒</string>
|
||||
<string name="text_again_and_again_again_again">又双叒叕</string>
|
||||
|
||||
<string-array name="record_control_keys">
|
||||
<item>无</item>
|
||||
|
||||