android: improve Settings UI and run mpd on boot
add 2 preferences to: - enable Wakelock when MPD is running (prevent suspend) - run MPD on boot and display MPD logs
This commit is contained in:

committed by
Max Kellermann

parent
ef38dbe5bf
commit
f37ab5482b
5
android/res/layout/log_item.xml
Normal file
5
android/res/layout/log_item.xml
Normal file
@@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<TextView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:typeface="monospace" />
|
37
android/res/layout/settings.xml
Normal file
37
android/res/layout/settings.xml
Normal file
@@ -0,0 +1,37 @@
|
||||
<?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:orientation="vertical" >
|
||||
|
||||
<ToggleButton
|
||||
android:id="@+id/run"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:textOn="@string/toggle_button_run_on"
|
||||
android:textOff="@string/toggle_button_run_off" />
|
||||
|
||||
<CheckBox
|
||||
android:id="@+id/run_on_boot"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/checkbox_run_on_boot" />
|
||||
|
||||
<CheckBox
|
||||
android:id="@+id/wakelock"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/checkbox_wakelock" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/status"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content" />
|
||||
|
||||
<ListView
|
||||
android:id="@+id/log_list"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingTop="10dip" />
|
||||
|
||||
</LinearLayout>
|
Reference in New Issue
Block a user