Commit f2e72925 authored by Sébastien Toque's avatar Sébastien Toque

New UI : change colors and globals behaviors

Next steps :
- change icons
- continue to apply these new colors (scrollbar, shadow when pressed
        button...)
- change the audio player
- hunt residual useless code
- ?attr can't be used in xml/color and xml/drawable,
  so those should not be used directly in layouts :
    - list_menu
    - list_subtitle
    - list_title_last
    - list_title
    - background_item
parent 6196610c
......@@ -23,7 +23,7 @@
android:icon="@drawable/icon"
android:logo="@drawable/header_logo"
android:label="@string/app_name"
android:theme="@style/Theme.VLC"
android:theme="@style/Theme.VLC.NoTitleBar"
android:hardwareAccelerated="true" >
<activity
android:name=".gui.MainActivity"
......@@ -37,12 +37,10 @@
</intent-filter>
</activity>
<activity
android:name=".gui.CompatErrorActivity"
android:theme="@android:style/Theme.NoTitleBar" />
android:name=".gui.CompatErrorActivity" />
<activity
android:name=".gui.SearchActivity"
android:configChanges="orientation|screenSize"
android:theme="@android:style/Theme.NoTitleBar"
android:exported="false" >
<intent-filter>
<action android:name="android.intent.action.SEARCH" />
......@@ -53,24 +51,19 @@
android:resource="@xml/searchable" />
</activity>
<activity
android:name=".gui.AboutActivity"
android:theme="@android:style/Theme.NoTitleBar" />
android:name=".gui.AboutActivity" />
<activity
android:name=".gui.PreferencesActivity"
android:theme="@android:style/Theme.NoTitleBar" />
android:name=".gui.PreferencesActivity" />
<activity
android:name=".gui.BrowserActivity"
android:label="@string/mediafiles"
android:theme="@android:style/Theme" />
android:theme="@style/Theme.VLC.Basic" />
<activity
android:name=".gui.DebugLogActivity"
android:theme="@android:style/Theme.NoTitleBar" />
android:name=".gui.DebugLogActivity" />
<activity
android:name=".gui.video.VideoGridFragment"
android:theme="@style/Theme.VLC"/>
android:name=".gui.video.VideoGridFragment" />
<activity
android:name=".gui.video.MediaInfoActivity"
android:theme="@android:style/Theme.NoTitleBar" />
android:name=".gui.video.MediaInfoActivity" />
<activity
android:name=".gui.video.VideoPlayerActivity"
android:configChanges="orientation|screenSize"
......@@ -376,11 +369,9 @@
</intent-filter>
</activity>
<activity
android:name=".gui.audio.AudioBrowserFragment"
android:theme="@android:style/Theme.NoTitleBar" />
android:name=".gui.audio.AudioBrowserFragment" />
<activity
android:name=".gui.audio.AudioListFragment"
android:theme="@style/Theme.VLC" />
android:name=".gui.audio.AudioListFragment" />
<activity
android:name=".gui.audio.AudioPlayerActivity"
android:theme="@android:style/Theme.NoTitleBar"
......
<?xml version="1.0" encoding="UTF-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_selected="true" android:color="@color/font_light" />
<item android:state_pressed="true" android:color="@color/font_light" />
<item android:color="@color/font_default" />
</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:state_selected="true" android:color="#F000" />
<item android:state_pressed="true" android:color="#F000" />
<item android:color="#F888" />
<item android:state_selected="true" android:color="@color/font_default" />
<item android:state_pressed="true" android:color="@color/font_default" />
<item android:color="@color/font_light" />
</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:state_selected="true" android:color="#FFFF" />
<item android:state_pressed="true" android:color="#FFFF" />
<item android:color="#FFFF" />
<item android:state_selected="true" android:color="@color/font_default" />
<item android:state_pressed="true" android:color="@color/font_default" />
<item android:color="@color/font_default" />
</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:state_selected="true" android:color="#FFFF" />
<item android:state_pressed="true" android:color="#FFFF" />
<item android:state_selected="true" android:color="@color/darkorange" />
<item android:state_pressed="true" android:color="@color/darkorange" />
<item android:color="@color/orange" />
</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:state_pressed="true">
<shape>
<gradient
android:angle="270"
android:centerColor="@color/orange"
android:endColor="@color/darkorange"
android:startColor="@color/darkorange" />
</shape>
<color android:color="@color/orange" />
</item>
<item android:state_selected="true">
<shape>
<gradient
android:angle="270"
android:centerColor="@color/orange"
android:endColor="@color/darkorange"
android:startColor="@color/darkorange" />
</shape>
</item>
<item>
<shape>
<solid android:color="@android:color/transparent"/>
</shape>
<color android:color="@color/darkorange"/>
</item>
</selector>
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_pressed="true">
<shape>
<gradient
android:angle="270"
android:centerColor="@color/orange"
android:endColor="@color/darkorange"
android:startColor="@color/darkorange" />
</shape>
</item>
<item android:state_selected="true">
<shape>
<gradient
android:angle="270"
android:centerColor="@color/orange"
android:endColor="@color/darkorange"
android:startColor="@color/darkorange" />
</shape>
</item>
<item>
<shape>
<gradient
android:angle="270"
android:centerColor="@color/item_1"
android:endColor="@color/item_common"
android:startColor="@color/item_common" />
</shape>
</item>
</selector>
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_pressed="true">
<shape>
<gradient
android:angle="270"
android:centerColor="@color/orange"
android:endColor="@color/darkorange"
android:startColor="@color/darkorange" />
</shape>
</item>
<item android:state_selected="true">
<shape>
<gradient
android:angle="270"
android:centerColor="@color/orange"
android:endColor="@color/darkorange"
android:startColor="@color/darkorange" />
</shape>
</item>
<item>
<shape>
<gradient
android:angle="270"
android:centerColor="@color/item_2"
android:endColor="@color/item_common"
android:startColor="@color/item_common" />
</shape>
</item>
</selector>
......@@ -2,8 +2,7 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical"
android:background="@drawable/background_item1" >
android:orientation="vertical" >
<LinearLayout
android:layout_width="fill_parent"
......@@ -22,7 +21,8 @@
android:id="@+id/title"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:textAppearance="?android:attr/textAppearanceMedium" />
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="?attr/font_default" />
<LinearLayout
android:layout_width="fill_parent"
......@@ -66,7 +66,8 @@
android:layout_gravity="bottom|right"
android:layout_margin="10dip"
android:background="@drawable/video_list_length_bg"
android:textAppearance="?android:attr/textAppearanceMedium" />
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#AFFF" />
</FrameLayout>
<ListView
......@@ -76,8 +77,8 @@
android:layout_weight="1"
android:cacheColorHint="#00000000"
android:divider="#00000000"
android:listSelector="@android:color/transparent"
android:fastScrollEnabled="true" />
android:fastScrollEnabled="true"
android:listSelector="@android:color/transparent" />
</LinearLayout>
</LinearLayout>
\ No newline at end of file
......@@ -35,20 +35,20 @@
android:layout_height="wrap_content" />
<View
android:id="@+id/add_subtitle_divider"
android:layout_width="match_parent"
android:layout_height="1px"
android:background="#8FFF"
tools:ignore="PxUsage"
android:id="@+id/add_subtitle_divider" />
tools:ignore="PxUsage" />
<TextView
android:id="@+id/add_subtitle"
android:layout_width="wrap_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/subtitle_label"
android:textAppearance="?android:attr/textAppearanceMedium"
android:layout_margin="10dp"
android:background="@drawable/background_item" />
android:background="@drawable/background_item"
android:text="@string/subtitle_label"
android:textAppearance="?android:attr/textAppearanceMedium" />
</LinearLayout>
</ScrollView>
\ No newline at end of file
......@@ -3,15 +3,14 @@
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical"
android:background="@color/item_common">
android:orientation="vertical">
<HorizontalScrollView
android:id="@+id/header"
android:scrollbars="none"
android:fadingEdge="none"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="@drawable/bg_with_shadow">
android:background="?attr/background_menu">
<LinearLayout
android:id="@+id/header_layout"
android:layout_width="wrap_content"
......@@ -20,7 +19,7 @@
<TextView
android:text="@string/artists"
android:textSize="16sp"
android:textColor="#ffffff"
android:textColor="?attr/font_light"
android:id="@+id/artists"
android:layout_width="80sp"
android:layout_height="wrap_content"
......@@ -28,7 +27,7 @@
<TextView
android:text="@string/albums"
android:textSize="16sp"
android:textColor="#888888"
android:textColor="?attr/font_light"
android:id="@+id/albums"
android:layout_width="80sp"
android:layout_height="wrap_content"
......@@ -36,7 +35,7 @@
<TextView
android:text="@string/songs"
android:textSize="16sp"
android:textColor="#888888"
android:textColor="?attr/font_light"
android:id="@+id/songs"
android:layout_width="80sp"
android:layout_height="wrap_content"
......@@ -44,7 +43,7 @@
<TextView
android:text="@string/genres"
android:textSize="16sp"
android:textColor="#888888"
android:textColor="?attr/font_light"
android:id="@+id/genres"
android:layout_width="80sp"
android:layout_height="wrap_content"
......@@ -54,17 +53,17 @@
<View
android:layout_width="fill_parent"
android:layout_height="1dip"
android:background="#f0f0f0" />
android:background="?attr/background_menu_divider" />
<org.videolan.vlc.widget.FlingViewGroup
android:id="@+id/content"
android:layout_width="fill_parent"
android:layout_height="fill_parent">
android:layout_height="fill_parent" >
<ExpandableListView
android:id="@+id/artists_list"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:divider="@color/item_common"
android:childDivider="@color/item_common"
android:divider="?attr/item_divider"
android:childDivider="?attr/item_divider"
android:dividerHeight="1dp"
android:groupIndicator="@null"
android:fastScrollEnabled="true" />
......@@ -72,8 +71,8 @@
android:id="@+id/albums_list"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:divider="@color/item_common"
android:childDivider="@color/item_common"
android:divider="?attr/item_divider"
android:childDivider="?attr/item_divider"
android:dividerHeight="1dp"
android:groupIndicator="@null"
android:fastScrollEnabled="true" />
......@@ -81,15 +80,15 @@
android:id="@+id/songs_list"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:divider="@color/item_common"
android:divider="?attr/item_divider"
android:dividerHeight="1dp"
android:fastScrollEnabled="true" />
<ExpandableListView
android:id="@+id/genres_list"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:divider="@color/item_common"
android:childDivider="@color/item_common"
android:divider="?attr/item_divider"
android:childDivider="?attr/item_divider"
android:dividerHeight="1dp"
android:groupIndicator="@null"
android:fastScrollEnabled="true" />
......
......@@ -9,7 +9,7 @@
android:layout_width="5dip"
android:layout_height="fill_parent"
android:layout_marginLeft="5dip"
android:background="@color/orange" />
android:background="?attr/orange" />
<ImageView
android:id="@+id/cover"
......
......@@ -2,29 +2,28 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="@color/item_common"
android:orientation="vertical" >
<TextView
android:id="@+id/title"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="@drawable/bg_with_shadow"
android:background="?attr/background_menu"
android:gravity="center_horizontal"
android:text="@string/songs"
android:textColor="#ffffff"
android:textColor="?attr/font_default"
android:textSize="16sp" />
<View
android:layout_width="fill_parent"
android:layout_height="1dip"
android:background="#f0f0f0" />
android:background="?attr/background_menu_divider" />
<ListView
android:id="@id/android:list"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:divider="@color/item_common"
android:divider="?attr/item_divider"
android:dividerHeight="1dp"
android:fastScrollEnabled="true" />
......
......@@ -5,7 +5,7 @@
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="@drawable/bg_with_shadow">
android:background="?attr/background_menu">
<ProgressBar
style="@android:style/Widget.ProgressBar.Horizontal"
android:id="@+id/timeline"
......@@ -42,7 +42,7 @@
android:layout_height="wrap_content"
android:text="@string/title"
android:textSize="16sp"
android:textColor="#ffffff"
android:textColor="?attr/font_default"
android:singleLine="true" />
<TextView
android:id="@+id/artist"
......@@ -50,7 +50,7 @@
android:layout_height="wrap_content"
android:text="@string/artist"
android:textSize="14sp"
android:textColor="#888888"
android:textColor="?attr/font_light"
android:singleLine="true" />
</LinearLayout>
<ImageButton
......
......@@ -2,11 +2,10 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="@color/item_common"
android:orientation="vertical">
<ListView android:id="@id/android:list"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:divider="@color/item_common"
android:divider="?attr/item_divider"
android:dividerHeight="1dp" />
</LinearLayout>
\ No newline at end of file
......@@ -3,8 +3,7 @@
android:id="@android:id/list"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:divider="@color/item_common"
android:dividerHeight="1dp"
android:background="@android:color/black">
android:divider="?attr/item_divider"
android:dividerHeight="1dp" >
</ListView>
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@android:color/black">
<ListView android:id="@android:id/list"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:divider="@color/item_common"
android:dividerHeight="1dp" />
<TextView android:id="@android:id/empty"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center_horizontal"
android:paddingTop="30dip"
android:textSize="20sp"
android:text="@string/nohistory"/>
android:orientation="vertical" >
<ListView
android:id="@android:id/list"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:divider="?attr/item_divider"
android:dividerHeight="1dp" />
<TextView
android:id="@android:id/empty"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center_horizontal"
android:paddingTop="30dip"
android:text="@string/nohistory"
android:textSize="20sp" />
</LinearLayout>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="@drawable/bg_with_shadow">
android:orientation="vertical" >
<TextView
android:id="@+id/text"
android:layout_height="wrap_content"
android:layout_width="fill_parent"
android:layout_marginLeft="18dip"
android:textSize="16sp"
android:textColor="#ffffff" />
android:layout_height="wrap_content"
android:background="?attr/background_menu"
android:gravity="center_horizontal"
android:textColor="?attr/font_default"
android:textSize="16sp" />
<View
android:layout_width="fill_parent"
android:layout_height="1dip"
android:background="#f0f0f0" />
android:background="?attr/background_menu_divider" />
</LinearLayout>
\ No newline at end of file
......@@ -11,13 +11,13 @@
<RelativeLayout
android:id="@+id/info_layout"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_height="20dp"
android:visibility="gone">
<ProgressBar
android:id="@+id/info_progress"
style="?android:attr/progressBarStyleHorizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_height="fill_parent"
android:progressDrawable="@drawable/progress"/>
<TextView
android:id="@+id/info_text"
......
......@@ -2,8 +2,7 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical"
android:background="@drawable/background_item1" >
android:orientation="vertical" >
<LinearLayout
android:layout_width="fill_parent"
......@@ -22,7 +21,8 @@
android:id="@+id/title"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:textAppearance="?android:attr/textAppearanceMedium" />
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="?attr/font_default" />
<FrameLayout
android:layout_width="fill_parent"
......@@ -58,7 +58,8 @@
android:layout_gravity="bottom|right"
android:layout_margin="10dip"
android:background="@drawable/video_list_length_bg"
android:textAppearance="?android:attr/textAppearanceMedium" />
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#AFFF" />
</FrameLayout>
<ListView
......@@ -67,7 +68,7 @@
android:layout_height="fill_parent"
android:cacheColorHint="#00000000"
android:divider="#00000000"
android:listSelector="@android:color/transparent"
android:fastScrollEnabled="true" />
android:fastScrollEnabled="true"
android:listSelector="@android:color/transparent" />
</LinearLayout>
\ No newline at end of file
......@@ -43,7 +43,6 @@
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:layout_gravity="top"
android:background="@color/transparent_gray"
android:paddingLeft="5dp"
android:paddingRight="5dp"
android:visibility="invisible" >
......@@ -120,7 +119,6 @@
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_gravity="bottom"
android:background="@color/transparent_gray"
android:paddingLeft="5dp"
android:paddingRight="5dp"
android:visibility="invisible" >
......@@ -147,7 +145,6 @@
android:layout_height="wrap_content"
android:layout_above="@+id/interface_overlay"
android:layout_alignParentLeft="true"
android:background="@color/transparent_gray"
android:paddingLeft="5dp"
android:paddingRight="5dp"
android:visibility="invisible" >
......
......@@ -3,8 +3,7 @@
xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="@color/item_common">
android:layout_height="fill_parent" >
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="48dip"
......@@ -35,7 +34,7 @@
android:id="@id/android:list"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:divider="@color/item_common"
android:divider="?attr/item_divider"
android:dividerHeight="1dp"
android:fastScrollEnabled="true" />
</LinearLayout>
......@@ -2,11 +2,11 @@
<ListView xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@android:id/list"
android:layout_height="match_parent"
android:divider="@color/item_common"
android:dividerHeight="1dp"
android:divider="?attr/background_menu_divider"
android:dividerHeight="0.2dp"
android:layout_width="208dp"
android:cacheColorHint="#0000"
android:fastScrollEnabled="true"
android:background="#424242">
android:backg