mpris_control.xml 6.16 KB
Newer Older
1 2 3
<?xml version="1.0" encoding="utf-8"?>

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
4
    xmlns:app="http://schemas.android.com/apk/res-auto"
5
    android:id="@+id/mpris_control_view"
6 7
    android:layout_width="match_parent"
    android:layout_height="match_parent"
8
    android:layout_gravity="center"
9
    android:gravity="center"
10
    android:orientation="vertical">
11

12
    <TextView
13
        android:id="@+id/no_players"
14 15
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
16
        android:layout_gravity="center_horizontal"
17
        android:text="@string/no_players_connected"
18
        android:textAppearance="?android:attr/textAppearanceMedium" />
19

20
    <Spinner
21
        android:id="@+id/player_spinner"
22
        android:layout_width="match_parent"
23
        android:layout_height="wrap_content"
24
        android:layout_gravity="center" />
25 26

    <TextView
27
        android:id="@+id/now_playing_textview"
28
        android:layout_width="wrap_content"
29
        android:layout_height="wrap_content"
30
        android:layout_gravity="center"
31
        android:ellipsize="marquee"
32
        android:gravity="center"
33
        android:marqueeRepeatLimit="marquee_forever"
34
        android:padding="8dip"
35
        android:scrollHorizontally="true"
36
        android:singleLine="true"
37
        android:textAppearance="?android:attr/textAppearanceMedium" />
38

39
    <ImageButton
40
        android:id="@+id/play_button"
41
        android:layout_width="fill_parent"
42
        android:layout_height="75dp"
43
        android:layout_gravity="center"
44 45
        android:layout_weight="0"
        android:adjustViewBounds="false"
46 47 48
        android:baselineAlignBottom="true"
        android:clickable="false"
        android:contentDescription="@string/mpris_play"
Nicolas Fella's avatar
Nicolas Fella committed
49 50
        android:src="@drawable/ic_play_black"
        android:theme="@style/DisableableButton" />
51 52

    <LinearLayout
53
        android:layout_width="match_parent"
Albert Vaca Cintora's avatar
Albert Vaca Cintora committed
54
        android:layout_height="60dip"
55
        android:layout_gravity="center"
56
        android:orientation="horizontal">
57 58

        <ImageButton
59
            android:id="@+id/prev_button"
60 61
            android:layout_width="match_parent"
            android:layout_height="fill_parent"
62
            android:layout_weight="0.25"
63
            android:contentDescription="@string/mpris_previous"
Nicolas Fella's avatar
Nicolas Fella committed
64 65
            android:src="@drawable/ic_previous_black"
            android:theme="@style/DisableableButton" />
66 67

        <ImageButton
68
            android:id="@+id/rew_button"
69 70
            android:layout_width="match_parent"
            android:layout_height="fill_parent"
71
            android:layout_weight="0.25"
72
            android:contentDescription="@string/mpris_rew"
Nicolas Fella's avatar
Nicolas Fella committed
73 74
            android:src="@drawable/ic_rewind_black"
            android:theme="@style/DisableableButton" />
75

Nicolas Fella's avatar
Nicolas Fella committed
76 77 78 79 80 81
        <ImageButton
            android:id="@+id/stop_button"
            android:layout_width="match_parent"
            android:layout_height="fill_parent"
            android:layout_weight="0.25"
            android:contentDescription="@string/mpris_stop"
Nicolas Fella's avatar
Nicolas Fella committed
82 83
            android:src="@drawable/ic_stop"
            android:theme="@style/DisableableButton" />
Nicolas Fella's avatar
Nicolas Fella committed
84 85


86
        <ImageButton
87
            android:id="@+id/ff_button"
88 89 90
            android:layout_width="match_parent"
            android:layout_height="fill_parent"
            android:layout_weight="0.25"
91
            android:contentDescription="@string/mpris_ff"
Nicolas Fella's avatar
Nicolas Fella committed
92 93
            android:src="@drawable/ic_fast_forward_black"
            android:theme="@style/DisableableButton" />
94 95

        <ImageButton
96
            android:id="@+id/next_button"
97 98 99
            android:layout_width="match_parent"
            android:layout_height="fill_parent"
            android:layout_weight="0.25"
100
            android:contentDescription="@string/mpris_next"
Nicolas Fella's avatar
Nicolas Fella committed
101 102
            android:src="@drawable/ic_next_black"
            android:theme="@style/DisableableButton" />
103 104

    </LinearLayout>
105

106
    <LinearLayout
107
        android:id="@+id/progress_slider"
108
        android:layout_width="match_parent"
109
        android:layout_height="wrap_content"
110
        android:orientation="horizontal">
111 112

        <TextView
113
            android:id="@+id/progress_textview"
114 115
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
116
            android:layout_gravity="center"
117 118
            android:gravity="center"
            android:padding="8dip"
119 120 121
            android:singleLine="true"
            android:text="00:00"
            android:textAppearance="?android:attr/textAppearanceMedium" />
122 123

        <SeekBar
124
            android:id="@+id/positionSeek"
125 126
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
127 128
            android:layout_gravity="center"
            android:layout_weight="1" />
129 130

        <TextView
131
            android:id="@+id/time_textview"
132 133
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
134
            android:layout_gravity="center"
135 136
            android:gravity="center"
            android:padding="8dip"
137 138 139
            android:singleLine="true"
            android:text="00:00"
            android:textAppearance="?android:attr/textAppearanceMedium" />
140 141
    </LinearLayout>

142
    <LinearLayout
143 144 145 146 147 148
        android:id="@+id/volume_layout"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_gravity="center"
        android:layout_marginTop="8dip"
        android:orientation="horizontal">
149

150
        <androidx.appcompat.widget.AppCompatImageView
151
            android:id="@+id/imageView"
152 153
            android:layout_width="30dip"
            android:layout_height="30dip"
154
            android:layout_marginEnd="10dip"
155
            android:layout_marginRight="10dip"
156
            android:layout_weight="0"
157
            android:contentDescription="@string/mpris_volume"
158
            android:maxWidth="30dip"
Nicolas Fella's avatar
Nicolas Fella committed
159 160
            android:src="@drawable/ic_volume_black"
            app:tint="?attr/colorHighContrast" />
161 162 163


        <SeekBar
164
            android:id="@+id/volume_seek"
165
            android:layout_width="wrap_content"
166 167
            android:layout_height="wrap_content"
            android:layout_gravity="center"
168 169
            android:layout_weight="1"
            android:max="100" />
170 171

    </LinearLayout>
172
</LinearLayout>