Import inital de l'application mobile Xamarin
50
BookAStar/BookAStar.Droid/Resources/AboutResources.txt
Normal file
|
|
@ -0,0 +1,50 @@
|
|||
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.xml),
|
||||
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-hdpi/
|
||||
icon.png
|
||||
|
||||
drawable-ldpi/
|
||||
icon.png
|
||||
|
||||
drawable-mdpi/
|
||||
icon.png
|
||||
|
||||
layout/
|
||||
main.xml
|
||||
|
||||
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
|
||||
"Resource" that contains the tokens for each one of the resources included. For example,
|
||||
for the above Resources layout, this is what the Resource class would expose:
|
||||
|
||||
public class Resource {
|
||||
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 Resource.layout.main
|
||||
to reference the layout/main.xml file, or Resource.strings.first_string to reference the first
|
||||
string in the dictionary file values/strings.xml.
|
||||
6536
BookAStar/BookAStar.Droid/Resources/Resource.Designer.cs
generated
Normal file
|
After Width: | Height: | Size: 353 B |
|
After Width: | Height: | Size: 507 B |
|
After Width: | Height: | Size: 601 B |
|
After Width: | Height: | Size: 293 B |
BIN
BookAStar/BookAStar.Droid/Resources/drawable/ic_corp_icon.png
Normal file
|
After Width: | Height: | Size: 3.9 KiB |
BIN
BookAStar/BookAStar.Droid/Resources/drawable/icon.png
Normal file
|
After Width: | Height: | Size: 5.5 KiB |
BIN
BookAStar/BookAStar.Droid/Resources/drawable/nfqrcode.png
Normal file
|
After Width: | Height: | Size: 1.1 KiB |
BIN
BookAStar/BookAStar.Droid/Resources/drawable/visuel_sexion.jpg
Normal file
|
After Width: | Height: | Size: 258 KiB |
11
BookAStar/BookAStar.Droid/Resources/layout/Tabbar.axml
Normal file
|
|
@ -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" />
|
||||
8
BookAStar/BookAStar.Droid/Resources/layout/Toolbar.axml
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
<?xml version="1.0" encoding="utf-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" />
|
||||
14
BookAStar/BookAStar.Droid/Resources/values/colors.xml
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<resources>
|
||||
<color name="design_textinput_error_color" >#FFFF0000</color>
|
||||
<color name="primary" type="color">#FF2196F3</color>
|
||||
<color name="primaryDark" type="color">#FF1976D2</color>
|
||||
<color name="accent" type="color">#FFFFC107</color>
|
||||
<color name="windowBackground" type="color">#fffafafa</color>
|
||||
<integer-array name="androidcolors">
|
||||
<item>@color/primary</item>
|
||||
<item>@color/primaryDark</item>
|
||||
<item>@color/accent</item>
|
||||
<item>@color/windowBackground</item>
|
||||
</integer-array>
|
||||
</resources>
|
||||
10
BookAStar/BookAStar.Droid/Resources/values/dimens.xml
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<resources>
|
||||
<dimen name="btnwidth">56dp</dimen>
|
||||
<dimen name="design_fab_content_size">56dp</dimen>
|
||||
<dimen name="design_navigation_padding_top_default">6dp</dimen>
|
||||
<dimen name="design_tab_min_width">15dp</dimen>
|
||||
<dimen name="dialog_fixed_height_major">150dp</dimen>
|
||||
<dimen name="dialog_fixed_width_major">250dp</dimen>
|
||||
<dimen name="dialog_fixed_width_minor">100dp</dimen>
|
||||
</resources>
|
||||
17
BookAStar/BookAStar.Droid/Resources/values/strings.xml
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<string name="app_name">Booking star</string>
|
||||
<string name="yavscIdentRemoved">Identification supprimée</string>
|
||||
<string name="yavscAccountTypeName">Booking star</string>
|
||||
<string name="cancel">Annuler</string>
|
||||
<string name="Settings">Paramètres</string>
|
||||
<string name="Title">Title</string>
|
||||
<string name="Description">Description</string>
|
||||
<string name="Date">Date</string>
|
||||
<string name="Location">Location</string>
|
||||
<string name="Pricing">Pricing</string>
|
||||
<string name="url">url</string>
|
||||
<string name="url_hint">url_hint</string>
|
||||
<string name="picture">picture</string>
|
||||
<string name="GoogleSenderId">AA325408689282</string>
|
||||
</resources>
|
||||
33
BookAStar/BookAStar.Droid/Resources/values/styles.xml
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<resources>
|
||||
|
||||
<style name="MainTheme" parent="MainTheme.Base">
|
||||
</style>
|
||||
<!-- Base theme applied no matter what API -->
|
||||
<style name="MainTheme.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>
|
||||
<!--If you are using revision 22.1 please use just windowNoTitle. Without android:-->
|
||||
|
||||
</style>
|
||||
|
||||
<style name="AppCompatDialogStyle" parent="Theme.AppCompat.Light.Dialog">
|
||||
<item name="colorAccent">#FF4081</item>
|
||||
</style>
|
||||
</resources>
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
<?xml version="1.0" encoding="utf-8" ?>
|
||||
<resources>
|
||||
<!--
|
||||
Base application theme for API 21+. This theme replaces
|
||||
MyTheme from resources/values/styles.xml on API 21+ devices.
|
||||
-->
|
||||
<style name="MyTheme" parent="MyTheme.Base">
|
||||
<item name="android:windowContentTransitions">true</item>
|
||||
<item name="android:windowAllowEnterTransitionOverlap">true</item>
|
||||
<item name="android:windowAllowReturnTransitionOverlap">true</item>
|
||||
<item name="android:windowSharedElementEnterTransition">@android:transition/move</item>
|
||||
<item name="android:windowSharedElementExitTransition">@android:transition/move</item>
|
||||
</style>
|
||||
</resources>
|
||||