diff options
author | Allan Wang <me@allanwang.ca> | 2018-12-28 23:11:31 -0500 |
---|---|---|
committer | Allan Wang <me@allanwang.ca> | 2018-12-28 23:11:31 -0500 |
commit | 30b359c944dabf7203630c3d3eae7a7dcea05204 (patch) | |
tree | fa0dd322b1392578bb0259e1a23ba01950efd259 /app | |
parent | 0d6f53c82c4c55afdc61ea20773e7421b368e46f (diff) | |
download | frost-30b359c944dabf7203630c3d3eae7a7dcea05204.tar.gz frost-30b359c944dabf7203630c3d3eae7a7dcea05204.tar.bz2 frost-30b359c944dabf7203630c3d3eae7a7dcea05204.zip |
Apply spotless
Diffstat (limited to 'app')
8 files changed, 71 insertions, 10 deletions
diff --git a/app/src/main/kotlin/com/pitchedapps/frost/activities/MainActivity.kt b/app/src/main/kotlin/com/pitchedapps/frost/activities/MainActivity.kt index e5eb1907..90f38e9e 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/activities/MainActivity.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/activities/MainActivity.kt @@ -22,7 +22,6 @@ import com.google.android.material.tabs.TabLayout import com.pitchedapps.frost.facebook.FbItem import com.pitchedapps.frost.utils.L import com.pitchedapps.frost.views.BadgedIcon -import io.reactivex.subjects.PublishSubject import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.ExperimentalCoroutinesApi import kotlinx.coroutines.channels.BroadcastChannel diff --git a/app/src/main/kotlin/com/pitchedapps/frost/contracts/ActivityContract.kt b/app/src/main/kotlin/com/pitchedapps/frost/contracts/ActivityContract.kt index 483e49c5..17753ce6 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/contracts/ActivityContract.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/contracts/ActivityContract.kt @@ -29,7 +29,7 @@ interface ActivityContract : FileChooserActivityContract interface MainActivityContract : ActivityContract, MainFabContract { val fragmentChannel: BroadcastChannel<Int> - val headerBadgeChannel : Channel<String> + val headerBadgeChannel: Channel<String> fun setTitle(res: Int) fun setTitle(text: CharSequence) /** diff --git a/app/src/main/kotlin/com/pitchedapps/frost/rx/Flyweight.kt b/app/src/main/kotlin/com/pitchedapps/frost/rx/Flyweight.kt index a9aedb6d..8bba4c3c 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/rx/Flyweight.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/rx/Flyweight.kt @@ -1,3 +1,19 @@ +/* + * 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 <http://www.gnu.org/licenses/>. + */ package com.pitchedapps.frost.rx import kotlinx.coroutines.CancellationException @@ -135,4 +151,4 @@ class Flyweight<K, V>( conditionMap.clear() resultMap.clear() } -}
\ No newline at end of file +} diff --git a/app/src/main/kotlin/com/pitchedapps/frost/utils/Const.kt b/app/src/main/kotlin/com/pitchedapps/frost/utils/Const.kt index 3d69b0ae..c878b6fb 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/utils/Const.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/utils/Const.kt @@ -32,4 +32,4 @@ const val REQUEST_TEXT_ZOOM = 1 shl 8 const val REQUEST_NAV = 1 shl 9 const val REQUEST_SEARCH = 1 shl 10 -const val MAIN_TIMEOUT_DURATION = 30 * 60 * 1000 // 30 min
\ No newline at end of file +const val MAIN_TIMEOUT_DURATION = 30 * 60 * 1000 // 30 min diff --git a/app/src/main/kotlin/com/pitchedapps/frost/utils/KotlinUtils.kt b/app/src/main/kotlin/com/pitchedapps/frost/utils/KotlinUtils.kt index 320aeb69..f4357c9b 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/utils/KotlinUtils.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/utils/KotlinUtils.kt @@ -1,3 +1,19 @@ +/* + * 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 <http://www.gnu.org/licenses/>. + */ package com.pitchedapps.frost.utils import kotlinx.coroutines.CoroutineScope @@ -17,4 +33,4 @@ fun <T> ReceiveChannel<T>.uniqueOnly(scope: CoroutineScope): ReceiveChannel<T> = send(current) } } -}
\ No newline at end of file +} diff --git a/app/src/main/kotlin/com/pitchedapps/frost/utils/Utils.kt b/app/src/main/kotlin/com/pitchedapps/frost/utils/Utils.kt index 8e4e410d..d2e6ea96 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/utils/Utils.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/utils/Utils.kt @@ -117,8 +117,7 @@ private inline fun <reified T : WebOverlayActivityBase> Context.launchWebOverlay if (argUrl.isFacebookUrl && argUrl.contains("/logout.php")) { L.d { "Logout php found" } FbCookie.logout(this) - } - else if (!(Prefs.linksInDefaultApp && resolveActivityForUri(Uri.parse(argUrl)))) + } else if (!(Prefs.linksInDefaultApp && resolveActivityForUri(Uri.parse(argUrl)))) startActivity<T>(false, intentBuilder = { putExtra(ARG_URL, argUrl) }) diff --git a/app/src/test/kotlin/com/pitchedapps/frost/rx/FlyweightTest.kt b/app/src/test/kotlin/com/pitchedapps/frost/rx/FlyweightTest.kt index 834163bd..b58878cb 100644 --- a/app/src/test/kotlin/com/pitchedapps/frost/rx/FlyweightTest.kt +++ b/app/src/test/kotlin/com/pitchedapps/frost/rx/FlyweightTest.kt @@ -1,3 +1,19 @@ +/* + * 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 <http://www.gnu.org/licenses/>. + */ package com.pitchedapps.frost.rx import kotlinx.coroutines.GlobalScope @@ -105,4 +121,4 @@ class FlyweightTest { println("Done") } } -}
\ No newline at end of file +} diff --git a/app/src/test/kotlin/com/pitchedapps/frost/utils/CoroutineTest.kt b/app/src/test/kotlin/com/pitchedapps/frost/utils/CoroutineTest.kt index f930e529..72eb6076 100644 --- a/app/src/test/kotlin/com/pitchedapps/frost/utils/CoroutineTest.kt +++ b/app/src/test/kotlin/com/pitchedapps/frost/utils/CoroutineTest.kt @@ -1,3 +1,19 @@ +/* + * 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 <http://www.gnu.org/licenses/>. + */ package com.pitchedapps.frost.utils import kotlinx.coroutines.Dispatchers @@ -188,7 +204,6 @@ class CoroutineTest { uniqueData, "Unique receiver should not have two consecutive events that are equal" ) - } } -}
\ No newline at end of file +} |