Commit 4a09720e90393b60d0d95bb27dfbdf99e39c96a3

Authored by rcavalie
1 parent 21f011f1

finalisation du projet

app/src/main/java/ssrmarcsautelet/automation/appli/ssrmarcsautelet/activity_age3.java
... ... @@ -2,6 +2,7 @@ package ssrmarcsautelet.automation.appli.ssrmarcsautelet;
2 2  
3 3 import android.app.Activity;
4 4 import android.content.Intent;
  5 +import android.net.Uri;
5 6 import android.os.Bundle;
6 7 import android.support.v7.app.AppCompatActivity;
7 8 import android.view.View;
... ... @@ -24,6 +25,7 @@ public class activity_age3 extends AppCompatActivity {
24 25 setContentView(R.layout.activity_age3);
25 26  
26 27 ImageButton btnScan = (ImageButton) findViewById(R.id.mode_aventure);
  28 + ImageButton btnColo = (ImageButton) findViewById(R.id.jeu);
27 29 final Activity activity = this;
28 30  
29 31 btnScan.setOnClickListener(new View.OnClickListener() {
... ... @@ -33,6 +35,26 @@ public class activity_age3 extends AppCompatActivity {
33 35 integrator.initiateScan();
34 36 }
35 37 });
  38 +
  39 + btnColo.setOnClickListener(new View.OnClickListener() {
  40 + @Override
  41 + public void onClick(View v) {
  42 +
  43 + Intent intent = getPackageManager().getLaunchIntentForPackage("com.replica.replicaisland");
  44 + if (intent != null) {
  45 + // We found the activity now start the activity
  46 + intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
  47 + startActivity(intent);
  48 + } else {
  49 + // Bring user to the market or let them choose an app?
  50 + intent = new Intent(Intent.ACTION_VIEW);
  51 + intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
  52 + intent.setData(Uri.parse("market://details?id=" + "com.replica.replicaisland"));
  53 + startActivity(intent);
  54 + }
  55 +
  56 + }
  57 + });
36 58 }
37 59  
38 60 public void onActivityResult(int requestCode, int resultCode, Intent data) {
... ...
app/src/main/java/ssrmarcsautelet/automation/appli/ssrmarcsautelet/activity_val.java
... ... @@ -166,6 +166,74 @@ public class activity_val extends AppCompatActivity {
166 166 "psy3.png",
167 167 "psychomo1.png",
168 168 "secret1.png",
  169 + "secret2.png",
  170 + "Ambulancier.jpg",
  171 + "Kine.jpg",
  172 + "ane.jpg",
  173 + "assistante.jpg",
  174 + "educateur.jpg",
  175 + "ergo.jpg",
  176 + "inf.jpg",
  177 + "medecin.jpg",
  178 + "ortho.jpg",
  179 + "orthoptiste.jpg",
  180 + "psychologue.jpg",
  181 + "secretaire.jpg",
  182 + "accueil1.png",
  183 + "accueil2.png",
  184 + "accueil3.png",
  185 + "accueil4.png",
  186 + "apa1.png",
  187 + "appareillage1.png",
  188 + "assist1.png",
  189 + "dame1.png",
  190 + "dame2.png",
  191 + "doc1.png",
  192 + "doc2.png",
  193 + "ecole1.png",
  194 + "ecole2.png",
  195 + "ergo1.png",
  196 + "ergo2.png",
  197 + "ergo3.png",
  198 + "ergo4.png",
  199 + "ergo5.png",
  200 + "grands1.png",
  201 + "grands2.png",
  202 + "grands3.png",
  203 + "inf1.png",
  204 + "inf2.png",
  205 + "inf3.png",
  206 + "kine1.png",
  207 + "kine10.png",
  208 + "kine11.png",
  209 + "kine12.png",
  210 + "kine2.png",
  211 + "kine3.png",
  212 + "kine4.png",
  213 + "kine5.png",
  214 + "kine6.png",
  215 + "kine7.png",
  216 + "kine8.png",
  217 + "kine9.png",
  218 + "moyens1.png",
  219 + "moyens2.png",
  220 + "moyens3.png",
  221 + "moyens4.png",
  222 + "moyens5.png",
  223 + "ortho1.png",
  224 + "ortho2.png",
  225 + "ortho3.png",
  226 + "orthopto1.png",
  227 + "pediatre1.png",
  228 + "petits1.png",
  229 + "petits2.png",
  230 + "petits3.png",
  231 + "petits4.png",
  232 + "psy1.png",
  233 + "psy2.png",
  234 + "psy3.png",
  235 + "psychomo1.png",
  236 + "secret1.png",
169 237 "secret2.png"};
170 238  
171 239 @Override
... ... @@ -200,7 +268,17 @@ public class activity_val extends AppCompatActivity {
200 268 url + dir[98], url + dir[99], url + dir[100], url + dir[101], url + dir[102], url + dir[103], url + dir[104],
201 269 url + dir[105], url + dir[106], url + dir[107], url + dir[108], url + dir[109], url + dir[110], url + dir[111], url + dir[112],
202 270 url + dir[113], url + dir[114], url + dir[115], url + dir[116], url + dir[117], url + dir[118],
203   - url + dir[119], url + dir[120], url + dir[121], url + dir[122]);//
  271 + url + dir[119], url + dir[120], url + dir[121], url + dir[122],url + dir[123], url + dir[124], url + dir[125], url + dir[126], url + dir[127],
  272 + url + dir[128], url + dir[129], url + dir[130], url + dir[131], url + dir[132], url + dir[133],
  273 + url + dir[134], url + dir[135], url + dir[136], url + dir[137], url + dir[138], url + dir[139],
  274 + url + dir[140], url + dir[141], url + dir[142], url + dir[143], url + dir[144],
  275 + url + dir[145], url + dir[146], url + dir[147], url + dir[148], url + dir[149], url + dir[150], url + dir[151],
  276 + url + dir[152], url + dir[153], url + dir[154], url + dir[155], url + dir[156], url + dir[157], url + dir[158],
  277 + url + dir[159], url + dir[160], url + dir[161], url + dir[162], url + dir[163], url + dir[164], url + dir[165],
  278 + url + dir[166], url + dir[167], url + dir[168], url + dir[169], url + dir[170], url + dir[171], url + dir[172],
  279 + url + dir[173], url + dir[174], url + dir[175], url + dir[176], url + dir[177], url + dir[178], url + dir[179], url + dir[180],
  280 + url + dir[181], url + dir[182], url + dir[183], url + dir[184], url + dir[185], url + dir[186],
  281 + url + dir[187], url + dir[188], url + dir[189], url + dir[190]);//
