mirror of
https://github.com/element-hq/element-android
synced 2024-11-27 11:59:12 +03:00
Rename class
This commit is contained in:
parent
c20de4feb0
commit
1228fcda0d
6 changed files with 19 additions and 19 deletions
|
@ -20,7 +20,7 @@ import im.vector.riotx.fdroid.features.settings.troubleshoot.TestAutoStartBoot
|
|||
import im.vector.riotx.fdroid.features.settings.troubleshoot.TestBackgroundRestrictions
|
||||
import im.vector.riotx.features.settings.troubleshoot.NotificationTroubleshootTestManager
|
||||
import im.vector.riotx.features.settings.troubleshoot.TestAccountSettings
|
||||
import im.vector.riotx.features.settings.troubleshoot.TestBingRulesSettings
|
||||
import im.vector.riotx.features.settings.troubleshoot.TestPushRulesSettings
|
||||
import im.vector.riotx.features.settings.troubleshoot.TestDeviceSettings
|
||||
import im.vector.riotx.features.settings.troubleshoot.TestSystemSettings
|
||||
import javax.inject.Inject
|
||||
|
@ -28,7 +28,7 @@ import javax.inject.Inject
|
|||
class NotificationTroubleshootTestManagerFactory @Inject constructor(private val testSystemSettings: TestSystemSettings,
|
||||
private val testAccountSettings: TestAccountSettings,
|
||||
private val testDeviceSettings: TestDeviceSettings,
|
||||
private val testBingRulesSettings: TestBingRulesSettings,
|
||||
private val testPushRulesSettings: TestPushRulesSettings,
|
||||
private val testAutoStartBoot: TestAutoStartBoot,
|
||||
private val testBackgroundRestrictions: TestBackgroundRestrictions) {
|
||||
|
||||
|
@ -37,7 +37,7 @@ class NotificationTroubleshootTestManagerFactory @Inject constructor(private val
|
|||
mgr.addTest(testSystemSettings)
|
||||
mgr.addTest(testAccountSettings)
|
||||
mgr.addTest(testDeviceSettings)
|
||||
mgr.addTest(testBingRulesSettings)
|
||||
mgr.addTest(testPushRulesSettings)
|
||||
mgr.addTest(testAutoStartBoot)
|
||||
mgr.addTest(testBackgroundRestrictions)
|
||||
return mgr
|
||||
|
|
|
@ -27,7 +27,7 @@ import im.vector.matrix.android.api.pushrules.rest.PushRule
|
|||
import im.vector.matrix.android.api.pushrules.rest.PushRuleAndKind
|
||||
import im.vector.riotx.R
|
||||
|
||||
class BingRulePreference : VectorPreference {
|
||||
class PushRulePreference : VectorPreference {
|
||||
|
||||
/**
|
||||
* @return the selected push rule and its kind
|
||||
|
@ -42,7 +42,7 @@ class BingRulePreference : VectorPreference {
|
|||
constructor(context: Context, attrs: AttributeSet, defStyle: Int) : super(context, attrs, defStyle)
|
||||
|
||||
init {
|
||||
layoutResource = R.layout.vector_preference_bing_rule
|
||||
layoutResource = R.layout.vector_preference_push_rule
|
||||
}
|
||||
|
||||
/**
|
|
@ -25,7 +25,7 @@ import im.vector.matrix.android.api.MatrixCallback
|
|||
import im.vector.matrix.android.api.pushrules.rest.PushRule
|
||||
import im.vector.matrix.android.api.pushrules.rest.PushRuleAndKind
|
||||
import im.vector.riotx.R
|
||||
import im.vector.riotx.core.preference.BingRulePreference
|
||||
import im.vector.riotx.core.preference.PushRulePreference
|
||||
import im.vector.riotx.core.preference.VectorPreference
|
||||
import im.vector.riotx.core.utils.toast
|
||||
import im.vector.riotx.features.notifications.NotificationUtils
|
||||
|
@ -92,7 +92,7 @@ class VectorSettingsAdvancedNotificationPreferenceFragment @Inject constructor(
|
|||
|
||||
for (preferenceKey in prefKeyToPushRuleId.keys) {
|
||||
val preference = findPreference<VectorPreference>(preferenceKey)
|
||||
if (preference is BingRulePreference) {
|
||||
if (preference is PushRulePreference) {
|
||||
// preference.isEnabled = null != rules && isConnected && pushManager.areDeviceNotificationsAllowed()
|
||||
val ruleAndKind: PushRuleAndKind? = session.getPushRules().findDefaultRule(prefKeyToPushRuleId[preferenceKey])
|
||||
|
||||
|
|
|
@ -23,7 +23,7 @@ import im.vector.riotx.core.resources.StringProvider
|
|||
import im.vector.riotx.features.notifications.toNotificationAction
|
||||
import javax.inject.Inject
|
||||
|
||||
class TestBingRulesSettings @Inject constructor(private val activeSessionHolder: ActiveSessionHolder,
|
||||
class TestPushRulesSettings @Inject constructor(private val activeSessionHolder: ActiveSessionHolder,
|
||||
private val stringProvider: StringProvider)
|
||||
: TroubleshootTest(R.string.settings_troubleshoot_test_bing_settings_title) {
|
||||
|
|
@ -5,59 +5,59 @@
|
|||
android:key="SETTINGS_NOTIFICATION_LEVEL"
|
||||
android:title="@string/settings_notification_by_event">
|
||||
|
||||
<im.vector.riotx.core.preference.BingRulePreference
|
||||
<im.vector.riotx.core.preference.PushRulePreference
|
||||
android:key="SETTINGS_PUSH_RULE_CONTAINING_MY_DISPLAY_NAME_PREFERENCE_KEY"
|
||||
android:persistent="false"
|
||||
android:title="@string/settings_containing_my_display_name" />
|
||||
|
||||
<im.vector.riotx.core.preference.BingRulePreference
|
||||
<im.vector.riotx.core.preference.PushRulePreference
|
||||
android:key="SETTINGS_PUSH_RULE_CONTAINING_MY_USER_NAME_PREFERENCE_KEY"
|
||||
android:persistent="false"
|
||||
android:title="@string/settings_containing_my_user_name" />
|
||||
|
||||
<im.vector.riotx.core.preference.BingRulePreference
|
||||
<im.vector.riotx.core.preference.PushRulePreference
|
||||
android:key="SETTINGS_PUSH_RULE_MESSAGES_CONTAINING_AT_ROOM_PREFERENCE_KEY"
|
||||
android:persistent="false"
|
||||
android:title="@string/settings_messages_at_room" />
|
||||
|
||||
<!-- TODO Support message with keywords rule -->
|
||||
|
||||
<im.vector.riotx.core.preference.BingRulePreference
|
||||
<im.vector.riotx.core.preference.PushRulePreference
|
||||
android:key="SETTINGS_PUSH_RULE_MESSAGES_IN_ONE_TO_ONE_PREFERENCE_KEY"
|
||||
android:persistent="false"
|
||||
android:title="@string/settings_messages_in_one_to_one" />
|
||||
|
||||
<im.vector.riotx.core.preference.BingRulePreference
|
||||
<im.vector.riotx.core.preference.PushRulePreference
|
||||
android:key="SETTINGS_PUSH_RULE_MESSAGES_IN_E2E_ONE_ONE_CHAT_PREFERENCE_KEY"
|
||||
android:persistent="false"
|
||||
android:title="@string/settings_messages_in_e2e_one_to_one" />
|
||||
|
||||
<im.vector.riotx.core.preference.BingRulePreference
|
||||
<im.vector.riotx.core.preference.PushRulePreference
|
||||
android:key="SETTINGS_PUSH_RULE_MESSAGES_IN_GROUP_CHAT_PREFERENCE_KEY"
|
||||
android:persistent="false"
|
||||
android:title="@string/settings_messages_in_group_chat" />
|
||||
|
||||
<im.vector.riotx.core.preference.BingRulePreference
|
||||
<im.vector.riotx.core.preference.PushRulePreference
|
||||
android:key="SETTINGS_PUSH_RULE_MESSAGES_IN_E2E_GROUP_CHAT_PREFERENCE_KEY"
|
||||
android:persistent="false"
|
||||
android:title="@string/settings_messages_in_e2e_group_chat" />
|
||||
|
||||
<im.vector.riotx.core.preference.BingRulePreference
|
||||
<im.vector.riotx.core.preference.PushRulePreference
|
||||
android:key="SETTINGS_PUSH_RULE_INVITED_TO_ROOM_PREFERENCE_KEY"
|
||||
android:persistent="false"
|
||||
android:title="@string/settings_invited_to_room" />
|
||||
|
||||
<im.vector.riotx.core.preference.BingRulePreference
|
||||
<im.vector.riotx.core.preference.PushRulePreference
|
||||
android:key="SETTINGS_PUSH_RULE_CALL_INVITATIONS_PREFERENCE_KEY"
|
||||
android:persistent="false"
|
||||
android:title="@string/settings_call_invitations" />
|
||||
|
||||
<im.vector.riotx.core.preference.BingRulePreference
|
||||
<im.vector.riotx.core.preference.PushRulePreference
|
||||
android:key="SETTINGS_PUSH_RULE_MESSAGES_SENT_BY_BOT_PREFERENCE_KEY"
|
||||
android:persistent="false"
|
||||
android:title="@string/settings_messages_sent_by_bot" />
|
||||
|
||||
<im.vector.riotx.core.preference.BingRulePreference
|
||||
<im.vector.riotx.core.preference.PushRulePreference
|
||||
android:key="SETTINGS_PUSH_RULE_ROOMS_UPGRADED_KEY"
|
||||
android:persistent="false"
|
||||
android:title="@string/settings_when_rooms_are_upgraded" />
|
||||
|
|
Loading…
Reference in a new issue