Compare commits
	
		
			6 Commits
		
	
	
		
			v171901013
			...
			v171901027
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
| 
						 | 
					e3460322b1 | ||
| 
						 | 
					7e3288a076 | ||
| 
						 | 
					ddc754ec25 | ||
| 
						 | 
					134a0766d6 | ||
| 
						 | 
					69da932ab5 | ||
| 
						 | 
					592fb6328a | 
@@ -1,5 +1,6 @@
 | 
			
		||||
package apps.amine.bou.readerforselfoss
 | 
			
		||||
 | 
			
		||||
import android.content.Context
 | 
			
		||||
import android.content.Intent
 | 
			
		||||
import android.os.Build
 | 
			
		||||
import android.os.Bundle
 | 
			
		||||
@@ -85,10 +86,12 @@ class AddSourceActivity : AppCompatActivity() {
 | 
			
		||||
 | 
			
		||||
        try {
 | 
			
		||||
            val prefs = PreferenceManager.getDefaultSharedPreferences(this)
 | 
			
		||||
            val settings =
 | 
			
		||||
                getSharedPreferences(Config.settingsName, Context.MODE_PRIVATE)
 | 
			
		||||
            api = SelfossApi(
 | 
			
		||||
                this,
 | 
			
		||||
                this@AddSourceActivity,
 | 
			
		||||
                prefs.getBoolean("isSelfSignedCert", false),
 | 
			
		||||
                settings.getBoolean("isSelfSignedCert", false),
 | 
			
		||||
                prefs.getString("api_timeout", "-1").toLong(),
 | 
			
		||||
                prefs.getBoolean("should_log_everything", false)
 | 
			
		||||
            )
 | 
			
		||||
 
 | 
			
		||||
@@ -519,7 +519,9 @@ class HomeActivity : AppCompatActivity(), SearchView.OnQueryTextListener {
 | 
			
		||||
                        )
 | 
			
		||||
                    }
 | 
			
		||||
                } else {
 | 
			
		||||
                    val filteredTags = maybeTags.filterNot { hiddenTags.contains(it.tag) }
 | 
			
		||||
                    val filteredTags = maybeTags
 | 
			
		||||
                        .filterNot { hiddenTags.contains(it.tag) }
 | 
			
		||||
                        .sortedBy { it.unread == 0 }
 | 
			
		||||
                    tagsBadge = filteredTags.map {
 | 
			
		||||
                        val gd = GradientDrawable()
 | 
			
		||||
                        val color = try {
 | 
			
		||||
 
 | 
			
		||||
@@ -1,5 +1,6 @@
 | 
			
		||||
package apps.amine.bou.readerforselfoss
 | 
			
		||||
 | 
			
		||||
import android.content.Context
 | 
			
		||||
import android.content.SharedPreferences
 | 
			
		||||
import android.graphics.drawable.ColorDrawable
 | 
			
		||||
import android.os.Build
 | 
			
		||||
@@ -27,6 +28,7 @@ import apps.amine.bou.readerforselfoss.persistence.migrations.MIGRATION_2_3
 | 
			
		||||
import apps.amine.bou.readerforselfoss.themes.AppColors
 | 
			
		||||
import apps.amine.bou.readerforselfoss.themes.Toppings
 | 
			
		||||
import apps.amine.bou.readerforselfoss.transformers.DepthPageTransformer
 | 
			
		||||
import apps.amine.bou.readerforselfoss.utils.Config
 | 
			
		||||
import apps.amine.bou.readerforselfoss.utils.maybeHandleSilentException
 | 
			
		||||
import apps.amine.bou.readerforselfoss.utils.network.isNetworkAccessible
 | 
			
		||||
import apps.amine.bou.readerforselfoss.utils.persistence.toEntity
 | 
			
		||||
@@ -94,6 +96,9 @@ class ReaderActivity : AppCompatActivity() {
 | 
			
		||||
        supportActionBar?.setDisplayHomeAsUpEnabled(true)
 | 
			
		||||
        supportActionBar?.setDisplayShowHomeEnabled(true)
 | 
			
		||||
 | 
			
		||||
        val settings =
 | 
			
		||||
            getSharedPreferences(Config.settingsName, Context.MODE_PRIVATE)
 | 
			
		||||
 | 
			
		||||
        prefs = PreferenceManager.getDefaultSharedPreferences(this)
 | 
			
		||||
        editor = prefs.edit()
 | 
			
		||||
 | 
			
		||||
@@ -105,7 +110,7 @@ class ReaderActivity : AppCompatActivity() {
 | 
			
		||||
        api = SelfossApi(
 | 
			
		||||
            this,
 | 
			
		||||
            this@ReaderActivity,
 | 
			
		||||
            prefs.getBoolean("isSelfSignedCert", false),
 | 
			
		||||
            settings.getBoolean("isSelfSignedCert", false),
 | 
			
		||||
            prefs.getString("api_timeout", "-1").toLong(),
 | 
			
		||||
            prefs.getBoolean("should_log_everything", false)
 | 
			
		||||
        )
 | 
			
		||||
 
 | 
			
		||||
@@ -1,5 +1,6 @@
 | 
			
		||||
package apps.amine.bou.readerforselfoss
 | 
			
		||||
 | 
			
		||||
import android.content.Context
 | 
			
		||||
import android.content.Intent
 | 
			
		||||
import android.content.res.ColorStateList
 | 
			
		||||
import android.os.Build
 | 
			
		||||
@@ -13,6 +14,7 @@ import apps.amine.bou.readerforselfoss.api.selfoss.SelfossApi
 | 
			
		||||
import apps.amine.bou.readerforselfoss.api.selfoss.Source
 | 
			
		||||
import apps.amine.bou.readerforselfoss.themes.AppColors
 | 
			
		||||
import apps.amine.bou.readerforselfoss.themes.Toppings
 | 
			
		||||
import apps.amine.bou.readerforselfoss.utils.Config
 | 
			
		||||
import apps.amine.bou.readerforselfoss.utils.network.isNetworkAccessible
 | 
			
		||||
import com.ftinc.scoop.Scoop
 | 
			
		||||
import kotlinx.android.synthetic.main.activity_sources.*
 | 
			
		||||
@@ -54,12 +56,14 @@ class SourcesActivity : AppCompatActivity() {
 | 
			
		||||
        super.onResume()
 | 
			
		||||
        val mLayoutManager = LinearLayoutManager(this)
 | 
			
		||||
 | 
			
		||||
        val settings =
 | 
			
		||||
            getSharedPreferences(Config.settingsName, Context.MODE_PRIVATE)
 | 
			
		||||
        val prefs = PreferenceManager.getDefaultSharedPreferences(this)
 | 
			
		||||
 | 
			
		||||
        val api = SelfossApi(
 | 
			
		||||
            this,
 | 
			
		||||
            this@SourcesActivity,
 | 
			
		||||
            prefs.getBoolean("isSelfSignedCert", false),
 | 
			
		||||
            settings.getBoolean("isSelfSignedCert", false),
 | 
			
		||||
            prefs.getString("api_timeout", "-1").toLong(),
 | 
			
		||||
            prefs.getBoolean("should_log_everything", false)
 | 
			
		||||
        )
 | 
			
		||||
 
 | 
			
		||||
@@ -127,7 +127,13 @@ class ArticleFragment : Fragment() {
 | 
			
		||||
            font = prefs.getString("reader_font", "")
 | 
			
		||||
            if (font.isNotEmpty()) {
 | 
			
		||||
                resId = context!!.resources.getIdentifier(font, "font", context!!.packageName)
 | 
			
		||||
                typeface = ResourcesCompat.getFont(context!!, resId)!!
 | 
			
		||||
                typeface = try {
 | 
			
		||||
                    ResourcesCompat.getFont(context!!, resId)!!
 | 
			
		||||
                } catch (e: java.lang.Exception) {
 | 
			
		||||
                    // ACRA.getErrorReporter().maybeHandleSilentException(Throwable("Font loading issue: ${e.message}"), context!!)
 | 
			
		||||
                    // Just to be sure
 | 
			
		||||
                    null
 | 
			
		||||
                }
 | 
			
		||||
            }
 | 
			
		||||
 | 
			
		||||
            refreshAlignment()
 | 
			
		||||
 
 | 
			
		||||
@@ -2,7 +2,7 @@
 | 
			
		||||
 | 
			
		||||
buildscript {
 | 
			
		||||
    ext {
 | 
			
		||||
        kotlin_version = '1.2.51'
 | 
			
		||||
        kotlin_version = '1.3.0'
 | 
			
		||||
        android_version = '1.0.0'
 | 
			
		||||
        lifecycle_version = '2.0.0'
 | 
			
		||||
        room_version = '2.1.0-alpha01'
 | 
			
		||||
@@ -16,7 +16,7 @@ buildscript {
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
    dependencies {
 | 
			
		||||
        classpath 'com.android.tools.build:gradle:3.2.1'
 | 
			
		||||
        classpath 'com.android.tools.build:gradle:3.3.0'
 | 
			
		||||
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										4
									
								
								gradle/wrapper/gradle-wrapper.properties
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										4
									
								
								gradle/wrapper/gradle-wrapper.properties
									
									
									
									
										vendored
									
									
								
							@@ -1,6 +1,6 @@
 | 
			
		||||
#Tue Sep 25 20:41:54 CEST 2018
 | 
			
		||||
#Mon Jan 14 20:50:06 CET 2019
 | 
			
		||||
distributionBase=GRADLE_USER_HOME
 | 
			
		||||
distributionPath=wrapper/dists
 | 
			
		||||
zipStoreBase=GRADLE_USER_HOME
 | 
			
		||||
zipStorePath=wrapper/dists
 | 
			
		||||
distributionUrl=https\://services.gradle.org/distributions/gradle-4.6-all.zip
 | 
			
		||||
distributionUrl=https\://services.gradle.org/distributions/gradle-4.10.1-all.zip
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user