Merge branch 'develop' of github.com:TwidereProject/Twidere-Android into chameleon
This commit is contained in:
commit
77299e457c
|
@ -253,6 +253,8 @@ public interface SharedPreferenceConstants {
|
||||||
String KEY_NOTIFICATION_MENTIONS_ONLY = "notification_mentions_only";
|
String KEY_NOTIFICATION_MENTIONS_ONLY = "notification_mentions_only";
|
||||||
@Preference(type = BOOLEAN, hasDefault = true, defaultBoolean = false)
|
@Preference(type = BOOLEAN, hasDefault = true, defaultBoolean = false)
|
||||||
String KEY_PEBBLE_NOTIFICATIONS = "pebble_notifications";
|
String KEY_PEBBLE_NOTIFICATIONS = "pebble_notifications";
|
||||||
|
@Preference(type = BOOLEAN, hasDefault = true, defaultBoolean = true)
|
||||||
|
String KEY_FAB_VISIBLE = "fab_visible";
|
||||||
|
|
||||||
@Preference(type = STRING, hasDefault = true, defaultString = VALUE_COMPOSE_NOW_ACTION_COMPOSE)
|
@Preference(type = STRING, hasDefault = true, defaultString = VALUE_COMPOSE_NOW_ACTION_COMPOSE)
|
||||||
String KEY_COMPOSE_NOW_ACTION = "compose_now_action";
|
String KEY_COMPOSE_NOW_ACTION = "compose_now_action";
|
||||||
|
|
|
@ -356,6 +356,12 @@ class HomeActivity : BaseActivity(), OnClickListener, OnPageChangeListener, Supp
|
||||||
drawerToggleButton.visibility = View.GONE
|
drawerToggleButton.visibility = View.GONE
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (preferences.getBoolean(SharedPreferenceConstants.KEY_FAB_VISIBLE)) {
|
||||||
|
actionsButton.visibility = View.VISIBLE
|
||||||
|
} else {
|
||||||
|
actionsButton.visibility = View.GONE
|
||||||
|
}
|
||||||
|
|
||||||
homeContent.addOnLayoutChangeListener { v, left, top, right, bottom, oldLeft, oldTop, oldRight, oldBottom ->
|
homeContent.addOnLayoutChangeListener { v, left, top, right, bottom, oldLeft, oldTop, oldRight, oldBottom ->
|
||||||
if (top != oldTop) {
|
if (top != oldTop) {
|
||||||
val fragment = leftDrawerFragment
|
val fragment = leftDrawerFragment
|
||||||
|
|
|
@ -805,4 +805,7 @@
|
||||||
<string name="filter_everywhere_description">Folgendes wird in Twidere gefiltert:\n · Tweets dieses Benutzers\n · Tweets, die diesen Benutzer erwähnen\n · Retweets/Zitate dieses Benutzers</string>
|
<string name="filter_everywhere_description">Folgendes wird in Twidere gefiltert:\n · Tweets dieses Benutzers\n · Tweets, die diesen Benutzer erwähnen\n · Retweets/Zitate dieses Benutzers</string>
|
||||||
<!-- Verb. Used for skip some settings -->
|
<!-- Verb. Used for skip some settings -->
|
||||||
<!-- Used for decide something later, like permission request -->
|
<!-- Used for decide something later, like permission request -->
|
||||||
|
|
||||||
|
<string name="fab_visible">Floating Action Button</string>
|
||||||
|
<string name="fab_visible_summary">Den Floating Action Button anzeigen</string>
|
||||||
</resources>
|
</resources>
|
||||||
|
|
|
@ -821,4 +821,6 @@
|
||||||
<string name="preference_randomize_account_rename_accounts_confirm">Rename existing accounts?</string>
|
<string name="preference_randomize_account_rename_accounts_confirm">Rename existing accounts?</string>
|
||||||
<string name="message_auto_refresh_confirm">Enable auto refresh to get new tweets automatically?</string>
|
<string name="message_auto_refresh_confirm">Enable auto refresh to get new tweets automatically?</string>
|
||||||
<string name="error_info_oauth_timestamp_error">Please check your system date & time settings.</string>
|
<string name="error_info_oauth_timestamp_error">Please check your system date & time settings.</string>
|
||||||
|
<string name="fab_visible">Floating Action Button</string>
|
||||||
|
<string name="fab_visible_summary">Show the Floating Action Button</string>
|
||||||
</resources>
|
</resources>
|
|
@ -21,6 +21,16 @@
|
||||||
<!--suppress AndroidElementNotAllowed -->
|
<!--suppress AndroidElementNotAllowed -->
|
||||||
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
|
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
|
||||||
|
<SwitchPreferenceCompat
|
||||||
|
android:defaultValue="true"
|
||||||
|
android:key="fab_visible"
|
||||||
|
android:summary="@string/fab_visible_summary"
|
||||||
|
android:title="@string/fab_visible">
|
||||||
|
<extra
|
||||||
|
android:name="should_recreate"
|
||||||
|
android:value="true"/>
|
||||||
|
</SwitchPreferenceCompat>
|
||||||
|
|
||||||
<SwitchPreferenceCompat
|
<SwitchPreferenceCompat
|
||||||
android:defaultValue="false"
|
android:defaultValue="false"
|
||||||
android:key="quick_send"
|
android:key="quick_send"
|
||||||
|
|
Loading…
Reference in New Issue