204 282  
205 283 context = getApplicationContext();
206 284 Toast toast1 = Toast.makeText(context, "Téléchargement en cours", duration);
... ...
app/src/main/res/drawable/colorier.gif

2.46 KB | W: | H:

3.05 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
app/src/main/res/drawable/game.png 0 → 100644

28 KB

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

6.5 KB | W: | H:

6.41 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
app/src/main/res/layout/activity_age1.xml
... ... @@ -2,23 +2,23 @@
2 2  
3 3  
4 4 <ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
  5 + xmlns:app="http://schemas.android.com/apk/res-auto"
5 6 android:layout_width="fill_parent"
6 7 android:layout_height="fill_parent" >
7 8  
8 9 <LinearLayout
9 10 xmlns:android="http://schemas.android.com/apk/res/android"
10 11 xmlns:app="http://schemas.android.com/apk/res-auto"
11   - xmlns:tools="http://schemas.android.com/tools"
12 12 android:orientation="vertical"
13 13 android:layout_width="fill_parent"
14   - android:layout_height="fill_parent"
  14 + android:layout_height="wrap_content"
15 15 android:weightSum="1"
16 16 android:background="@color/colorPrimaryDark">
17 17  
18 18 <ImageButton
19 19 android:layout_width="wrap_content"
20 20 android:layout_height="wrap_content"
21   - app:srcCompat="@mipmap/kode"
  21 + app:srcCompat="@drawable/kode"
