Commit 572448b0 authored by Alexandre Perraud's avatar Alexandre Perraud

UI : Make repeat button focussable

parent c89c095d
......@@ -14,7 +14,7 @@
id="svg4682"
version="1.1"
inkscape:version="0.48.5 r10040"
sodipodi:docname="ic_repeat_normal_w.svg"
sodipodi:docname="ic_repeat_normal.svg"
inkscape:export-filename="/home/corbax/Dev/android/Icons/Test 1/ic_play_normal.png"
inkscape:export-xdpi="90"
inkscape:export-ydpi="90">
......@@ -28,7 +28,7 @@
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="22.4"
inkscape:cx="13.40099"
inkscape:cx="11.972419"
inkscape:cy="15.548271"
inkscape:document-units="px"
inkscape:current-layer="layer1"
......@@ -50,7 +50,7 @@
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
<dc:title />
</cc:Work>
</rdf:RDF>
</metadata>
......@@ -59,17 +59,11 @@
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1028.3622)">
<g
id="g5269"
style="font-size:16px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Roboto;-inkscape-font-specification:Roboto"
transform="translate(-64,740.00002)">
<path
style="font-size:6px;fill:#212121;fill-opacity:1"
d="m 17,2 0,3 -10,0 -2,0 0,6 2,0 0,-4 10,0 0,3 4,-4 z m 0,11 0,4 -10,0 0,-3 -4,4 4,4 0,-3 10,0 2,0 0,-6 z"
transform="translate(64,288.36218)"
id="path5271"
inkscape:connector-curvature="0"
sodipodi:nodetypes="cccccccccccccccccccccc" />
</g>
<path
sodipodi:nodetypes="cccccccccccccccccccccc"
inkscape:connector-curvature="0"
id="path5271"
d="m 17,1030.3622 0,3 -10,0 -2,0 0,6 2,0 0,-4 10,0 0,3 4,-4 z m 0,11 0,4 -10,0 0,-3 -4,4 4,4 0,-3 10,0 2,0 0,-6 z"
style="font-size:6px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#212121;fill-opacity:1;stroke:none;font-family:Roboto;-inkscape-font-specification:Roboto" />
</g>
</svg>
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="24"
height="24"
id="svg4682"
version="1.1"
inkscape:version="0.48.5 r10040"
sodipodi:docname="ic_repeat_normal.svg"
inkscape:export-filename="/home/corbax/Dev/android/Icons/Test 1/ic_play_normal.png"
inkscape:export-xdpi="90"
inkscape:export-ydpi="90">
<defs
id="defs4684" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="22.4"
inkscape:cx="5.5438471"
inkscape:cy="15.548271"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="true"
inkscape:window-width="960"
inkscape:window-height="1028"
inkscape:window-x="1920"
inkscape:window-y="24"
inkscape:window-maximized="0">
<inkscape:grid
type="xygrid"
id="grid3002" />
</sodipodi:namedview>
<metadata
id="metadata4687">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1028.3622)">
<g
id="g5269"
style="font-size:16px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#ff8800;fill-opacity:1;stroke:none;font-family:Roboto;-inkscape-font-specification:Roboto"
transform="translate(-64,740.00002)">
<path
style="font-size:6px;fill:#ff8800;fill-opacity:1"
d="m 17,2 0,3 -10,0 -2,0 0,6 2,0 0,-4 10,0 0,3 4,-4 z m 0,11 0,4 -10,0 0,-3 -4,4 4,4 0,-3 10,0 2,0 0,-6 z"
transform="translate(64,288.36218)"
id="path5271"
inkscape:connector-curvature="0"
sodipodi:nodetypes="cccccccccccccccccccccc" />
</g>
</g>
</svg>
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="24"
height="24"
id="svg4682"
version="1.1"
inkscape:version="0.48.5 r10040"
sodipodi:docname="ic_repeat_one.svg"
inkscape:export-filename="/home/corbax/Dev/android/Icons/Test 1/ic_play_normal.png"
inkscape:export-xdpi="90"
inkscape:export-ydpi="90">
<defs
id="defs4684" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="22.4"
inkscape:cx="5.5438471"
inkscape:cy="15.548271"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="true"
inkscape:window-width="960"
inkscape:window-height="1028"
inkscape:window-x="1920"
inkscape:window-y="24"
inkscape:window-maximized="0">
<inkscape:grid
type="xygrid"
id="grid3002" />
</sodipodi:namedview>
<metadata
id="metadata4687">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1028.3622)">
<g
id="g5269"
style="font-size:16px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#ffb54c;fill-opacity:1;stroke:none;font-family:Roboto;-inkscape-font-specification:Roboto"
transform="translate(-64,740.00002)">
<path
style="font-size:6px;fill:#ffb54c;fill-opacity:1"
d="M 17 2 L 17 5 L 7 5 L 5 5 L 5 11 L 7 11 L 7 7 L 17 7 L 17 10 L 21 6 L 17 2 z M 12.75 9.5 L 10.25 10.25 L 10.25 11 L 11.25 11 L 11.25 15 L 12.75 15 L 12.75 9.5 z M 17 13 L 17 17 L 7 17 L 7 14 L 3 18 L 7 22 L 7 19 L 17 19 L 19 19 L 19 13 L 17 13 z "
transform="translate(64,288.36218)"
id="path5271" />
</g>
</g>
</svg>
......@@ -14,7 +14,7 @@
id="svg4682"
version="1.1"
inkscape:version="0.48.5 r10040"
sodipodi:docname="ic_repeat_one.svg"
sodipodi:docname="ic_repeat_pressed.svg"
inkscape:export-filename="/home/corbax/Dev/android/Icons/Test 1/ic_play_normal.png"
inkscape:export-xdpi="90"
inkscape:export-ydpi="90">
......@@ -28,7 +28,7 @@
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="22.4"
inkscape:cx="13.40099"
inkscape:cx="5.5438471"
inkscape:cy="15.548271"
inkscape:document-units="px"
inkscape:current-layer="layer1"
......@@ -50,7 +50,7 @@
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
<dc:title />
</cc:Work>
</rdf:RDF>
</metadata>
......@@ -61,10 +61,10 @@
transform="translate(0,-1028.3622)">
<g
id="g5269"
style="font-size:16px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Roboto;-inkscape-font-specification:Roboto"
style="font-size:16px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#ffb54c;fill-opacity:1;stroke:none;font-family:Roboto;-inkscape-font-specification:Roboto"
transform="translate(-64,740.00002)">
<path
style="font-size:6px;fill:#ff8800;fill-opacity:1"
style="font-size:6px;fill:#ffb54c;fill-opacity:1"
d="m 17,2 0,3 -10,0 -2,0 0,6 2,0 0,-4 10,0 0,3 4,-4 z m 0,11 0,4 -10,0 0,-3 -4,4 4,4 0,-3 10,0 2,0 0,-6 z"
transform="translate(64,288.36218)"
id="path5271"
......
<?xml version="1.0" encoding="UTF-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@drawable/ic_repeat_normal" android:state_focused="true" android:state_pressed="false"/>
<item android:drawable="@drawable/ic_repeat_pressed" android:state_focused="true" android:state_pressed="true"/>
<item android:drawable="@drawable/ic_repeat_pressed" android:state_focused="false" android:state_pressed="true"/>
<item android:drawable="@drawable/ic_repeat_normal"/>
</selector>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@drawable/ic_repeat_normal_o" android:state_focused="true" android:state_pressed="false"/>
<item android:drawable="@drawable/ic_repeat_pressed" android:state_focused="true" android:state_pressed="true"/>
<item android:drawable="@drawable/ic_repeat_pressed" android:state_focused="false" android:state_pressed="true"/>
<item android:drawable="@drawable/ic_repeat_normal_o"/>
</selector>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@drawable/ic_repeat_one_o" android:state_focused="true" android:state_pressed="false"/>
<item android:drawable="@drawable/ic_repeat_one_pressed" android:state_focused="true" android:state_pressed="true"/>
<item android:drawable="@drawable/ic_repeat_one_pressed" android:state_focused="false" android:state_pressed="true"/>
<item android:drawable="@drawable/ic_repeat_one_o"/>
</selector>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@drawable/ic_repeat_normal_w" android:state_focused="true" android:state_pressed="false"/>
<item android:drawable="@drawable/ic_repeat_pressed" android:state_focused="true" android:state_pressed="true"/>
<item android:drawable="@drawable/ic_repeat_pressed" android:state_focused="false" android:state_pressed="true"/>
<item android:drawable="@drawable/ic_repeat_normal_w"/>
</selector>
\ No newline at end of file
......@@ -211,7 +211,7 @@
android:contentDescription="@string/repeat"
android:focusable="true"
android:scaleType="fitXY"
android:src="?attr/ic_repeat_normal" />
android:src="?attr/ic_repeat" />
<ImageButton
android:id="@+id/play_pause"
......
......@@ -35,8 +35,8 @@
<attr name="ic_up_style" format="reference" />
<attr name="ic_playlist" format="reference" />
<attr name="ic_playlist_on" format="reference" />
<attr name="ic_repeat_normal" format="reference" />
<attr name="ic_repeat_pressed" format="reference" />
<attr name="ic_repeat" format="reference" />
<attr name="ic_repeat_on" format="reference" />
<attr name="ic_repeat_one" format="reference" />
<attr name="ic_shuffle_normal" format="reference" />
<attr name="ic_shuffle_pressed" format="reference" />
......
......@@ -42,8 +42,8 @@
<item name="ic_playlist">@drawable/ic_playlist</item>
<item name="ic_playlist_on">@drawable/ic_playlist_on</item>
<item name="ic_repeat_normal">@drawable/ic_repeat_normal</item>
<item name="ic_repeat_pressed">@drawable/ic_repeat_pressed</item>
<item name="ic_repeat">@drawable/ic_repeat</item>
<item name="ic_repeat_on">@drawable/ic_repeat_on</item>
<item name="ic_repeat_one">@drawable/ic_repeat_one</item>
<item name="ic_shuffle_normal">@drawable/ic_shuffle_normal</item>
<item name="ic_shuffle_pressed">@drawable/ic_shuffle_pressed</item>
......@@ -113,8 +113,8 @@
<item name="ic_playlist">@drawable/ic_playlist_w</item>
<item name="ic_playlist_on">@drawable/ic_playlist_on</item>
<item name="ic_repeat_normal">@drawable/ic_repeat_normal_w</item>
<item name="ic_repeat_pressed">@drawable/ic_repeat_pressed</item>
<item name="ic_repeat">@drawable/ic_repeat_w</item>
<item name="ic_repeat_on">@drawable/ic_repeat_on</item>
<item name="ic_repeat_one">@drawable/ic_repeat_one</item>
<item name="ic_shuffle_normal">@drawable/ic_shuffle_normal_w</item>
<item name="ic_shuffle_pressed">@drawable/ic_shuffle_pressed</item>
......
......@@ -44,7 +44,6 @@ import org.videolan.vlc.widget.AudioMediaSwitcher.AudioMediaSwitcherListener;
import android.media.AudioManager;
import android.os.Bundle;
import android.os.Handler;
import android.os.Parcelable;
import android.preference.PreferenceManager;
import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentActivity;
......@@ -350,14 +349,14 @@ public class AudioPlayer extends Fragment implements IAudioPlayer, View.OnClickL
}
switch(mAudioController.getRepeatType()) {
case None:
mRepeat.setImageResource(Util.getResourceFromAttribute(act, R.attr.ic_repeat_normal));
mRepeat.setImageResource(Util.getResourceFromAttribute(act, R.attr.ic_repeat));
break;
case Once:
mRepeat.setImageResource(Util.getResourceFromAttribute(act, R.attr.ic_repeat_one));
break;
default:
case All:
mRepeat.setImageResource(Util.getResourceFromAttribute(act, R.attr.ic_repeat_pressed));
mRepeat.setImageResource(Util.getResourceFromAttribute(act, R.attr.ic_repeat_on));
break;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment