Folder list resize optimization

This commit is contained in:
RainLoop Team 2014-05-08 02:20:17 +04:00
parent 53dc509d79
commit 1250efa445
26 changed files with 31233 additions and 31154 deletions

View file

@ -1075,6 +1075,7 @@ Utils.setExpandedFolder = function (sFullNameHash, bExpanded)
Utils.initLayoutResizer = function (sLeft, sRight, sClientSideKeyName)
{
var
iDisabledWidth = 65,
iMinWidth = 155,
oLeft = $(sLeft),
oRight = $(sRight),
@ -1095,16 +1096,15 @@ Utils.initLayoutResizer = function (sLeft, sRight, sClientSideKeyName)
},
fDisable = function (bDisable) {
var iWidth = 5;
if (bDisable)
{
oLeft.resizable('disable');
fSetWidth(iWidth);
fSetWidth(iDisabledWidth);
}
else
{
oLeft.resizable('enable');
iWidth = Utils.pInt(RL.local().get(sClientSideKeyName)) || iMinWidth;
var iWidth = Utils.pInt(RL.local().get(sClientSideKeyName)) || iMinWidth;
fSetWidth(iWidth > iMinWidth ? iWidth : iMinWidth);
}
},
@ -1123,7 +1123,7 @@ Utils.initLayoutResizer = function (sLeft, sRight, sClientSideKeyName)
if (null !== mLeftWidth)
{
fSetWidth(mLeftWidth);
fSetWidth(mLeftWidth > iMinWidth ? mLeftWidth : iMinWidth);
}
oLeft.resizable({

View file

@ -154,6 +154,14 @@ html.rl-started-trigger.no-mobile #rl-content {
animation: highlight-folder-row 0.5s linear;
}
&.csstransitions .b-folders .btn.buttonContacts {
.transition(margin 0.3s linear);
}
&.csstransitions .b-folders .b-content.opacity-on-panel-disabled {
.transition(opacity 0.3s linear);
}
&.csstransitions .messageList {
.messageListItem {
.transition(max-height 400ms ease);

View file

@ -58,7 +58,7 @@
}*/
}
.b-list-toopbar {
.b-list-toolbar {
padding: 0;
height: 45px;
text-align: center;
@ -71,7 +71,7 @@
}
}
.b-list-footer-toopbar {
.b-list-footer-toolbar {
position: absolute;
left: 0;
bottom: 0;

View file

@ -15,22 +15,23 @@
height: 30px;
padding: 10px 10px 0 @rlLowMargin;
color: #fff;
z-index: 101;
}
.b-footer {
position: absolute;
bottom: 18px;
bottom: 20px;
right: 0;
left: 0;
height: 20px;
padding: 0 10px 0 0;
padding: 0 10px 0 5px;
z-index: 101;
}
.b-content {
position: absolute;
top: 50px + @rlLowMargin;
bottom: 30px + @rlLowMargin + @rlBottomMargin;
bottom: 32px + @rlLowMargin + @rlBottomMargin;
// left: @rlLowMargin;
left: 0;
right: 0;
@ -161,3 +162,10 @@
padding-left: @subPadding * 3 + @folderItemPadding;
}
}
html.rl-left-panel-disabled {
.btn.buttonContacts {
margin-top: 10px !important;
margin-left: 0 !important;
}
}

View file

@ -36,7 +36,7 @@
.g-ui-absolute-reset;
width: @rlLeftWidth;
min-width: 120px;
min-width: 60px;
}
#rl-right {
@ -147,10 +147,10 @@ html.ssm-state-tablet, html.ssm-state-mobile {
}
.b-contacts-content.modal {
.b-list-toopbar, .b-list-content, .b-list-footer-toopbar {
.b-list-toolbar, .b-list-content, .b-list-footer-toolbar {
width: 150px;
}
.b-list-toopbar .e-search {
.b-list-toolbar .e-search {
width: 125px;
}
.b-view-content {
@ -173,10 +173,10 @@ html.ssm-state-tablet {
}
.b-contacts-content.modal {
.b-list-toopbar, .b-list-content, .b-list-footer-toopbar {
.b-list-toolbar, .b-list-content, .b-list-footer-toolbar {
width: 200px;
}
.b-list-toopbar .e-search {
.b-list-toolbar .e-search {
width: 175px;
}
.b-view-content {
@ -188,15 +188,38 @@ html.ssm-state-tablet {
}
}
.show-on-panel-disabled {
display: none;
}
html.rl-left-panel-disabled {
#rl-left {
width: 5px !important;
display: none;
width: 65px !important;
.show-on-panel-disabled {
display: block;
}
.opacity-on-panel-disabled {
.opacity(30);
}
.visibility-hidden-on-panel-disabled {
visibility: hidden;
}
.hide-on-panel-disabled {
display: none;
}
&.ui-state-disabled {
.opacity(100);
}
}
#rl-right {
left: 5px !important;
left: 65px !important;
}
}

View file

@ -10,6 +10,8 @@ function AdminMenuViewModel(oScreen)
{
KnoinAbstractViewModel.call(this, 'Left', 'AdminMenu');
this.leftPanelDisabled = RL.data().leftPanelDisabled;
this.menu = oScreen.menu;
Knoin.constructorEnd(this);

View file

@ -12,7 +12,6 @@ function AdminPaneViewModel()
this.version = ko.observable(RL.settingsGet('Version'));
this.adminManLoadingVisibility = RL.data().adminManLoadingVisibility;
this.leftPanelDisabled = RL.data().leftPanelDisabled;
Knoin.constructorEnd(this);
}

View file

@ -26,7 +26,6 @@ function MailBoxMessageListViewModel()
this.folderMenuForMove = oData.folderMenuForMove;
this.useCheckboxesInList = oData.useCheckboxesInList;
this.leftPanelDisabled = oData.leftPanelDisabled;
this.mainMessageListSearch = oData.mainMessageListSearch;
this.messageListEndFolder = oData.messageListEndFolder;

View file

@ -10,6 +10,8 @@ function SettingsMenuViewModel(oScreen)
{
KnoinAbstractViewModel.call(this, 'Left', 'SettingsMenu');
this.leftPanelDisabled = RL.data().leftPanelDisabled;
this.menu = oScreen.menu;
Knoin.constructorEnd(this);

View file

@ -8,8 +8,6 @@ function SettingsPaneViewModel()
{
KnoinAbstractViewModel.call(this, 'Right', 'SettingsPane');
this.leftPanelDisabled = RL.data().leftPanelDisabled;
Knoin.constructorEnd(this);
}