From 5d796703e8d69861bbff01bebf079d8401e66f77 Mon Sep 17 00:00:00 2001 From: Allan Wang Date: Thu, 15 Aug 2019 23:25:54 -0700 Subject: Remove dbflow --- .../main/kotlin/com/pitchedapps/frost/FrostApp.kt | 23 --------- .../kotlin/com/pitchedapps/frost/StartActivity.kt | 31 ------------ .../pitchedapps/frost/activities/AboutActivity.kt | 1 - .../kotlin/com/pitchedapps/frost/db/CookiesDb.kt | 23 --------- .../kotlin/com/pitchedapps/frost/db/FbTabsDb.kt | 39 --------------- .../kotlin/com/pitchedapps/frost/db/GenericDb.kt | 2 + .../com/pitchedapps/frost/db/NotificationDb.kt | 57 +--------------------- .../frost/services/FrostNotifications.kt | 1 - 8 files changed, 3 insertions(+), 174 deletions(-) delete mode 100644 app/src/main/kotlin/com/pitchedapps/frost/db/FbTabsDb.kt (limited to 'app') diff --git a/app/src/main/kotlin/com/pitchedapps/frost/FrostApp.kt b/app/src/main/kotlin/com/pitchedapps/frost/FrostApp.kt index 2ebdd215..7a4472b4 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/FrostApp.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/FrostApp.kt @@ -30,10 +30,7 @@ import com.bumptech.glide.request.RequestOptions import com.bumptech.glide.signature.ApplicationVersionSignature import com.mikepenz.materialdrawer.util.AbstractDrawerImageLoader import com.mikepenz.materialdrawer.util.DrawerImageLoader -import com.pitchedapps.frost.db.CookiesDb -import com.pitchedapps.frost.db.FbTabsDb import com.pitchedapps.frost.db.FrostDatabase -import com.pitchedapps.frost.db.NotificationDb import com.pitchedapps.frost.glide.GlideApp import com.pitchedapps.frost.services.scheduleNotificationsFromPrefs import com.pitchedapps.frost.services.setupNotificationChannels @@ -42,15 +39,10 @@ import com.pitchedapps.frost.utils.FrostPglAdBlock import com.pitchedapps.frost.utils.L import com.pitchedapps.frost.utils.Prefs import com.pitchedapps.frost.utils.Showcase -import com.raizlabs.android.dbflow.config.DatabaseConfig -import com.raizlabs.android.dbflow.config.FlowConfig -import com.raizlabs.android.dbflow.config.FlowManager -import com.raizlabs.android.dbflow.runtime.ContentResolverNotifier import org.koin.android.ext.koin.androidContext import org.koin.android.ext.koin.androidLogger import org.koin.core.context.startKoin import java.util.Random -import kotlin.reflect.KClass /** * Created by Allan Wang on 2017-05-28. @@ -63,27 +55,12 @@ class FrostApp : Application() { // lateinit var refWatcher: RefWatcher - private fun FlowConfig.Builder.withDatabase(name: String, klass: KClass<*>) = - addDatabaseConfig( - DatabaseConfig.builder(klass.java) - .databaseName(name) - .modelNotifier(ContentResolverNotifier("${BuildConfig.APPLICATION_ID}.dbflow.provider")) - .build() - ) - override fun onCreate() { if (!buildIsLollipopAndUp) { // not supported super.onCreate() return } - FlowManager.init( - FlowConfig.Builder(this) - .withDatabase(CookiesDb.NAME, CookiesDb::class) - .withDatabase(FbTabsDb.NAME, FbTabsDb::class) - .withDatabase(NotificationDb.NAME, NotificationDb::class) - .build() - ) // if (LeakCanary.isInAnalyzerProcess(this)) return // refWatcher = LeakCanary.install(this) initPrefs() diff --git a/app/src/main/kotlin/com/pitchedapps/frost/StartActivity.kt b/app/src/main/kotlin/com/pitchedapps/frost/StartActivity.kt index 61b4a194..e5b6d49a 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/StartActivity.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/StartActivity.kt @@ -34,12 +34,7 @@ import com.pitchedapps.frost.activities.MainActivity import com.pitchedapps.frost.activities.SelectorActivity import com.pitchedapps.frost.db.CookieDao import com.pitchedapps.frost.db.CookieEntity -import com.pitchedapps.frost.db.CookieModel -import com.pitchedapps.frost.db.FbTabModel import com.pitchedapps.frost.db.GenericDao -import com.pitchedapps.frost.db.getTabs -import com.pitchedapps.frost.db.save -import com.pitchedapps.frost.db.saveTabs import com.pitchedapps.frost.db.selectAll import com.pitchedapps.frost.facebook.FbCookie import com.pitchedapps.frost.utils.BiometricUtils @@ -48,11 +43,7 @@ import com.pitchedapps.frost.utils.L import com.pitchedapps.frost.utils.Prefs import com.pitchedapps.frost.utils.launchNewTask import com.pitchedapps.frost.utils.loadAssets -import com.raizlabs.android.dbflow.kotlinextensions.from -import com.raizlabs.android.dbflow.kotlinextensions.select -import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.launch -import kotlinx.coroutines.withContext import org.koin.android.ext.android.inject import java.util.ArrayList @@ -82,7 +73,6 @@ class StartActivity : KauBaseActivity() { launch { val authDefer = BiometricUtils.authenticate(this@StartActivity) try { - migrate() FbCookie.switchBackUser() val cookies = ArrayList(cookieDao.selectAll()) L.i { "Cookies loaded at time ${System.currentTimeMillis()}" } @@ -111,27 +101,6 @@ class StartActivity : KauBaseActivity() { } } - /** - * Migrate from dbflow to room - * TODO delete dbflow data - */ - private suspend fun migrate() = withContext(Dispatchers.IO) { - if (cookieDao.selectAll().isNotEmpty()) return@withContext - val cookies = (select from CookieModel::class).queryList() - .map { CookieEntity(it.id, it.name, it.cookie) } - if (cookies.isNotEmpty()) { - cookieDao.save(cookies) - L._d { "Migrated cookies ${cookieDao.selectAll()}" } - } - val tabs = (select from FbTabModel::class).queryList().map(FbTabModel::tab) - if (tabs.isNotEmpty()) { - genericDao.saveTabs(tabs) - L._d { "Migrated tabs ${genericDao.getTabs()}" } - } - deleteDatabase("Cookies.db") - deleteDatabase("FrostTabs.db") - } - private fun showInvalidWebView() = showInvalidView(R.string.error_webview) diff --git a/app/src/main/kotlin/com/pitchedapps/frost/activities/AboutActivity.kt b/app/src/main/kotlin/com/pitchedapps/frost/activities/AboutActivity.kt index e2ccb8e5..4b98c6c9 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/activities/AboutActivity.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/activities/AboutActivity.kt @@ -68,7 +68,6 @@ class AboutActivity : AboutActivityBase(null, { val include = arrayOf( "AboutLibraries", "AndroidIconics", - "dbflow", "fastadapter", "glide", "Jsoup", diff --git a/app/src/main/kotlin/com/pitchedapps/frost/db/CookiesDb.kt b/app/src/main/kotlin/com/pitchedapps/frost/db/CookiesDb.kt index 82548396..d90ff3de 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/db/CookiesDb.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/db/CookiesDb.kt @@ -24,11 +24,6 @@ import androidx.room.Insert import androidx.room.OnConflictStrategy import androidx.room.Query import com.pitchedapps.frost.utils.Prefs -import com.raizlabs.android.dbflow.annotation.ConflictAction -import com.raizlabs.android.dbflow.annotation.Database -import com.raizlabs.android.dbflow.annotation.PrimaryKey -import com.raizlabs.android.dbflow.annotation.Table -import com.raizlabs.android.dbflow.structure.BaseModel import kotlinx.android.parcel.Parcelize /** @@ -74,21 +69,3 @@ suspend fun CookieDao.save(cookie: CookieEntity) = dao { _save(cookie) } suspend fun CookieDao.save(cookies: List) = dao { _save(cookies) } suspend fun CookieDao.deleteById(id: Long) = dao { _deleteById(id) } suspend fun CookieDao.currentCookie() = selectById(Prefs.userId) - -@Database(version = CookiesDb.VERSION) -object CookiesDb { - const val NAME = "Cookies" - const val VERSION = 2 -} - -@Parcelize -@Table(database = CookiesDb::class, allFields = true, primaryKeyConflict = ConflictAction.REPLACE) -data class CookieModel( - @PrimaryKey var id: Long = -1L, - var name: String? = null, - var cookie: String? = null -) : - BaseModel(), Parcelable { - - override fun toString(): String = "CookieModel(${hashCode()})" -} diff --git a/app/src/main/kotlin/com/pitchedapps/frost/db/FbTabsDb.kt b/app/src/main/kotlin/com/pitchedapps/frost/db/FbTabsDb.kt deleted file mode 100644 index 475d134f..00000000 --- a/app/src/main/kotlin/com/pitchedapps/frost/db/FbTabsDb.kt +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright 2018 Allan Wang - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -package com.pitchedapps.frost.db - -import com.pitchedapps.frost.facebook.FbItem -import com.raizlabs.android.dbflow.annotation.Database -import com.raizlabs.android.dbflow.annotation.PrimaryKey -import com.raizlabs.android.dbflow.annotation.Table -import com.raizlabs.android.dbflow.structure.BaseModel - -/** - * Created by Allan Wang on 2017-05-30. - */ - -const val TAB_COUNT = 4 - -@Database(version = FbTabsDb.VERSION) -object FbTabsDb { - const val NAME = "FrostTabs" - const val VERSION = 1 -} - -@Table(database = FbTabsDb::class, allFields = true) -data class FbTabModel(@PrimaryKey var position: Int = -1, var tab: FbItem = FbItem.FEED) : - BaseModel() diff --git a/app/src/main/kotlin/com/pitchedapps/frost/db/GenericDb.kt b/app/src/main/kotlin/com/pitchedapps/frost/db/GenericDb.kt index f36c8af9..b7274c33 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/db/GenericDb.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/db/GenericDb.kt @@ -56,6 +56,8 @@ interface GenericDao { } } +const val TAB_COUNT = 4 + suspend fun GenericDao.saveTabs(tabs: List) = dao { val content = tabs.joinToString(",") { it.name } _save(GenericEntity(GenericDao.TYPE_TABS, content)) diff --git a/app/src/main/kotlin/com/pitchedapps/frost/db/NotificationDb.kt b/app/src/main/kotlin/com/pitchedapps/frost/db/NotificationDb.kt index e89bf46d..93df01dc 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/db/NotificationDb.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/db/NotificationDb.kt @@ -26,22 +26,8 @@ import androidx.room.Insert import androidx.room.OnConflictStrategy import androidx.room.Query import androidx.room.Transaction -import com.pitchedapps.frost.services.NOTIF_CHANNEL_GENERAL -import com.pitchedapps.frost.services.NOTIF_CHANNEL_MESSAGES import com.pitchedapps.frost.services.NotificationContent import com.pitchedapps.frost.utils.L -import com.raizlabs.android.dbflow.annotation.ConflictAction -import com.raizlabs.android.dbflow.annotation.Database -import com.raizlabs.android.dbflow.annotation.Migration -import com.raizlabs.android.dbflow.annotation.PrimaryKey -import com.raizlabs.android.dbflow.annotation.Table -import com.raizlabs.android.dbflow.kotlinextensions.eq -import com.raizlabs.android.dbflow.kotlinextensions.from -import com.raizlabs.android.dbflow.kotlinextensions.select -import com.raizlabs.android.dbflow.kotlinextensions.where -import com.raizlabs.android.dbflow.sql.SQLiteType -import com.raizlabs.android.dbflow.sql.migration.AlterTableMigration -import com.raizlabs.android.dbflow.structure.BaseModel @Entity( tableName = "notifications", @@ -164,46 +150,5 @@ suspend fun NotificationDao.saveNotifications( } suspend fun NotificationDao.latestEpoch(userId: Long, type: String): Long = dao { - _selectEpoch(userId, type) ?: lastNotificationTime(userId).let { - when (type) { - NOTIF_CHANNEL_GENERAL -> it.epoch - NOTIF_CHANNEL_MESSAGES -> it.epochIm - else -> -1L - } - } -} - -/** - * Created by Allan Wang on 2017-05-30. - */ - -@Database(version = NotificationDb.VERSION) -object NotificationDb { - const val NAME = "Notifications" - const val VERSION = 2 + _selectEpoch(userId, type) ?: -1L } - -@Migration(version = 2, database = NotificationDb::class) -class NotificationMigration2(modelClass: Class) : - AlterTableMigration(modelClass) { - override fun onPreMigrate() { - super.onPreMigrate() - addColumn(SQLiteType.INTEGER, "epochIm") - L.d { "Added column" } - } -} - -@Table( - database = NotificationDb::class, - allFields = true, - primaryKeyConflict = ConflictAction.REPLACE -) -data class NotificationModel( - @PrimaryKey var id: Long = -1L, - var epoch: Long = -1L, - var epochIm: Long = -1L -) : BaseModel() - -internal fun lastNotificationTime(id: Long): NotificationModel = - (select from NotificationModel::class where (NotificationModel_Table.id eq id)).querySingle() - ?: NotificationModel(id = id) diff --git a/app/src/main/kotlin/com/pitchedapps/frost/services/FrostNotifications.kt b/app/src/main/kotlin/com/pitchedapps/frost/services/FrostNotifications.kt index cab1311c..6ff20bfb 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/services/FrostNotifications.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/services/FrostNotifications.kt @@ -144,7 +144,6 @@ enum class NotificationType( if (notifContents.isEmpty()) return 0 val userId = data.id - // Legacy, remove with dbflow val prevLatestEpoch = notifDao.latestEpoch(userId, channelId) L.v { "Notif $name prev epoch $prevLatestEpoch" } -- cgit v1.2.3 From 658da93f983a9cd68f83eff5e8778625f1ef3fba Mon Sep 17 00:00:00 2001 From: Allan Wang Date: Fri, 16 Aug 2019 00:14:33 -0700 Subject: Remove dbflow dependencies --- app/build.gradle | 5 ----- app/proguard-rules.pro | 1 - app/src/main/AndroidManifest.xml | 5 ----- 3 files changed, 11 deletions(-) (limited to 'app') diff --git a/app/build.gradle b/app/build.gradle index dbc38c37..b1e8085e 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -277,11 +277,6 @@ dependencies { debugImplementation "com.squareup.leakcanary:leakcanary-android:${Versions.leakCanary}" // testImplementation "com.squareup.leakcanary:leakcanary-android-no-op:${Versions.leakCanary}" - implementation "com.github.Raizlabs.DBFlow:dbflow:${Versions.dbflow}" - implementation "com.github.Raizlabs.DBFlow:dbflow-core:${Versions.dbflow}" - kapt "com.github.Raizlabs.DBFlow:dbflow-processor:${Versions.dbflow}" - implementation "com.github.Raizlabs.DBFlow:dbflow-kotlinextensions:${Versions.dbflow}" - //Icons implementation kau.Dependencies.iconicsMaterial implementation kau.Dependencies.iconicsCommunity diff --git a/app/proguard-rules.pro b/app/proguard-rules.pro index c05edb53..cdb57300 100644 --- a/app/proguard-rules.pro +++ b/app/proguard-rules.pro @@ -1,6 +1,5 @@ -ignorewarnings -dontwarn kotlin.** --keep class * extends com.raizlabs.android.dbflow.config.DatabaseHolder { *; } -keepattributes *Annotation* # Enums #-keepclassmembers class * extends java.lang.Enum { diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index e4fc0415..664ffd38 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -197,11 +197,6 @@ android:name="android.support.FILE_PROVIDER_PATHS" android:resource="@xml/file_paths" /> - - -- cgit v1.2.3 From de4f6072f4318661734acd57ca1684a002f68f45 Mon Sep 17 00:00:00 2001 From: Allan Wang Date: Mon, 19 Aug 2019 23:53:02 -0700 Subject: Remove _ft_ query, resolves #1506 --- .../pitchedapps/frost/facebook/FbUrlFormatter.kt | 2 +- .../com/pitchedapps/frost/facebook/FbUrlTest.kt | 22 ++++++++++++++++++---- 2 files changed, 19 insertions(+), 5 deletions(-) (limited to 'app') diff --git a/app/src/main/kotlin/com/pitchedapps/frost/facebook/FbUrlFormatter.kt b/app/src/main/kotlin/com/pitchedapps/frost/facebook/FbUrlFormatter.kt index 16cbc9c8..2b576ae1 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/facebook/FbUrlFormatter.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/facebook/FbUrlFormatter.kt @@ -137,7 +137,7 @@ class FbUrlFormatter(url: String) { * * acontext is not required for "friends interested in" notifications */ - val discardableQueries = arrayOf("ref", "refid", "SharedWith", "fbclid") + val discardableQueries = arrayOf("ref", "refid", "SharedWith", "fbclid", "_ft_") val converter = listOf( "\\3C " to "%3C", "\\3E " to "%3E", "\\23 " to "%23", "\\25 " to "%25", diff --git a/app/src/test/kotlin/com/pitchedapps/frost/facebook/FbUrlTest.kt b/app/src/test/kotlin/com/pitchedapps/frost/facebook/FbUrlTest.kt index ca842ed9..5e1082d7 100644 --- a/app/src/test/kotlin/com/pitchedapps/frost/facebook/FbUrlTest.kt +++ b/app/src/test/kotlin/com/pitchedapps/frost/facebook/FbUrlTest.kt @@ -31,7 +31,11 @@ class FbUrlTest { @Suppress("NOTHING_TO_INLINE") inline fun assertFbFormat(expected: String, url: String) { val fbUrl = FbUrlFormatter(url) - assertEquals(expected, fbUrl.toString(), "FbUrl Mismatch:\n${fbUrl.toLogList().joinToString("\n\t")}") + assertEquals( + expected, + fbUrl.toString(), + "FbUrl Mismatch:\n${fbUrl.toLogList().joinToString("\n\t")}" + ) } @Test @@ -65,8 +69,10 @@ class FbUrlTest { @Test fun ampersand() { - val url = "https://scontent-yyz1-1.xx.fbcdn.net/v/t31.0-8/fr/cp0/e15/q65/123.jpg?_nc_cat=0&efg=asdf" - val formattedUrl = "https://scontent-yyz1-1.xx.fbcdn.net/v/t31.0-8/fr/cp0/e15/q65/123.jpg?_nc_cat=0&efg=asdf" + val url = + "https://scontent-yyz1-1.xx.fbcdn.net/v/t31.0-8/fr/cp0/e15/q65/123.jpg?_nc_cat=0&efg=asdf" + val formattedUrl = + "https://scontent-yyz1-1.xx.fbcdn.net/v/t31.0-8/fr/cp0/e15/q65/123.jpg?_nc_cat=0&efg=asdf" assertFbFormat(formattedUrl, url) } @@ -138,10 +144,18 @@ class FbUrlTest { @Test fun viewFullImage() { - val url = "https://scontent-yyz1-1.xx.fbcdn.net/v/t1.0-9/fr/cp0/e15/q65/asdf_n.jpg?efg=asdf&oh=asdf&oe=asdf" + val url = + "https://scontent-yyz1-1.xx.fbcdn.net/v/t1.0-9/fr/cp0/e15/q65/asdf_n.jpg?efg=asdf&oh=asdf&oe=asdf" assertFbFormat(url, "#!$url") } + @Test + fun queryFt() { + val url = "${FB_URL_BASE}sample/photos/a.12346/?source=48&_ft_=xxx" + val expected = "${FB_URL_BASE}sample/photos/a.12346/?source=48" + assertFbFormat(expected, url) + } + // @Test // fun viewFullImageIndirect() { // val urlBase = "photo/view_full_size/?fbid=1234&ref_component=mbasic_photo_permalink&ref_page=%2Fwap%2Fphoto.php&refid=13&_ft_=qid.1234%3Amf_story_key.1234%3Atop_level_post_id" -- cgit v1.2.3 From 9b0990b2ef3538b3634318af362b722d9a472fab Mon Sep 17 00:00:00 2001 From: Allan Wang Date: Tue, 20 Aug 2019 00:24:26 -0700 Subject: Fix tests --- app/src/test/kotlin/com/pitchedapps/frost/facebook/FbUrlTest.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app') diff --git a/app/src/test/kotlin/com/pitchedapps/frost/facebook/FbUrlTest.kt b/app/src/test/kotlin/com/pitchedapps/frost/facebook/FbUrlTest.kt index 5e1082d7..7e13e6dc 100644 --- a/app/src/test/kotlin/com/pitchedapps/frost/facebook/FbUrlTest.kt +++ b/app/src/test/kotlin/com/pitchedapps/frost/facebook/FbUrlTest.kt @@ -107,7 +107,7 @@ class FbUrlTest { val url = "/video_redirect/?src=https%3A%2F%2Fvideo-yyz1-1.xx.fbcdn.net%2Fv%2Ft42.1790-2%2F2349078999904_n.mp4%3Fefg%3DeyJ87J9%26oh%3Df5777784%26oe%3D56FD4&source=media_collage&id=1735049&refid=8&_ft_=qid.6484464%3Amf_story_key.-43172431214%3Atop_level_post_id.102773&__tn__=FEH-R" val expected = - "https://video-yyz1-1.xx.fbcdn.net/v/t42.1790-2/2349078999904_n.mp4?efg=eyJ87J9&oh=f5777784&oe=56FD4&source=media_collage&id=1735049&_ft_=qid.6484464:mf_story_key.-43172431214:top_level_post_id.102773&__tn__=FEH-R" + "https://video-yyz1-1.xx.fbcdn.net/v/t42.1790-2/2349078999904_n.mp4?efg=eyJ87J9&oh=f5777784&oe=56FD4&source=media_collage&id=1735049&__tn__=FEH-R" assertFbFormat(expected, url) } -- cgit v1.2.3 From 1a0ec6fc0239d77c2aa771a23ab857f5bd7703d9 Mon Sep 17 00:00:00 2001 From: Allan Wang Date: Wed, 21 Aug 2019 00:33:46 -0700 Subject: Add more query discards, following 8872d81bccd13ba10b45caebe9d0aec1f487ac25 --- .../com/pitchedapps/frost/facebook/FbUrlFormatter.kt | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) (limited to 'app') diff --git a/app/src/main/kotlin/com/pitchedapps/frost/facebook/FbUrlFormatter.kt b/app/src/main/kotlin/com/pitchedapps/frost/facebook/FbUrlFormatter.kt index 2b576ae1..2095f8fd 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/facebook/FbUrlFormatter.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/facebook/FbUrlFormatter.kt @@ -137,7 +137,20 @@ class FbUrlFormatter(url: String) { * * acontext is not required for "friends interested in" notifications */ - val discardableQueries = arrayOf("ref", "refid", "SharedWith", "fbclid", "_ft_") + val discardableQueries = arrayOf( + "ref", + "refid", + "SharedWith", + "fbclid", + "_ft_", + "_tn_", + "_xt_", + "bacr", + "frefs", + "hc_ref", + "loc_ref", + "pn_ref" + ) val converter = listOf( "\\3C " to "%3C", "\\3E " to "%3E", "\\23 " to "%23", "\\25 " to "%25", -- cgit v1.2.3 From e736b53094629c4250c536170e938c625f5dc03c Mon Sep 17 00:00:00 2001 From: Allan Wang Date: Sat, 7 Sep 2019 18:10:38 -0700 Subject: Remove desktop overlay activity --- app/src/main/AndroidManifest.xml | 7 ------- .../frost/activities/WebOverlayActivity.kt | 17 +++-------------- .../main/kotlin/com/pitchedapps/frost/utils/Utils.kt | 4 ---- .../pitchedapps/frost/web/FrostUrlOverlayValidator.kt | 19 +------------------ 4 files changed, 4 insertions(+), 43 deletions(-) (limited to 'app') diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index 664ffd38..d30b5177 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -59,13 +59,6 @@ android:label="@string/frost_name" android:launchMode="singleTop" android:theme="@style/FrostTheme.Overlay.Slide" /> - Context.launchWebOverlay fun Context.launchWebOverlay(url: String) = launchWebOverlayImpl(url) -fun Context.launchWebOverlayDesktop(url: String) = - launchWebOverlayImpl(url) - private fun Context.fadeBundle() = ActivityOptions.makeCustomAnimation( this, android.R.anim.fade_in, android.R.anim.fade_out diff --git a/app/src/main/kotlin/com/pitchedapps/frost/web/FrostUrlOverlayValidator.kt b/app/src/main/kotlin/com/pitchedapps/frost/web/FrostUrlOverlayValidator.kt index 4aa43b49..eec5a5dc 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/web/FrostUrlOverlayValidator.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/web/FrostUrlOverlayValidator.kt @@ -22,7 +22,6 @@ import com.pitchedapps.frost.activities.WebOverlayActivityBase import com.pitchedapps.frost.contracts.VideoViewHolder import com.pitchedapps.frost.facebook.FbCookie import com.pitchedapps.frost.facebook.FbItem -import com.pitchedapps.frost.facebook.USER_AGENT_DESKTOP import com.pitchedapps.frost.facebook.formattedFbUrl import com.pitchedapps.frost.utils.L import com.pitchedapps.frost.utils.Prefs @@ -32,7 +31,6 @@ import com.pitchedapps.frost.utils.isIndirectImageUrl import com.pitchedapps.frost.utils.isVideoUrl import com.pitchedapps.frost.utils.launchImageActivity import com.pitchedapps.frost.utils.launchWebOverlay -import com.pitchedapps.frost.utils.launchWebOverlayDesktop import com.pitchedapps.frost.views.FrostWebView /** @@ -74,22 +72,7 @@ fun FrostWebView.requestWebOverlay(url: String): Boolean { return false } if (!Prefs.overlayEnabled) return false - if (context is WebOverlayActivityBase) { - val shouldUseDesktop = url.formattedFbUrl.shouldUseDesktopAgent - //already overlay; manage user agent - if (userAgentString != USER_AGENT_DESKTOP && shouldUseDesktop) { - L._i { "Switch to desktop agent overlay" } - context.launchWebOverlayDesktop(url) - return true - } - if (userAgentString == USER_AGENT_DESKTOP && !shouldUseDesktop) { - L._i { "Switch from desktop agent" } - context.launchWebOverlay(url) - return true - } - L._i { "return false switch" } - return false - } + if (context is WebOverlayActivityBase) return false L.v { "Request web overlay passed" } context.launchWebOverlay(url) return true -- cgit v1.2.3 From 9363d4bc987cb7b4886ffb6a863b5d14c602e402 Mon Sep 17 00:00:00 2001 From: Allan Wang Date: Sat, 7 Sep 2019 18:15:53 -0700 Subject: Remove desktop and mobile user agent def --- .../kotlin/com/pitchedapps/frost/debugger/OfflineWebsite.kt | 4 ++-- app/src/main/kotlin/com/pitchedapps/frost/facebook/FbConst.kt | 10 ++++++++-- .../com/pitchedapps/frost/facebook/requests/FbRequest.kt | 4 ++-- app/src/main/kotlin/com/pitchedapps/frost/utils/Downloader.kt | 6 +++--- app/src/main/kotlin/com/pitchedapps/frost/utils/Utils.kt | 9 +++++---- .../main/kotlin/com/pitchedapps/frost/views/FrostWebView.kt | 9 ++------- app/src/main/kotlin/com/pitchedapps/frost/web/DebugWebView.kt | 4 ++-- .../com/pitchedapps/frost/web/FrostUrlOverlayValidator.kt | 1 + app/src/main/kotlin/com/pitchedapps/frost/web/LoginWebView.kt | 4 ++-- 9 files changed, 27 insertions(+), 24 deletions(-) (limited to 'app') diff --git a/app/src/main/kotlin/com/pitchedapps/frost/debugger/OfflineWebsite.kt b/app/src/main/kotlin/com/pitchedapps/frost/debugger/OfflineWebsite.kt index 8215de03..bc453250 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/debugger/OfflineWebsite.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/debugger/OfflineWebsite.kt @@ -19,7 +19,7 @@ package com.pitchedapps.frost.debugger import ca.allanwang.kau.logging.KauLoggerExtension import ca.allanwang.kau.utils.copyFromInputStream import com.pitchedapps.frost.facebook.FB_CSS_URL_MATCHER -import com.pitchedapps.frost.facebook.USER_AGENT_DESKTOP +import com.pitchedapps.frost.facebook.USER_AGENT import com.pitchedapps.frost.facebook.get import com.pitchedapps.frost.facebook.requests.call import com.pitchedapps.frost.utils.createFreshDir @@ -59,7 +59,7 @@ class OfflineWebsite( * Directory that holds all the files */ val baseDir: File, - private val userAgent: String = USER_AGENT_DESKTOP + private val userAgent: String = USER_AGENT ) { /** diff --git a/app/src/main/kotlin/com/pitchedapps/frost/facebook/FbConst.kt b/app/src/main/kotlin/com/pitchedapps/frost/facebook/FbConst.kt index 032ff31e..c01bce55 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/facebook/FbConst.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/facebook/FbConst.kt @@ -28,6 +28,13 @@ fun profilePictureUrl(id: Long) = "https://graph.facebook.com/$id/picture?type=l const val FB_LOGIN_URL = "${FB_URL_BASE}login" const val FB_HOME_URL = "${FB_URL_BASE}home.php" +/* + * User agent candidates. + * For those building from source, you can feel free to set the used agent to one of these options. + * Following https://github.com/AllanWang/Frost-for-Facebook/pull/1531, we do not support multiple + * agents per login session. + */ + // Default user agent private const val USER_AGENT_MOBILE_CONST = "Mozilla/5.0 (Linux; Android 8.0.0; ONEPLUS A3000) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.90 Mobile Safari/537.36" @@ -35,8 +42,7 @@ private const val USER_AGENT_MOBILE_CONST = private const val USER_AGENT_DESKTOP_CONST = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/73.0.3683.90 Safari/537.36" -const val USER_AGENT_MOBILE = USER_AGENT_DESKTOP_CONST -const val USER_AGENT_DESKTOP = USER_AGENT_DESKTOP_CONST +const val USER_AGENT = USER_AGENT_DESKTOP_CONST /** * Animation transition delay, just to ensure that the styles diff --git a/app/src/main/kotlin/com/pitchedapps/frost/facebook/requests/FbRequest.kt b/app/src/main/kotlin/com/pitchedapps/frost/facebook/requests/FbRequest.kt index 8a89b973..b948506f 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/facebook/requests/FbRequest.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/facebook/requests/FbRequest.kt @@ -22,7 +22,7 @@ import com.pitchedapps.frost.facebook.FB_JSON_URL_MATCHER import com.pitchedapps.frost.facebook.FB_REV_MATCHER import com.pitchedapps.frost.facebook.FB_URL_BASE import com.pitchedapps.frost.facebook.FB_USER_MATCHER -import com.pitchedapps.frost.facebook.USER_AGENT_DESKTOP +import com.pitchedapps.frost.facebook.USER_AGENT import com.pitchedapps.frost.facebook.get import com.pitchedapps.frost.kotlin.Flyweight import com.pitchedapps.frost.utils.L @@ -97,7 +97,7 @@ internal fun List>.withEmptyData(vararg key: String): List = setOf(FbItem.MESSAGES, FbItem.CHAT, FbItem.FEED_MOST_RECENT, FbItem.FEED_TOP_STORIES) .mapTo(mutableSetOf(), FbItem::url) +@Deprecated(message = "Should not be used in production as we only support one user agent at a time.") val String.shouldUseDesktopAgent: Boolean get() = when { contains("story.php") -> false // do not use desktop for comment section diff --git a/app/src/main/kotlin/com/pitchedapps/frost/web/LoginWebView.kt b/app/src/main/kotlin/com/pitchedapps/frost/web/LoginWebView.kt index 8e437c29..857c166d 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/web/LoginWebView.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/web/LoginWebView.kt @@ -33,7 +33,7 @@ import com.pitchedapps.frost.db.CookieEntity import com.pitchedapps.frost.facebook.FB_LOGIN_URL import com.pitchedapps.frost.facebook.FB_USER_MATCHER import com.pitchedapps.frost.facebook.FbCookie -import com.pitchedapps.frost.facebook.USER_AGENT_MOBILE +import com.pitchedapps.frost.facebook.USER_AGENT import com.pitchedapps.frost.facebook.get import com.pitchedapps.frost.injectors.CssHider import com.pitchedapps.frost.injectors.jsInject @@ -58,7 +58,7 @@ class LoginWebView @JvmOverloads constructor( @SuppressLint("SetJavaScriptEnabled") private fun setupWebview() { settings.javaScriptEnabled = true - settings.userAgentString = USER_AGENT_MOBILE + settings.userAgentString = USER_AGENT setLayerType(View.LAYER_TYPE_HARDWARE, null) webViewClient = LoginClient() webChromeClient = LoginChromeClient() -- cgit v1.2.3 From 4c7521d2f773424d76bfe8b4f5beb6cb8b1af815 Mon Sep 17 00:00:00 2001 From: Allan Wang Date: Sat, 7 Sep 2019 21:56:46 -0700 Subject: Replace web only with native ui and auth requests --- .../pitchedapps/frost/fragments/FragmentBase.kt | 2 +- .../frost/services/FrostRequestService.kt | 4 +-- .../frost/services/NotificationService.kt | 4 --- .../com/pitchedapps/frost/settings/Behaviour.kt | 7 ++++ .../com/pitchedapps/frost/settings/Experimental.kt | 7 ++-- .../pitchedapps/frost/settings/Notifications.kt | 38 ++-------------------- .../kotlin/com/pitchedapps/frost/utils/Prefs.kt | 4 ++- app/src/main/res/values/strings_pref_behaviour.xml | 2 ++ .../main/res/values/strings_pref_experimental.xml | 2 ++ 9 files changed, 22 insertions(+), 48 deletions(-) (limited to 'app') diff --git a/app/src/main/kotlin/com/pitchedapps/frost/fragments/FragmentBase.kt b/app/src/main/kotlin/com/pitchedapps/frost/fragments/FragmentBase.kt index c580c9ed..50bae16c 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/fragments/FragmentBase.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/fragments/FragmentBase.kt @@ -67,7 +67,7 @@ abstract class BaseFragment : Fragment(), CoroutineScope, FragmentContract, Dyna data: FbItem, position: Int ): BaseFragment { - val fragment = if (useFallback || Prefs.webOnly) WebFragment() else base() + val fragment = if (useFallback || !Prefs.nativeUi) WebFragment() else base() val d = if (data == FbItem.FEED) FeedSort(Prefs.feedSort).item else data fragment.withArguments( ARG_URL to d.url, diff --git a/app/src/main/kotlin/com/pitchedapps/frost/services/FrostRequestService.kt b/app/src/main/kotlin/com/pitchedapps/frost/services/FrostRequestService.kt index fe59c421..77546971 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/services/FrostRequestService.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/services/FrostRequestService.kt @@ -163,8 +163,8 @@ class FrostRequestService : BaseJobService() { override fun onStartJob(params: JobParameters?): Boolean { super.onStartJob(params) - if (Prefs.webOnly) { - L.i { "Web only; skipping request service" } + if (!Prefs.authRequests) { + L.i { "Auth requests disabled; skipping request service" } return false } val bundle = params?.extras diff --git a/app/src/main/kotlin/com/pitchedapps/frost/services/NotificationService.kt b/app/src/main/kotlin/com/pitchedapps/frost/services/NotificationService.kt index 091fbb4b..95726974 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/services/NotificationService.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/services/NotificationService.kt @@ -72,10 +72,6 @@ class NotificationService : BaseJobService() { override fun onStartJob(params: JobParameters?): Boolean { super.onStartJob(params) L.i { "Fetching notifications" } - if (Prefs.webOnly) { - L.i { "Web only mode; skipping notification service" } - return false - } launch { try { sendNotifications(params) diff --git a/app/src/main/kotlin/com/pitchedapps/frost/settings/Behaviour.kt b/app/src/main/kotlin/com/pitchedapps/frost/settings/Behaviour.kt index ba5b839b..a0a8117f 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/settings/Behaviour.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/settings/Behaviour.kt @@ -79,6 +79,13 @@ fun SettingsActivity.getBehaviourPrefs(): KPrefAdapterBuilder.() -> Unit = { } } + checkbox(R.string.native_ui, Prefs::nativeUi, { + Prefs.nativeUi = it + shouldRestartMain() + }) { + descRes = R.string.native_ui_desc + } + checkbox(R.string.exit_confirmation, Prefs::exitConfirmation, { Prefs.exitConfirmation = it }) { descRes = R.string.exit_confirmation_desc } diff --git a/app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt b/app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt index d0963665..2f45547d 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt @@ -43,11 +43,8 @@ fun SettingsActivity.getExperimentalPrefs(): KPrefAdapterBuilder.() -> Unit = { // Experimental content starts here ------------------ - checkbox(R.string.web_only, Prefs::webOnly, { - Prefs.webOnly = it - shouldRestartMain() - }) { - descRes = R.string.web_only_desc + checkbox(R.string.web_requests, Prefs::authRequests, { Prefs.authRequests = it }) { + descRes = R.string.web_requests_desc } // Experimental content ends here -------------------- diff --git a/app/src/main/kotlin/com/pitchedapps/frost/settings/Notifications.kt b/app/src/main/kotlin/com/pitchedapps/frost/settings/Notifications.kt index ccf04935..9fcf2e96 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/settings/Notifications.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/settings/Notifications.kt @@ -22,7 +22,6 @@ import android.media.RingtoneManager import android.os.Build import android.provider.Settings import ca.allanwang.kau.kpref.activity.KPrefAdapterBuilder -import ca.allanwang.kau.kpref.activity.KPrefItemActions import ca.allanwang.kau.kpref.activity.items.KPrefText import ca.allanwang.kau.utils.materialDialog import ca.allanwang.kau.utils.minuteToText @@ -48,25 +47,11 @@ import kotlinx.coroutines.launch */ val Prefs.hasNotifications: Boolean - get() = !webOnly && (notificationsGeneral || notificationsInstantMessages) + get() = notificationsGeneral || notificationsInstantMessages @SuppressLint("InlinedApi") fun SettingsActivity.getNotificationPrefs(): KPrefAdapterBuilder.() -> Unit = { - fun KPrefItemActions.leaveWebOnlyDialog() { - if (Prefs.webOnly) { - materialDialog { - title(R.string.leave_web_only_title) - message(R.string.leave_web_only_desc) - positiveButton(R.string.kau_yes) { - Prefs.webOnly = false - reload() - } - negativeButton(R.string.kau_no) - } - } - } - text( R.string.notification_frequency, Prefs::notificationFreq, @@ -86,9 +71,6 @@ fun SettingsActivity.getNotificationPrefs(): KPrefAdapterBuilder.() -> Unit = { } } } - onDisabledClick = { - leaveWebOnlyDialog() - } enabler = { Prefs.hasNotifications } textGetter = { minuteToText(it) } } @@ -114,19 +96,12 @@ fun SettingsActivity.getNotificationPrefs(): KPrefAdapterBuilder.() -> Unit = { reloadByTitle(R.string.notification_frequency) }) { descRes = R.string.notification_general_desc - enabler = { !Prefs.webOnly } - onDisabledClick = { - leaveWebOnlyDialog() - } } checkbox(R.string.notification_general_all_accounts, Prefs::notificationAllAccounts, { Prefs.notificationAllAccounts = it }) { descRes = R.string.notification_general_all_accounts_desc - enabler = { !Prefs.webOnly && Prefs.notificationsGeneral } - onDisabledClick = { - leaveWebOnlyDialog() - } + enabler = { Prefs.notificationsGeneral } } checkbox(R.string.notification_messages, Prefs::notificationsInstantMessages, @@ -137,19 +112,12 @@ fun SettingsActivity.getNotificationPrefs(): KPrefAdapterBuilder.() -> Unit = { reloadByTitle(R.string.notification_frequency) }) { descRes = R.string.notification_messages_desc - enabler = { !Prefs.webOnly } - onDisabledClick = { - leaveWebOnlyDialog() - } } checkbox(R.string.notification_messages_all_accounts, Prefs::notificationsImAllAccounts, { Prefs.notificationsImAllAccounts = it }) { descRes = R.string.notification_messages_all_accounts_desc - enabler = { !Prefs.webOnly && Prefs.notificationsInstantMessages } - onDisabledClick = { - leaveWebOnlyDialog() - } + enabler = { Prefs.notificationsInstantMessages } } if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) { diff --git a/app/src/main/kotlin/com/pitchedapps/frost/utils/Prefs.kt b/app/src/main/kotlin/com/pitchedapps/frost/utils/Prefs.kt index f17645d0..522e1733 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/utils/Prefs.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/utils/Prefs.kt @@ -191,7 +191,9 @@ object Prefs : KPref() { var showCreateFab: Boolean by kpref("show_create_fab", true) - var webOnly: Boolean by kpref("web_only", false) + var authRequests: Boolean by kpref("web_requests", false) + + var nativeUi: Boolean by kpref("native_ui", true) inline val mainActivityLayout: MainActivityLayout get() = MainActivityLayout(mainActivityLayoutType) diff --git a/app/src/main/res/values/strings_pref_behaviour.xml b/app/src/main/res/values/strings_pref_behaviour.xml index 32188698..aac56250 100644 --- a/app/src/main/res/values/strings_pref_behaviour.xml +++ b/app/src/main/res/values/strings_pref_behaviour.xml @@ -17,6 +17,8 @@ Enable the search bar instead of a search overlay Force Message Bottom When loading a message thread, trigger a scroll to the bottom of the page rather than loading the page as is. + Native UI + Enables native UI for certain options in the main activity. Done through parsing. Enable PIP Enable picture in picture videos Autoplay Settings diff --git a/app/src/main/res/values/strings_pref_experimental.xml b/app/src/main/res/values/strings_pref_experimental.xml index fad29ff6..b1ce508f 100644 --- a/app/src/main/res/values/strings_pref_experimental.xml +++ b/app/src/main/res/values/strings_pref_experimental.xml @@ -12,6 +12,8 @@ Web Only Having troubles? Enable to use web exclusive features. All parsing and background services will be disabled. + Web Requests + Enables features such as marking notifications as read. Known to potentially cause phishing responses. Leave web only mode Currently in web only mode. Would you like to disable it to continue? \ No newline at end of file -- cgit v1.2.3 From db857056e6226e5d91eeb8ab13478376c51fd89e Mon Sep 17 00:00:00 2001 From: Allan Wang Date: Sat, 7 Sep 2019 21:59:49 -0700 Subject: Remove web only strings --- app/src/main/res/values/strings_pref_experimental.xml | 4 ---- 1 file changed, 4 deletions(-) (limited to 'app') diff --git a/app/src/main/res/values/strings_pref_experimental.xml b/app/src/main/res/values/strings_pref_experimental.xml index b1ce508f..5ae5d56c 100644 --- a/app/src/main/res/values/strings_pref_experimental.xml +++ b/app/src/main/res/values/strings_pref_experimental.xml @@ -10,10 +10,6 @@ Launch a cold restart for the application. - Web Only - Having troubles? Enable to use web exclusive features. All parsing and background services will be disabled. Web Requests Enables features such as marking notifications as read. Known to potentially cause phishing responses. - Leave web only mode - Currently in web only mode. Would you like to disable it to continue? \ No newline at end of file -- cgit v1.2.3 From 3b457c0e5728d8643ba6b2d06329f6a7dead156f Mon Sep 17 00:00:00 2001 From: Allan Wang Date: Sat, 7 Sep 2019 22:01:34 -0700 Subject: Update request stringss --- app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt | 4 ++-- app/src/main/res/values/strings_pref_experimental.xml | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'app') diff --git a/app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt b/app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt index 2f45547d..d7c405dc 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt @@ -43,8 +43,8 @@ fun SettingsActivity.getExperimentalPrefs(): KPrefAdapterBuilder.() -> Unit = { // Experimental content starts here ------------------ - checkbox(R.string.web_requests, Prefs::authRequests, { Prefs.authRequests = it }) { - descRes = R.string.web_requests_desc + checkbox(R.string.auth_requests, Prefs::authRequests, { Prefs.authRequests = it }) { + descRes = R.string.auth_requests_desc } // Experimental content ends here -------------------- diff --git a/app/src/main/res/values/strings_pref_experimental.xml b/app/src/main/res/values/strings_pref_experimental.xml index 5ae5d56c..797878bf 100644 --- a/app/src/main/res/values/strings_pref_experimental.xml +++ b/app/src/main/res/values/strings_pref_experimental.xml @@ -10,6 +10,6 @@ Launch a cold restart for the application. - Web Requests - Enables features such as marking notifications as read. Known to potentially cause phishing responses. + Auth Requests + Enables post features such as marking notifications as read. Known to potentially cause phishing responses. \ No newline at end of file -- cgit v1.2.3 From ad0fcdcb581ee036ace2c55524069b2beef3603a Mon Sep 17 00:00:00 2001 From: Allan Wang Date: Sat, 7 Sep 2019 23:59:43 -0700 Subject: Delete experimental by default options --- app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt | 7 ------- app/src/main/kotlin/com/pitchedapps/frost/utils/Showcase.kt | 5 +---- app/src/main/res/values-ar-rSA/strings_pref_experimental.xml | 2 -- app/src/main/res/values-cs-rCZ/strings_pref_experimental.xml | 2 -- app/src/main/res/values-da-rDK/strings_pref_experimental.xml | 2 -- app/src/main/res/values-de-rDE/strings_pref_experimental.xml | 2 -- app/src/main/res/values-es-rES/strings_pref_experimental.xml | 2 -- app/src/main/res/values-fr-rFR/strings_pref_experimental.xml | 2 -- app/src/main/res/values-gl-rES/strings_pref_experimental.xml | 2 -- app/src/main/res/values-gr-rGR/strings_pref_experimental.xml | 2 -- app/src/main/res/values-hu-rHU/strings_pref_experimental.xml | 2 -- app/src/main/res/values-in-rID/strings_pref_experimental.xml | 2 -- app/src/main/res/values-it-rIT/strings_pref_experimental.xml | 2 -- app/src/main/res/values-ko-rKR/strings_pref_experimental.xml | 2 -- app/src/main/res/values-nl-rNL/strings_pref_experimental.xml | 2 -- app/src/main/res/values-no-rNO/strings_pref_experimental.xml | 2 -- app/src/main/res/values-pl-rPL/strings_pref_experimental.xml | 2 -- app/src/main/res/values-pt-rBR/strings_pref_experimental.xml | 2 -- app/src/main/res/values-pt-rPT/strings_pref_experimental.xml | 2 -- app/src/main/res/values-ro-rRO/strings_pref_experimental.xml | 2 -- app/src/main/res/values-ru-rRU/strings_pref_experimental.xml | 2 -- app/src/main/res/values-sr-rSP/strings_pref_experimental.xml | 3 --- app/src/main/res/values-sv-rSE/strings_pref_experimental.xml | 2 -- app/src/main/res/values-th-rTH/strings_pref_experimental.xml | 2 -- app/src/main/res/values-tl-rPH/strings_pref_experimental.xml | 2 -- app/src/main/res/values-tr-rTR/strings_pref_experimental.xml | 2 -- app/src/main/res/values-uk-rUA/strings_pref_experimental.xml | 2 -- app/src/main/res/values-vi-rVN/strings_pref_experimental.xml | 2 -- app/src/main/res/values-zh-rCN/strings_pref_experimental.xml | 2 -- app/src/main/res/values-zh-rTW/strings_pref_experimental.xml | 2 -- app/src/main/res/values/strings_pref_experimental.xml | 2 -- 31 files changed, 1 insertion(+), 70 deletions(-) (limited to 'app') diff --git a/app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt b/app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt index d7c405dc..a73dc1a4 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt @@ -34,13 +34,6 @@ fun SettingsActivity.getExperimentalPrefs(): KPrefAdapterBuilder.() -> Unit = { descRes = R.string.experimental_disclaimer_info } - checkbox( - R.string.experimental_by_default, - Showcase::experimentalDefault, - { Showcase.experimentalDefault = it }) { - descRes = R.string.experimental_by_default_desc - } - // Experimental content starts here ------------------ checkbox(R.string.auth_requests, Prefs::authRequests, { Prefs.authRequests = it }) { diff --git a/app/src/main/kotlin/com/pitchedapps/frost/utils/Showcase.kt b/app/src/main/kotlin/com/pitchedapps/frost/utils/Showcase.kt index df48bfbc..f69af40b 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/utils/Showcase.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/utils/Showcase.kt @@ -30,8 +30,5 @@ object Showcase : KPref() { val intro: Boolean by kprefSingle("intro_pages") - //not a showcase but cannot be in the same file as Prefs - var experimentalDefault: Boolean by kpref("experimental_by_default", false) - - override fun deleteKeys() = arrayOf("shown_release") + override fun deleteKeys() = arrayOf("shown_release", "experimental_by_default") } diff --git a/app/src/main/res/values-ar-rSA/strings_pref_experimental.xml b/app/src/main/res/values-ar-rSA/strings_pref_experimental.xml index bb8c5f7c..7d3343c4 100644 --- a/app/src/main/res/values-ar-rSA/strings_pref_experimental.xml +++ b/app/src/main/res/values-ar-rSA/strings_pref_experimental.xml @@ -2,8 +2,6 @@ الميزات التجريبية قد تكون غير مستقرة، وقد لا تصل إلى الإنتاج. استخدمها على مسؤوليتك الخاصة وإرسل ردود الفعل، ولا تتردد في تعطيلها إذا كانت لا تعمل بشكل جيد. - التجريبي بشكل افتراضي - هل تشعر بالخطر أو تريد فقط المساعدة في تصحيح الأخطاء؟ سيؤدي التحقق من ذلك إلى تمكين الوظائف التجريبية المستقبلية بشكل افتراضي. التسجيل المطول تمكين خاصية التسجيل المطول للمساعدة في تقارير الأعطال. سترسل التسجيلات فقط عند حدوث أخطاء، لهذا كرر الخطأ لإخطار المطور. سيتم تلقائياً تعطيلها إذا تمت إعادة تشغيل التطبيق. إعادة تشغيل Frost diff --git a/app/src/main/res/values-cs-rCZ/strings_pref_experimental.xml b/app/src/main/res/values-cs-rCZ/strings_pref_experimental.xml index 350e3676..f0c85860 100644 --- a/app/src/main/res/values-cs-rCZ/strings_pref_experimental.xml +++ b/app/src/main/res/values-cs-rCZ/strings_pref_experimental.xml @@ -2,8 +2,6 @@ Experimentální nastavení mohou způsobovat problémy a být bez varování odstraněna. Povolte je jen na vlastní nebezpečí a dejte vědět vývojářům jak fungují. - Povolit experimentální nastavení ve výchozím režimu - Chcete pomoct vývojářům s laděním? Povolit všechna, i budoucí experimentální nastavení. Rozšířené logování Povolit detailní protokolování v hlášeních o pádu aplikace. Pošle vývojářům hlášení chyby při jejím výskytu. Toto nastavení se automaticky vypne při restartu aplikace. Restartovat Frost diff --git a/app/src/main/res/values-da-rDK/strings_pref_experimental.xml b/app/src/main/res/values-da-rDK/strings_pref_experimental.xml index 406d0d56..e68d3c91 100644 --- a/app/src/main/res/values-da-rDK/strings_pref_experimental.xml +++ b/app/src/main/res/values-da-rDK/strings_pref_experimental.xml @@ -2,8 +2,6 @@ Eksperimentelle funktioner kan være ustabile og bliver muligvis aldrig sat i produktion. Brug foregår på eget ansvar, send feedback og deaktivér dem endelig, hvis de ikke fungerer godt. - Eksperimentel som standard - Føler du dig dristig eller vil du bare gerne hjælpe med fejlfinding? Aktivér denne for automatisk at bruge alle fremtidige eksperimentelle funktioner som standard. Detaljeret logføring Aktivér detaljeret logføring for at hjælpe med nedbrudsrapporter. Log-filer vil kun blive sent ved fejl, så gentag den fejlen for at underrette udvikleren. Dette bliver automatisk deaktiveret, når app\'en genstartes. Genstart Frost diff --git a/app/src/main/res/values-de-rDE/strings_pref_experimental.xml b/app/src/main/res/values-de-rDE/strings_pref_experimental.xml index a432f793..c7917efd 100644 --- a/app/src/main/res/values-de-rDE/strings_pref_experimental.xml +++ b/app/src/main/res/values-de-rDE/strings_pref_experimental.xml @@ -2,8 +2,6 @@ Experimentelle Funktionen sind möglicherweise instabil und schaffen es eventuell nie in die App. Auf eigenes Risiko verwenden! Senden Sie Ihr Feedback und zögern Sie nicht, diese zu deaktivieren, wenn sie nicht gut funktionieren. - Standartmäßig Experimentell - Sie fühlen sich mutig oder wollen einfach helfen bei der Fehlersuche? Beim Aktivieren dieser Option werden zukünftige, experimentelle Funktionen standardmäßig eingeschaltet. Ausführliche Protokollierung Aktivieren Sie die ausführliche Protokollierung um bei Crash-Berichten zu helfen. Die Protokollierung wird erst dann gesendet, wenn ein Fehler auftritt. Wiederhole das Problem um den Entwickler zu Informieren. Dies wird automatisch deaktiviert, wenn die App neustartet. Starte Frost neu diff --git a/app/src/main/res/values-es-rES/strings_pref_experimental.xml b/app/src/main/res/values-es-rES/strings_pref_experimental.xml index a653b081..20670052 100644 --- a/app/src/main/res/values-es-rES/strings_pref_experimental.xml +++ b/app/src/main/res/values-es-rES/strings_pref_experimental.xml @@ -2,8 +2,6 @@ Las características experimentales pueden ser inestables y nunca entrar en vigencia. Úsalas bajo tu propio riesgo. Envía un informe y no dudes en desactivarlas si no funcionan correctamente. - Experimental por Defecto - ¿Notas algún error o deseas ayudar a depurar? Las futuras funciones experimentales se habilitarán por defecto. Registro detallado Habilita los registros detallados para ayudar con los informes de errores. El registro sólo será enviado una vez se detecte el error, debes repetir el fallo para notificar al desarrollador. Esta función quedará desactivada una vez se reinicie la app. Reiniciar Frost diff --git a/app/src/main/res/values-fr-rFR/strings_pref_experimental.xml b/app/src/main/res/values-fr-rFR/strings_pref_experimental.xml index ae9b4388..e5d8ad6a 100644 --- a/app/src/main/res/values-fr-rFR/strings_pref_experimental.xml +++ b/app/src/main/res/values-fr-rFR/strings_pref_experimental.xml @@ -2,8 +2,6 @@ Les fonctionnalités expérimentales peuvent être instables et peuvent ne jamais se rendre à la production. Utiliser à vos risques et périls, envoyer vos commentaires et n’hésitez pas à les désactiver si elles ne fonctionnent pas bien. - Expérimentale par défaut - Vous vous sentez risqué ou vous souhaitez simplement aider avec le débogage? Cocher ceci permettra aux futures fonctions expérimentales d\'être activées par défaut. Logs détaillés Activer les logs détaillés pour aider avec les rapports d\'incidents. Les logs seront seulement envoyés lorsqu\'un erreur est rencontré, alors répétez le problème pour aviser le développeur. Ceci sera automatiquement désactivé si l\'application redémarre. Redémarrer Frost diff --git a/app/src/main/res/values-gl-rES/strings_pref_experimental.xml b/app/src/main/res/values-gl-rES/strings_pref_experimental.xml index 7d6766ab..fff98327 100644 --- a/app/src/main/res/values-gl-rES/strings_pref_experimental.xml +++ b/app/src/main/res/values-gl-rES/strings_pref_experimental.xml @@ -2,8 +2,6 @@ As funcionalidades en proba ou experimentais poden resultar inestables e mesmo poden non funcionar. Utilízaas baixo a túa responsabilidade, envíanos comentarios acerca delas e sempre poderás deshabilitalas se non funcionan ben. - Experimentar predefinido - Gústache o risco ou simplemente é que queres axudar coa depuración? Ao marcares esta opción, as funcionalidades experimentais activaranse por defecto. Rexistros detallados Activa os rexistros detallados o cal resultará de axuda cos informes de erros. Os informes enviaranse de cada vez que se atope un erro, de modo que ao se repetir o problema notificarase ao desenvolvedor. Esta función quedará deshabilitada unha vez que se reinicie a aplicación. Reiniciar Frost diff --git a/app/src/main/res/values-gr-rGR/strings_pref_experimental.xml b/app/src/main/res/values-gr-rGR/strings_pref_experimental.xml index 16471c0a..ed7e8e7d 100644 --- a/app/src/main/res/values-gr-rGR/strings_pref_experimental.xml +++ b/app/src/main/res/values-gr-rGR/strings_pref_experimental.xml @@ -1,8 +1,6 @@ Πειραματικά χαρακτηριστικά μπορεί να είναι ασταθή και να μην ολοκληρωθούν ποτέ. Χρησιμοποιήστε τα με δικό σας ρίσκο, αποστείλτε δεδομένα ανάδρασης , και μην διστάσετε να τα απενεργοποιήσετε αν δεν λειτουργούν σωστά. - Προκαθορισμένα Πειραματικό - Νιώθετε ρισκαδόροι ή απλά θέλετε να βοηθήσετε με τη διόρθωση σφαλμάτων; Ελέγχοντας το αυτό θα οδηγήσει μελλοντικές πειραματικές λειτουργίες να είναι προκαθορισμένες. Σύνθετη Καταγραφή Ενεργοποίησε την Σύνθετη Καταγραφή για να βοηθήσεις σε αναφορές σφαλμάτων. Η Καταγραφή θα αποσταλλεί μόνο όταν προκύψει ένα σφάλμα, οπότε ενεργοποιήστε την για να ενημερώνετε τον προγραμματιστή. Αυτόματα θα απενεργοποιηθεί όταν η εφαρμογή επανεκκινηθεί. diff --git a/app/src/main/res/values-hu-rHU/strings_pref_experimental.xml b/app/src/main/res/values-hu-rHU/strings_pref_experimental.xml index b64f0de6..67ab3b65 100644 --- a/app/src/main/res/values-hu-rHU/strings_pref_experimental.xml +++ b/app/src/main/res/values-hu-rHU/strings_pref_experimental.xml @@ -2,8 +2,6 @@ A kísérleti funkciók instabilak lehetnek, és talán sosem kerülnek forgalomba. Használd saját felelősségre, küldj visszajelzést, és nyugodtan tiltsd le őket, ha nem működnek jól. - Kísérletek alapértelmezetten - Szereted a kockázatot, vagy csak segítenél a hibák elhárításában? Ezt bekapcsolva a jövőbeli kísérleti funkciók is engedélyezve lesznek. Verbose Logging Részletes naplózás engedélyezése a hibajelentések segítésére. A napló csak akkor lesz elküldve, ha hiba lép fel, ezért ismételd meg a problémát, hogy értesítsd a fejlesztőt. Ez automatikusan le lesz tiltva, ha az alkalmazás újraindul. Frost újraindítása diff --git a/app/src/main/res/values-in-rID/strings_pref_experimental.xml b/app/src/main/res/values-in-rID/strings_pref_experimental.xml index 4071d963..b866936f 100644 --- a/app/src/main/res/values-in-rID/strings_pref_experimental.xml +++ b/app/src/main/res/values-in-rID/strings_pref_experimental.xml @@ -2,8 +2,6 @@ Fitur eksperimental mungkin tidak stabil dan mungkin tidak pernah sampai ke produksi. Gunakan dengan resiko Anda sendiri, kirim umpan balik, dan jangan ragu untuk menonaktifkan jika tidak bekerja dengan baik. - Eksperimental secara standar - Merasa berisiko atau hanya ingin membantu kesalahan? Memeriksa ini akan mengaktifkan fungsi eksperimental masa depan menjadi standar. Mencatat banyak kata Aktifkan mencatat banyak kata untuk membantu laporan kerusakan. Pencatatan hanya akan dikirim setelah terjadi kesalahan, jadi ulangi masalahnya untuk memberitahukan dev. Ini akan secara otomatis dinonaktifkan jika mengulang kembali aplikasi. Mengulang kembali Frost diff --git a/app/src/main/res/values-it-rIT/strings_pref_experimental.xml b/app/src/main/res/values-it-rIT/strings_pref_experimental.xml index 9492ca2b..355c95c2 100644 --- a/app/src/main/res/values-it-rIT/strings_pref_experimental.xml +++ b/app/src/main/res/values-it-rIT/strings_pref_experimental.xml @@ -2,8 +2,6 @@ Le funzioni sperimentali potrebbero essere instabili e potrebbero non arrivare mai al rilascio. Usale a tuo rischio e pericolo, manda il tuo feedback e sentiti libero di disabilitarle se non funzionano bene. - Funzioni Sperimentali di Default - Ti senti temerario o vuoi solo aiutarci con il debugging? Attivandolo abiliterai le funzioni sperimentali di default. Log Dettagliati Abilita log dettagliati per aiutare con il rapporto dei crash. Il log verrà mandato solamente quando verrà riscontrato un errore, quindi ricrea la situazione per notificare gli sviluppatori. Verrà automaticamente disattivato se si riavvia l\'applicazione. Riavvia Frost diff --git a/app/src/main/res/values-ko-rKR/strings_pref_experimental.xml b/app/src/main/res/values-ko-rKR/strings_pref_experimental.xml index 22c31278..55848289 100644 --- a/app/src/main/res/values-ko-rKR/strings_pref_experimental.xml +++ b/app/src/main/res/values-ko-rKR/strings_pref_experimental.xml @@ -2,8 +2,6 @@ 실험적 기능은 불안정하거나 출시로 이어지지 않을 수 있습니다. 이를 사용함으로써 발생하는 일의 책임은 당신에게 있으며, 피드백을 보내시거나 제대로 작동하지 않으면 비활성화 하시기 바랍니다. - 실험적 기능 항상 사용 - 위험을 감수하거나 디버그에 도움을 주고 싶나요? 이를 활성화하면 앞으로도 기본적으로 실험적 기능이 활성화 됩니다. 자세한 로그 충돌 보고서에 도움을 주기 위해 자세한 로그를 켭니다. 로그는 에러가 발생했을 때 한번만 보내지며, 문제를 개발자에게 알리려면 문제를 재현하세요. 앱이 재시작되면 이 옵션은 자동으로 꺼집니다. Frost 재시작 diff --git a/app/src/main/res/values-nl-rNL/strings_pref_experimental.xml b/app/src/main/res/values-nl-rNL/strings_pref_experimental.xml index 53b71632..1cf43a43 100644 --- a/app/src/main/res/values-nl-rNL/strings_pref_experimental.xml +++ b/app/src/main/res/values-nl-rNL/strings_pref_experimental.xml @@ -2,8 +2,6 @@ Experimentele functies kunnen instabiliteit veroorzaken en zullen mogelijk nooit volledig worden geïmplementeerd. Gebruik de functies op eigen verantwoordelijkheid, stuur feedback en wees vrij om ze uit te schakelen bij problemen. - Experimentele functies standaard inschakelen - Wees een waaghals en activeer nieuwe experimentele functies automatisch. Uitgebreide logging Schakel uitgebreide logging in om te helpen met crashrapporten. Logs worden alleen doorgestuurd bij fouten, dus herhaal de stappen die het probleem veroorzaken om de ontwikkelaar op de hoogte te brengen. Deze optie wordt automatisch uitgeschakeld bij een herstart van de app. Frost herstarten diff --git a/app/src/main/res/values-no-rNO/strings_pref_experimental.xml b/app/src/main/res/values-no-rNO/strings_pref_experimental.xml index e1758cd0..0893a03b 100644 --- a/app/src/main/res/values-no-rNO/strings_pref_experimental.xml +++ b/app/src/main/res/values-no-rNO/strings_pref_experimental.xml @@ -2,8 +2,6 @@ Eksperimentelle funksjonene kan være ustabile. Bruk på eget ansvar og du må gjerne deaktivere dem om de ikke fungerer. - Eksperimentell som standard - Føles det risikabelt eller bare ønsker å hjelpe til med feilsøking? Å velge dette vil aktivere fremtidige eksperimentelle funksjonene som standard. Detaljert logging Aktiver detaljert logging for å hjelpe med feilrapporter. Logging sendes bare når en feil oppstår, så fremtving feil for å varsle utvikler. Dette vil automatisk bli deaktivert hvis programmet startes på nytt. Start Frost på nytt diff --git a/app/src/main/res/values-pl-rPL/strings_pref_experimental.xml b/app/src/main/res/values-pl-rPL/strings_pref_experimental.xml index 6f097c15..96c76265 100644 --- a/app/src/main/res/values-pl-rPL/strings_pref_experimental.xml +++ b/app/src/main/res/values-pl-rPL/strings_pref_experimental.xml @@ -2,8 +2,6 @@ Funkcje eksperymentalne mogą być niestabilne i mogą nigdy nie być wprowadzone. Używaj na własne ryzyko, wyślij opinię i wyłącz je jeśli nie działają dobrze. - Eksperymentalne domyślnie - Lubisz ryzyko lub po prostu chcesz pomóc z debugowaniem? Zaznaczenie tej opcji, będzie domyślnie włączać eksperymentalne funkcje. Pełne zbieranie logów Włącz pełne zbieranie logów żeby pomóc z raportami o awariach. Logi będą wysłane tylko kiedy błąd wystąpi, więc odtwórz problem, aby powiadomić dewelopera. Ta opcja zostanie automatycznie wyłączona po restarcie aplikacji. Uruchom ponownie Frost diff --git a/app/src/main/res/values-pt-rBR/strings_pref_experimental.xml b/app/src/main/res/values-pt-rBR/strings_pref_experimental.xml index eaec0fe8..15154a40 100644 --- a/app/src/main/res/values-pt-rBR/strings_pref_experimental.xml +++ b/app/src/main/res/values-pt-rBR/strings_pref_experimental.xml @@ -2,8 +2,6 @@ As funções experimentais podem ser instáveis ​​e podem não funcionar. Use a seu próprio risco, envie comentários e sinta-se livre para desativá-los se eles não funcionarem bem. - Experimental por Padrão - Deseja arriscar-se ou simplesmente quer ajudar com a depuração? Ativando isso, as futuras funções experimentais serão ativadas como padrão. Relatório Detalhado Habilite o relatório detalhado para ajudar com relatórios de falhas. O relatório só será enviado quando um erro for encontrado, então repita o problema para notificar o desenvolvedor. Isso será automaticamente desabilitado se o aplicativo for reiniciado. Reiniciar o Frost diff --git a/app/src/main/res/values-pt-rPT/strings_pref_experimental.xml b/app/src/main/res/values-pt-rPT/strings_pref_experimental.xml index 344c0a83..7bd2a644 100644 --- a/app/src/main/res/values-pt-rPT/strings_pref_experimental.xml +++ b/app/src/main/res/values-pt-rPT/strings_pref_experimental.xml @@ -2,8 +2,6 @@ As funcionalidades experimentais podem ser instáveis e podem nem sequer ser incluídas na versão final. Utilize-as por sua conta e risco e submeta os relatório com os erros encontrados. Pode desativar esta opção sempre que quiser. - Experimental por defeito - Está a sentir-se com sorte ou apenas quer ajudar com a depuração? Tenha noção que com esta função permitirá que funções futuras experimentais sejam padrão. Registo detalhado Ativar o registo detalhado para nos ajudar com os erros. Os registos apenas serão enviados se for encontrado um erro. Esta opção será desativada automaticamente se reiniciar a aplicação. Reiniciar diff --git a/app/src/main/res/values-ro-rRO/strings_pref_experimental.xml b/app/src/main/res/values-ro-rRO/strings_pref_experimental.xml index 67d7be5e..bf4f9c65 100644 --- a/app/src/main/res/values-ro-rRO/strings_pref_experimental.xml +++ b/app/src/main/res/values-ro-rRO/strings_pref_experimental.xml @@ -2,8 +2,6 @@ Caracteristici experimentale pot fi instabile. Folosește-le pe propriul tău risc, trimite feedback-ul şi nu ezita să le dezactivaţi dacă nu funcţionează bine. - Experimental implicit - Esti aventuros sau doar vrei sa ajuți? Încearcând asta vei activa viitoare funcții experimentale în mod prestabilit. Logări abuzive Activează logări repetate să ajuți cu report-uri ale erorilor. Logarile vor fi trimise când o eroare este prezentă, așadar repetă problema să anunți dezvoltatorii. Acesta va fi dezactivat când repornești. Reporniţi Frost diff --git a/app/src/main/res/values-ru-rRU/strings_pref_experimental.xml b/app/src/main/res/values-ru-rRU/strings_pref_experimental.xml index 100f224e..b36797de 100644 --- a/app/src/main/res/values-ru-rRU/strings_pref_experimental.xml +++ b/app/src/main/res/values-ru-rRU/strings_pref_experimental.xml @@ -2,8 +2,6 @@ Экспериментальные функции может быть нестабильным и никогда не может сделать его в производство. Используйте на свой страх и риск, обратная связь и не стесняйтесь отключить их, если они не работают хорошо. - Экспериментальный по умолчанию - Чувствуя рискованным или просто хотите, чтобы помочь с отладкой? Проверка, что это позволит будущим экспериментальные функции быть по умолчанию. Подробная информация Включите ведение подробного журнала, чтобы помочь с падениях. Протоколирование будет отправлено только после того, как возникает ошибка, так повторить вопрос уведомления dev. Это будет автоматически отключается, если приложение перезапускается. Перезапустить Frost diff --git a/app/src/main/res/values-sr-rSP/strings_pref_experimental.xml b/app/src/main/res/values-sr-rSP/strings_pref_experimental.xml index 107d9e73..5f48741b 100644 --- a/app/src/main/res/values-sr-rSP/strings_pref_experimental.xml +++ b/app/src/main/res/values-sr-rSP/strings_pref_experimental.xml @@ -2,9 +2,6 @@ Експерименталне функције су нестабилне и можда никада неће бити уврштене у апликацију. Користите на сопствени ризик, пошаљите рецензију, слободно их искључите уколико не функционишу како треба. - Подразумевано коришћење експерименталних функција - Желите да помогнете у отклањању грешака? -Штиклирањем ове опције подесићете експерименталне функције као подразумеване. Потпуна евиденција Укључите потпуну евиденцију и помозите нам у отклањању грешака. Евиденција ће бити послата само уколико дође до грешке, зато поновите грешку да би помогли програмерима. Оција ће бити искључена уколико се апликација рестартује. Рестартујте Фрост diff --git a/app/src/main/res/values-sv-rSE/strings_pref_experimental.xml b/app/src/main/res/values-sv-rSE/strings_pref_experimental.xml index 6ff34233..1848bf2e 100644 --- a/app/src/main/res/values-sv-rSE/strings_pref_experimental.xml +++ b/app/src/main/res/values-sv-rSE/strings_pref_experimental.xml @@ -2,8 +2,6 @@ Experimentella funktioner kan vara ostabila och kanske aldrig implementeras i slutprodukten. Använd dessa på egen risk, skicka feedback, och stäng gärna av dem om de inte fungerar bra. - Experimentell som standard - Känner du dig riskfylld eller bara vill hjälpa till? Att markera den här kommer att aktivera alla framtida experimentella funktioner som standard. Detaljerad loggning Aktivera utförlig loggning för att hjälpa till med felrapporter. Loggar skickas endast när ett fel påträffas, så upprepa problemet i appen för att skicka informationen till utvecklaren. Detta inaktiveras automatiskt om appen startas om. Starta om Frost diff --git a/app/src/main/res/values-th-rTH/strings_pref_experimental.xml b/app/src/main/res/values-th-rTH/strings_pref_experimental.xml index eddac20d..d64996f4 100644 --- a/app/src/main/res/values-th-rTH/strings_pref_experimental.xml +++ b/app/src/main/res/values-th-rTH/strings_pref_experimental.xml @@ -2,8 +2,6 @@ คุณสัมบัติทดลองอาจไม่เสถียนและอาจจะไม่ได้อยู่ถาวร ยอมรับความเสี่ยงเองถ้าคุณใช้มัน, ส่งข้อเสนอแนะ หรือ ปิดมันไปเลยก็ได้ถ้ามันไม่ทำงาน - คุณสัมบัติทดลอง โดยค่าเริ่มต้น - ชอบความเสี่ยงหรือแค่อยากจะช่วยหาของข้อผิดพลาด? สามารถทำได้โดยการเปิด คุณสัมบัติทดลอง เป็นค่าเริ่มต้น การบันทึกทั่วไป เปิดบันทิกทั่วไปและรายงานข้อผิดพลาด บันทึกจะส่งเมื่อเจอข้อผิดพลาด ดังนั้นกรุณาทำให้เกิดข้อผิดพลาดอีกครั้งนึง ตัวเลือกนี้จะปิดเองเมื่อแอพเริ่มต้นใหม่ เริ่ม Frost ใหม่ diff --git a/app/src/main/res/values-tl-rPH/strings_pref_experimental.xml b/app/src/main/res/values-tl-rPH/strings_pref_experimental.xml index 6debc50f..0ed09ad2 100644 --- a/app/src/main/res/values-tl-rPH/strings_pref_experimental.xml +++ b/app/src/main/res/values-tl-rPH/strings_pref_experimental.xml @@ -2,8 +2,6 @@ Ang tampok na pageekspiremento ay hindi siguradong matatag at hindi kailanman ito gagawin sa produksyon. Gamitin sa iyong sariling kapahamakan, ipadala ang feedback, at malaya kang i-disable sila kapag hindi ito nagawa ng maayos. - Ang pageekspiremento ayon sa Default - Ang pakiramdam na parang nasa pilegro o gusto lang tumulong sa pagdi-debug? Tignan kung ito ay naka-enable sa hinaharap na pageekspiremento at ang mga paggawa ay default. Ang pagsasalita ay logging I-enable ang logging na pagsasalita para matulongan ang mga ulat pagbangga. Ang logging ay pinapadala lamang kapag may mali na naranasan, kaya ulitin ang isyu para masabihan ang taga-gawa. Ito ay awtomatikong idi-disable kapag ang aplikasyon ay nirestart. I-restart ang Frost diff --git a/app/src/main/res/values-tr-rTR/strings_pref_experimental.xml b/app/src/main/res/values-tr-rTR/strings_pref_experimental.xml index f230382b..fd0f9c65 100644 --- a/app/src/main/res/values-tr-rTR/strings_pref_experimental.xml +++ b/app/src/main/res/values-tr-rTR/strings_pref_experimental.xml @@ -2,8 +2,6 @@ Deneysel özellikler dengesiz olabilir ve asla üretime neden olmayabilir. Kendi sorumluluğunuzdadır kullanın, geri bildirim gönderin ve iyi çalışmazlarsa onları devre dışı bırakmaktan çekinmeyin. - Varsayılan deneysel - Hata ayıklamayla yardım etmek mi istiyorsunuz? Bunu kontrol ederseniz, gelecek deneysel işlevlerin varsayılan olmasını sağlayabilirsiniz. Ayrıntılı günlüğe kaydetme Kilitlenme raporlarıyla yardımcı olmak için ayrıntılı günlüğü etkinleştirin. Günlüğe kaydetme yalnızca bir hata ile karşılaştığında gönderilir, bu nedenle devi bilgilendirmek için sorunu tekrarlayın. Uygulama yeniden başlatılırsa, bu otomatik olarak devre dışı bırakılacaktır. Frostu yeniden başlatın diff --git a/app/src/main/res/values-uk-rUA/strings_pref_experimental.xml b/app/src/main/res/values-uk-rUA/strings_pref_experimental.xml index 38662371..baa02f33 100644 --- a/app/src/main/res/values-uk-rUA/strings_pref_experimental.xml +++ b/app/src/main/res/values-uk-rUA/strings_pref_experimental.xml @@ -2,8 +2,6 @@ Експериментальні функції можуть бути нестабільними і можуть ніколи не бути впроваджені. Використовуйте на свій страх і ризик, надішліть відгук і можете вимкнути їх, якщо вони не працюють добре. - Експериментальний режим за замовчуванням - Почуваєшся ризиковано або просто хочеш допомогти з налагодженням? Перевірка цього параметра дозволить використовувати майбутні експериментальні функції за умовчанням. Докладне ведення журналу Увімкнути докладне ведення журналу, щоб допомогти з повідомленнями про аварійне завершення роботи. Журнал буде відправлений тільки після виявлення помилки, тому повторіть цю проблему, щоб повідомити про це розробника. Це буде автоматично вимкнено, якщо додаток перезавантажиться. Перезавантажити Frost diff --git a/app/src/main/res/values-vi-rVN/strings_pref_experimental.xml b/app/src/main/res/values-vi-rVN/strings_pref_experimental.xml index f8350b72..2c6c47d1 100644 --- a/app/src/main/res/values-vi-rVN/strings_pref_experimental.xml +++ b/app/src/main/res/values-vi-rVN/strings_pref_experimental.xml @@ -2,8 +2,6 @@ Các tính năng thử nghiệm có thể không ổn định và có thể không bao giờ thành hiện thực. Bạn chấp nhận rủi ro khi dùng, hãy tắt nó đi nếu bạn thấy không hoạt động tốt. - Thử nghiệm theo mặc định - Muốn thử hay chỉ đơn giản muốn giúp soát lỗi? Đánh dấu ở đây sẽ bật các tính năng thử nghiệm tương lai theo mặc định. Nhật ký chi tiết Bật nhật ký chi tiết để giúp báo cáo lỗi. Các ghi chép sẽ chỉ được gửi khi phát sinh lỗi, nên hãy lặc lại lỗi để báo cho tác giả. Tính năng này sẽ tự động tắt khi khởi động lại ứng dụng. Khởi động lại Frost diff --git a/app/src/main/res/values-zh-rCN/strings_pref_experimental.xml b/app/src/main/res/values-zh-rCN/strings_pref_experimental.xml index 6d180ec0..6df4c27e 100644 --- a/app/src/main/res/values-zh-rCN/strings_pref_experimental.xml +++ b/app/src/main/res/values-zh-rCN/strings_pref_experimental.xml @@ -2,8 +2,6 @@ 实验性的功能可能不稳定,也许都不会正式使用。选择使用您自己的风险。如果有发生崩溃, 发送反馈,并禁用它们。 - 默认情况下实验 - 感觉有风险或只是想要帮助进行调试?检查这将使未来的实验功能是默认类型。 Verbose Logging 启用详细日志记录以帮助崩溃报告。所以一旦遇到错误时,才会发送日志记录重复问题通知行业的发展现状如果应用程序重新启动,这将自动禁用。 重启Frost diff --git a/app/src/main/res/values-zh-rTW/strings_pref_experimental.xml b/app/src/main/res/values-zh-rTW/strings_pref_experimental.xml index 25291512..42289ce6 100644 --- a/app/src/main/res/values-zh-rTW/strings_pref_experimental.xml +++ b/app/src/main/res/values-zh-rTW/strings_pref_experimental.xml @@ -4,8 +4,6 @@ 實驗性的特性可能不穩定, 可能永遠無法生產。選擇使用您自己的風險, 發回饋, 並隨時禁用他們 实验性的功能可能不稳定,也许都不会正式使用。选择使用您自己的风险。如果有发生崩溃, 发送反馈,并禁用它们。 - 預設實驗 - 感覺有風險還是只是幫助想説明調試?檢查這將使未來的實驗功能是預設的。 Verbose 記錄 啟用Verbose記錄以幫助崩潰報告。只有在遇到錯誤後才會發送日誌記錄, 因此重複此問題以通知我們。如果應用程式重新啟動, 會自動禁用此功能。 重啟 Frost diff --git a/app/src/main/res/values/strings_pref_experimental.xml b/app/src/main/res/values/strings_pref_experimental.xml index 797878bf..2d2ca131 100644 --- a/app/src/main/res/values/strings_pref_experimental.xml +++ b/app/src/main/res/values/strings_pref_experimental.xml @@ -1,8 +1,6 @@ Experimental features may be unstable and may never make it to production. Use at your own risk, send feedback, and feel free to disable them if they don\'t work well. - Experimental by Default - Feeling risky or just want to help with debugging? Checking this will enable future experimental functions be default. Verbose Logging Enable verbose logging to help with crash reports. Logging will only be sent once an error is encountered, so repeat the issue to notify the dev. This will automatically be disabled if the app restarts. -- cgit v1.2.3 From 4e09cf236f8aa33f3ceb67ce907e920ed1f81dc0 Mon Sep 17 00:00:00 2001 From: Allan Wang Date: Sun, 8 Sep 2019 00:19:57 -0700 Subject: Update changelog and apply spotless --- .../kotlin/com/pitchedapps/frost/settings/Experimental.kt | 1 - app/src/main/play/en-US/whatsnew | 11 ++--------- app/src/main/res/xml/frost_changelog.xml | 4 ++++ .../com/pitchedapps/frost/facebook/requests/FbRequestTest.kt | 1 + docs/Changelog.md | 3 +++ 5 files changed, 10 insertions(+), 10 deletions(-) (limited to 'app') diff --git a/app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt b/app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt index a73dc1a4..5647584e 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/settings/Experimental.kt @@ -23,7 +23,6 @@ import com.pitchedapps.frost.R import com.pitchedapps.frost.activities.SettingsActivity import com.pitchedapps.frost.utils.Prefs import com.pitchedapps.frost.utils.REQUEST_RESTART_APPLICATION -import com.pitchedapps.frost.utils.Showcase /** * Created by Allan Wang on 2017-06-29. diff --git a/app/src/main/play/en-US/whatsnew b/app/src/main/play/en-US/whatsnew index dfb4e201..4db2b010 100644 --- a/app/src/main/play/en-US/whatsnew +++ b/app/src/main/play/en-US/whatsnew @@ -1,10 +1,3 @@ -v2.3.2 +v2.4.0 -* Disable auto feed refresh by default and add setting to re-enable it -* Update theme -* Disable bugsnag completely when opting out of analytics -* Filter urls before sending to other apps -* Allow hiding main fab (see settings > newsfeed) -* Add some experimental options to debug login problems (settings > experimental) -* Enforce desktop user agent for now -* Obfuscate js tags \ No newline at end of file +* Removed web only mode for auth requests. Marking notifications as read is now disabled by default to deal with phishing accusations. \ No newline at end of file diff --git a/app/src/main/res/xml/frost_changelog.xml b/app/src/main/res/xml/frost_changelog.xml index 6142f595..42739ab1 100644 --- a/app/src/main/res/xml/frost_changelog.xml +++ b/app/src/main/res/xml/frost_changelog.xml @@ -6,6 +6,10 @@ --> + + + + diff --git a/app/src/test/kotlin/com/pitchedapps/frost/facebook/requests/FbRequestTest.kt b/app/src/test/kotlin/com/pitchedapps/frost/facebook/requests/FbRequestTest.kt index 8610436a..67f62a40 100644 --- a/app/src/test/kotlin/com/pitchedapps/frost/facebook/requests/FbRequestTest.kt +++ b/app/src/test/kotlin/com/pitchedapps/frost/facebook/requests/FbRequestTest.kt @@ -65,6 +65,7 @@ class FbRequestTest { } @Test + @Ignore("Post requests are now experimental") fun markNotification() { val notifId = 1514443903880 AUTH.markNotificationRead(notifId).call.assertNoError() diff --git a/docs/Changelog.md b/docs/Changelog.md index 31315d04..224607e4 100644 --- a/docs/Changelog.md +++ b/docs/Changelog.md @@ -1,5 +1,8 @@ # Changelog +## v2.4.0 +* Removed web only mode for auth requests. Marking notifications as read is now disabled by default to deal with phishing accusations. + ## v2.3.2 * Disable auto feed refresh by default and add setting to re-enable it * Update theme -- cgit v1.2.3