Sfoglia il codice sorgente

Style changes in the main menu and sections.

Colors and shapes are now similar to the ones on the website.
seavenois 10 anni fa
parent
commit
afae2ef12b

+ 14 - 5
app/src/main/res/drawable/section.xml

@@ -1,9 +1,18 @@
-<shape xmlns:android="http://schemas.android.com/apk/res/android"
+<shape
+    xmlns:android="http://schemas.android.com/apk/res/android"
     android:shape="rectangle" >
 
-    <!--<stroke-->
-        <!--android:width="2dp"-->
-        <!--android:color="@color/section_border" />-->
-    <solid android:color="@color/section_background" />
+    <stroke
+        android:width="1dp"
+        android:color="@color/section_border" />
+
+    <solid
+        android:color="@color/section_background" />
+
+    <corners
+        android:bottomRightRadius="5dp"
+        android:bottomLeftRadius="5dp"
+        android:topLeftRadius="8dp"
+        android:topRightRadius="8dp"/>
 
 </shape>

+ 22 - 12
app/src/main/res/layout/activity_main.xml

@@ -9,7 +9,7 @@
 	<LinearLayout
 		android:layout_width="fill_parent"
 		android:layout_height="wrap_content"
-		android:background="@drawable/titlebar"
+		android:background="@color/background_menu"
 		android:gravity="center_vertical"
 		android:orientation="horizontal"
 		android:padding="2dp">
@@ -46,7 +46,8 @@
 				android:gravity="center"
 				android:text="@string/app_name"
 				android:textSize="18sp"
-				android:textStyle="bold" />
+				android:textStyle="bold"
+				android:textColor="@color/menu_entry"/>
 
 			<!-- Section title -->
 
@@ -56,7 +57,8 @@
 				android:layout_height="wrap_content"
 				android:gravity="center"
 				android:text="@string/menu_home"
-				android:textSize="20sp" />
+				android:textSize="20sp"
+				android:textColor="@color/menu_entry"/>
 
 		</LinearLayout>
 
@@ -91,7 +93,7 @@
 		android:scrollIndicators="none"
 		android:requiresFadingEdge="horizontal"
 		android:fadingEdgeLength="125dp"
-		android:background="@color/background_bar_gradient"
+		android:background="@color/background_menu"
 		tools:ignore="UnusedAttribute">
 
 		<LinearLayout
@@ -117,7 +119,8 @@
 					android:textSize="15sp"
 					android:layout_centerInParent="true"
 					android:textStyle="bold"
-					android:id="@+id/tv_menu_home"/>
+					android:id="@+id/tv_menu_home"
+					android:textColor="@color/menu_entry"/>
 
 				<ImageView
 					android:layout_width="match_parent"
@@ -150,7 +153,8 @@
 					android:layout_gravity="top"
 					android:textSize="15sp"
 					android:layout_centerInParent="true"
-					android:id="@+id/tv_menu_location"/>
+					android:id="@+id/tv_menu_location"
+					android:textColor="@color/menu_entry"/>
 
 				<ImageView
 					android:layout_width="match_parent"
@@ -183,7 +187,8 @@
 					android:layout_gravity="top"
 					android:textSize="15sp"
 					android:layout_centerInParent="true"
-					android:id="@+id/tv_menu_lablanca"/>
+					android:id="@+id/tv_menu_lablanca"
+					android:textColor="@color/menu_entry"/>
 
 				<ImageView
 					android:layout_width="match_parent"
@@ -216,7 +221,8 @@
 					android:layout_gravity="top"
 					android:textSize="15sp"
 					android:layout_centerInParent="true"
-					android:id="@+id/tv_menu_activities"/>
+					android:id="@+id/tv_menu_activities"
+					android:textColor="@color/menu_entry"/>
 
 				<ImageView
 					android:layout_width="match_parent"
@@ -249,7 +255,8 @@
 					android:layout_gravity="top"
 					android:textSize="15sp"
 					android:layout_centerInParent="true"
-					android:id="@+id/tv_menu_blog"/>
+					android:id="@+id/tv_menu_blog"
+					android:textColor="@color/menu_entry"/>
 
 				<ImageView
 					android:layout_width="match_parent"
@@ -282,7 +289,8 @@
 					android:layout_gravity="top"
 					android:textSize="15sp"
 					android:layout_centerInParent="true"
-					android:id="@+id/tv_menu_gallery"/>
+					android:id="@+id/tv_menu_gallery"
+					android:textColor="@color/menu_entry"/>
 
 				<ImageView
 					android:layout_width="match_parent"
@@ -305,13 +313,15 @@
 	<ScrollView
 		android:layout_width="fill_parent"
 		android:layout_height="wrap_content"
-		android:id="@+id/sv_main_content">
+		android:id="@+id/sv_main_content"
+		android:background="@color/background_app">
 
 		<FrameLayout
 			android:id="@+id/activity_main_content_fragment"
 			android:layout_width="match_parent"
 			android:layout_height="match_parent"
-			tools:ignore="ScrollViewSize">
+			tools:ignore="ScrollViewSize"
+			android:background="@color/background_app">
 
 		</FrameLayout>
 	</ScrollView>

+ 6 - 6
app/src/main/res/values/color.xml

@@ -3,15 +3,15 @@
 
     <!-- Backgrounds for several sections -->
     
-    <color name="background_app">#e4f4fd</color>
-    <color name="background_menu">#4c9ed8</color>
+    <color name="background_app">#b5d3e5</color>
+    <color name="background_menu">#0078ff</color>
     <color name="background_notification">#000000</color>
     <color name="background_separator">#000000</color>
 
 
-    <color name="section_background">#d9ecf9</color>
-    <color name="section_border">#badde1</color>
-    <color name="section_title">#07383e</color>
+    <color name="section_background">#98c8ff</color>
+    <color name="section_border">#000011</color>
+    <color name="section_title">#ffffff</color>
     <color name="entry_background">#ffffff</color>
     <color name="entry_border">#d8f3f5</color>
     <color name="entry_title">#41786e</color>
@@ -23,7 +23,7 @@
 
     <color name="background_bar">#9bc1da</color>
     <color name="background_bar_gradient">#bdf8fd</color>
-    <color name="menu_selected">#456075</color>
+    <color name="menu_selected">#ccccff</color>
 
     <!--Color for input fields-->
     <color name="input_background">#223344</color>