adding a FAQ activity

This commit is contained in:
tibbi 2018-02-21 22:04:37 +01:00
parent a1772a4fd2
commit 0a9a594503
2 changed files with 12 additions and 1 deletions

View File

@ -90,6 +90,11 @@
android:label="@string/customize_colors"
android:parentActivityName=".activities.SettingsActivity"/>
<activity
android:name="com.simplemobiletools.commons.activities.FAQActivity"
android:label="@string/frequently_asked_questions"
android:parentActivityName="com.simplemobiletools.commons.activities.AboutActivity"/>
<provider
android:name="android.support.v4.content.FileProvider"
android:authorities="${applicationId}.provider"

View File

@ -15,6 +15,7 @@ import android.view.MenuItem
import com.simplemobiletools.commons.dialogs.RadioGroupDialog
import com.simplemobiletools.commons.extensions.*
import com.simplemobiletools.commons.helpers.*
import com.simplemobiletools.commons.models.FAQItem
import com.simplemobiletools.commons.models.RadioItem
import com.simplemobiletools.commons.models.Release
import com.simplemobiletools.filemanager.BuildConfig
@ -266,7 +267,12 @@ class MainActivity : SimpleActivity() {
}
private fun launchAbout() {
startAboutActivity(R.string.app_name, LICENSE_KOTLIN or LICENSE_MULTISELECT or LICENSE_GLIDE or LICENSE_PATTERN or LICENSE_REPRINT, BuildConfig.VERSION_NAME)
val faqItems = arrayListOf(
FAQItem(R.string.faq_2_title_commons, R.string.faq_2_text_commons),
FAQItem(R.string.faq_3_title_commons, R.string.faq_3_text_commons))
startAboutActivity(R.string.app_name, LICENSE_KOTLIN or LICENSE_MULTISELECT or LICENSE_GLIDE or LICENSE_PATTERN or LICENSE_REPRINT,
BuildConfig.VERSION_NAME, faqItems)
}
override fun onBackPressed() {