Fix eslint version

This commit is contained in:
RainLoop Team 2016-07-01 01:50:11 +03:00
parent 8e8a041032
commit 8a6765faeb
15 changed files with 342 additions and 398 deletions

View file

@ -187,7 +187,9 @@ class AbstractApp extends AbstractBoot
}
redirectToAdminPanel() {
_.delay(() => window.location.href = Links.rootAdmin(), 100);
_.delay(() => {
window.location.href = Links.rootAdmin();
}, 100);
}
clearClientSideToken() {

View file

@ -270,6 +270,8 @@ class HtmlEditor
{
return false;
}
return true;
});
this.editor.on('blur', () => {

View file

@ -403,6 +403,8 @@ class Selector
return false;
}
}
return true;
});
}
}

1
dev/External/ko.js vendored
View file

@ -407,6 +407,7 @@ ko.bindingHandlers.onTab = {
{
return fValueAccessor().call(oViewModel, !!oEvent.shiftKey);
}
return true;
});
ko.utils.domNodeDisposal.addDisposeCallback(oElement, function() {

View file

@ -98,6 +98,8 @@ function SecurityAdminSettings()
'NewPassword': this.adminPasswordNew()
});
return true;
}, function() {
return '' !== Utils.trim(this.adminLogin()) && '' !== this.adminPassword();
});

View file

@ -85,7 +85,9 @@ PgpUserStore.prototype.findPrivateKeysByEncryptionKeyIds = function(aEncryptionK
{
aResult = _.uniq(_.compact(_.flatten(_.map(aRecipients, function(sEmail) {
var aKeys = sEmail ? self.findAllPrivateKeysByEmailNotNative(sEmail) : null;
return aKeys ? (bReturnWrapKeys ? aKeys : _.flatten(_.map(aKeys, function(oKey) {return oKey.getNativeKeys();}), true)) : [null];
return aKeys ? (bReturnWrapKeys ? aKeys : _.flatten(_.map(aKeys, function(oKey) {
return oKey.getNativeKeys();
}), true)) : [null];
}), true)), function(oKey) {return oKey.id;});
}

View file

@ -493,6 +493,8 @@ function ComposePopupView()
);
}
return true;
}, this.canBeSentOrSaved);
this.skipCommand = Utils.createCommand(this, function() {
@ -1410,6 +1412,8 @@ ComposePopupView.prototype.onBuild = function()
self.identitiesDropdownTrigger(true);
return false;
}
return true;
});
key('ctrl+`', Enums.KeyState.Compose, function() {

View file

@ -293,6 +293,8 @@ function ContactsPopupView()
}, 200);
}
return true;
}, function() {
return 0 < this.contactsCheckedOrSelected().length;
});

View file

@ -26,31 +26,35 @@ _.extend(KeyboardShortcutsHelpPopupView.prototype, AbstractView.prototype);
KeyboardShortcutsHelpPopupView.prototype.onBuild = function(oDom)
{
key('tab, shift+tab, left, right', Enums.KeyState.PopupKeyboardShortcutsHelp, _.throttle(_.bind(function(event, handler) {
key('tab, shift+tab, left, right', Enums.KeyState.PopupKeyboardShortcutsHelp, _.throttle(function(event, handler) {
if (event && handler)
{
var
$tabs = oDom.find('.nav.nav-tabs > li'),
bNext = handler && ('tab' === handler.shortcut || 'right' === handler.shortcut),
iIndex = $tabs.index($tabs.filter('.active'));
isNext = handler && ('tab' === handler.shortcut || 'right' === handler.shortcut),
index = $tabs.index($tabs.filter('.active'));
if (!bNext && 0 < iIndex)
if (!isNext && 0 < index)
{
iIndex -= 1;
index -= 1;
}
else if (bNext && iIndex < $tabs.length - 1)
else if (isNext && index < $tabs.length - 1)
{
iIndex += 1;
index += 1;
}
else
{
iIndex = bNext ? 0 : $tabs.length - 1;
index = isNext ? 0 : $tabs.length - 1;
}
$tabs.eq(iIndex).find('a[data-toggle="tab"]').tab('show');
$tabs.eq(index).find('a[data-toggle="tab"]').tab('show');
return false;
}
}, this), 100));
return true;
}, 100));
};
module.exports = KeyboardShortcutsHelpPopupView;

View file

@ -131,6 +131,7 @@ AbstractSystemDropDownUserView.prototype.onBuild = function()
require('Knoin/Knoin').showScreenPopup(require('View/Popup/KeyboardShortcutsHelp'));
return false;
}
return true;
});
};

View file

@ -430,6 +430,8 @@ MessageListMailBoxUserView.prototype.goToUpUpOrDownDown = function(bUp)
}
}, 350);
return true;
};
MessageListMailBoxUserView.prototype.useAutoSelect = function()
@ -788,6 +790,8 @@ MessageListMailBoxUserView.prototype.initShortcuts = function()
Events.pub('mailbox.message-view.toggle-full-screen');
return false;
}
return true;
});
if (Settings.capa(Enums.Capa.MessageListActions))
@ -816,6 +820,8 @@ MessageListMailBoxUserView.prototype.initShortcuts = function()
return false;
}
return true;
});
}
@ -921,6 +927,8 @@ MessageListMailBoxUserView.prototype.initShortcuts = function()
self.cancelThreadUid();
return false;
}
return true;
});
// change focused state

View file

@ -820,12 +820,13 @@ MessageViewMailBoxUserView.prototype.escShortcuts = function()
return false;
}
return true;
};
MessageViewMailBoxUserView.prototype.initShortcuts = function()
{
var
self = this;
var self = this;
// exit fullscreen, back
key('esc, backspace', Enums.KeyState.MessageView, _.bind(this.escShortcuts, this));
@ -843,6 +844,8 @@ MessageViewMailBoxUserView.prototype.initShortcuts = function()
self.replyCommand();
return false;
}
return true;
});
// replaAll
@ -852,6 +855,8 @@ MessageViewMailBoxUserView.prototype.initShortcuts = function()
self.replyAllCommand();
return false;
}
return true;
});
// forward
@ -861,6 +866,8 @@ MessageViewMailBoxUserView.prototype.initShortcuts = function()
self.forwardCommand();
return false;
}
return true;
});
// message information
@ -879,6 +886,8 @@ MessageViewMailBoxUserView.prototype.initShortcuts = function()
MessageStore.message().body.find('.rlBlockquoteSwitcher').click();
return false;
}
return true;
});
key('ctrl+up, command+up, ctrl+left, command+left', [Enums.KeyState.MessageList, Enums.KeyState.MessageView], function() {
@ -916,6 +925,8 @@ MessageViewMailBoxUserView.prototype.initShortcuts = function()
return false;
}
return true;
});
// change focused state