From 41c14362a811a3fad6f3cd80ca45501341371876 Mon Sep 17 00:00:00 2001 From: aminecmi Date: Sat, 9 Jan 2021 15:01:59 +0100 Subject: [PATCH] Fixes #323. --- app/build.gradle | 40 +++++++++---------- .../bou/readerforselfoss/AddSourceActivity.kt | 2 +- .../bou/readerforselfoss/HomeActivity.kt | 21 ++++------ .../bou/readerforselfoss/LoginActivity.kt | 5 +-- .../apps/amine/bou/readerforselfoss/MyApp.kt | 2 +- .../bou/readerforselfoss/ReaderActivity.kt | 4 +- .../bou/readerforselfoss/SourcesActivity.kt | 2 +- .../adapters/ItemCardAdapter.kt | 14 +++++++ .../adapters/ItemListAdapter.kt | 11 +++++ .../api/mercury/MercuryModels.kt | 14 +++---- .../api/selfoss/SelfossModels.kt | 16 ++++---- .../readerforselfoss/background/background.kt | 2 +- .../fragments/ArticleFragment.kt | 8 ++-- .../fragments/ImageFragment.kt | 2 +- .../bou/readerforselfoss/themes/AppColors.kt | 7 ++++ .../bou/readerforselfoss/utils/Config.kt | 10 ++--- build.gradle | 2 +- 17 files changed, 93 insertions(+), 69 deletions(-) diff --git a/app/build.gradle b/app/build.gradle index a456f57..ba9916e 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -24,12 +24,12 @@ def versionNameFromGit() { return gitVersion() } -apply plugin: 'kotlin-kapt' - apply plugin: 'com.android.application' apply plugin: 'kotlin-android' +apply plugin: 'kotlin-kapt' + apply plugin: 'kotlin-android-extensions' android { @@ -37,12 +37,12 @@ android { sourceCompatibility JavaVersion.VERSION_1_8 targetCompatibility JavaVersion.VERSION_1_8 } - compileSdkVersion 28 - buildToolsVersion '28.0.3' + compileSdkVersion 30 + buildToolsVersion '30.0.3' defaultConfig { applicationId "apps.amine.bou.readerforselfoss" minSdkVersion 16 - targetSdkVersion 28 + targetSdkVersion 30 versionCode versionCodeFromGit() versionName versionNameFromGit() @@ -85,23 +85,23 @@ android { dependencies { // Testing - androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0-beta01' - androidTestImplementation 'androidx.test:runner:1.2.0-beta01' + androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0-alpha02' + androidTestImplementation 'androidx.test:runner:1.3.1-alpha02' // Espresso-contrib for DatePicker, RecyclerView, Drawer actions, Accessibility checks, CountingIdlingResource - androidTestImplementation 'androidx.test.espresso:espresso-contrib:3.2.0-beta01' + androidTestImplementation 'androidx.test.espresso:espresso-contrib:3.4.0-alpha02' // Espresso-intents for validation and stubbing of Intents - androidTestImplementation 'androidx.test.espresso:espresso-intents:3.2.0-beta01' + androidTestImplementation 'androidx.test.espresso:espresso-intents:3.4.0-alpha02' implementation fileTree(include: ['*.jar'], dir: 'libs') implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" // Android Support - implementation "androidx.appcompat:appcompat:$androidx_version" - implementation "com.google.android.material:material:1.1.0-alpha06" - implementation "androidx.recyclerview:recyclerview:1.1.0-alpha05" + implementation "androidx.appcompat:appcompat:1.3.0-alpha02" + implementation 'com.google.android.material:material:1.3.0-beta01' + implementation 'androidx.recyclerview:recyclerview:1.2.0-beta01' implementation "androidx.legacy:legacy-support-v4:$android_version" - implementation "androidx.vectordrawable:vectordrawable:1.1.0-beta01" - implementation "androidx.browser:browser:$android_version" + implementation 'androidx.vectordrawable:vectordrawable:1.2.0-alpha02' + implementation "androidx.browser:browser:1.3.0" implementation "androidx.cardview:cardview:$android_version" - implementation 'androidx.constraintlayout:constraintlayout:2.1.0-alpha1' + implementation 'androidx.constraintlayout:constraintlayout:2.1.0-alpha2' implementation 'org.jsoup:jsoup:1.13.1' //multidex @@ -141,13 +141,13 @@ dependencies { //PhotoView implementation 'com.github.chrisbanes:PhotoView:2.0.0' - implementation 'androidx.core:core-ktx:1.1.0-beta01' + implementation 'androidx.core:core-ktx:1.5.0-alpha05' - implementation "androidx.lifecycle:lifecycle-livedata:$lifecycle_version" - implementation "androidx.lifecycle:lifecycle-common-java8:$lifecycle_version" + implementation "androidx.lifecycle:lifecycle-livedata:2.3.0-rc01" + implementation "androidx.lifecycle:lifecycle-common-java8:2.3.0-rc01" - implementation "androidx.room:room-runtime:$room_version" - kapt "androidx.room:room-compiler:$room_version" + implementation "androidx.room:room-runtime:2.3.0-alpha04" + kapt "androidx.room:room-compiler:2.3.0-alpha04" implementation "android.arch.work:work-runtime-ktx:$work_version" } diff --git a/app/src/main/java/apps/amine/bou/readerforselfoss/AddSourceActivity.kt b/app/src/main/java/apps/amine/bou/readerforselfoss/AddSourceActivity.kt index e7586f3..2ccfcfb 100644 --- a/app/src/main/java/apps/amine/bou/readerforselfoss/AddSourceActivity.kt +++ b/app/src/main/java/apps/amine/bou/readerforselfoss/AddSourceActivity.kt @@ -92,7 +92,7 @@ class AddSourceActivity : AppCompatActivity() { this, this@AddSourceActivity, settings.getBoolean("isSelfSignedCert", false), - prefs.getString("api_timeout", "-1").toLong() + prefs.getString("api_timeout", "-1")!!.toLong() ) } catch (e: IllegalArgumentException) { mustLoginToAddSource() diff --git a/app/src/main/java/apps/amine/bou/readerforselfoss/HomeActivity.kt b/app/src/main/java/apps/amine/bou/readerforselfoss/HomeActivity.kt index 0e39688..94e90b8 100644 --- a/app/src/main/java/apps/amine/bou/readerforselfoss/HomeActivity.kt +++ b/app/src/main/java/apps/amine/bou/readerforselfoss/HomeActivity.kt @@ -177,7 +177,7 @@ class HomeActivity : AppCompatActivity(), SearchView.OnQueryTextListener { this, this@HomeActivity, settings.getBoolean("isSelfSignedCert", false), - sharedPref.getString("api_timeout", "-1").toLong() + sharedPref.getString("api_timeout", "-1")!!.toLong() ) items = ArrayList() allItems = ArrayList() @@ -389,19 +389,19 @@ class HomeActivity : AppCompatActivity(), SearchView.OnQueryTextListener { displayUnreadCount = sharedPref.getBoolean("display_unread_count", true) displayAllCount = sharedPref.getBoolean("display_other_count", false) fullHeightCards = sharedPref.getBoolean("full_height_cards", false) - itemsNumber = sharedPref.getString("prefer_api_items_number", "200").toInt() - userIdentifier = sharedPref.getString("unique_id", "") + itemsNumber = sharedPref.getString("prefer_api_items_number", "200")!!.toInt() + userIdentifier = sharedPref.getString("unique_id", "")!! displayAccountHeader = sharedPref.getBoolean("account_header_displaying", false) infiniteScroll = sharedPref.getBoolean("infinite_loading", false) itemsCaching = sharedPref.getBoolean("items_caching", false) - hiddenTags = if (sharedPref.getString("hidden_tags", "").isNotEmpty()) { - sharedPref.getString("hidden_tags", "").replace("\\s".toRegex(), "").split(",") + hiddenTags = if (sharedPref.getString("hidden_tags", "")!!.isNotEmpty()) { + sharedPref.getString("hidden_tags", "")!!.replace("\\s".toRegex(), "").split(",") } else { emptyList() } periodicRefresh = sharedPref.getBoolean("periodic_refresh", false) refreshWhenChargingOnly = sharedPref.getBoolean("refresh_when_charging", false) - refreshMinutes = sharedPref.getString("periodic_refresh_minutes", "360").toLong() + refreshMinutes = sharedPref.getString("periodic_refresh_minutes", "360")!!.toLong() if (refreshMinutes <= 15) { refreshMinutes = 15 @@ -450,7 +450,7 @@ class HomeActivity : AppCompatActivity(), SearchView.OnQueryTextListener { if (displayAccountHeader) { accountHeader { background = R.drawable.bg - profile(settings.getString("url", "")) { + profile(settings.getString("url", "")!!) { iconDrawable = resources.getDrawable(R.mipmap.ic_launcher) } selectionListEnabledForSingleProfile = false @@ -684,13 +684,6 @@ class HomeActivity : AppCompatActivity(), SearchView.OnQueryTextListener { .withIconTintingEnabled(true) .withOnDrawerItemClickListener { _, _, _ -> LibsBuilder() - .withActivityStyle( - if (appColors.isDarkTheme) { - Libs.ActivityStyle.DARK - } else { - Libs.ActivityStyle.LIGHT_DARK_TOOLBAR - } - ) .withAboutIconShown(true) .withAboutVersionShown(true) .start(this@HomeActivity) diff --git a/app/src/main/java/apps/amine/bou/readerforselfoss/LoginActivity.kt b/app/src/main/java/apps/amine/bou/readerforselfoss/LoginActivity.kt index f35854b..eeb7735 100644 --- a/app/src/main/java/apps/amine/bou/readerforselfoss/LoginActivity.kt +++ b/app/src/main/java/apps/amine/bou/readerforselfoss/LoginActivity.kt @@ -52,11 +52,11 @@ class LoginActivity : AppCompatActivity() { handleBaseUrlFail() settings = getSharedPreferences(Config.settingsName, Context.MODE_PRIVATE) - userIdentifier = settings.getString("unique_id", "") + userIdentifier = settings.getString("unique_id", "")!! editor = settings.edit() - if (settings.getString("url", "").isNotEmpty()) { + if (settings.getString("url", "")!!.isNotEmpty()) { goToMain() } @@ -284,7 +284,6 @@ class LoginActivity : AppCompatActivity() { return when (item.itemId) { R.id.about -> { LibsBuilder() - .withActivityStyle(Libs.ActivityStyle.LIGHT_DARK_TOOLBAR) .withAboutIconShown(true) .withAboutVersionShown(true) .start(this) diff --git a/app/src/main/java/apps/amine/bou/readerforselfoss/MyApp.kt b/app/src/main/java/apps/amine/bou/readerforselfoss/MyApp.kt index 61a0186..9974916 100644 --- a/app/src/main/java/apps/amine/bou/readerforselfoss/MyApp.kt +++ b/app/src/main/java/apps/amine/bou/readerforselfoss/MyApp.kt @@ -26,7 +26,7 @@ class MyApp : MultiDexApplication() { config = Config(baseContext) val prefs = getSharedPreferences(Config.settingsName, Context.MODE_PRIVATE) - if (prefs.getString("unique_id", "").isEmpty()) { + if (prefs.getString("unique_id", "")!!.isEmpty()) { val editor = prefs.edit() editor.putString("unique_id", randomUUID().toString()) editor.apply() diff --git a/app/src/main/java/apps/amine/bou/readerforselfoss/ReaderActivity.kt b/app/src/main/java/apps/amine/bou/readerforselfoss/ReaderActivity.kt index 6b8e2b1..0a0d11d 100644 --- a/app/src/main/java/apps/amine/bou/readerforselfoss/ReaderActivity.kt +++ b/app/src/main/java/apps/amine/bou/readerforselfoss/ReaderActivity.kt @@ -100,7 +100,7 @@ class ReaderActivity : AppCompatActivity() { prefs = PreferenceManager.getDefaultSharedPreferences(this) editor = prefs.edit() - userIdentifier = prefs.getString("unique_id", "") + userIdentifier = prefs.getString("unique_id", "")!! markOnScroll = prefs.getBoolean("mark_on_scroll", false) activeAlignment = prefs.getInt("text_align", JUSTIFY) @@ -108,7 +108,7 @@ class ReaderActivity : AppCompatActivity() { this, this@ReaderActivity, settings.getBoolean("isSelfSignedCert", false), - prefs.getString("api_timeout", "-1").toLong() + prefs.getString("api_timeout", "-1")!!.toLong() ) if (allItems.isEmpty()) { diff --git a/app/src/main/java/apps/amine/bou/readerforselfoss/SourcesActivity.kt b/app/src/main/java/apps/amine/bou/readerforselfoss/SourcesActivity.kt index b6974b0..4069aa2 100644 --- a/app/src/main/java/apps/amine/bou/readerforselfoss/SourcesActivity.kt +++ b/app/src/main/java/apps/amine/bou/readerforselfoss/SourcesActivity.kt @@ -64,7 +64,7 @@ class SourcesActivity : AppCompatActivity() { this, this@SourcesActivity, settings.getBoolean("isSelfSignedCert", false), - prefs.getString("api_timeout", "-1").toLong() + prefs.getString("api_timeout", "-1")!!.toLong() ) var items: ArrayList = ArrayList() diff --git a/app/src/main/java/apps/amine/bou/readerforselfoss/adapters/ItemCardAdapter.kt b/app/src/main/java/apps/amine/bou/readerforselfoss/adapters/ItemCardAdapter.kt index 4393993..afdc2a5 100644 --- a/app/src/main/java/apps/amine/bou/readerforselfoss/adapters/ItemCardAdapter.kt +++ b/app/src/main/java/apps/amine/bou/readerforselfoss/adapters/ItemCardAdapter.kt @@ -9,6 +9,7 @@ import android.view.View import android.view.ViewGroup import android.widget.ImageView.ScaleType import android.widget.Toast +import androidx.core.content.ContextCompat import apps.amine.bou.readerforselfoss.R import apps.amine.bou.readerforselfoss.api.selfoss.Item import apps.amine.bou.readerforselfoss.api.selfoss.SelfossApi @@ -34,6 +35,10 @@ import com.bumptech.glide.Glide import com.like.LikeButton import com.like.OnLikeListener import kotlinx.android.synthetic.main.card_item.view.* +import kotlinx.android.synthetic.main.card_item.view.itemImage +import kotlinx.android.synthetic.main.card_item.view.sourceTitleAndDate +import kotlinx.android.synthetic.main.card_item.view.title +import kotlinx.android.synthetic.main.list_item.view.* import retrofit2.Call import retrofit2.Callback import retrofit2.Response @@ -69,12 +74,21 @@ class ItemCardAdapter( holder.mView.favButton.isLiked = itm.starred holder.mView.title.text = itm.getTitleDecoded() + holder.mView.title.setTextColor(ContextCompat.getColor( + c, + appColors.textColor + )) holder.mView.title.setOnTouchListener(LinkOnTouchListener()) holder.mView.title.setLinkTextColor(appColors.colorAccent) holder.mView.sourceTitleAndDate.text = itm.sourceAndDateText() + holder.mView.sourceTitleAndDate.setTextColor(ContextCompat.getColor( + c, + appColors.textColor + )) + if (!fullHeightCards) { holder.mView.itemImage.maxHeight = imageMaxHeight holder.mView.itemImage.scaleType = ScaleType.CENTER_CROP diff --git a/app/src/main/java/apps/amine/bou/readerforselfoss/adapters/ItemListAdapter.kt b/app/src/main/java/apps/amine/bou/readerforselfoss/adapters/ItemListAdapter.kt index c2b0386..6e7c669 100644 --- a/app/src/main/java/apps/amine/bou/readerforselfoss/adapters/ItemListAdapter.kt +++ b/app/src/main/java/apps/amine/bou/readerforselfoss/adapters/ItemListAdapter.kt @@ -13,6 +13,7 @@ import android.view.View import android.view.ViewGroup import android.widget.TextView import android.widget.Toast +import androidx.core.content.ContextCompat import apps.amine.bou.readerforselfoss.R import apps.amine.bou.readerforselfoss.api.selfoss.Item import apps.amine.bou.readerforselfoss.api.selfoss.SelfossApi @@ -72,12 +73,22 @@ class ItemListAdapter( holder.mView.title.text = itm.getTitleDecoded() + holder.mView.title.setTextColor(ContextCompat.getColor( + c, + appColors.textColor + )) + holder.mView.title.setOnTouchListener(LinkOnTouchListener()) holder.mView.title.setLinkTextColor(appColors.colorAccent) holder.mView.sourceTitleAndDate.text = itm.sourceAndDateText() + holder.mView.sourceTitleAndDate.setTextColor(ContextCompat.getColor( + c, + appColors.textColor + )) + if (itm.getThumbnail(c).isEmpty()) { if (itm.getIcon(c).isEmpty()) { diff --git a/app/src/main/java/apps/amine/bou/readerforselfoss/api/mercury/MercuryModels.kt b/app/src/main/java/apps/amine/bou/readerforselfoss/api/mercury/MercuryModels.kt index d263c94..a1b7fbc 100644 --- a/app/src/main/java/apps/amine/bou/readerforselfoss/api/mercury/MercuryModels.kt +++ b/app/src/main/java/apps/amine/bou/readerforselfoss/api/mercury/MercuryModels.kt @@ -28,17 +28,17 @@ class ParsedContent( } constructor(source: Parcel) : this( - title = source.readString(), + title = source.readString().orEmpty(), content = source.readString(), - date_published = source.readString(), + date_published = source.readString().orEmpty(), lead_image_url = source.readString(), - dek = source.readString(), - url = source.readString(), - domain = source.readString(), - excerpt = source.readString(), + dek = source.readString().orEmpty(), + url = source.readString().orEmpty(), + domain = source.readString().orEmpty(), + excerpt = source.readString().orEmpty(), total_pages = source.readInt(), rendered_pages = source.readInt(), - next_page_url = source.readString() + next_page_url = source.readString().orEmpty() ) override fun describeContents() = 0 diff --git a/app/src/main/java/apps/amine/bou/readerforselfoss/api/selfoss/SelfossModels.kt b/app/src/main/java/apps/amine/bou/readerforselfoss/api/selfoss/SelfossModels.kt index 8a2399e..05ef1c4 100644 --- a/app/src/main/java/apps/amine/bou/readerforselfoss/api/selfoss/SelfossModels.kt +++ b/app/src/main/java/apps/amine/bou/readerforselfoss/api/selfoss/SelfossModels.kt @@ -94,17 +94,17 @@ data class Item( } constructor(source: Parcel) : this( - id = source.readString(), - datetime = source.readString(), - title = source.readString(), - content = source.readString(), + id = source.readString().orEmpty(), + datetime = source.readString().orEmpty(), + title = source.readString().orEmpty(), + content = source.readString().orEmpty(), unread = 0.toByte() != source.readByte(), starred = 0.toByte() != source.readByte(), thumbnail = source.readString(), icon = source.readString(), - link = source.readString(), - sourcetitle = source.readString(), - tags = source.readParcelable(ClassLoader.getSystemClassLoader()) + link = source.readString().orEmpty(), + sourcetitle = source.readString().orEmpty(), + tags = if (source.readParcelable(ClassLoader.getSystemClassLoader()) != null) source.readParcelable(ClassLoader.getSystemClassLoader())!! else SelfossTagType("") ) override fun describeContents() = 0 @@ -216,7 +216,7 @@ data class SelfossTagType(val tags: String) : Parcelable { } constructor(source: Parcel) : this( - tags = source.readString() + tags = source.readString().orEmpty() ) override fun describeContents() = 0 diff --git a/app/src/main/java/apps/amine/bou/readerforselfoss/background/background.kt b/app/src/main/java/apps/amine/bou/readerforselfoss/background/background.kt index a1ce7dc..b2b5beb 100644 --- a/app/src/main/java/apps/amine/bou/readerforselfoss/background/background.kt +++ b/app/src/main/java/apps/amine/bou/readerforselfoss/background/background.kt @@ -63,7 +63,7 @@ class LoadingWorker(val context: Context, params: WorkerParameters) : Worker(con this.context, null, settings.getBoolean("isSelfSignedCert", false), - sharedPref.getString("api_timeout", "-1").toLong() + sharedPref.getString("api_timeout", "-1")!!.toLong() ) api.allItems().enqueue(object : Callback> { diff --git a/app/src/main/java/apps/amine/bou/readerforselfoss/fragments/ArticleFragment.kt b/app/src/main/java/apps/amine/bou/readerforselfoss/fragments/ArticleFragment.kt index f5b10a9..8007a84 100644 --- a/app/src/main/java/apps/amine/bou/readerforselfoss/fragments/ArticleFragment.kt +++ b/app/src/main/java/apps/amine/bou/readerforselfoss/fragments/ArticleFragment.kt @@ -100,7 +100,7 @@ class ArticleFragment : Fragment() { super.onCreate(savedInstanceState) pageNumber = arguments!!.getInt(ARG_POSITION) - allItems = arguments!!.getParcelableArrayList(ARG_ITEMS) + allItems = arguments!!.getParcelableArrayList(ARG_ITEMS) as ArrayList db = Room.databaseBuilder( context!!, @@ -126,9 +126,9 @@ class ArticleFragment : Fragment() { prefs = PreferenceManager.getDefaultSharedPreferences(activity) editor = prefs.edit() - fontSize = prefs.getString("reader_font_size", "16").toInt() + fontSize = prefs.getString("reader_font_size", "16")!!.toInt() - font = prefs.getString("reader_font", "") + font = prefs.getString("reader_font", "")!! if (font.isNotEmpty()) { resId = context!!.resources.getIdentifier(font, "font", context!!.packageName) typeface = try { @@ -148,7 +148,7 @@ class ArticleFragment : Fragment() { context!!, activity!!, settings.getBoolean("isSelfSignedCert", false), - prefs.getString("api_timeout", "-1").toLong() + prefs.getString("api_timeout", "-1")!!.toLong() ) fab = rootView!!.fab diff --git a/app/src/main/java/apps/amine/bou/readerforselfoss/fragments/ImageFragment.kt b/app/src/main/java/apps/amine/bou/readerforselfoss/fragments/ImageFragment.kt index 57e26c8..30c0cd8 100644 --- a/app/src/main/java/apps/amine/bou/readerforselfoss/fragments/ImageFragment.kt +++ b/app/src/main/java/apps/amine/bou/readerforselfoss/fragments/ImageFragment.kt @@ -17,7 +17,7 @@ class ImageFragment : Fragment() { override fun onCreate(savedInstanceState: Bundle?) { super.onCreate(savedInstanceState) - imageUrl = arguments!!.getString("imageUrl") + imageUrl = arguments!!.getString("imageUrl")!! } override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?, savedInstanceState: Bundle?): View? { diff --git a/app/src/main/java/apps/amine/bou/readerforselfoss/themes/AppColors.kt b/app/src/main/java/apps/amine/bou/readerforselfoss/themes/AppColors.kt index a4d86e3..8626770 100644 --- a/app/src/main/java/apps/amine/bou/readerforselfoss/themes/AppColors.kt +++ b/app/src/main/java/apps/amine/bou/readerforselfoss/themes/AppColors.kt @@ -18,6 +18,7 @@ class AppColors(a: Activity) { @ColorInt val colorAccentDark: Int @ColorInt val cardBackgroundColor: Int @ColorInt val colorBackground: Int + @ColorInt val textColor: Int val isDarkTheme: Boolean init { @@ -57,6 +58,12 @@ class AppColors(a: Activity) { android.R.color.background_light } + textColor = if (isDarkTheme) { + R.color.md_white_1000 + } else { + R.color.md_grey_900 + } + val wrapper = Context::class.java val method = wrapper!!.getMethod("getThemeResId") method.isAccessible = true diff --git a/app/src/main/java/apps/amine/bou/readerforselfoss/utils/Config.kt b/app/src/main/java/apps/amine/bou/readerforselfoss/utils/Config.kt index 9047012..1f9f290 100644 --- a/app/src/main/java/apps/amine/bou/readerforselfoss/utils/Config.kt +++ b/app/src/main/java/apps/amine/bou/readerforselfoss/utils/Config.kt @@ -11,19 +11,19 @@ class Config(c: Context) { val settings: SharedPreferences = c.getSharedPreferences(settingsName, Context.MODE_PRIVATE) val baseUrl: String - get() = settings.getString("url", "") + get() = settings.getString("url", "")!! val userLogin: String - get() = settings.getString("login", "") + get() = settings.getString("login", "")!! val userPassword: String - get() = settings.getString("password", "") + get() = settings.getString("password", "")!! val httpUserLogin: String - get() = settings.getString("httpUserName", "") + get() = settings.getString("httpUserName", "")!! val httpUserPassword: String - get() = settings.getString("httpPassword", "") + get() = settings.getString("httpPassword", "")!! companion object { const val settingsName = "paramsselfoss" diff --git a/build.gradle b/build.gradle index 29e64db..4d6928b 100644 --- a/build.gradle +++ b/build.gradle @@ -2,7 +2,7 @@ buildscript { ext { - kotlin_version = '1.3.31' + kotlin_version = '1.4.21' android_version = '1.0.0' androidx_version = '1.1.0-alpha05' lifecycle_version = '2.2.0-alpha01'