diff options
Diffstat (limited to 'Xamarin.Forms.ControlGallery.Android/Resources')
27 files changed, 212 insertions, 0 deletions
diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/AboutResources.txt b/Xamarin.Forms.ControlGallery.Android/Resources/AboutResources.txt new file mode 100644 index 00000000..10f52d46 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/AboutResources.txt @@ -0,0 +1,44 @@ +Images, layout descriptions, binary blobs and string dictionaries can be included +in your application as resource files. Various Android APIs are designed to +operate on the resource IDs instead of dealing with images, strings or binary blobs +directly. + +For example, a sample Android app that contains a user interface layout (main.axml), +an internationalization string table (strings.xml) and some icons (drawable-XXX/icon.png) +would keep its resources in the "Resources" directory of the application: + +Resources/ + drawable/ + icon.png + + layout/ + main.axml + + values/ + strings.xml + +In order to get the build system to recognize Android resources, set the build action to +"AndroidResource". The native Android APIs do not operate directly with filenames, but +instead operate on resource IDs. When you compile an Android application that uses resources, +the build system will package the resources for distribution and generate a class called "R" +(this is an Android convention) that contains the tokens for each one of the resources +included. For example, for the above Resources layout, this is what the R class would expose: + +public class R { + public class drawable { + public const int icon = 0x123; + } + + public class layout { + public const int main = 0x456; + } + + public class strings { + public const int first_string = 0xabc; + public const int second_string = 0xbcd; + } +} + +You would then use R.drawable.icon to reference the drawable/icon.png file, or R.layout.main +to reference the layout/main.axml file, or R.strings.first_string to reference the first +string in the dictionary file values/strings.xml. diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/CustomSelector.xml b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/CustomSelector.xml new file mode 100644 index 00000000..973f9480 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/CustomSelector.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8"?> +<selector xmlns:android="http://schemas.android.com/apk/res/android"> + <item android:state_pressed="false" + android:state_selected="false" + android:drawable="@color/cellback" /> + <item android:state_pressed="true" > + <shape> + <gradient + android:startColor="#E77A26" + android:endColor="#E77A26" + android:angle="270" /> + </shape> + </item> + + <item android:state_selected="true" + android:state_pressed="false" + android:drawable="@color/cellback" /> +</selector>
\ No newline at end of file diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/CustomSelector2.xml b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/CustomSelector2.xml new file mode 100644 index 00000000..efe02fa8 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/CustomSelector2.xml @@ -0,0 +1,18 @@ +<?xml version="1.0" encoding="utf-8"?> +<selector xmlns:android="http://schemas.android.com/apk/res/android"> + <item android:state_pressed="false" + android:state_selected="false" + android:drawable="@color/cellback2" /> + <item android:state_pressed="true" > + <shape> + <gradient + android:startColor="#E77A26" + android:endColor="#E77A26" + android:angle="270" /> + </shape> + </item> + + <item android:state_selected="true" + android:state_pressed="false" + android:drawable="@color/cellback2" /> +</selector>
\ No newline at end of file diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/FlowerBuds.jpg b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/FlowerBuds.jpg Binary files differnew file mode 100644 index 00000000..023797cc --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/FlowerBuds.jpg diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/Fruits.jpg b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/Fruits.jpg Binary files differnew file mode 100644 index 00000000..6c4ea3d9 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/Fruits.jpg diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/Icon.png b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/Icon.png Binary files differnew file mode 100644 index 00000000..a07c69fa --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/Icon.png diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/Legumes.jpg b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/Legumes.jpg Binary files differnew file mode 100644 index 00000000..5f299b41 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/Legumes.jpg diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/Vegetables.jpg b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/Vegetables.jpg Binary files differnew file mode 100644 index 00000000..297964d7 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/Vegetables.jpg diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/bank.png b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/bank.png Binary files differnew file mode 100644 index 00000000..fbf2947e --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/bank.png diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/calculator.png b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/calculator.png Binary files differnew file mode 100644 index 00000000..339cab59 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/calculator.png diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/coffee.png b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/coffee.png Binary files differnew file mode 100644 index 00000000..350257c0 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/coffee.png diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/cover1.jpg b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/cover1.jpg Binary files differnew file mode 100644 index 00000000..f2cea334 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/cover1.jpg diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/cover1small.jpg b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/cover1small.jpg Binary files differnew file mode 100644 index 00000000..c820c471 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/cover1small.jpg diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/crimson.jpg b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/crimson.jpg Binary files differnew file mode 100644 index 00000000..3db7bb21 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/crimson.jpg diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/crimsonsmall.jpg b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/crimsonsmall.jpg Binary files differnew file mode 100644 index 00000000..426c5e07 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/crimsonsmall.jpg diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/menuIcon.png b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/menuIcon.png Binary files differnew file mode 100644 index 00000000..0793dc7b --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/menuIcon.png diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/oasis.jpg b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/oasis.jpg Binary files differnew file mode 100644 index 00000000..078a6e09 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/oasis.jpg diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/oasissmall.jpg b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/oasissmall.jpg Binary files differnew file mode 100644 index 00000000..f8d43821 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/oasissmall.jpg diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/photo.jpg b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/photo.jpg Binary files differnew file mode 100644 index 00000000..07fd4b0a --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/photo.jpg diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/seth.png b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/seth.png Binary files differnew file mode 100644 index 00000000..568360e8 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/seth.png diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/drawable/toolbar_close.png b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/toolbar_close.png Binary files differnew file mode 100644 index 00000000..12f82abb --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/drawable/toolbar_close.png diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/layout/NativeAndroidCell.axml b/Xamarin.Forms.ControlGallery.Android/Resources/layout/NativeAndroidCell.axml new file mode 100644 index 00000000..541dc07b --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/layout/NativeAndroidCell.axml @@ -0,0 +1,35 @@ +<?xml version="1.0" encoding="utf-8"?> +<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" + android:layout_width="fill_parent" + android:layout_height="wrap_content" + android:padding="8dp" + android:background="@drawable/CustomSelector"> + <LinearLayout + android:id="@+id/Text" + android:orientation="vertical" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:paddingLeft="10dip"> + <TextView + android:id="@+id/Text1" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:textColor="#FF7F3300" + android:textSize="20dip" + android:textStyle="italic" /> + <TextView + android:id="@+id/Text2" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:textSize="14dip" + android:textColor="#FF267F00" + android:paddingLeft="100dip" /> + </LinearLayout> + <ImageView + android:id="@+id/Image" + android:layout_width="48dp" + android:layout_height="48dp" + android:padding="5dp" + android:src="@drawable/icon" + android:layout_alignParentRight="true" /> +</RelativeLayout>
\ No newline at end of file diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/layout/NativeAndroidListViewCell.axml b/Xamarin.Forms.ControlGallery.Android/Resources/layout/NativeAndroidListViewCell.axml new file mode 100644 index 00000000..4c79bea8 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/layout/NativeAndroidListViewCell.axml @@ -0,0 +1,35 @@ +<?xml version="1.0" encoding="utf-8"?> +<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" + android:layout_width="fill_parent" + android:layout_height="wrap_content" + android:padding="8dp" + android:background="@drawable/CustomSelector2"> + <LinearLayout + android:id="@+id/Text" + android:orientation="vertical" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:paddingLeft="10dip"> + <TextView + android:id="@+id/Text1" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:textColor="#FF7F3300" + android:textSize="20dip" + android:textStyle="italic" /> + <TextView + android:id="@+id/Text2" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:textSize="14dip" + android:textColor="#FF267F00" + android:paddingLeft="100dip" /> + </LinearLayout> + <ImageView + android:id="@+id/Image" + android:layout_width="48dp" + android:layout_height="48dp" + android:padding="5dp" + android:src="@drawable/icon" + android:layout_alignParentRight="true" /> +</RelativeLayout>
\ No newline at end of file diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/layout/Tabbar.axml b/Xamarin.Forms.ControlGallery.Android/Resources/layout/Tabbar.axml new file mode 100644 index 00000000..97cb27ad --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/layout/Tabbar.axml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="utf-8"?> +<android.support.design.widget.TabLayout xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto" + android:id="@+id/sliding_tabs" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:background="?attr/colorPrimary" + android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar" + app:tabIndicatorColor="@android:color/white" + app:tabGravity="fill" + app:tabMode="fixed" />
\ No newline at end of file diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/layout/Toolbar.axml b/Xamarin.Forms.ControlGallery.Android/Resources/layout/Toolbar.axml new file mode 100644 index 00000000..3a1989a8 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/layout/Toolbar.axml @@ -0,0 +1,8 @@ +<android.support.v7.widget.Toolbar + xmlns:android="http://schemas.android.com/apk/res/android" + android:id="@+id/toolbar" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:background="?attr/colorPrimary" + android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar" + android:popupTheme="@style/ThemeOverlay.AppCompat.Light" /> diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/values/Colors.xml b/Xamarin.Forms.ControlGallery.Android/Resources/values/Colors.xml new file mode 100644 index 00000000..8b96fc81 --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/values/Colors.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8"?> +<resources> + <color name="cellback">#FFFFFFE0</color> + <color name="cellback2">#FFDAFF7F</color> +</resources>
\ No newline at end of file diff --git a/Xamarin.Forms.ControlGallery.Android/Resources/values/styles.xml b/Xamarin.Forms.ControlGallery.Android/Resources/values/styles.xml new file mode 100644 index 00000000..971153df --- /dev/null +++ b/Xamarin.Forms.ControlGallery.Android/Resources/values/styles.xml @@ -0,0 +1,38 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<resources> + <color name="custom_theme_color">#FF0000</color> + <style name="FormsTheme" parent="android:Theme.Holo.Light"> + <item name="android:windowActionBar">true</item> + <item name="android:windowBackground">@color/custom_theme_color</item> + </style> + + <style name="MyTheme" parent="MyTheme.Base"> + </style> + <!-- Base theme applied no matter what API --> + <style name="MyTheme.Base" parent="Theme.AppCompat.Light.DarkActionBar"> + <!--If you are using revision 22.1 please use just windowNoTitle. Without android:--> + <item name="windowNoTitle">true</item> + <!--We will be using the toolbar so no need to show ActionBar--> + <item name="windowActionBar">false</item> + <!-- Set theme colors from http://www.google.com/design/spec/style/color.html#color-color-palette--> + <!-- colorPrimary is used for the default action bar background --> + <item name="colorPrimary">#2196F3</item> + <!-- colorPrimaryDark is used for the status bar --> + <item name="colorPrimaryDark">#1976D2</item> + <!-- colorAccent is used as the default value for colorControlActivated + which is used to tint widgets --> + <item name="colorAccent">#FF4081</item> + <!-- You can also set colorControlNormal, colorControlActivated + colorControlHighlight and colorSwitchThumbNormal. --> + <item name="windowActionModeOverlay">true</item> + + <item name="android:datePickerDialogTheme">@style/AppCompatDialogStyle</item> + </style> + + <style name="AppCompatDialogStyle" parent="Theme.AppCompat.Light.Dialog"> + <item name="colorAccent">#FF4081</item> + </style> + + <style name="TestStyle" parent="@android:style/Theme.Holo.Light.DarkActionBar"> + </style> +</resources>
\ No newline at end of file |