22 22 android:id="@+id/mode_aventure"
23 23 android:layout_gravity="center"
24 24 android:backgroundTint="@color/colorPrimaryDark"
... ... @@ -43,13 +43,13 @@
43 43 android:layout_marginRight="20dp" />
44 44  
45 45 <ImageButton
  46 + android:id="@+id/dessine"
46 47 android:layout_width="wrap_content"
47 48 android:layout_height="wrap_content"
48   - app:srcCompat="@drawable/colorier"
49   - android:id="@+id/dessine"
50   - android:layout_marginTop="50dp"
51 49 android:layout_gravity="center"
52   - android:layout_weight="0.09" />
  50 + android:layout_marginTop="50dp"
  51 + android:layout_weight="0.09"
  52 + app:srcCompat="@drawable/colorier" />
53 53  
54 54 <TextView
55 55 android:text="Mode dessin"
... ... @@ -61,7 +61,12 @@
61 61 android:layout_marginLeft="20dp"/>
62 62  
63 63 <TextView
64   - android:text="Dans ce mode, tu peux créer ton propre dessin et l'enregistrer sur la tablette."
  64 + android:text="Dans ce mode, tu peux créer ton propre dessin et l'enregistrer sur la tablette.
  65 +\n
  66 +\n
  67 +\n
  68 +\n
  69 +\n"
65 70 android:layout_width="match_parent"
66 71 android:layout_height="wrap_content"
67 72 android:id="@+id/textView4"
... ...
app/src/main/res/layout/activity_age2.xml
... ... @@ -3,7 +3,7 @@
3 3  
4 4 <ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
5 5 android:layout_width="fill_parent"
6   - android:layout_height="fill_parent" >
  6 + android:layout_height="wrap_content" >
7 7  
8 8 <LinearLayout
9 9 xmlns:android="http://schemas.android.com/apk/res/android"
... ... @@ -17,7 +17,7 @@
17 17 <ImageButton
18 18 android:layout_width="wrap_content"
19 19 android:layout_height="wrap_content"
20   - app:srcCompat="@mipmap/kode"
  20 + app:srcCompat="@drawable/kode"
21 21 android:id="@+id/mode_aventure"
22 22 android:layout_gravity="center"
23 23 android:backgroundTint="@color/colorPrimaryDark"
... ... @@ -61,7 +61,12 @@
61 61 android:layout_marginLeft="20dp"/>
62 62  
63 63 <TextView
64   - android:text="Ce mini-jeu te permet de résoudre un puzzle à partir d'une image présente sur la tablette. "
  64 + android:text="Ce mini-jeu te permet de résoudre un puzzle à partir d'une image présente sur la tablette.
  65 +\n
  66 +\n
  67 +\n
  68 +\n
  69 +\n"
65 70 android:layout_width="match_parent"
66 71 android:layout_height="wrap_content"
67 72 android:id="@+id/textView4"
... ...
app/src/main/res/layout/activity_age3.xml
1 1 <?xml version="1.0" encoding="utf-8"?>
2 2 <ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
3 3 android:layout_width="fill_parent"
4   - android:layout_height="fill_parent" >
  4 + android:layout_height="wrap_content" >
5 5  
6 6 <LinearLayout
7 7 xmlns:android="http://schemas.android.com/apk/res/android"
... ... @@ -15,14 +15,14 @@
15 15 <ImageButton
16 16 android:layout_width="wrap_content"
17 17 android:layout_height="wrap_content"
18   - app:srcCompat="@mipmap/kode"
  18 + app:srcCompat="@drawable/kode"
19 19 android:id="@+id/mode_aventure"
20 20 android:layout_gravity="center"
21 21 android:backgroundTint="@color/colorPrimaryDark"
22 22 android:layout_marginTop="100dp" />
23 23  
24 24 <TextView
25   - android:text="Mode aventure "
  25 + android:text="Mode aventure"
26 26 android:layout_width="wrap_content"
27 27 android:layout_height="wrap_content"
28 28 android:id="@+id/textView"
... ... @@ -39,5 +39,37 @@
39 39 android:layout_marginLeft="20dp"
40 40 android:layout_marginRight="20dp" />
41 41  
  42 + <ImageButton
  43 + android:id="@+id/jeu"
  44 + android:layout_width="wrap_content"
  45 + android:layout_height="wrap_content"
  46 + android:layout_gravity="center"
  47 + android:layout_marginTop="50dp"
  48 + android:layout_weight="0.09"
  49 + app:srcCompat="@drawable/game" />
  50 +
  51 + <TextView
  52 + android:text="Jeu de plateforme"
  53 + android:layout_width="match_parent"
  54 + android:layout_height="wrap_content"
  55 + android:id="@+id/descrip"
  56 + android:textAppearance="@style/TextAppearance.AppCompat.Display1"
  57 + android:textColor="?android:attr/windowBackground"
  58 + android:layout_marginLeft="20dp"/>
  59 +
  60 + <TextView
  61 + android:text="Dans ce jeu, tu vas pouvoir contrôler un robot un peu spécial. Le but est d'aller le plus loin possible dans l'aventure.
  62 +\n
  63 +\n
  64 +\n
  65 +\n
  66 +\n"
  67 + android:layout_width="match_parent"
  68 + android:layout_height="wrap_content"
  69 + android:id="@+id/textView7"
  70 + android:textColor="?android:attr/windowBackground"
  71 + android:layout_marginLeft="20dp"
  72 + android:layout_marginRight="20dp"/>
  73 +
42 74 </LinearLayout>
43 75 </ScrollView>
44 76 \ No newline at end of file
... ...
app/src/main/res/layout/activity_main.xml
... ... @@ -108,23 +108,26 @@
108 108 android:id="@+id/imageView6"
109 109 tools:ignore="RtlHardcoded"
110 110 android:contentDescription="@string/ok"
111   - android:layout_marginTop="@dimen/hauteurimage"
112   - android:layout_below="@+id/textView5"
113   - android:layout_centerHorizontal="true" />
  111 + android:layout_alignParentTop="true"
  112 + android:layout_alignParentLeft="true"
  113 + android:layout_alignParentStart="true"
  114 + android:layout_marginBottom="32dp"
  115 + android:layout_alignBottom="@+id/telechargement" />
114 116  
115 117 <Button
116 118 android:id="@+id/telechargement"
117   - android:backgroundTint="@color/colorPrimary"
118 119 android:layout_width="wrap_content"
  120 + android:layout_height="wrap_content"
  121 + android:backgroundTint="@color/colorPrimary"
  122 + android:onClick="demande_mdp"
  123 + android:text="Administrateur"
119 124 android:textColor="@android:color/background_light"
120 125 android:textSize="@dimen/txtmenu"
121 126 tools:ignore="HardcodedText,UnusedAttribute"
122   - android:layout_height="wrap_content"
123   - android:text="MàJ"
124   - android:layout_alignBottom="@+id/savoir_plus"
125   - android:layout_alignRight="@+id/imageView6"
126   - android:layout_alignEnd="@+id/imageView6"
127   - android:onClick="demande_mdp"/>
  127 + android:layout_marginBottom="11dp"
  128 + android:layout_above="@+id/hop_jour"
  129 + android:layout_alignLeft="@+id/hop_jour"
  130 + android:layout_alignStart="@+id/hop_jour" />
128 131  
129 132 </RelativeLayout>
130 133  
... ...
app/src/main/res/layout/motdepasse.xml
... ... @@ -2,7 +2,8 @@
2 2 <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
3 3 xmlns:tools="http://schemas.android.com/tools"
4 4 android:orientation="vertical" android:layout_width="match_parent"
5   - android:layout_height="match_parent">
  5 + android:layout_height="match_parent"
  6 + android:background="@color/colorPrimaryDark">
6 7  
7 8 <EditText
8 9 android:id="@+id/texte_mdp"
... ... @@ -27,5 +28,6 @@
27 28 android:layout_alignParentLeft="true"
28 29 android:layout_alignParentStart="true"
29 30 android:layout_marginBottom="244dp"
30   - tools:ignore="HardcodedText" />
  31 + tools:ignore="HardcodedText"
  32 + android:backgroundTint="@color/colorPrimary"/>
31 33 </RelativeLayout>
32 34 \ No newline at end of file
... ...