mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-27 19:19:21 +03:00
Small fixes and changes
This commit is contained in:
parent
91b3f1a3e9
commit
54edeaa645
15 changed files with 77 additions and 94 deletions
|
|
@ -271,15 +271,6 @@
|
|||
'FalseResult': 0
|
||||
};
|
||||
|
||||
/**
|
||||
* @enum {string}
|
||||
*/
|
||||
Enums.InterfaceAnimation = {
|
||||
'None': 'None',
|
||||
'Normal': 'Normal',
|
||||
'Full': 'Full'
|
||||
};
|
||||
|
||||
/**
|
||||
* @enum {number}
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -111,11 +111,6 @@
|
|||
*/
|
||||
Globals.bXMLHttpRequestSupported = !!window.XMLHttpRequest;
|
||||
|
||||
/**
|
||||
* @type {string}
|
||||
*/
|
||||
Globals.sAnimationType = '';
|
||||
|
||||
/**
|
||||
* @type {*}
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -871,10 +871,8 @@
|
|||
{
|
||||
oData.editorDefaultType = ko.observable(Enums.EditorDefaultType.Html);
|
||||
oData.showImages = ko.observable(false);
|
||||
oData.interfaceAnimation = ko.observable(Enums.InterfaceAnimation.Full);
|
||||
oData.contactsAutosave = ko.observable(false);
|
||||
|
||||
Globals.sAnimationType = Enums.InterfaceAnimation.Full;
|
||||
oData.interfaceAnimation = ko.observable(true);
|
||||
|
||||
oData.capaThemes = ko.observable(true);
|
||||
oData.capaUserBackground = ko.observable(false);
|
||||
|
|
@ -893,26 +891,14 @@
|
|||
return Enums.Layout.NoPreview !== oData.layout();
|
||||
});
|
||||
|
||||
oData.interfaceAnimation.subscribe(function (sValue) {
|
||||
if (Globals.bMobileDevice || sValue === Enums.InterfaceAnimation.None)
|
||||
oData.interfaceAnimation.subscribe(function (bValue) {
|
||||
if (Globals.bMobileDevice || !bValue)
|
||||
{
|
||||
Globals.$html.removeClass('rl-anim rl-anim-full').addClass('no-rl-anim');
|
||||
|
||||
Globals.sAnimationType = Enums.InterfaceAnimation.None;
|
||||
Globals.$html.removeClass('rl-anim').addClass('no-rl-anim');
|
||||
}
|
||||
else
|
||||
{
|
||||
switch (sValue)
|
||||
{
|
||||
case Enums.InterfaceAnimation.Full:
|
||||
Globals.$html.removeClass('no-rl-anim').addClass('rl-anim rl-anim-full');
|
||||
Globals.sAnimationType = sValue;
|
||||
break;
|
||||
case Enums.InterfaceAnimation.Normal:
|
||||
Globals.$html.removeClass('no-rl-anim rl-anim-full').addClass('rl-anim');
|
||||
Globals.sAnimationType = sValue;
|
||||
break;
|
||||
}
|
||||
Globals.$html.removeClass('no-rl-anim').addClass('rl-anim');
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
|||
|
|
@ -28,9 +28,12 @@
|
|||
this.loadingDesc = ko.observable(Settings.settingsGet('LoadingDescription'));
|
||||
this.loadingDesc.trigger = ko.observable(Enums.SaveSettingsStep.Idle);
|
||||
|
||||
this.loginLogo = ko.observable(Settings.settingsGet('LoginLogo'));
|
||||
this.loginLogo = ko.observable(Settings.settingsGet('LoginLogo') || '');
|
||||
this.loginLogo.trigger = ko.observable(Enums.SaveSettingsStep.Idle);
|
||||
|
||||
this.userLogo = ko.observable(Settings.settingsGet('UserLogo') || '');
|
||||
this.userLogo.trigger = ko.observable(Enums.SaveSettingsStep.Idle);
|
||||
|
||||
this.loginDescription = ko.observable(Settings.settingsGet('LoginDescription'));
|
||||
this.loginDescription.trigger = ko.observable(Enums.SaveSettingsStep.Idle);
|
||||
|
||||
|
|
@ -56,7 +59,8 @@
|
|||
f2 = Utils.settingsSaveHelperSimpleFunction(self.loadingDesc.trigger, self),
|
||||
f3 = Utils.settingsSaveHelperSimpleFunction(self.loginLogo.trigger, self),
|
||||
f4 = Utils.settingsSaveHelperSimpleFunction(self.loginDescription.trigger, self),
|
||||
f5 = Utils.settingsSaveHelperSimpleFunction(self.loginCss.trigger, self)
|
||||
f5 = Utils.settingsSaveHelperSimpleFunction(self.loginCss.trigger, self),
|
||||
f6 = Utils.settingsSaveHelperSimpleFunction(self.userLogo.trigger, self)
|
||||
;
|
||||
|
||||
self.title.subscribe(function (sValue) {
|
||||
|
|
@ -77,6 +81,12 @@
|
|||
});
|
||||
});
|
||||
|
||||
self.userLogo.subscribe(function (sValue) {
|
||||
Remote.saveAdminConfig(f6, {
|
||||
'UserLogo': Utils.trim(sValue)
|
||||
});
|
||||
});
|
||||
|
||||
self.loginDescription.subscribe(function (sValue) {
|
||||
Remote.saveAdminConfig(f4, {
|
||||
'LoginDescription': Utils.trim(sValue)
|
||||
|
|
|
|||
|
|
@ -26,7 +26,6 @@
|
|||
this.mainMessagesPerPageArray = Consts.Defaults.MessagesPerPageArray;
|
||||
this.editorDefaultType = Data.editorDefaultType;
|
||||
this.showImages = Data.showImages;
|
||||
this.interfaceAnimation = Data.interfaceAnimation;
|
||||
this.useDesktopNotifications = Data.useDesktopNotifications;
|
||||
this.threading = Data.threading;
|
||||
this.useThreads = Data.useThreads;
|
||||
|
|
@ -128,12 +127,6 @@
|
|||
});
|
||||
});
|
||||
|
||||
Data.interfaceAnimation.subscribe(function (sValue) {
|
||||
Remote.saveSettings(null, {
|
||||
'InterfaceAnimation': sValue
|
||||
});
|
||||
});
|
||||
|
||||
Data.useDesktopNotifications.subscribe(function (bValue) {
|
||||
Utils.timeOutAction('SaveDesktopNotifications', function () {
|
||||
Remote.saveSettings(null, {
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@
|
|||
this.editorDefaultType(Settings.settingsGet('EditorDefaultType'));
|
||||
this.showImages(!!Settings.settingsGet('ShowImages'));
|
||||
this.contactsAutosave(!!Settings.settingsGet('ContactsAutosave'));
|
||||
this.interfaceAnimation(Settings.settingsGet('InterfaceAnimation'));
|
||||
this.interfaceAnimation(!!Settings.settingsGet('InterfaceAnimation'));
|
||||
|
||||
this.mainMessagesPerPage(Settings.settingsGet('MPP'));
|
||||
|
||||
|
|
|
|||
|
|
@ -134,6 +134,16 @@ html.rl-no-preview-pane {
|
|||
border-radius: 5px;
|
||||
padding: 10px 15px;
|
||||
}
|
||||
|
||||
.emptySubjectText {
|
||||
display: none;
|
||||
font-style: italic;
|
||||
color: #999;
|
||||
}
|
||||
|
||||
&.emptySubject .emptySubjectText {
|
||||
display: inline;
|
||||
}
|
||||
}
|
||||
|
||||
.messageItem {
|
||||
|
|
@ -147,16 +157,6 @@ html.rl-no-preview-pane {
|
|||
-webkit-overflow-scrolling: touch;
|
||||
border-radius: @rlLowBorderRadius;
|
||||
|
||||
.emptySubjectText {
|
||||
display: none;
|
||||
font-style: italic;
|
||||
color: #999;
|
||||
}
|
||||
|
||||
&.emptySubject .emptySubjectText {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
.buttonUp, .buttonUnFull, .buttonFull {
|
||||
display: inline-block;
|
||||
position: fixed;
|
||||
|
|
|
|||
|
|
@ -7,6 +7,8 @@
|
|||
_ = require('_'),
|
||||
ko = require('ko'),
|
||||
|
||||
Utils = require('Common/Utils'),
|
||||
|
||||
Settings = require('Storage/Settings'),
|
||||
Data = require('Storage/Admin/Data'),
|
||||
Remote = require('Storage/Admin/Remote'),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue