Skip to content

Commit

Permalink
Merge pull request #29 from PhenoApps/dev
Browse files Browse the repository at this point in the history
v1.0.1 release
  • Loading branch information
trife authored Jun 24, 2021
2 parents 91ce401 + d5185e0 commit 00af08e
Show file tree
Hide file tree
Showing 17 changed files with 397 additions and 170 deletions.
16 changes: 12 additions & 4 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ apply plugin: 'kotlin-android'
apply plugin: 'kotlin-kapt'
apply plugin: 'androidx.navigation.safeargs.kotlin'
apply plugin: 'dagger.hilt.android.plugin'
apply plugin: 'com.google.gms.google-services'
apply plugin: 'com.google.firebase.crashlytics'

android {
signingConfigs {
Expand All @@ -25,8 +27,8 @@ android {
//link square api has minimum requirement of 21
minSdkVersion 21
targetSdkVersion 30
versionCode 2
versionName "1.0"
versionCode 4
versionName "1.0.1"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
multiDexEnabled true

Expand Down Expand Up @@ -65,12 +67,11 @@ android {
flavorDimensions "version"

productFlavors {

demo {
dimension "version"
applicationIdSuffix ".demo"
versionNameSuffix "-demo"
}

full {
dimension "version"
}
Expand All @@ -91,12 +92,17 @@ kapt {
}

dependencies {
implementation platform('com.google.firebase:firebase-bom:27.1.0')
implementation 'com.google.firebase:firebase-analytics'
implementation 'com.google.firebase:firebase-crashlytics'

kapt 'com.android.databinding:compiler:3.1.4'

implementation "com.google.dagger:hilt-android:$hilt_version"
kapt "com.google.dagger:hilt-android-compiler:$hilt_version"

implementation group: 'org.apache.commons', name: 'commons-math', version: '2.2'

// Navigation
androidTestImplementation "androidx.navigation:navigation-testing:$nav_version"
implementation "androidx.navigation:navigation-fragment-ktx:$nav_version"
Expand Down Expand Up @@ -153,6 +159,8 @@ dependencies {
//other
implementation "com.journeyapps:zxing-android-embedded:$journeyapps_version"
implementation "com.jjoe64:graphview:$graphview_version"
//app intro github AndroidX Capable version
implementation 'com.github.AppIntro:AppIntro:6.1.0'

//local
implementation fileTree(include: ['*.jar', '*.aar'], dir: 'libs')
Expand Down
40 changes: 40 additions & 0 deletions app/google-services.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
{
"project_info": {
"project_number": "694219135598",
"firebase_url": "https://prospector-152d1.firebaseio.com",
"project_id": "prospector-152d1",
"storage_bucket": "prospector-152d1.appspot.com"
},
"client": [
{
"client_info": {
"mobilesdk_app_id": "1:694219135598:android:24dfad3f9a06a09627a47f",
"android_client_info": {
"package_name": "org.phenoapps.prospector"
}
},
"oauth_client": [
{
"client_id": "694219135598-cfgu6j9mod78hlt8pp1p4kt3t8f6jvg4.apps.googleusercontent.com",
"client_type": 3
}
],
"api_key": [
{
"current_key": "AIzaSyDTiJwSIZ-eqFpw-u6Qio5ddqR9NNQdG3s"
}
],
"services": {
"appinvite_service": {
"other_platform_oauth_client": [
{
"client_id": "694219135598-cfgu6j9mod78hlt8pp1p4kt3t8f6jvg4.apps.googleusercontent.com",
"client_type": 3
}
]
}
}
}
],
"configuration_version": "1"
}
1 change: 1 addition & 0 deletions app/proguard-rules.pro
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,4 @@

# Keep class names of Hilt injected ViewModels since their name are used as a multibinding map key.
-keepnames @dagger.hilt.android.lifecycle.HiltViewModel class * extends androidx.lifecycle.ViewModel
-keepattributes LineNumberTable,SourceFile
5 changes: 5 additions & 0 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,11 @@
</intent-filter>
</activity>

<!-- app intro activity -->
<activity android:name=".activities.IntroActivity"
android:label="My Custom AppIntro"
android:theme="@style/AppIntroTheme"/>

<provider
android:authorities="${applicationId}.fileprovider"
android:name="androidx.core.content.FileProvider"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
package org.phenoapps.prospector.activities

import android.os.Bundle
import androidx.fragment.app.Fragment
import com.github.appintro.AppIntro
import com.github.appintro.AppIntroFragment
import org.phenoapps.prospector.R

class IntroActivity : AppIntro() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
// Make sure you don't call setContentView!

isWizardMode = true

askForPermissions(arrayOf(android.Manifest.permission.CAMERA,
android.Manifest.permission.READ_EXTERNAL_STORAGE,
android.Manifest.permission.WRITE_EXTERNAL_STORAGE), slideNumber = 1, required = false)

addSlide(AppIntroFragment.newInstance(
title = getString(R.string.accept_permissions),
description = getString(R.string.frag_instructions_step_zero),
))
// Call addSlide passing your Fragments.
// You can use AppIntroFragment to use a pre-built fragment
addSlide(AppIntroFragment.newInstance(
title = getString(R.string.welcome),
description = getString(R.string.frag_instructions_step_one),
imageDrawable = R.drawable.icon_device_ap

))
addSlide(AppIntroFragment.newInstance(
title = getString(R.string.choose_network),
description = getString(R.string.frag_instructions_step_two),
imageDrawable = R.drawable.choose_ap_wifi_network
))
addSlide(AppIntroFragment.newInstance(
title = getString(R.string.check_connection),
description = getString(R.string.frag_instructions_step_three),
imageDrawable = R.drawable.icon_ap
))
addSlide(AppIntroFragment.newInstance(
title = getString(R.string.prospector_workflow),
description = getString(R.string.frag_instructions_step_four),
imageDrawable = R.drawable.instructions_create_button
))
addSlide(AppIntroFragment.newInstance(
title = getString(R.string.iot_compatible),
description = getString(R.string.frag_instructions_step_five),
imageDrawable = R.drawable.iot_instructions
))
}

override fun onSkipPressed(currentFragment: Fragment?) {
super.onSkipPressed(currentFragment)
// Decide what to do when the user clicks on "Skip"
finish()
}

override fun onDonePressed(currentFragment: Fragment?) {
super.onDonePressed(currentFragment)
// Decide what to do when the user clicks on "Done"
finish()
}
}
Loading

0 comments on commit 00af08e

Please sign in to comment.