mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-09-04 15:07:02 +03:00
Add new "Move to folder" button
This commit is contained in:
parent
2c3881abc6
commit
f0e9d1a6d5
14 changed files with 312 additions and 182 deletions
|
|
@ -1,7 +1,8 @@
|
|||
|
||||
import ko from 'ko';
|
||||
import {Focused, KeyState} from 'Common/Enums';
|
||||
import {keyScope} from 'Common/Globals';
|
||||
|
||||
import {keyScope, leftPanelDisabled} from 'Common/Globals';
|
||||
import {isNonEmptyArray} from 'Common/Utils';
|
||||
|
||||
import * as Settings from 'Storage/Settings';
|
||||
|
|
@ -17,17 +18,28 @@ class AppUserStore extends AbstractAppStore
|
|||
|
||||
this.focusedState = ko.observable(Focused.None);
|
||||
|
||||
const isMobile = Settings.appSettingsGet('mobile');
|
||||
|
||||
this.focusedState.subscribe((value) => {
|
||||
switch (value)
|
||||
{
|
||||
case Focused.MessageList:
|
||||
keyScope(KeyState.MessageList);
|
||||
if (isMobile) {
|
||||
leftPanelDisabled(true);
|
||||
}
|
||||
break;
|
||||
case Focused.MessageView:
|
||||
keyScope(KeyState.MessageView);
|
||||
if (isMobile) {
|
||||
leftPanelDisabled(true);
|
||||
}
|
||||
break;
|
||||
case Focused.FolderList:
|
||||
keyScope(KeyState.FolderList);
|
||||
if (isMobile) {
|
||||
leftPanelDisabled(false);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue