From 7b5d00ff016df5b46a4037f19c3efbf39a40e49d Mon Sep 17 00:00:00 2001 From: RainLoop Team Date: Tue, 13 Oct 2015 19:36:43 +0300 Subject: [PATCH] Small improvements --- dev/Common/ClientStorageDriver/Cookie.js | 6 +++--- dev/Common/ClientStorageDriver/LocalStorage.js | 6 +++--- dev/Common/Utils.js | 8 +++++++- dev/Stores/User/Pgp.js | 5 ++++- dev/Styles/FolderList.less | 16 ++++++++++++++++ dev/Styles/MessageView.less | 4 ++-- dev/View/User/MailBox/MessageView.js | 1 + package.json | 2 +- .../v/0.0.0/app/libraries/RainLoop/Actions.php | 11 ++++++++++- .../templates/Views/User/MailFolderListItem.html | 1 + .../Views/User/MailFolderListSystemItem.html | 1 + .../app/templates/Views/User/SystemDropDown.html | 5 +++-- 12 files changed, 52 insertions(+), 14 deletions(-) diff --git a/dev/Common/ClientStorageDriver/Cookie.js b/dev/Common/ClientStorageDriver/Cookie.js index 27c25861c..db1fe8a30 100644 --- a/dev/Common/ClientStorageDriver/Cookie.js +++ b/dev/Common/ClientStorageDriver/Cookie.js @@ -44,7 +44,7 @@ { mResult = null === mStorageValue ? null : JSON.parse(mStorageValue); } - catch (oException) {} + catch (e) {} if (!mResult) { @@ -61,7 +61,7 @@ bResult = true; } - catch (oException) {} + catch (e) {} return bResult; }; @@ -89,7 +89,7 @@ mResult = null; } } - catch (oException) {} + catch (e) {} return mResult; }; diff --git a/dev/Common/ClientStorageDriver/LocalStorage.js b/dev/Common/ClientStorageDriver/LocalStorage.js index 2ad03cea8..2d873a383 100644 --- a/dev/Common/ClientStorageDriver/LocalStorage.js +++ b/dev/Common/ClientStorageDriver/LocalStorage.js @@ -44,7 +44,7 @@ { mResult = null === mStorageValue ? null : JSON.parse(mStorageValue); } - catch (oException) {} + catch (e) {} if (!mResult) { @@ -59,7 +59,7 @@ bResult = true; } - catch (oException) {} + catch (e) {} return bResult; }; @@ -87,7 +87,7 @@ mResult = null; } } - catch (oException) {} + catch (e) {} return mResult; }; diff --git a/dev/Common/Utils.js b/dev/Common/Utils.js index ed59539b0..b59caddc8 100644 --- a/dev/Common/Utils.js +++ b/dev/Common/Utils.js @@ -365,7 +365,7 @@ return false; }; - Utils.removeInFocus = function () + Utils.removeInFocus = function (force) { if (window.document && window.document.activeElement && window.document.activeElement.blur) { @@ -374,6 +374,12 @@ { window.document.activeElement.blur(); } + else if (force) + { + try { + window.document.activeElement.blur(); + } catch (e) {} + } } }; diff --git a/dev/Stores/User/Pgp.js b/dev/Stores/User/Pgp.js index bbda64410..91e0f239d 100644 --- a/dev/Stores/User/Pgp.js +++ b/dev/Stores/User/Pgp.js @@ -240,7 +240,10 @@ return true; } } - catch (e) {} + catch (e) + { + Utils.log(e); + } } fCallback(null, aSigningKeyIds); diff --git a/dev/Styles/FolderList.less b/dev/Styles/FolderList.less index c97c3e0ea..063becfb8 100644 --- a/dev/Styles/FolderList.less +++ b/dev/Styles/FolderList.less @@ -72,6 +72,17 @@ cursor: not-allowed; font-size: 14px; + .focused-poiner { + float: left; + display: inline-block; + background-color: transparent; + height: 100%; + width: 3px; + position: absolute; + top: 0; + left: 0; + } + padding: 0; padding-left: @folderItemPadding; padding-right: @folderItemPadding; @@ -96,8 +107,13 @@ &.focused { background-color: #888; + + .focused-poiner { + background-color: #fff; + } } + &.system { cursor: default; color: grey; diff --git a/dev/Styles/MessageView.less b/dev/Styles/MessageView.less index 0d5b92f43..8361e918c 100644 --- a/dev/Styles/MessageView.less +++ b/dev/Styles/MessageView.less @@ -376,8 +376,8 @@ html.rl-no-preview-pane { &.html { div[data-x-div-type=body] { - padding: 15px; - // margin: 15px; + /*padding: 15px;*/ + margin: 15px; } pre, code { diff --git a/dev/View/User/MailBox/MessageView.js b/dev/View/User/MailBox/MessageView.js index 5246082d8..b86546bf4 100644 --- a/dev/View/User/MailBox/MessageView.js +++ b/dev/View/User/MailBox/MessageView.js @@ -618,6 +618,7 @@ { oDiv.on('onBeforeOpen.lg', function () { Globals.useKeyboardShortcuts(false); + Utils.removeInFocus(true); }); oDiv.on('onCloseAfter.lg', function () { diff --git a/package.json b/package.json index 4d35529fa..d87ae7a7a 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "RainLoop", "title": "RainLoop Webmail", "version": "1.9.3", - "release": "363", + "release": "365", "description": "Simple, modern & fast web-based email client", "homepage": "http://rainloop.net", "main": "gulpfile.js", diff --git a/rainloop/v/0.0.0/app/libraries/RainLoop/Actions.php b/rainloop/v/0.0.0/app/libraries/RainLoop/Actions.php index 7f65c596c..305165b74 100644 --- a/rainloop/v/0.0.0/app/libraries/RainLoop/Actions.php +++ b/rainloop/v/0.0.0/app/libraries/RainLoop/Actions.php @@ -2294,6 +2294,13 @@ class Actions throw new \RainLoop\Exceptions\ClientException(\RainLoop\Notifications::AuthError); } } + else if ('sleep@sleep.dev' === $sEmail && 0 < \strlen($sPassword) && + \is_numeric($sPassword) && $this->Config()->Get('debug', 'enable', false) + ) + { + \sleep((int) $sPassword); + throw new \RainLoop\Exceptions\ClientException(\RainLoop\Notifications::AuthError); + } try { @@ -7227,7 +7234,7 @@ class Actions try { - $sHash = $this->MailClient()->FolderHash($sFromFolder); + $sHash = $this->MailClient()->FolderHash($sFolder); } catch (\Exception $oException) { @@ -8288,6 +8295,8 @@ class Actions $mResult = $this->MailClient()->MessageMimeStream(function($rResource, $sContentType, $sFileName, $sMimeIndex = '') use ($oAccount, $oFileProvider, $sFileNameIn, $sContentTypeIn, &$sResultHash) { + unset($sContentType, $sFileName, $sMimeIndex); + if ($oAccount && \is_resource($rResource)) { $sHash = \MailSo\Base\Utils::Md5Rand($sFileNameIn.'~'.$sContentTypeIn); diff --git a/rainloop/v/0.0.0/app/templates/Views/User/MailFolderListItem.html b/rainloop/v/0.0.0/app/templates/Views/User/MailFolderListItem.html index bf1172ca4..7ae0e600c 100644 --- a/rainloop/v/0.0.0/app/templates/Views/User/MailFolderListItem.html +++ b/rainloop/v/0.0.0/app/templates/Views/User/MailFolderListItem.html @@ -5,6 +5,7 @@ css: { 'i-am-inbox': isInbox, 'selected': selected() && !isSystemFolder(), 'selectable': selectableForFolderList, 'hidden' : hidden, 'print-count': hasUnreadMessages, 'unread-sub': hasSubScribedUnreadMessagesSubfolders, 'system': isSystemFolder, 'anim-action-class': actionBlink }"> +
diff --git a/rainloop/v/0.0.0/app/templates/Views/User/MailFolderListSystemItem.html b/rainloop/v/0.0.0/app/templates/Views/User/MailFolderListSystemItem.html index 1338e6d6a..6a64de054 100644 --- a/rainloop/v/0.0.0/app/templates/Views/User/MailFolderListSystemItem.html +++ b/rainloop/v/0.0.0/app/templates/Views/User/MailFolderListSystemItem.html @@ -2,6 +2,7 @@   + \ No newline at end of file diff --git a/rainloop/v/0.0.0/app/templates/Views/User/SystemDropDown.html b/rainloop/v/0.0.0/app/templates/Views/User/SystemDropDown.html index b103b352c..b48e0353f 100644 --- a/rainloop/v/0.0.0/app/templates/Views/User/SystemDropDown.html +++ b/rainloop/v/0.0.0/app/templates/Views/User/SystemDropDown.html @@ -31,18 +31,19 @@ - + +