mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-09-01 21:49:21 +03:00
Code refactoring
This commit is contained in:
parent
bf56821c2d
commit
31860420cb
32 changed files with 1342 additions and 1282 deletions
|
|
@ -17,9 +17,10 @@
|
|||
|
||||
AppStore = require('Stores/User/App'),
|
||||
SettingsStore = require('Stores/User/Settings'),
|
||||
FolderStore = require('Stores/User/Folder'),
|
||||
MessageStore = require('Stores/User/Message'),
|
||||
|
||||
Cache = require('Storage/User/Cache'),
|
||||
Data = require('Storage/User/Data'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
@ -36,14 +37,14 @@
|
|||
this.oContentVisible = null;
|
||||
this.oContentScrollable = null;
|
||||
|
||||
this.composeInEdit = Data.composeInEdit;
|
||||
this.composeInEdit = AppStore.composeInEdit;
|
||||
|
||||
this.messageList = Data.messageList;
|
||||
this.folderList = Data.folderList;
|
||||
this.folderListSystem = Data.folderListSystem;
|
||||
this.foldersChanging = Data.foldersChanging;
|
||||
this.messageList = MessageStore.messageList;
|
||||
this.folderList = FolderStore.folderList;
|
||||
this.folderListSystem = FolderStore.folderListSystem;
|
||||
this.foldersChanging = FolderStore.foldersChanging;
|
||||
|
||||
this.foldersListWithSingleInboxRootFolder = Data.foldersListWithSingleInboxRootFolder;
|
||||
this.foldersListWithSingleInboxRootFolder = FolderStore.foldersListWithSingleInboxRootFolder;
|
||||
|
||||
this.leftPanelDisabled = Globals.leftPanelDisabled;
|
||||
|
||||
|
|
@ -94,10 +95,10 @@
|
|||
{
|
||||
if (Enums.Layout.NoPreview === SettingsStore.layout())
|
||||
{
|
||||
Data.message(null);
|
||||
MessageStore.message(null);
|
||||
}
|
||||
|
||||
if (oFolder.fullNameRaw === Data.currentFolderFullNameRaw())
|
||||
if (oFolder.fullNameRaw === FolderStore.currentFolderFullNameRaw())
|
||||
{
|
||||
Cache.setFolderHash(oFolder.fullNameRaw, '');
|
||||
}
|
||||
|
|
@ -143,7 +144,7 @@
|
|||
var $items = $('.b-folders .e-item .e-link:not(.hidden).focused', oDom);
|
||||
if ($items.length && $items[0])
|
||||
{
|
||||
self.folderList.focused(false);
|
||||
FolderStore.folderList.focused(false);
|
||||
$items.click();
|
||||
}
|
||||
|
||||
|
|
@ -167,11 +168,11 @@
|
|||
});
|
||||
|
||||
key('esc, tab, shift+tab, right', Enums.KeyState.FolderList, function () {
|
||||
self.folderList.focused(false);
|
||||
FolderStore.folderList.focused(false);
|
||||
return false;
|
||||
});
|
||||
|
||||
self.folderList.focused.subscribe(function (bValue) {
|
||||
FolderStore.folderList.focused.subscribe(function (bValue) {
|
||||
$('.b-folders .e-item .e-link.focused', oDom).removeClass('focused');
|
||||
if (bValue)
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue