Fixed strange characters in plain text mode (Firefox) (Closes #462)

This commit is contained in:
RainLoop Team 2015-02-17 16:04:03 +04:00
parent 2a90664574
commit e3064b10aa
24 changed files with 206 additions and 159 deletions

View file

@ -4,7 +4,6 @@
'use strict';
var
window = require('window'),
_ = require('_'),
ko = require('ko'),
@ -21,37 +20,13 @@
{
this.domains = DomainStore.domains;
this.iDomainForDeletionTimeout = 0;
this.visibility = ko.computed(function () {
return this.domains.loading() ? 'visible' : 'hidden';
}, this);
this.domainForDeletion = ko.observable(null).extend({'toggleSubscribe': [this,
function (oPrev) {
if (oPrev)
{
oPrev.deleteAccess(false);
}
}, function (oNext) {
if (oNext)
{
oNext.deleteAccess(true);
this.startDomainForDeletionTimeout();
}
}
]});
this.domainForDeletion = ko.observable(null).deleteAccessHelper();
}
DomainsAdminSettings.prototype.startDomainForDeletionTimeout = function ()
{
var self = this;
window.clearInterval(this.iDomainForDeletionTimeout);
this.iDomainForDeletionTimeout = window.setTimeout(function () {
self.domainForDeletion(null);
}, 1000 * 3);
};
DomainsAdminSettings.prototype.createDomain = function ()
{
require('Knoin/Knoin').showScreenPopup(require('View/Popup/Domain'));

View file

@ -31,11 +31,8 @@
this.serverErrorDesc = ko.observable('');
this.haveChanges = ko.observable(false);
this.processText = ko.observable('');
this.saveErrorText = ko.observable('');
this.visibility = ko.observable(false);
this.filters.subscribe(Utils.windowResizeCallback);
this.serverError.subscribe(function (bValue) {
@ -51,14 +48,6 @@
this.filterRaw.allow = ko.observable(false);
this.filterRaw.error = ko.observable(false);
this.processText = ko.computed(function () {
return this.filters.loading() ? Translator.i18n('SETTINGS_FILTERS/LOADING_PROCESS') : '';
}, this);
this.visibility = ko.computed(function () {
return '' === this.processText() ? 'hidden' : 'visible';
}, this);
this.filterForDeletion = ko.observable(null).extend({'falseTimeout': 3000}).extend(
{'toggleSubscribeProperty': [this, 'deleteAccess']});

View file

@ -24,7 +24,7 @@
{
this.folderList = Data.folderList;
this.processText = ko.computed(function () {
this.loading = ko.computed(function () {
var
bLoading = Data.foldersLoading(),
@ -33,44 +33,11 @@
bRenaming = Data.foldersRenaming()
;
if (bCreating)
{
return Translator.i18n('SETTINGS_FOLDERS/CREATING_PROCESS');
}
else if (bDeleting)
{
return Translator.i18n('SETTINGS_FOLDERS/DELETING_PROCESS');
}
else if (bRenaming)
{
return Translator.i18n('SETTINGS_FOLDERS/RENAMING_PROCESS');
}
else if (bLoading)
{
return Translator.i18n('SETTINGS_FOLDERS/LOADING_PROCESS');
}
return '';
return bLoading || bCreating || bDeleting || bRenaming;
}, this);
this.visibility = ko.computed(function () {
return '' === this.processText() ? 'hidden' : 'visible';
}, this);
this.folderForDeletion = ko.observable(null).extend({'falseTimeout': 3000}).extend({'toggleSubscribe': [this,
function (oPrev) {
if (oPrev)
{
oPrev.deleteAccess(false);
}
}, function (oNext) {
if (oNext)
{
oNext.deleteAccess(true);
}
}
]});
this.folderForDeletion = ko.observable(null).deleteAccessHelper();
this.folderForEdit = ko.observable(null).extend({'toggleSubscribe': [this,
function (oPrev) {

View file

@ -23,19 +23,7 @@
this.openpgpkeysPublic = PgpStore.openpgpkeysPublic;
this.openpgpkeysPrivate = PgpStore.openpgpkeysPrivate;
this.openPgpKeyForDeletion = ko.observable(null).extend({'falseTimeout': 3000}).extend({'toggleSubscribe': [this,
function (oPrev) {
if (oPrev)
{
oPrev.deleteAccess(false);
}
}, function (oNext) {
if (oNext)
{
oNext.deleteAccess(true);
}
}
]});
this.openPgpKeyForDeletion = ko.observable(null).deleteAccessHelper();
}
OpenPgpUserSettings.prototype.addOpenPgpKey = function ()