├── .idea ├── .name ├── caches │ ├── gradle_models.ser │ └── build_file_checksums.ser ├── vcs.xml ├── runConfigurations.xml ├── gradle.xml ├── misc.xml └── codeStyles │ └── Project.xml ├── app ├── .gitignore ├── src │ ├── main │ │ ├── ic_launcher-web.png │ │ ├── res │ │ │ ├── drawable │ │ │ │ ├── chopflashlight.gif │ │ │ │ └── ic_launcher_background.xml │ │ │ ├── mipmap-hdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ ├── ic_launcher_round.png │ │ │ │ └── ic_launcher_foreground.png │ │ │ ├── mipmap-mdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ ├── ic_launcher_round.png │ │ │ │ └── ic_launcher_foreground.png │ │ │ ├── mipmap-xhdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ ├── ic_launcher_round.png │ │ │ │ └── ic_launcher_foreground.png │ │ │ ├── mipmap-xxhdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ ├── ic_launcher_round.png │ │ │ │ └── ic_launcher_foreground.png │ │ │ ├── mipmap-xxxhdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ ├── ic_launcher_round.png │ │ │ │ └── ic_launcher_foreground.png │ │ │ ├── values │ │ │ │ ├── ic_launcher_background.xml │ │ │ │ ├── colors.xml │ │ │ │ ├── styles.xml │ │ │ │ └── strings.xml │ │ │ ├── mipmap-anydpi-v26 │ │ │ │ ├── ic_launcher.xml │ │ │ │ └── ic_launcher_round.xml │ │ │ ├── layout │ │ │ │ ├── activity_main.xml │ │ │ │ └── activity_settings.xml │ │ │ └── drawable-v24 │ │ │ │ └── ic_launcher_foreground.xml │ │ ├── AndroidManifest.xml │ │ └── java │ │ │ └── android │ │ │ └── nachiketa │ │ │ └── flashlight │ │ │ ├── SettingsActivity.java │ │ │ ├── MainActivity.java │ │ │ ├── Global.java │ │ │ └── ShakeDetectService.java │ ├── test │ │ └── java │ │ │ └── android │ │ │ └── nachiketa │ │ │ └── flashlight │ │ │ └── ExampleUnitTest.java │ └── androidTest │ │ └── java │ │ └── android │ │ └── nachiketa │ │ └── flashlight │ │ └── ExampleInstrumentedTest.java ├── proguard-rules.pro └── build.gradle ├── settings.gradle ├── _config.yml ├── images ├── gif │ ├── gif1.gif │ ├── gif2.gif │ └── gif3.gif ├── notification_icons │ ├── 22px.png │ ├── 33px.png │ ├── 44px.png │ ├── 66px.png │ ├── 88px.png │ ├── 24px (mdpi).png │ ├── 36px (hdpi).png │ ├── 48px (xhdpi).png │ ├── 72px (xxhdpi).png │ └── 96px (xxxhdpi).png ├── launcher_icons │ ├── 48px (mdpi).png │ ├── 72px (hdpi).png │ ├── 96px (xhdpi).png │ ├── 144px (xxhdpi).png │ ├── 192px (xxxhdpi).png │ └── 512px (google play store).png ├── action_bar, dialog & tab_icons │ ├── 24px.png │ ├── 36px.png │ ├── 72px.png │ ├── 32px (mdpi).png │ ├── 48px (hdpi).png │ ├── 64px (xhdpi).png │ ├── 96px (xxhdpi).png │ └── 128px (xxxhdpi).png ├── small_contextual_icons │ ├── 16px (mdpi).png │ ├── 24px (hdpi).png │ ├── 32px (xhdpi).png │ ├── 48px (xxhdpi).png │ └── 64px (xxxhdpi).png └── license │ └── Logo license.txt ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── .gitignore ├── .github └── ISSUE_TEMPLATE │ ├── feature_request.md │ └── bug_report.md ├── gradle.properties ├── gradlew.bat ├── CODE_OF_CONDUCT.md ├── README.md ├── gradlew └── LICENSE /.idea/.name: -------------------------------------------------------------------------------- 1 | Flashlight-master -------------------------------------------------------------------------------- /app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | -------------------------------------------------------------------------------- /_config.yml: -------------------------------------------------------------------------------- 1 | theme: jekyll-theme-architect -------------------------------------------------------------------------------- /images/gif/gif1.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/gif/gif1.gif -------------------------------------------------------------------------------- /images/gif/gif2.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/gif/gif2.gif -------------------------------------------------------------------------------- /images/gif/gif3.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/gif/gif3.gif -------------------------------------------------------------------------------- /.idea/caches/gradle_models.ser: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/.idea/caches/gradle_models.ser -------------------------------------------------------------------------------- /app/src/main/ic_launcher-web.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/app/src/main/ic_launcher-web.png -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /images/notification_icons/22px.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/notification_icons/22px.png -------------------------------------------------------------------------------- /images/notification_icons/33px.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/notification_icons/33px.png -------------------------------------------------------------------------------- /images/notification_icons/44px.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/notification_icons/44px.png -------------------------------------------------------------------------------- /images/notification_icons/66px.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/notification_icons/66px.png -------------------------------------------------------------------------------- /images/notification_icons/88px.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/notification_icons/88px.png -------------------------------------------------------------------------------- /.idea/caches/build_file_checksums.ser: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/.idea/caches/build_file_checksums.ser -------------------------------------------------------------------------------- /images/launcher_icons/48px (mdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/launcher_icons/48px (mdpi).png -------------------------------------------------------------------------------- /images/launcher_icons/72px (hdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/launcher_icons/72px (hdpi).png -------------------------------------------------------------------------------- /images/launcher_icons/96px (xhdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/launcher_icons/96px (xhdpi).png -------------------------------------------------------------------------------- /images/launcher_icons/144px (xxhdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/launcher_icons/144px (xxhdpi).png -------------------------------------------------------------------------------- /images/launcher_icons/192px (xxxhdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/launcher_icons/192px (xxxhdpi).png -------------------------------------------------------------------------------- /images/notification_icons/24px (mdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/notification_icons/24px (mdpi).png -------------------------------------------------------------------------------- /images/notification_icons/36px (hdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/notification_icons/36px (hdpi).png -------------------------------------------------------------------------------- /app/src/main/res/drawable/chopflashlight.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/app/src/main/res/drawable/chopflashlight.gif -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /images/notification_icons/48px (xhdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/notification_icons/48px (xhdpi).png -------------------------------------------------------------------------------- /images/notification_icons/72px (xxhdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/notification_icons/72px (xxhdpi).png -------------------------------------------------------------------------------- /images/notification_icons/96px (xxxhdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/notification_icons/96px (xxxhdpi).png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /images/action_bar, dialog & tab_icons/24px.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/action_bar, dialog & tab_icons/24px.png -------------------------------------------------------------------------------- /images/action_bar, dialog & tab_icons/36px.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/action_bar, dialog & tab_icons/36px.png -------------------------------------------------------------------------------- /images/action_bar, dialog & tab_icons/72px.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/action_bar, dialog & tab_icons/72px.png -------------------------------------------------------------------------------- /images/small_contextual_icons/16px (mdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/small_contextual_icons/16px (mdpi).png -------------------------------------------------------------------------------- /images/small_contextual_icons/24px (hdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/small_contextual_icons/24px (hdpi).png -------------------------------------------------------------------------------- /images/small_contextual_icons/32px (xhdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/small_contextual_icons/32px (xhdpi).png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /images/small_contextual_icons/48px (xxhdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/small_contextual_icons/48px (xxhdpi).png -------------------------------------------------------------------------------- /images/small_contextual_icons/64px (xxxhdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/small_contextual_icons/64px (xxxhdpi).png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /images/launcher_icons/512px (google play store).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/launcher_icons/512px (google play store).png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /images/action_bar, dialog & tab_icons/32px (mdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/action_bar, dialog & tab_icons/32px (mdpi).png -------------------------------------------------------------------------------- /images/action_bar, dialog & tab_icons/48px (hdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/action_bar, dialog & tab_icons/48px (hdpi).png -------------------------------------------------------------------------------- /images/action_bar, dialog & tab_icons/64px (xhdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/action_bar, dialog & tab_icons/64px (xhdpi).png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png -------------------------------------------------------------------------------- /images/action_bar, dialog & tab_icons/96px (xxhdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/action_bar, dialog & tab_icons/96px (xxhdpi).png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png -------------------------------------------------------------------------------- /app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png -------------------------------------------------------------------------------- /app/src/main/res/values/ic_launcher_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #000000 4 | -------------------------------------------------------------------------------- /images/action_bar, dialog & tab_icons/128px (xxxhdpi).png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/mhasancse15/Flashlight-master/HEAD/images/action_bar, dialog & tab_icons/128px (xxxhdpi).png -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | .gradle 3 | /local.properties 4 | /.idea/libraries 5 | /.idea/modules.xml 6 | /.idea/workspace.xml 7 | .DS_Store 8 | /build 9 | /captures 10 | .externalNativeBuild 11 | -------------------------------------------------------------------------------- /.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /images/license/Logo license.txt: -------------------------------------------------------------------------------- 1 | This logo design created by Dee-y (https://github.com/dee-y) is licensed under a Creative Commons Attribution 4.0 International License (http://creativecommons.org/licenses/by/4.0/) -------------------------------------------------------------------------------- /app/src/main/res/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #3F51B5 4 | #303F9F 5 | #FF4081 6 | 7 | -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Thu Jul 18 17:28:07 BDT 2019 2 | distributionBase=GRADLE_USER_HOME 3 | distributionPath=wrapper/dists 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | distributionUrl=https\://services.gradle.org/distributions/gradle-5.1.1-all.zip 7 | -------------------------------------------------------------------------------- /app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /app/src/test/java/android/nachiketa/flashlight/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package android.nachiketa.flashlight; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /.idea/runConfigurations.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 11 | 12 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/feature_request.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Feature request 3 | about: Suggest an idea for this project 4 | 5 | --- 6 | 7 | **Is your feature request related to a problem? Please describe.** 8 | A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] 9 | 10 | **Describe the solution you'd like** 11 | A clear and concise description of what you want to happen. 12 | 13 | **Describe alternatives you've considered** 14 | A clear and concise description of any alternative solutions or features you've considered. 15 | 16 | **Additional context** 17 | Add any other context or screenshots about the feature request here. 18 | -------------------------------------------------------------------------------- /.idea/gradle.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 17 | 18 | -------------------------------------------------------------------------------- /app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | Flashlight 3 | Shake Threshold 4 | Save 5 | Settings 6 | Settings 7 | How hard to shake to switch flashlight on? 8 | Gif Image to show shake motion 9 | Switch On 10 | Switch Off 11 | 12 | -------------------------------------------------------------------------------- /gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | # IDE (e.g. Android Studio) users: 3 | # Gradle settings configured through the IDE *will override* 4 | # any settings specified in this file. 5 | # For more details on how to configure your build environment visit 6 | # http://www.gradle.org/docs/current/userguide/build_environment.html 7 | # Specifies the JVM arguments used for the daemon process. 8 | # The setting is particularly useful for tweaking memory settings. 9 | org.gradle.jvmargs=-Xmx1536m 10 | # When configured, Gradle will run in incubating parallel mode. 11 | # This option should only be used with decoupled projects. More details, visit 12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 13 | # org.gradle.parallel=true 14 | -------------------------------------------------------------------------------- /app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /app/src/androidTest/java/android/nachiketa/flashlight/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package android.nachiketa.flashlight; 2 | 3 | import android.content.Context; 4 | import android.support.test.InstrumentationRegistry; 5 | import android.support.test.runner.AndroidJUnit4; 6 | 7 | import org.junit.Test; 8 | import org.junit.runner.RunWith; 9 | 10 | import static org.junit.Assert.*; 11 | 12 | /** 13 | * Instrumented test, which will execute on an Android device. 14 | * 15 | * @see Testing documentation 16 | */ 17 | @RunWith(AndroidJUnit4.class) 18 | public class ExampleInstrumentedTest { 19 | @Test 20 | public void useAppContext() { 21 | // Context of the app under test. 22 | Context appContext = InstrumentationRegistry.getTargetContext(); 23 | 24 | assertEquals("android.nachiketa.flashlight", appContext.getPackageName()); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/bug_report.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Bug report 3 | about: Create a report to help us improve 4 | 5 | --- 6 | 7 | **Describe the bug** 8 | A clear and concise description of what the bug is. 9 | 10 | **To Reproduce** 11 | Steps to reproduce the behavior: 12 | 1. Go to '...' 13 | 2. Click on '....' 14 | 3. Scroll down to '....' 15 | 4. See error 16 | 17 | **Expected behavior** 18 | A clear and concise description of what you expected to happen. 19 | 20 | **Screenshots** 21 | If applicable, add screenshots to help explain your problem. 22 | 23 | **Desktop (please complete the following information):** 24 | - OS: [e.g. iOS] 25 | - Browser [e.g. chrome, safari] 26 | - Version [e.g. 22] 27 | 28 | **Smartphone (please complete the following information):** 29 | - Device: [e.g. iPhone6] 30 | - OS: [e.g. iOS8.1] 31 | - Browser [e.g. stock browser, safari] 32 | - Version [e.g. 22] 33 | 34 | **Additional context** 35 | Add any other context about the problem here. 36 | -------------------------------------------------------------------------------- /app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /app/src/main/res/layout/activity_main.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 |