Reload automatically when changing cross-signing flag
parent
50cccd3212
commit
b8c0a0fe72
|
@ -23,7 +23,7 @@ import {
|
||||||
} from "./controllers/NotificationControllers";
|
} from "./controllers/NotificationControllers";
|
||||||
import CustomStatusController from "./controllers/CustomStatusController";
|
import CustomStatusController from "./controllers/CustomStatusController";
|
||||||
import ThemeController from './controllers/ThemeController';
|
import ThemeController from './controllers/ThemeController';
|
||||||
import LowBandwidthController from "./controllers/LowBandwidthController";
|
import ReloadOnChangeController from "./controllers/ReloadOnChangeController";
|
||||||
|
|
||||||
// These are just a bunch of helper arrays to avoid copy/pasting a bunch of times
|
// These are just a bunch of helper arrays to avoid copy/pasting a bunch of times
|
||||||
const LEVELS_ROOM_SETTINGS = ['device', 'room-device', 'room-account', 'account', 'config'];
|
const LEVELS_ROOM_SETTINGS = ['device', 'room-device', 'room-account', 'account', 'config'];
|
||||||
|
@ -151,6 +151,7 @@ export const SETTINGS = {
|
||||||
displayName: _td("Enable cross-signing to verify per-user instead of per-device"),
|
displayName: _td("Enable cross-signing to verify per-user instead of per-device"),
|
||||||
supportedLevels: LEVELS_FEATURE,
|
supportedLevels: LEVELS_FEATURE,
|
||||||
default: false,
|
default: false,
|
||||||
|
controller: new ReloadOnChangeController(),
|
||||||
},
|
},
|
||||||
"useCiderComposer": {
|
"useCiderComposer": {
|
||||||
displayName: _td("Use the new, faster, composer for writing messages"),
|
displayName: _td("Use the new, faster, composer for writing messages"),
|
||||||
|
@ -433,7 +434,7 @@ export const SETTINGS = {
|
||||||
supportedLevels: LEVELS_DEVICE_ONLY_SETTINGS_WITH_CONFIG,
|
supportedLevels: LEVELS_DEVICE_ONLY_SETTINGS_WITH_CONFIG,
|
||||||
displayName: _td('Low bandwidth mode'),
|
displayName: _td('Low bandwidth mode'),
|
||||||
default: false,
|
default: false,
|
||||||
controller: new LowBandwidthController(),
|
controller: new ReloadOnChangeController(),
|
||||||
},
|
},
|
||||||
"fallbackICEServerAllowed": {
|
"fallbackICEServerAllowed": {
|
||||||
supportedLevels: LEVELS_DEVICE_ONLY_SETTINGS,
|
supportedLevels: LEVELS_DEVICE_ONLY_SETTINGS,
|
||||||
|
|
|
@ -17,7 +17,7 @@ limitations under the License.
|
||||||
import SettingController from "./SettingController";
|
import SettingController from "./SettingController";
|
||||||
import PlatformPeg from "../../PlatformPeg";
|
import PlatformPeg from "../../PlatformPeg";
|
||||||
|
|
||||||
export default class LowBandwidthController extends SettingController {
|
export default class ReloadOnChangeController extends SettingController {
|
||||||
onChange(level, roomId, newValue) {
|
onChange(level, roomId, newValue) {
|
||||||
PlatformPeg.get().reload();
|
PlatformPeg.get().reload();
|
||||||
}
|
}
|
Loading…
Reference in New Issue