diff --git a/.idea/caches/gradle_models.ser b/.idea/caches/gradle_models.ser index a4be51d..269169c 100644 Binary files a/.idea/caches/gradle_models.ser and b/.idea/caches/gradle_models.ser differ diff --git a/.idea/gradle.xml b/.idea/gradle.xml index f43d428..2996d53 100644 --- a/.idea/gradle.xml +++ b/.idea/gradle.xml @@ -8,12 +8,6 @@ diff --git a/.idea/inspectionProfiles/Project_Default.xml b/.idea/inspectionProfiles/Project_Default.xml deleted file mode 100644 index ab9a541..0000000 --- a/.idea/inspectionProfiles/Project_Default.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml index 51fa3e5..37a7509 100644 --- a/.idea/misc.xml +++ b/.idea/misc.xml @@ -1,40 +1,5 @@ - - - - diff --git a/.idea/render.experimental.xml b/.idea/render.experimental.xml deleted file mode 100644 index 8ec256a..0000000 --- a/.idea/render.experimental.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - \ No newline at end of file diff --git a/app/debug/app.aab b/app/debug/app.aab new file mode 100644 index 0000000..9a43d13 Binary files /dev/null and b/app/debug/app.aab differ diff --git a/app/release/app.aab b/app/release/app.aab new file mode 100644 index 0000000..1d7a7a5 Binary files /dev/null and b/app/release/app.aab differ diff --git a/app/src/androidTest/java/com/example/se/catornot2/ExampleInstrumentedTest.java b/app/src/androidTest/java/com/example/se/catornot2/ExampleInstrumentedTest.java index 6e181e9..ab9eeda 100644 --- a/app/src/androidTest/java/com/example/se/catornot2/ExampleInstrumentedTest.java +++ b/app/src/androidTest/java/com/example/se/catornot2/ExampleInstrumentedTest.java @@ -7,7 +7,7 @@ import android.support.test.runner.AndroidJUnit4; import org.junit.Test; import org.junit.runner.RunWith; -import static org.junit.Assert.*; +import static org.junit.Assert.assertEquals; /** * Instrumented test, which will execute on an Android device. diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index 72ac52a..f7a0c8b 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -9,6 +9,7 @@ android:name="android.permission.WRITE_EXTERNAL_STORAGE" /> + = 26) { + ((Vibrator) getSystemService(VIBRATOR_SERVICE)).vibrate(VibrationEffect.createOneShot(500, VibrationEffect.DEFAULT_AMPLITUDE)); + } else { + ((Vibrator) getSystemService(VIBRATOR_SERVICE)).vibrate(500); + } + } + + + // Process voice command given by user private void processVoiceCommand(String spokenText) { if (spokenText.contains("photo") || spokenText.contains("foto")) { // camera shutter sound (?); indication of app taking a photo - + MediaPlayer mySound; + mySound= MediaPlayer.create(MainActivity.this,R.raw.photosound); + mySound.start(); // Starting question - String question = "Is it a cat or not?"; - tts.speak(question, TextToSpeech.QUEUE_FLUSH, null); - + try { + Thread.sleep(3000); + String question = "Is it a cat or not?"; + tts.speak(question, TextToSpeech.QUEUE_FLUSH, null); + }catch(Exception e) { + } // Initiating randomizer method on 'answers' List answers = Arrays.asList("It is a cat", "It is NOT a cat"); randomizer(answers); diff --git a/app/src/main/res/raw/PhotoSound.mp3 b/app/src/main/res/raw/PhotoSound.mp3 new file mode 100644 index 0000000..091c9c2 Binary files /dev/null and b/app/src/main/res/raw/PhotoSound.mp3 differ diff --git a/app/src/test/java/com/example/se/catornot2/ExampleUnitTest.java b/app/src/test/java/com/example/se/catornot2/ExampleUnitTest.java index 2d9bbbb..8c68e7b 100644 --- a/app/src/test/java/com/example/se/catornot2/ExampleUnitTest.java +++ b/app/src/test/java/com/example/se/catornot2/ExampleUnitTest.java @@ -2,7 +2,7 @@ package com.example.se.catornot2; import org.junit.Test; -import static org.junit.Assert.*; +import static org.junit.Assert.assertEquals; /** * Example local unit test, which will execute on the development machine (host).