mirror of
https://github.com/laurent22/joplin.git
synced 2025-01-11 18:24:43 +02:00
Renamed 'layout' setting to 'layoutButtonSequence'
This commit is contained in:
parent
f450ef09cc
commit
2997b0f2c4
@ -126,11 +126,11 @@ class Application extends BaseApplication {
|
||||
currentLayout = panes.length === 2 ? 'both' : currentLayout[0];
|
||||
|
||||
let paneOptions;
|
||||
if (state.settings.layout === Setting.LAYOUT_EDITOR_VIEWER) {
|
||||
if (state.settings.layoutButtonSequence === Setting.LAYOUT_EDITOR_VIEWER) {
|
||||
paneOptions = ['editor', 'viewer'];
|
||||
} else if (state.settings.layout === Setting.LAYOUT_EDITOR_SPLIT) {
|
||||
} else if (state.settings.layoutButtonSequence === Setting.LAYOUT_EDITOR_SPLIT) {
|
||||
paneOptions = ['editor', 'both'];
|
||||
} else if (state.settings.layout === Setting.LAYOUT_VIEWER_SPLIT) {
|
||||
} else if (state.settings.layoutButtonSequence === Setting.LAYOUT_VIEWER_SPLIT) {
|
||||
paneOptions = ['viewer', 'both'];
|
||||
} else {
|
||||
paneOptions = ['editor', 'viewer', 'both'];
|
||||
@ -738,13 +738,13 @@ class Application extends BaseApplication {
|
||||
],
|
||||
};
|
||||
|
||||
const layoutOptions = Object.entries(Setting.enumOptions('layout')).map(([layoutKey, layout]) => ({
|
||||
const layoutButtonSequenceOptions = Object.entries(Setting.enumOptions('layoutButtonSequence')).map(([layoutKey, layout]) => ({
|
||||
label: layout,
|
||||
screens: ['Main'],
|
||||
type: 'checkbox',
|
||||
checked: Setting.value('layout') == layoutKey,
|
||||
checked: Setting.value('layoutButtonSequence') == layoutKey,
|
||||
click: () => {
|
||||
Setting.setValue('layout', layoutKey);
|
||||
Setting.setValue('layoutButtonSequence', layoutKey);
|
||||
this.refreshMenu();
|
||||
},
|
||||
}));
|
||||
@ -906,9 +906,9 @@ class Application extends BaseApplication {
|
||||
type: 'separator',
|
||||
screens: ['Main'],
|
||||
}, {
|
||||
label: _('Layouts'),
|
||||
label: _('Layout button sequence'),
|
||||
screens: ['Main'],
|
||||
submenu: layoutOptions,
|
||||
submenu: layoutButtonSequenceOptions,
|
||||
}, {
|
||||
label: _('Toggle note list'),
|
||||
screens: ['Main'],
|
||||
|
@ -233,7 +233,7 @@ class Setting extends BaseModel {
|
||||
return output;
|
||||
},
|
||||
},
|
||||
layout: {
|
||||
layoutButtonSequence: {
|
||||
value: Setting.LAYOUT_ALL,
|
||||
type: Setting.TYPE_INT,
|
||||
public: false,
|
||||
|
Loading…
Reference in New Issue
Block a user