...
 
Commits (11)
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/kotlin-for-android.iml" filepath="$PROJECT_DIR$/kotlin-for-android.iml" />
</modules>
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="RunConfigurationProducerService">
<option name="ignoredProducers">
<set>
<option value="org.jetbrains.plugins.gradle.execution.test.runner.AllInPackageGradleConfigurationProducer" />
<option value="org.jetbrains.plugins.gradle.execution.test.runner.TestClassGradleConfigurationProducer" />
<option value="org.jetbrains.plugins.gradle.execution.test.runner.TestMethodGradleConfigurationProducer" />
</set>
</option>
</component>
</project>
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="" vcs="Git" />
</component>
</project>
\ No newline at end of file
......@@ -34,3 +34,16 @@ CHANGELOG](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/CHANGELOG.md)).
### Added, Fixed, Security, Removed, Deprecated, Changed, Performance, Other (X Merge Requests)
* Add screen of the in-app purchase
## Version 1.5 `versionCode 7` (12-12-2018)
### Added
* Add content 1-b
* Add link purchase screen
## Version 1.5 `versionCode 8` (24-01-2019)
### Added
* Add first content part in incremental way
* Add code to access premium
# Mobile Application : Kotlin For Android
![Kotlin4Android Icon][]
# Mobile Education Application : Kotlin For Android
This application is a show case of _Android_ development with _Kotlin_ language,
using _Anko_ libraries.
[<img src="https://gitlab.com/chillcoding-at-the-beach/kotlin-for-android/raw/master/app/src/main/ic_launcher-web.png" width="10%">](https://play.google.com/apps/testing/com.chillcoding.kotlin)
« Kotlin For Android » is a demo of an **Android** application, entirely coded in **Kotlin**!
In particular, it is a show case of **Android** development with **Kotlin** language,
using *Anko* libraries.
It invites you to learn **Kotlin** through different themes:
* 1o1 Android
* Kotlin
* Native User Interface, Material Design
* Interactive User Interface
* Adapter, RecyclerView
* User Settings, Shared Preference
* Developer Tools
* Data Base
* Network
* Sensor
* Map
* Publication
These themes can be viewed in disorder, like a game who you are the hero.
♦ Don't hesitate to open an issue to send feedback 👉
## Demo
[Download Kotlin For Android, in Beta version](https://play.google.com/apps/testing/com.chillcoding.kotlin)
[Download on **Google Play** (Beta version)](https://play.google.com/apps/testing/com.chillcoding.kotlin)
## Article en Français (FR)
* [Installer un environnement de développement Android \[AK 1\]](https://www.chillcoding.com/blog/2016/08/03/android-studio-installation/)
* [Comprendre la configuration d'un projet Android Studio \[AK 2\]](https://www.chillcoding.com/blog/2017/09/28/configurer-kotlin-projet-android/)
* [Dessiner un coeur dans une vue en Kotlin avec Android \[AK 2\]](https://www.chillcoding.com/android-custom-view-heart/)
* [Android References \[AK 3 D\]](https://www.chillcoding.com/blog/2017/01/27/android-references/)
* [Top 6 des raccourcis dans Android Studio (AK 3 E)](https://www.chillcoding.com/blog/2016/04/01/android-top-raccourcis/)
* [Utiliser les extensions Kotlin pour accéder facilement aux éléments de la vue \[AK 4 A\]](https://www.chillcoding.com/blog/2017/10/03/utiliser-extensions-kotlin/)
* [UI Cheatsheet (AK 4 B)](https://www.chillcoding.com/blog/2017/01/16/android-ui-cheatsheet/)
* [Utiliser la bibliothèque Anko \[AK 4 C\]](https://www.chillcoding.com/blog/2017/10/09/utiliser-anko-kotlin-android/)
* [Afficher une liste d'éléments avec un RecyclerView \[AK 6\]](https://www.chillcoding.com/blog/2018/10/22/creer-liste-recyclerview-kotlin-android/)
* [Utiliser le fichier de Préférences \[AK 7\]](https://www.chillcoding.com/blog/2014/10/10/utiliser-fichier-preferences/)
* [Créer une base de données locale avec Anko SQLite \[AK 8\]](https://www.chillcoding.com/blog/2018/01/17/creer-bdd-sqlite-kotlin-android/)
* [Faire une requête HTTP GET avec Retrofit en Kotlin Android (AK 9)](https://www.chillcoding.com/blog/2017/03/14/requete-http-get-retrofit-android/)
Autres articles :
* [L'extraordinaire Humanoïde !](https://www.chillcoding.com/blog/2014/08/08/extraordinaire-humanoide/)
* [Introduction à Kotlin](https://www.chillcoding.com/blog/2017/07/11/android-kotlin-introduction/)
* [Déployer une app. Android Wear sur une smartwatch](https://www.chillcoding.com/blog/2016/06/14/android-wear-configuration/)
## Features
......@@ -38,28 +78,3 @@ using _Anko_ libraries.
* Retrofit - http://square.github.io/retrofit
* Moshi - https://github.com/square/moshi
* OkHttp - http://square.github.io/okhttp
## Article en Français (FR)
* [Installer un environnement de développement Android \[AK 1\]](https://www.chillcoding.com/blog/2016/08/03/android-studio-installation/)
* [Comprendre la configuration d'un projet Android Studio \[AK 2\]](https://www.chillcoding.com/blog/2017/09/28/configurer-kotlin-projet-android/)
* [Dessiner un coeur dans une vue en Kotlin avec Android \[AK 2\]](https://www.chillcoding.com/android-custom-view-heart/)
* [Android References \[AK 3 D\]](https://www.chillcoding.com/blog/2017/01/27/android-references/)
* [Top 6 des raccourcis dans Android Studio (AK 3 E)](https://www.chillcoding.com/blog/2016/04/01/android-top-raccourcis/)
* [Utiliser les extensions Kotlin pour accéder facilement aux éléments de la vue \[AK 4 A\]](https://www.chillcoding.com/blog/2017/10/03/utiliser-extensions-kotlin/)
* [UI Cheatsheet (AK 4 B)](https://www.chillcoding.com/blog/2017/01/16/android-ui-cheatsheet/)
* [Utiliser la bibliothèque Anko \[AK 4 C\]](https://www.chillcoding.com/blog/2017/10/09/utiliser-anko-kotlin-android/)
* [Afficher une liste d'éléments avec un RecyclerView \[AK 6\]](https://www.chillcoding.com/blog/2018/10/22/creer-liste-recyclerview-kotlin-android/)
* [Utiliser le fichier de Préférences \[AK 7\]](https://www.chillcoding.com/blog/2014/10/10/utiliser-fichier-preferences/)
* [Créer une base de données locale avec Anko SQLite \[AK 8\]](https://www.chillcoding.com/blog/2018/01/17/creer-bdd-sqlite-kotlin-android/)
* [Faire une requête HTTP GET avec Retrofit en Kotlin Android (AK 9)](https://www.chillcoding.com/blog/2017/03/14/requete-http-get-retrofit-android/)
Bonus :
* [L'extraordinaire Humanoïde !](https://www.chillcoding.com/blog/2014/08/08/extraordinaire-humanoide/)
* [Introduction à Kotlin](https://www.chillcoding.com/blog/2017/07/11/android-kotlin-introduction/)
* [Déployer une app. Android Wear sur une smartwatch](https://www.chillcoding.com/blog/2016/06/14/android-wear-configuration/)
[Kotlin4Android Icon]:
https://gitlab.com/chillcoding-at-the-beach/kotlin-for-android/raw/master/app/src/main/ic_launcher-web.png
......@@ -6,19 +6,21 @@ apply plugin: 'kotlin-android-extensions'
android {
compileSdkVersion 26
buildToolsVersion '28.0.3'
defaultConfig {
applicationId "com.chillcoding.kotlin"
minSdkVersion 15
targetSdkVersion 26
versionCode 6
versionCode 9
versionName "1.5"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
multiDexEnabled true
}
buildTypes {
release {
multiDexEnabled true
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
lintOptions {
......@@ -34,12 +36,11 @@ android {
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation "org.jetbrains.kotlin:kotlin-stdlib-jre7:$kotlin_version"
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation "com.android.support:appcompat-v7:$support_version"
implementation "com.android.support:gridlayout-v7:$support_version"
implementation "com.android.support:cardview-v7:$support_version"
implementation 'com.android.support.constraint:constraint-layout:1.0.2'
implementation "org.jetbrains.anko:anko-common:$anko_version"
implementation "org.jetbrains.anko:anko-support-v4-commons:$anko_version"
implementation "com.android.support:preference-v7:$support_version"
implementation "org.jetbrains.anko:anko-sqlite:$anko_version"
......@@ -48,8 +49,8 @@ dependencies {
implementation "com.squareup.okhttp3:okhttp:$okhttp_version"
implementation "com.squareup.retrofit2:converter-moshi:$retrofit_version"
implementation "com.android.support:support-v4:$support_version"
compile 'com.google.android.gms:play-services:11.8.0'
compile 'com.squareup.picasso:picasso:2.5.2'
implementation 'com.google.android.gms:play-services:11.8.0'
implementation 'com.squareup.picasso:picasso:2.5.2'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.1'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1'
......
<!doctype html>
<html>
<body>
<h2>Glossary</h2>
<p><b>IDE</b>: <i>Integrated Development Environment</i>.</p>
<p><b>Framework Android</b>: tools to develop Android application.</p>
<p><b>Manifest</b>: </p>
<p><b>NDK</b>: <i>Native Development Kit</i>.</p>
<p><b>OHA</b>: <i>Open Handset Alliance</i>.</p>
<p><b>OS</b>: <i>Operating System</i>.</p>
<p><b>SDK</b>: <i>System Development Kit</i>.</p>
</body>
</html>
......@@ -3,5 +3,104 @@
<body>
<h2>Android Platform</h2>
<p>The <b>Android</b> platform is an <i>Operating System</i> (OS) for mobile phone.</p>
<table>
<tr>
<th>Date</th>
<th>Name</th>
<th>Version</th>
<th>API</th>
</tr>
<tr>
<td>April 2009</td>
<td>Cupcake</td>
<td>1.5</td>
<td>3</td>
</tr>
<tr>
<td>September 2009</td>
<td>Donut</td>
<td>1.6</td>
<td>4</td>
</tr>
<tr>
<td>October 2009</td>
<td>Eclair</td>
<td>2.1</td>
<td>7</td>
</tr>
<tr>
<td>May 2010</td>
<td>Froyo</td>
<td>2.2</td>
<td>8</td>
</tr>
<tr>
<td>December 2010</td>
<td>Gingerbread</td>
<td>2.3</td>
<td>10</td>
</tr>
<tr>
<td>Febrary 2011</td>
<td>Honeycomb</td>
<td>3.X</td>
<td>13</td>
</tr>
<tr>
<td>October 2011</td>
<td>Ice Cream Sandwich</td>
<td>4.0</td>
<td>15</td>
</tr>
<tr>
<td>June 2012</td>
<td>Jelly Bean</td>
<td>4.1</td>
<td>18</td>
</tr>
<tr>
<td>October 2013</td>
<td>KitKat</td>
<td>4.4</td>
<td>20</td>
</tr>
<tr>
<td>October 2014</td>
<td>Lollipop</td>
<td>5.1</td>
<td>21</td>
</tr>
<tr>
<td>October 2015</td>
<td>Marshmallow</td>
<td>6.0</td>
<td>23</td>
</tr>
<tr>
<td>October 2016</td>
<td>Nougat</td>
<td>7.0</td>
<td>24</td>
</tr>
<tr>
<td>September 2017</td>
<td>Oreo</td>
<td>8.0</td>
<td>26</td>
</tr>
<tr>
<td>August 2018</td>
<td>Pie</td>
<td>9.0</td>
<td>28</td>
</tr>
</table>
<p>The most important to know is the API number and its corresponding name ;
because in configuration file the API number is used to indicate the minimum
targeted version, the current targeted version and the compile used version.</p>
<p>Generally an <b>Android</b> version is propagated on more than 70% of <b>Android</b>
devices in two years.</p>
<h4>Next part</h4>
<a href="file:///android_asset/1B-developmentenvironment.html">Development environnement</a>
</body>
</html>
<!doctype html>
<html>
<body>
<h2>Developement environment</h2>
</body>
</html>
<!doctype html>
<html>
<body>
<h2>Development environment</h2>
<h3>Java, Kotlin or C/C++ language</h3>
It is possible to <i>TRY</i> <i>Kotlin</i> on
<a href="https://try.kotlinlang.org">official site</a> (Kotlin Koans part).
<h3>Android Studio</h3>
It is possible to download <i>Android Studio</i> on
<a href="https://developer.android.com/studio/">developper.android.com</a>
<p><i>Android Studio</i> main functionalities:
<ul>
<li>Start a new Android Studio project</li>
<li>Open an existing Android Studio projec</li>
<li>Check out project from Version Control(GIT, SVN)</li>
<li>Profile or debug APK</li>
<li>Import project from <i>Eclipse</i>, etc.</li>
<li>Import an Android code sample</li>
</ul></p>
<p>
<i>APK</i> stands for <i>Android Application Package</i>. It is build with
<i>Gradle</i> files.
</p>
<p>The <i>Android SDK</i> contains:
<ul>
<li><i>aapt</i> (<i>Android Asset Packaging Tool</i>), to create and analyze
<i>APK</i> files.</li>
<li><i>adb</i> (<i>Android Debug Bridge</i>), to establish connections with
an <i>Android</i> device or an emulator (access to their <i>shell</i>, transfer data etc.).</li>
<li><i>ddms</i> (<i>Dalvik Debug Monitor Server</i>), to debug app, make
screen capture, see processus, messages console, simulate messages sending,
call and <i>GPS</i> position, etc.</li>
<li>Emulator system</li>
<li>Sample projects</li>
</ul>
</p>
<p>After the install of <i>Android Studio</i>, to see details of downloaded
files, go to <i>SDK Manager</i> (from <i>Configure</i> menu), then click on
<i>Show Package Details</i>. </p>
<p>Then <i>SDK Tools</i> part show tools like:
<ul>
<li><i>Android SDK Build-Tools</i></li>
<li><i>Android SDK Platforms-Tools</i></li>
<li><i>Android SDK Tools</i></li>
<li><i>Android SDK Emulator</i></li>
<li><i>Intel x86 Emulator Accelerator (HAXM installer)</i>, tools to have fast emulator</li>
</ul>
</p>
<p>The field <i>Android SDK Location</i> inform of the <i>SDK
Android</i> location on computer. The <i>sdk</i> repository contains:
<ul>
<li><i>build-tools</i>, tools to create APK</li>
<li><i>emulator</i>, created emulator(s)</li>
<li><i>extras</i>, downloaded tools</li>
<li><i>platforms-tools</i>, tools to develop and debug app</li>
<li><i>platforms</i>, all downloaded <i>SDK</i> versions, classed by API version</li>
<li><i>skins</i>, related to emulator</li>
<li><i>system-images</i>, emulator factory</li>
<li><i>tools</i>, tools to use <i>Android SDK</i></li>
</ul>
</p>
<p>The most important repository is <i>platforms-tools</i> because it contains
the <code>adb</code> command line tool.</p>
<h4>Next part</h4>
<a href="file:///android_asset/1C-programmingconcepts.html">Programming concepts</a>
</body>
</html>
......@@ -101,7 +101,7 @@
un appareil <i>Android</i> ou un émulateur, cela en facilitant l'accès à leur
<i>shell</i>, de cette façon il est possible de parcourir le contenu de l'appareil,
d'éxecuter des commandes, de transférer des applications ou des fichiers.</li>
<li><i>ddms</i> (<i>Dalvik Debug Monitor Service</i>), sert au débogage de
<li><i>ddms</i> (<i>Dalvik Debug Monitor Server</i>), sert au débogage de
l'application et à faire des captures d'écran, voir les processus en cours d'exécution
voir la console des messages d'erreur, simuler l'envoi de messages et d'appels,
simuler une position <i>GPS</i>, etc.</li>
......@@ -139,7 +139,7 @@
<li><i>platforms</i>, les différentes versions de <i>SDK</i> téléchargées, organisées par numéro de version</li>
<li><i>skins</i>, les façades des émulateurs</li>
<li><i>system-images</i>, les fabriques d'émulateur</li>
<li><i>tools</i>, les outils facilitant l'iutilisation du <i>SDK Android</i></li>
<li><i>tools</i>, les outils facilitant l'utilisation du <i>SDK Android</i></li>
</ul>
</p>
<h3>Déploiement</h3>
......
......@@ -162,7 +162,7 @@ est enlevé de la pile (∅|A|).</p>
des processus (activité) est en cours d’exécution. Dans la pratique, il y a
une exception à la règle (abordé dans la partie « Interface Utilisateur Native »).</p>
<p>Le schéma suivant, en anglais, illustre le cycle de vie d'une <i>Activity</i>.<br>
<img src="file:///android_asset/img/activity_lifecycle.png" alt="Architecture Android en cinq couches"/>
<img src="file:///android_asset/img/activity_lifecycle.png" alt="Activity lifecycle"/>
Les cinq états se retrouvent dans les méthodes associées aux mots anglais :
<ul>
<li><i>Created, Started</i> : en création</li>
......
......@@ -2,5 +2,31 @@
<html>
<body>
<h2>Programming concepts</h2>
<h3>Android Architecture</h3>
<img src="file:///android_asset/img/architecture.png" alt="Android Architecture"/>
<h3>Android component</h3>
<p>The main <i>Android</i> components:
<ul>
<li><i>Activity</i></li>
<li><i>Fragment</i></li>
<li><i>Service</i></li>
<li><i>BroadcastReceiver</i></li>
<li><i>Content Provider</i></li>
<li><i>Intent</i></li>
<li><i>Application</i></li>
</ul></p>
<p>The <i>Activity</i> lifecycle:<br>
<img src="file:///android_asset/img/activity_lifecycle.png" alt="Activity lifecycle"/></p>
<p>Example of <i>Manifeste</i> file:<br>
<code>
&lt;manifest xmlns:android="http://schemas.android.com/apk/res/android"
 package="com.chillcoding.hello"&gt;
<br>&lt;uses-permission android:name="android.permission.INTERNET"/&gt;
&lt;application
<br>android:allowBackup="true"
<br>android:icon="@mipmap/ic_launcher"
<br>android:label="@string/app_name"
<br>android:theme="@style/AppTheme"&gt;
<br>&lt;activity
<br>android:name="com.chillcoding.hello"/&gt;
&lt;/manifest&gt;
</code>
</p>
<h4>Next part</h4>
<a href="file:///android_asset/1D-firstproject.html">First project.</a>
</body>
</html>
......@@ -2,5 +2,39 @@
<html>
<body>
<h2>First project</h2>
<h3>Tree view</h3>
<p>
app/<br>
-manifests<br>
-java<br>
-res<br>
--drawable<br>
--layout<br>
--values<br>
--menu<br>
Gradle Scripts<br>
</p>
<h3>Key files</h3>
<p>Main files and repertories in <i>Android</i> project:
<ul>
<li>Manifeste: Declares <i>Activity</i> and their behaviour</li>
<li><code>java/</code>: the directory with source files, the <i>Kotlin</i> code
(or <i>Java</i> code) organised in <code>package</code></li>
<li><code>res/</code>: the directory of ressources</li>
<li><code>drawable/</code>: the directory of images</li>
<li><code>mipmap/</code>: the directory of icons</li>
<li><code>layout/</code>: the directory for graphic interfaces</li>
<li><code>values/</code>: the directory of color variables, string,
dimension, style, ...</li>
<li><code>gen/R</code>: generated files</li>
<li><code>Gradle Scripts</code> : contains two main files of configuration
one for the project, the other for the <code>app/</code> module</li>
</ul>
</p>
<p>Finaly, in this theme « 101 Android » we reach the Android platform,
the development environment, the programming concepts and a first project.</p>
<cite>« Alone we go faster,
together we go further.»</cite>
<br>-> african proverb
</body>
</html>
[
{
"question": "What is Android?",
"opt": [
"an operating system",
"a banana",
"a mobile phone",
"a framework"
],
"ans": 0
},
{
"question": "What is Kotlin?",
"opt": [
"an exchange system",
"a language",
"a tool",
"an Android plugin"
],
"ans": 1
},
{
"question": "Android OS was designed for phone and tablet in which version?",
"opt": [
"KitKat",
"Lollipop",
"Marshmallow",
"Ice Cream Sandwich"
],
"ans": 3
},
{
"question": "What is the executable for Android application?",
"opt": [
"APK, Android Application Package",
"APP, Application",
"EXE, Executable",
"DMG, Disk Image"
],
"ans": 0
},
{
"question": "Where is all the permissions are defined?",
"opt": [
"in AndroidManifest.xml file",
"in Graddle file",
"in res folder",
"in Google Play console developer"
],
"ans": 0
},
{
"question": "Android is based on wich kernel?",
"opt": [
"Linux Kernel",
"Mac Kernel",
"Windows Kernel",
"Hybrid Kernel"
],
"ans": 0
},
{
"question": "What does AAPT stand for",
"opt": [
"Application Asset Packaging Tool",
"Android Asset Packaging Tool",
"Asset Android Packaging Tool",
"Application Asset Packing Tool"
],
"ans": 1
},
{
"question": "Which class present a screen to user?",
"opt": [
"Broadcast Receiver",
"Service",
"Activity",
"Content Provider"
],
"ans": 2
},
{
"question": "What does ADT stand for",
"opt": [
"Android Development Tool",
"Application Development Tool",
"Asset Development Tool",
"Android Debug Tool"
],
"ans": 0
},
{
"question": "Which method is called when the Activity is visible?",
"opt": [
"onCreate()",
"onRestart()",
"onPause()",
"onStart()"
],
"ans": 3
},
{
"question": "What does DDMS stand for",
"opt": [
"Data Debug Monitor Server",
"Data Dalvik Monitor System",
"Dalvik Debug Monitor Server",
"Dalvik Debug Monitor Service"
],
"ans": 2
},
{
"question": "Which method is call to finish an Activity?",
"opt": [
"onStart()",
"finish()",
"close()",
"onDestroy()"
],
"ans": 1
}
]
[
{
"question": "Qu'est-ce qu'Android ?",
"opt": [
"un système d'exploitation mobile",
"une banane",
"un mobile",
"un framework"
],
"ans": 0
},
{
"question": "Qu'est-ce que Kotlin ?",
"opt": [
"un système d'échange",
"un langage",
"un plugin",
"un outil"
],
"ans": 1
},
{
"question": "En quoi la fragmentation des versions Android est un inconvénient ?",
"opt": [
"il faut créer une app. pour chaque version",
"il faut gérer la compatibilité de l'app. pour les différentes versions",
"il faut souvent mettre à jour son téléphone Android",
"il y a des problèmes de compatibilité entre les composants Android"
],
"ans": 1
},
{
"question": "À partir de quelle version, l'OS Android a été conçu pour tablette et smartphone ?",
"opt": [
"KitKat",
"Lollipop",
"Marshmallow",
"Ice Cream Sandwich"
],
"ans": 3
},
{
"question": "Comment s’appelle l’exécutable d’une application Android ?",
"opt": [
"APK pour Android Application Package",
"APP pour Application",
"EXE pour Executable",
"DMG pour Disk Image"
],
"ans": 0
},
{
"question": "Où sont déclarées les permissions ?",
"opt": [
"dans le fichier AndroidManifest.xml, à l'intérieur de la balise application",
"dans le fichier Graddle, au niveau des dépendences",
"dans le fichier Manifest, à l'intérieur de la balise manifest et à l'extérieur de la balise application",
"dans la console développeur de Google Play"
],
"ans": 2
},
{
"question": "Sur quel noyaux est basé Android ?",
"opt": [
"Linux Kernel",
"Mac Kernel",
"Windows Kernel",
"Hybrid Kernel"
],
"ans": 0
},
{
"question": "Que signifie l'acronyme AAPT ?",
"opt": [
"Application Asset Packaging Tool",
"Android Asset Packaging Tool",
"Asset Android Packaging Tool",
"Application Asset Packing Tool"
],
"ans": 1
},
{
"question": "Quel classe est utilisé pour représenter un écran utilisateur ?",
"opt": [
"Broadcast Receiver",
"Service",
"Activity",
"Content Provider"
],
"ans": 2
},
{
"question": "Quelle méthode est invoquée lorsque l'Activity est visible ?",
"opt": [
"onCreate()",
"onRestart()",
"onPause()",
"onStart()"
],
"ans": 3
},
{
"question": "Quelle méthode est utilisée pour fermer une Activity ?",
"opt": [
"onStart()",
"finish()",
"close()",
"onDestroy()"
],
"ans": 1
},
{
"question": "Qu'est-ce qu'un Bundle ?",
"opt": [
"un objet qui contient des données (primitives ou Parcelable) à partager entre les composantes Android",
"un paramètre de la fonction onResume()",
"un objet qui indique l'état de l'Activity",
"un objet permettant de lancer un autre écran"
],
"ans": 0
}
]
......@@ -13,6 +13,7 @@ class App : Application() {
val FRAGMENT_ABOUT = 1
val FRAGMENT_WEB_VIEW = 2
val FRAGMENT_EXP_LIST = 3
val FRAGMENT_QUIZ = 4
const val BUNDLE_PART = "BUNDLDE_PART"
const val BUNDLE_URL = "BUNDLDE_URL"
const val BUNDLE_TOC = "BUNDLDE_TOC"
......
package com.chillcoding.kotlin.model
data class Question(val question: String = "What is Android?", val opt: Array<String> = arrayOf("a mobile", "a banana", "an operating system", "a market"), val ans: Int = 2)
\ No newline at end of file
......@@ -7,10 +7,7 @@ import android.support.v7.app.AppCompatActivity
import com.chillcoding.kotlin.App
import com.chillcoding.kotlin.R
import com.chillcoding.kotlin.tool.setFragment
import com.chillcoding.kotlin.view.fragment.AboutFragment
import com.chillcoding.kotlin.view.fragment.ExpandableListFragment
import com.chillcoding.kotlin.view.fragment.SettingsFragment
import com.chillcoding.kotlin.view.fragment.WebViewFragment
import com.chillcoding.kotlin.view.fragment.*
import kotlinx.android.synthetic.main.app_bar.*
class FragmentContainerActivity : AppCompatActivity() {
......@@ -35,13 +32,19 @@ class FragmentContainerActivity : AppCompatActivity() {
}
App.FRAGMENT_WEB_VIEW -> {
setFragment(WebViewFragment())
supportActionBar!!.title = resources.getStringArray(R.array.title_session)[0]
supportActionBar?.setBackgroundDrawable(ColorDrawable(App.sColors[0]))
supportActionBar!!.title = resources.getStringArray(R.array.title_session)[intent.getIntExtra(App.BUNDLE_PART, 0)]
supportActionBar?.setBackgroundDrawable(ColorDrawable(App.sColors[intent.getIntExtra(App.BUNDLE_PART, 0)]))
}
App.FRAGMENT_EXP_LIST -> {
setFragment(ExpandableListFragment())
supportActionBar!!.title = resources.getStringArray(R.array.title_session)[0]
supportActionBar?.setBackgroundDrawable(ColorDrawable(App.sColors[0]))
supportActionBar!!.title = resources.getStringArray(R.array.title_session)[intent.getIntExtra(App.BUNDLE_PART, 0)]
supportActionBar?.setBackgroundDrawable(ColorDrawable(App.sColors[intent.getIntExtra(App.BUNDLE_PART, 0)]))
}
App.FRAGMENT_QUIZ -> {
if (savedInstanceState == null)
setFragment(QuizFragment())
supportActionBar!!.title = getString(R.string.label_quiz)
supportActionBar?.setBackgroundDrawable(ColorDrawable(App.sColors[intent.getIntExtra(App.BUNDLE_PART, 0)]))
}
}
}
......
......@@ -42,13 +42,15 @@ class ScrollingActivity : AppCompatActivity() {
fab.setImageResource(R.drawable.ic_check)
fab.setOnClickListener { toast("cool") }
srollBtnPrez.setOnClickListener { browse(urlPrez[index]) }
scrollBtn.setOnClickListener { startActivity<FragmentContainerActivity>(FragmentContainerActivity.FRAGMENT_ID to App.FRAGMENT_EXP_LIST, App.BUNDLE_TOC to tocArray, App.BUNDLE_URL_ARRAY to urlArray) }
scrollBtn.setOnClickListener { startActivity<FragmentContainerActivity>(FragmentContainerActivity.FRAGMENT_ID to App.FRAGMENT_EXP_LIST, App.BUNDLE_TOC to tocArray, App.BUNDLE_URL_ARRAY to urlArray, App.BUNDLE_PART to index) }
scrollList.setOnItemClickListener { parent, view, position, id ->
startActivity<FragmentContainerActivity>(FragmentContainerActivity.FRAGMENT_ID to App.FRAGMENT_WEB_VIEW, App.BUNDLE_URL to urlArray[position])
startActivity<FragmentContainerActivity>(FragmentContainerActivity.FRAGMENT_ID to App.FRAGMENT_WEB_VIEW, App.BUNDLE_URL to urlArray[position], App.BUNDLE_PART to index)
}
scrollBtnQuiz.setOnClickListener { startActivity<FragmentContainerActivity>(FragmentContainerActivity.FRAGMENT_ID to App.FRAGMENT_QUIZ, App.BUNDLE_PART to index) }
} else {
scrollBtn.visibility = View.GONE
srollBtnPrez.visibility = View.GONE
scrollBtnQuiz.visibility = View.GONE
}
}
......
package com.chillcoding.kotlin.view.fragment
import android.os.Bundle
import android.support.v4.app.Fragment
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import com.chillcoding.kotlin.App
import com.chillcoding.kotlin.R
import com.chillcoding.kotlin.model.Question
import com.squareup.moshi.JsonAdapter
import com.squareup.moshi.Moshi
import com.squareup.moshi.Types
import kotlinx.android.synthetic.main.fragment_quiz.*
import okio.Okio
import org.jetbrains.anko.support.v4.alert
import org.jetbrains.anko.support.v4.toast
import java.io.IOException
import java.nio.charset.Charset
/**
* A simple quiz [Fragment].
*
*/
class QuizFragment : Fragment() {
lateinit var quiz: List<Question>
var questionIndex = 0
var question = Question()
var score = 0
companion object {
const val BUNDLE_QUESTION_INDEX = "question index key"
const val BUNDLE_SCORE = "score key"
}
override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?,
savedInstanceState: Bundle?): View? {
// Inflate the layout for this fragment
return inflater.inflate(R.layout.fragment_quiz, container, false)
}
override fun onViewCreated(view: View?, savedInstanceState: Bundle?) {
getAllQuestions()
showQuestion()
quizBtn.setOnClickListener { submitAnswer() }
}
fun showNextQuestion() {
questionIndex++
quizRadio.clearCheck()
showQuestion()
}
fun showQuestion() {
if (questionIndex < quiz.size) {
question = quiz[questionIndex]
quizQuestion.text = question.question
quizOpt0.text = question.opt[0]
quizOpt1.text = question.opt[1]
quizOpt2.text = question.opt[2]
quizOpt3.text = question.opt[3]
} else
showScore()
}
private fun showScore() {
quizScore.visibility = View.VISIBLE
if (score > 0)
quizScore.text = "${getString(R.string.text_good_match)}\n ${getString(R.string.text_score)} $score / ${quiz.size}"
else
quizScore.text = "${getString(R.string.text_replay)}"
quizQuestion.visibility = View.GONE
quizRadio.visibility = View.GONE
quizBtn.visibility = View.GONE
}
private fun submitAnswer() {
var correctAnswer = false
when (quizRadio.checkedRadioButtonId) {
R.id.quizOpt0 -> if (question.ans == 0) correctAnswer = true
R.id.quizOpt1 -> if (question.ans == 1) correctAnswer = true
R.id.quizOpt2 -> if (question.ans == 2) correctAnswer = true
R.id.quizOpt3 -> if (question.ans == 3) correctAnswer = true
}
if (correctAnswer) {
toast(R.string.text_good_answer)
score++
showNextQuestion()
} else {
alert("« ${question.opt[question.ans]} » ${getString(R.string.text_was_correct)}") {
positiveButton(getString(R.string.action_next)) { showNextQuestion() }
}.show()
}
}
private fun getAllQuestions() {
val type = Types.newParameterizedType(List::class.java, Question::class.java)
val moshi = Moshi.Builder().build()
val jsonAdapter: JsonAdapter<List<Question>> = moshi.adapter(type)
quiz = jsonAdapter.fromJson(loadJSONFromAsset())
}
private fun loadJSONFromAsset(): String {
try {
val input = activity.assets.open(resources.getStringArray(R.array.path_quiz)[activity.intent.getIntExtra(App.BUNDLE_PART, 0)])
val source = Okio.buffer(Okio.source(input))
return source.readByteString().string(Charset.forName("utf-8"))
} catch (ex: IOException) {
ex.printStackTrace()
}
return ""
}
override fun onSaveInstanceState(outState: Bundle?) {
super.onSaveInstanceState(outState)
outState?.putInt(BUNDLE_QUESTION_INDEX, questionIndex)
outState?.putInt(BUNDLE_SCORE, score)
}
override fun onViewStateRestored(savedInstanceState: Bundle?) {
super.onViewStateRestored(savedInstanceState)
if (savedInstanceState != null) {
questionIndex = savedInstanceState.getInt(BUNDLE_QUESTION_INDEX)
score = savedInstanceState.getInt(BUNDLE_SCORE)
}
showQuestion()
}
}
<vector xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:aapt="http://schemas.android.com/aapt"
android:width="108dp"
android:height="108dp"
android:viewportHeight="108"
android:viewportWidth="108">
<path
android:fillType="evenOdd"
android:pathData="M32,64C32,64 38.39,52.99 44.13,50.95C51.37,48.37 70.14,49.57 70.14,49.57L108.26,87.69L108,109.01L75.97,107.97L32,64Z"
android:strokeColor="#00000000"
android:strokeWidth="1">
<aapt:attr name="android:fillColor">
<gradient
android:endX="78.5885"
android:endY="90.9159"
android:startX="48.7653"
android:startY="61.0927"
android:type="linear">
<item
android:color="#44000000"
android:offset="0.0" />
<item
android:color="#00000000"
android:offset="1.0" />
</gradient>
</aapt:attr>
</path>
<path
android:fillColor="#FFFFFF"
android:fillType="nonZero"
android:pathData="M66.94,46.02L66.94,46.02C72.44,50.07 76,56.61 76,64L32,64C32,56.61 35.56,50.11 40.98,46.06L36.18,41.19C35.45,40.45 35.45,39.3 36.18,38.56C36.91,37.81 38.05,37.81 38.78,38.56L44.25,44.05C47.18,42.57 50.48,41.71 54,41.71C57.48,41.71 60.78,42.57 63.68,44.05L69.11,38.56C69.84,37.81 70.98,37.81 71.71,38.56C72.44,39.3 72.44,40.45 71.71,41.19L66.94,46.02ZM62.94,56.92C64.08,56.92 65,56.01 65,54.88C65,53.76 64.08,52.85 62.94,52.85C61.8,52.85 60.88,53.76 60.88,54.88C60.88,56.01 61.8,56.92 62.94,56.92ZM45.06,56.92C46.2,56.92 47.13,56.01 47.13,54.88C47.13,53.76 46.2,52.85 45.06,52.85C43.92,52.85 43,53.76 43,54.88C43,56.01 43.92,56.92 45.06,56.92Z"
android:strokeColor="#00000000"
android:strokeWidth="1" />
</vector>
app/src/main/res/drawable/cupcake.png

56.9 KB | W: | H:

app/src/main/res/drawable/cupcake.png

15.3 KB | W: | H:

app/src/main/res/drawable/cupcake.png
app/src/main/res/drawable/cupcake.png
app/src/main/res/drawable/cupcake.png
app/src/main/res/drawable/cupcake.png
  • 2-up
  • Swipe
  • Onion skin
app/src/main/res/drawable/eclair.png

29.6 KB | W: | H:

app/src/main/res/drawable/eclair.png

9.9 KB | W: | H:

app/src/main/res/drawable/eclair.png
app/src/main/res/drawable/eclair.png
app/src/main/res/drawable/eclair.png
app/src/main/res/drawable/eclair.png
  • 2-up
  • Swipe
  • Onion skin
app/src/main/res/drawable/froyo.png

41.2 KB | W: | H:

app/src/main/res/drawable/froyo.png

12.5 KB | W: | H:

app/src/main/res/drawable/froyo.png
app/src/main/res/drawable/froyo.png
app/src/main/res/drawable/froyo.png
app/src/main/res/drawable/froyo.png
  • 2-up
  • Swipe
  • Onion skin
app/src/main/res/drawable/honeycomb.png

56.3 KB | W: | H:

app/src/main/res/drawable/honeycomb.png

20.1 KB | W: | H:

app/src/main/res/drawable/honeycomb.png
app/src/main/res/drawable/honeycomb.png
app/src/main/res/drawable/honeycomb.png
app/src/main/res/drawable/honeycomb.png
  • 2-up
  • Swipe
  • Onion skin
<?xml version="1.0" encoding="utf-8"?>
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="108dp"
android:height="108dp"
android:viewportHeight="108"
android:viewportWidth="108">
<path
android:fillColor="#26A69A"
android:pathData="M0,0h108v108h-108z" />
<path
android:fillColor="#00000000"
android:pathData="M9,0L9,108"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M19,0L19,108"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M29,0L29,108"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M39,0L39,108"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M49,0L49,108"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M59,0L59,108"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M69,0L69,108"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M79,0L79,108"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M89,0L89,108"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M99,0L99,108"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M0,9L108,9"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M0,19L108,19"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M0,29L108,29"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M0,39L108,39"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M0,49L108,49"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M0,59L108,59"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M0,69L108,69"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M0,79L108,79"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M0,89L108,89"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M0,99L108,99"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M19,29L89,29"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M19,39L89,39"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M19,49L89,49"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M19,59L89,59"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M19,69L89,69"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M19,79L89,79"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M29,19L29,89"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M39,19L39,89"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M49,19L49,89"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M59,19L59,89"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M69,19L69,89"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
<path
android:fillColor="#00000000"
android:pathData="M79,19L79,89"
android:strokeColor="#33FFFFFF"
android:strokeWidth="0.8" />
</vector>
app/src/main/res/drawable/jellybean.png

33.9 KB | W: | H:

app/src/main/res/drawable/jellybean.png

9.24 KB | W: | H:

app/src/main/res/drawable/jellybean.png
app/src/main/res/drawable/jellybean.png
app/src/main/res/drawable/jellybean.png
app/src/main/res/drawable/jellybean.png
  • 2-up
  • Swipe
  • Onion skin
app/src/main/res/drawable/kitkat.png

18.5 KB | W: | H:

app/src/main/res/drawable/kitkat.png

7.3 KB | W: | H:

app/src/main/res/drawable/kitkat.png
app/src/main/res/drawable/kitkat.png
app/src/main/res/drawable/kitkat.png
app/src/main/res/drawable/kitkat.png
  • 2-up
  • Swipe
  • Onion skin
app/src/main/res/drawable/kotlin.png

24.7 KB | W: | H:

app/src/main/res/drawable/kotlin.png

8.66 KB | W: | H:

app/src/main/res/drawable/kotlin.png
app/src/main/res/drawable/kotlin.png
app/src/main/res/drawable/kotlin.png
app/src/main/res/drawable/kotlin.png
  • 2-up
  • Swipe
  • Onion skin
app/src/main/res/drawable/lollipop.png

27.9 KB | W: | H:

app/src/main/res/drawable/lollipop.png

8.27 KB | W: | H:

app/src/main/res/drawable/lollipop.png
app/src/main/res/drawable/lollipop.png
app/src/main/res/drawable/lollipop.png
app/src/main/res/drawable/lollipop.png
  • 2-up
  • Swipe
  • Onion skin
app/src/main/res/drawable/nougat.png

29.4 KB | W: | H:

app/src/main/res/drawable/nougat.png

11.7 KB | W: | H:

app/src/main/res/drawable/nougat.png
app/src/main/res/drawable/nougat.png
app/src/main/res/drawable/nougat.png
app/src/main/res/drawable/nougat.png
  • 2-up
  • Swipe
  • Onion skin
app/src/main/res/drawable/oreo.png

59.1 KB | W: | H:

app/src/main/res/drawable/oreo.png

19.9 KB | W: | H:

app/src/main/res/drawable/oreo.png
app/src/main/res/drawable/oreo.png
app/src/main/res/drawable/oreo.png
app/src/main/res/drawable/oreo.png
  • 2-up
  • Swipe
  • Onion skin
......@@ -22,7 +22,7 @@
<Button
android:id="@+id/srollBtnPrez"
style="@style/Widget.AppCompat.Button.Colored"
android:layout_width="wrap_content"
android:layout_width="@dimen/size_176"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginBottom="@dimen/spacing_24"
......@@ -40,18 +40,27 @@
<ListView
android:id="@+id/scrollList"
android:layout_width="match_parent"
android:layout_height="300dp"
android:layout_height="@dimen/size_300"
android:paddingLeft="@dimen/spacing_24"
android:paddingRight="@dimen/spacing_24" />
<Button
android:id="@+id/scrollBtn"
style="@style/Widget.AppCompat.Button.Colored"
android:layout_width="wrap_content"
android:layout_width="@dimen/size_176"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginBottom="@dimen/spacing_24"
android:text="@string/label_show_details" />
<Button
android:id="@+id/scrollBtnQuiz"
style="@style/Widget.AppCompat.Button.Colored"
android:layout_width="@dimen/size_176"
android:layout_height="@dimen/size_80"
android:layout_gravity="center_horizontal"
android:layout_marginBottom="@dimen/spacing_24"
android:text="@string/label_quiz" />
</LinearLayout>
</android.support.v4.widget.NestedScrollView>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
tools:context=".view.fragment.QuizFragment">
<TextView
android:id="@+id/quizQuestion"
style="@style/TextAppearance.AppCompat.Large"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="@dimen/spacing_24" />
<RadioGroup
android:id="@+id/quizRadio"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center">
<RadioButton
android:id="@+id/quizOpt0"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="RadioButton" />
<RadioButton
android:id="@+id/quizOpt1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="RadioButton" />
<RadioButton
android:id="@+id/quizOpt2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="RadioButton" />
<RadioButton
android:id="@+id/quizOpt3"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="RadioButton" />
</RadioGroup>
<Button
android:id="@+id/quizBtn"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_marginTop="@dimen/spacing_24"
android:text="@string/action_confirm"
android:theme="@style/AppTheme.CustomButton" />
<TextView
android:id="@+id/quizScore"
style="@style/TextAppearance.AppCompat.Large"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_margin="@dimen/spacing_24"
android:visibility="gone" />
</LinearLayout>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="colorPrimary">#0d47a1</color>
<color name="colorPrimaryLight">#5472d3</color>
<color name="colorPrimaryDark">#002171</color>
<color name="colorAccent">#ffeb3b</color>
<color name="colorAccentLight">#ffff72</color>
<color name="colorAccentDark">#c8b900</color>
<color name="primaryTextColor">#ffffff</color>
<color name="secondaryTextColor">#000000</color>
</resources>
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="colorPrimary">#0d47a1</color>
<color name="colorPrimaryLight">#5472d3</color>
<color name="colorPrimaryDark">#002171</color>
<color name="colorAccent">#d32f2f</color>
<color name="colorAccentLight">#ff6659</color>
<color name="colorAccentDark">#9a0007</color>
<color name="colorText">#ffffff</color>
</resources>
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="colorPrimary">#d32f2f</color>
<color name="colorPrimaryLight">#ff6659</color>
<color name="colorPrimaryDark">#9a0007</color>
<color name="colorAccent">#2e7d32</color>
<color name="colorAccentLight">#60ad5e</color>
<color name="colorAccentDark">#005005</color>
<color name="colorText">#ffffff</color>
</resources>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="colorPrimary">#2e7d32</color>
<color name="colorPrimaryLight">#60ad5e</color>
<color name="colorPrimaryDark">#005005</color>
<color name="colorAccent">#ffeb3b</color>
<color name="colorAccentLight">#ffff72</color>
<color name="colorAccentDark">#c8b900</color>
<color name="primaryTextColor">#ffffff</color>
<color name="secondaryTextColor">#000000</color>
</resources>
......@@ -14,7 +14,6 @@
<string name="title_simple_button">Bouton Simple</string>
<string name="label_example_button">Bouton Exemple</string>
<string name="label_custom_button">Boutons Personnalisés</string>
<string name="title_activity_navigation_drawer">Activité de Menu Latéral</string>
<string name="navigation_drawer_open">Ouvre le navigation drawer</string>
<string name="navigation_drawer_close">Ferme navigation drawer</string>
......@@ -41,11 +40,10 @@
<string name="text_year">Année de sortie :</string>
<string name="label_link">Voir le Code</string>
<string name="action_like">Cool</string>
<string name="text_abc">Tout d\'abord, installez Android Studio. Ensuite, apprenez Kotlin et implémentez le
cycle de vie d\'une activité (<i>Activity</i>). Apprenez à utiliser les extensions Kotlin tout en suivant
les règles du Material Design. Aussi, gagnez en productivité grâce à la bibliothèque Anko.\nFinalement,
gardez votre calme et allez à la plage.\n
</string>
<string name="action_buy">Buy</string>
<string name="action_more">Plus</string>
<string name="action_confirm">Valider</string>
<string name="action_next">Suivant</string>
<string-array name="motivation_quote">
......@@ -58,7 +56,6 @@
<item>Tout seul on va plus vite, ensemble on va plus loin.</item>
</string-array>
<string name="kotlin_url">https://www.chillcoding.com/blog/2017/07/11/android-kotlin-introduction/</string>
<string name="androidStudio_url">https://www.chillcoding.com/blog/2016/08/03/android-studio-installation/</string>
<string name="text_architecture">Cette vue appartient au <i>Fragment</i> <b>ArchitectureFragment</b>.
Ce <i>Fragment</i> est contenu dans l\'<i>Activity</i> principale (<b>NavigationDrawerActivity</b>)
......@@ -92,7 +89,6 @@
<string name="text_md">«Apprends les règles comme un professionnel afin de pouvoir les briser comme un artiste.» -> Pablo Picasso</string>
<string name="text_about">Cette application est une démonstration de ce qui peut être fait en Android avec le langage Kotlin, développée par Macha da Costa.</string>
<string name="email_subject">Application Kotlin pour Android</string>
<string name="action_more">Plus</string>
<string name="text_3_minutes">"Rhubarbe sur la terrasse\n"
"\nA pas feutrés, je descends l'escalier. Je presse l\'interrupteur de la cuisine. Le temps semble s\'être arrêté. Casseroles en cuivre alignées contre le mur, bols en faïence, tasses et assiettes sur les étagères, louche, cuillères en bois dans le pot en grès, tous sont figés dans l’attente qu’une main les saisisse. Seule l’horloge murale laisse échapper son tic-tac familier.
......@@ -111,7 +107,7 @@ Tel un soupir, je sens l’air encore frais de la nuit qui s’échappe. Le ciel
<item>Interface Utilisateur Native</item>
<item>Interface Utilisateur Interactive</item>
<item>Adaptateur</item>
<item>Fichier de Préférences</item>
<item>Paramètre Utilisateur</item>
<item>Base de Données</item>
<item>Communication HTTPS</item>
<item>Capteur</item>
......@@ -129,7 +125,6 @@ Tel un soupir, je sens l’air encore frais de la nuit qui s’échappe. Le ciel
"\n+ Accès à tous les quiz️"
"\n+ Accès à tous les articles"
"\n+ Accès à tout le code"</string>
<string name="action_buy">Buy</string>
<string name="subtitle_purchase_session1">Prix : €0.59</string>
<string name="text_thank_you_premium">Merci d\'avoir choisi la version premium!</string>
<string name="text_thank_you_session">Merci d\'avoir acheté du contenu !</string>
......@@ -166,6 +161,12 @@ Tel un soupir, je sens l’air encore frais de la nuit qui s’échappe. Le ciel
<string name="label_overview">Vue d\'ensemble</string>
<string name="label_show_details">Voir le détail</string>
<string name="label_show_prez">Présentation</string>
<string name="label_quiz">Quizz</string>
<string name="text_good_answer">Bonne réponse !</string>