diff --git a/.idea/codeStyles/Project.xml b/.idea/codeStyles/Project.xml deleted file mode 100644 index 681f41a..0000000 --- a/.idea/codeStyles/Project.xml +++ /dev/null @@ -1,116 +0,0 @@ - - - - - - - -
- - - - xmlns:android - - ^$ - - - -
-
- - - - xmlns:.* - - ^$ - - - BY_NAME - -
-
- - - - .*:id - - http://schemas.android.com/apk/res/android - - - -
-
- - - - .*:name - - http://schemas.android.com/apk/res/android - - - -
-
- - - - name - - ^$ - - - -
-
- - - - style - - ^$ - - - -
-
- - - - .* - - ^$ - - - BY_NAME - -
-
- - - - .* - - http://schemas.android.com/apk/res/android - - - ANDROID_ATTRIBUTE_ORDER - -
-
- - - - .* - - .* - - - BY_NAME - -
-
-
-
-
-
\ No newline at end of file diff --git a/.idea/gradle.xml b/.idea/gradle.xml deleted file mode 100644 index d291b3d..0000000 --- a/.idea/gradle.xml +++ /dev/null @@ -1,16 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/.idea/runConfigurations.xml b/.idea/runConfigurations.xml deleted file mode 100644 index 7f68460..0000000 --- a/.idea/runConfigurations.xml +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/app/src/main/java/net/foucry/pilldroid/MedicamentDetailActivity.java b/app/src/main/java/net/foucry/pilldroid/MedicamentDetailActivity.java index 3b3de8e..d556206 100644 --- a/app/src/main/java/net/foucry/pilldroid/MedicamentDetailActivity.java +++ b/app/src/main/java/net/foucry/pilldroid/MedicamentDetailActivity.java @@ -35,6 +35,8 @@ public class MedicamentDetailActivity extends AppCompatActivity { public void onClick(View view) { Snackbar.make(view, "Will be use to save changes in a drug", Snackbar.LENGTH_LONG) .setAction("Action", null).show(); + setResult(1); + return; } }); diff --git a/app/src/main/java/net/foucry/pilldroid/MedicamentListActivity.java b/app/src/main/java/net/foucry/pilldroid/MedicamentListActivity.java index a200853..ef3141d 100644 --- a/app/src/main/java/net/foucry/pilldroid/MedicamentListActivity.java +++ b/app/src/main/java/net/foucry/pilldroid/MedicamentListActivity.java @@ -319,7 +319,10 @@ public class MedicamentListActivity extends AppCompatActivity { // Handle cancel Toast.makeText(context, "Scan annulé", Toast.LENGTH_LONG).show(); } - } + else { + Toast.makeText(context, "back from detail", Toast.LENGTH_SHORT).show(); + } + } // TODO : Si requestCode=1 -> Sauvegarde du medoc dans la base et raffraichissement de la base. } private void setupRecyclerView(@NonNull RecyclerView recyclerView) { diff --git a/build.gradle b/build.gradle index ff58aa3..4fdbf45 100644 --- a/build.gradle +++ b/build.gradle @@ -9,7 +9,7 @@ buildscript { google() } dependencies { - classpath 'com.android.tools.build:gradle:3.5.0' + classpath 'com.android.tools.build:gradle:3.5.1' // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files