fixed message date label
This commit is contained in:
parent
e3978b91bf
commit
10c5f3fd34
|
@ -38,7 +38,7 @@ android {
|
|||
versionName projectVersionName
|
||||
multiDexEnabled true
|
||||
|
||||
buildConfigField 'boolean', 'LEAK_CANARY_ENABLED', 'Boolean.parseBoolean("true")'
|
||||
buildConfigField 'boolean', 'LEAK_CANARY_ENABLED', 'Boolean.parseBoolean("false")'
|
||||
buildConfigField 'boolean', 'SHOW_CUSTOM_TOKEN_DIALOG', 'Boolean.parseBoolean("false")'
|
||||
|
||||
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
package android.support.v4.content
|
||||
|
||||
import android.content.Context
|
||||
|
||||
import android.os.AsyncTask
|
||||
import org.mariotaku.twidere.extension.set
|
||||
import org.mariotaku.twidere.util.Analyzer
|
||||
|
||||
/**
|
||||
|
@ -10,7 +11,16 @@ import org.mariotaku.twidere.util.Analyzer
|
|||
|
||||
abstract class FixedAsyncTaskLoader<D>(context: Context) : AsyncTaskLoader<D>(context) {
|
||||
|
||||
internal override fun executePendingTask() {
|
||||
init {
|
||||
try {
|
||||
val executorField = javaClass.getDeclaredField("mExecutor")
|
||||
this[executorField] = AsyncTask.SERIAL_EXECUTOR
|
||||
} catch (e: Exception) {
|
||||
// Ignore
|
||||
}
|
||||
}
|
||||
|
||||
override fun executePendingTask() {
|
||||
try {
|
||||
super.executePendingTask()
|
||||
} catch (e: IllegalStateException) {
|
||||
|
|
|
@ -182,6 +182,7 @@ class MessagesConversationAdapter(
|
|||
val messages = this.messages!!
|
||||
if (messages is ObjectCursor) {
|
||||
val cursor = messages.cursor
|
||||
cursor.moveToPosition(position)
|
||||
val indices = messages.indices
|
||||
val timestamp = cursor.getLong(indices[Messages.MESSAGE_TIMESTAMP])
|
||||
if (timestamp > 0) return timestamp
|
||||
|
|
|
@ -44,7 +44,6 @@ import org.mariotaku.kpreferences.get
|
|||
import org.mariotaku.kpreferences.set
|
||||
import org.mariotaku.ktextension.addOnAccountsUpdatedListenerSafe
|
||||
import org.mariotaku.ktextension.isCurrentThreadCompat
|
||||
import org.mariotaku.ktextension.localesCompat
|
||||
import org.mariotaku.mediaviewer.library.MediaDownloader
|
||||
import org.mariotaku.restfu.http.RestHttpClient
|
||||
import org.mariotaku.twidere.BuildConfig
|
||||
|
|
|
@ -548,7 +548,7 @@ object IntentUtils {
|
|||
val builder = Uri.Builder()
|
||||
builder.scheme(SCHEME_TWIDERE_SETTINGS)
|
||||
builder.authority(initialTag.orEmpty())
|
||||
return builder.intent()
|
||||
return builder.intent(Intent.ACTION_MAIN)
|
||||
}
|
||||
|
||||
fun openProfileEditor(context: Context, accountKey: UserKey?) {
|
||||
|
@ -576,8 +576,8 @@ object IntentUtils {
|
|||
}
|
||||
val builder = CustomTabsIntent.Builder()
|
||||
builder.addDefaultShareMenuItem()
|
||||
theme?.let { theme ->
|
||||
builder.setToolbarColor(theme.colorToolbar)
|
||||
theme?.let { t ->
|
||||
builder.setToolbarColor(t.colorToolbar)
|
||||
}
|
||||
val customTabsIntent = builder.build()
|
||||
val intent = customTabsIntent.intent
|
||||
|
|
Loading…
Reference in New Issue