OpenPGP (Compose) (#53) UNSTABLE

This commit is contained in:
RainLoop Team 2014-03-20 02:39:36 +04:00
parent 2bf7c2e033
commit 67b5a72a71
22 changed files with 496 additions and 247 deletions

View file

@ -65,11 +65,6 @@ Globals.bDisableNanoScroll = Globals.bMobileDevice;
*/
Globals.bAllowPdfPreview = !Globals.bMobileDevice;
/**
* @type {boolean}
*/
Globals.bAllowOpenPGP = false;
/**
* @type {boolean}
*/

View file

@ -456,7 +456,11 @@ ko.bindingHandlers.emailsTags = {
'parseHook': function (aInput) {
return _.map(aInput, function (sInputValue) {
var sValue = Utils.trim(sInputValue), oEmail = null;
var
sValue = Utils.trim(sInputValue),
oEmail = null
;
if ('' !== sValue)
{
oEmail = new EmailModel();

View file

@ -4,14 +4,16 @@
* @param {Object} oElement
* @param {Function=} fOnBlur
* @param {Function=} fOnReady
* @param {Function=} fOnModeChange
*/
function NewHtmlEditorWrapper(oElement, fOnBlur, fOnReady)
function NewHtmlEditorWrapper(oElement, fOnBlur, fOnReady, fOnModeChange)
{
var self = this;
self.editor = null;
self.iBlurTimer = 0;
self.fOnBlur = fOnBlur || null;
self.fOnReady = fOnReady || null;
self.fOnModeChange = fOnModeChange || null;
self.$element = $(oElement);
@ -162,6 +164,11 @@ NewHtmlEditorWrapper.prototype.init = function ()
self.editor.on('mode', function() {
self.blurTrigger();
if (self.fOnModeChange)
{
self.fOnModeChange('plain' !== self.editor.mode);
}
});
self.editor.on('focus', function() {