feat(ui): supports debugging
This commit is contained in:
BIN
app/src/main/res/drawable-xhdpi/ic_debug.png
Normal file
BIN
app/src/main/res/drawable-xhdpi/ic_debug.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 3.1 KiB |
BIN
app/src/main/res/drawable/ic_debug_step_into.png
Normal file
BIN
app/src/main/res/drawable/ic_debug_step_into.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.7 KiB |
BIN
app/src/main/res/drawable/ic_debug_step_out.png
Normal file
BIN
app/src/main/res/drawable/ic_debug_step_out.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.6 KiB |
BIN
app/src/main/res/drawable/ic_debug_step_over.png
Normal file
BIN
app/src/main/res/drawable/ic_debug_step_over.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 2.6 KiB |
46
app/src/main/res/layout/fragment_debug_toolbar.xml
Normal file
46
app/src/main/res/layout/fragment_debug_toolbar.xml
Normal file
@@ -0,0 +1,46 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="right"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<org.autojs.autojs.ui.widget.ToolbarMenuItem
|
||||
android:id="@+id/step_over"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="match_parent"
|
||||
app:icon="@drawable/ic_debug_step_over"
|
||||
app:text="@string/text_debug_step_over"/>
|
||||
|
||||
<org.autojs.autojs.ui.widget.ToolbarMenuItem
|
||||
android:id="@+id/step_into"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="match_parent"
|
||||
app:icon="@drawable/ic_debug_step_into"
|
||||
app:text="@string/text_debug_step_into"/>
|
||||
|
||||
<org.autojs.autojs.ui.widget.ToolbarMenuItem
|
||||
android:id="@+id/stop_out"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="match_parent"
|
||||
app:icon="@drawable/ic_debug_step_out"
|
||||
app:text="@string/text_debug_step_out"/>
|
||||
|
||||
<org.autojs.autojs.ui.widget.ToolbarMenuItem
|
||||
android:id="@+id/resume_script"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="match_parent"
|
||||
app:icon="@drawable/ic_play_arrow_white_48dp"
|
||||
app:text="@string/text_debug_resume_script"/>
|
||||
|
||||
|
||||
<org.autojs.autojs.ui.widget.ToolbarMenuItem
|
||||
android:id="@+id/stop_script"
|
||||
android:layout_width="40dp"
|
||||
android:layout_height="match_parent"
|
||||
app:icon="@drawable/ic_close_white_48dp"
|
||||
app:text="@string/text_stop"/>
|
||||
|
||||
|
||||
</LinearLayout>
|
||||
@@ -79,6 +79,24 @@
|
||||
|
||||
</item>
|
||||
|
||||
<item
|
||||
android:title="@string/text_debug"
|
||||
app:showAsAction="never">
|
||||
|
||||
<menu>
|
||||
|
||||
<item
|
||||
android:id="@+id/action_breakpoint"
|
||||
android:title="@string/text_set_breakpoint"
|
||||
app:showAsAction="never"/>
|
||||
|
||||
<item
|
||||
android:id="@+id/action_launch_debugger"
|
||||
android:title="@string/text_launch_debugger"
|
||||
app:showAsAction="never"/>
|
||||
</menu>
|
||||
|
||||
</item>
|
||||
|
||||
<item
|
||||
android:id="@+id/action_build_apk"
|
||||
|
||||
@@ -359,4 +359,12 @@
|
||||
<string name="key_script_dir_path">key_script_dir_path</string>
|
||||
<string name="default_value_script_dir_path">/脚本/</string>
|
||||
<string name="text_error_copy_file" formatted="true">发生错误: %s</string>
|
||||
<string name="text_debug">调试</string>
|
||||
<string name="text_set_breakpoint">断点</string>
|
||||
<string name="text_launch_debugger">启动调试</string>
|
||||
<string name="text_debug_step_out">跳出</string>
|
||||
<string name="text_debug_step_into">进入</string>
|
||||
<string name="text_debug_step_over">单步</string>
|
||||
<string name="text_debug_resume_script">继续</string>
|
||||
<string name="text_stop">停止</string>
|
||||
</resources>
|
||||
|
||||
Reference in New Issue
Block a user