mirror of
https://gitee.com/jmix/cuba.git
synced 2024-12-04 04:07:42 +08:00
Refs #1065 New web theme fixes
This commit is contained in:
parent
8a9abfb304
commit
37ccc0de71
@ -222,6 +222,7 @@ public class VSplitPanel extends ComplexPanel implements Container,
|
||||
@Override
|
||||
public void onClick(ClickEvent event) {
|
||||
if (hookButtonState == HookButtonState.LEFT) {
|
||||
defaultPosition = position;
|
||||
position = "0px";
|
||||
} else if (defaultPosition != null) {
|
||||
position = defaultPosition;
|
||||
@ -327,8 +328,11 @@ public class VSplitPanel extends ComplexPanel implements Container,
|
||||
setStylenames();
|
||||
|
||||
position = uidl.getStringAttribute("position");
|
||||
if (defaultPosition == null)
|
||||
defaultPosition = position;
|
||||
if (defaultPosition == null) {
|
||||
defaultPosition = uidl.getStringAttribute("defaultPosition");
|
||||
if (defaultPosition == null)
|
||||
defaultPosition = position;
|
||||
}
|
||||
setSplitPosition(position);
|
||||
|
||||
final Paintable newFirstChild = client.getPaintable(uidl
|
||||
|
@ -49,7 +49,7 @@
|
||||
}
|
||||
|
||||
.v-splitpanel-horizontal .v-splitpanel-second-container {
|
||||
margin-left: 1px;
|
||||
/*margin-left: 1px;*/
|
||||
}
|
||||
|
||||
/* IE specific styles */
|
||||
|
@ -34,6 +34,12 @@
|
||||
padding-left: 6px;
|
||||
}
|
||||
|
||||
.v-tabsheet-content {
|
||||
background: #fff url(img/main-tabpanel-bg.png) repeat-x;
|
||||
border: none;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
/* Second level tabsheet */
|
||||
|
||||
.v-tabsheet-content .v-tabsheet-tabs {
|
||||
@ -60,7 +66,8 @@
|
||||
}
|
||||
|
||||
.v-tabsheet-content .v-tabsheet-content {
|
||||
border-color: #D2E3EE;
|
||||
border: 1px solid #D2E3EE;
|
||||
border-top-style: none;
|
||||
background: #F5F7F9;
|
||||
}
|
||||
|
||||
@ -88,7 +95,8 @@
|
||||
|
||||
.v-tabsheet-content .v-tabsheet-content .v-tabsheet-content {
|
||||
background: #EBF0F4;
|
||||
border-color: #A4C5DF;
|
||||
border: 1px solid #A4C5DF;
|
||||
border-top-style: none;
|
||||
}
|
||||
|
||||
/* Tabsheet in dialog windows */
|
||||
@ -117,7 +125,8 @@
|
||||
}
|
||||
|
||||
.v-window-contents .v-tabsheet-content {
|
||||
border-color: #D2E3EE;
|
||||
border: 1px solid #D2E3EE;
|
||||
border-top-style: none;
|
||||
background: #F5F7F9;
|
||||
}
|
||||
|
||||
@ -145,7 +154,8 @@
|
||||
|
||||
.v-window-contents .v-tabsheet-content .v-tabsheet-content {
|
||||
background: #EBF0F4;
|
||||
border-color: #A4C5DF;
|
||||
border: 1px solid #A4C5DF;
|
||||
border-top-style: none;
|
||||
}
|
||||
|
||||
/* General */
|
||||
@ -311,10 +321,7 @@
|
||||
*/
|
||||
|
||||
.v-tabsheet-content {
|
||||
border: 1px solid #5280b7;
|
||||
background-color: #fff;
|
||||
border-top: none;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.v-tabsheet-hidetabs .v-tabsheet-content {
|
||||
|
@ -211,12 +211,16 @@ public class AppWindow extends Window implements UserSubstitutionListener {
|
||||
if (foldersPane != null) {
|
||||
foldersSplit = new WebSplitPanel();
|
||||
|
||||
if (webConfig.getUseLightHeader())
|
||||
if (webConfig.getUseLightHeader()) {
|
||||
foldersSplit.setShowHookButton(true);
|
||||
foldersSplit.setDefaultPosition("300px");
|
||||
}
|
||||
|
||||
foldersSplit.setOrientation(SplitPanel.ORIENTATION_HORIZONTAL);
|
||||
foldersSplit.setSplitPosition(0, UNITS_PIXELS);
|
||||
foldersSplit.setLocked(true);
|
||||
|
||||
if (!webConfig.getUseLightHeader())
|
||||
foldersSplit.setLocked(true);
|
||||
|
||||
foldersSplit.addComponent(foldersPane);
|
||||
|
||||
@ -396,8 +400,10 @@ public class AppWindow extends Window implements UserSubstitutionListener {
|
||||
|
||||
if (webConfig.getUseLightHeader()) {
|
||||
Embedded appIcon = getLogoImage();
|
||||
layout.addComponent(appIcon);
|
||||
layout.setComponentAlignment(appIcon, Alignment.MIDDLE_LEFT);
|
||||
if (appIcon != null) {
|
||||
layout.addComponent(appIcon);
|
||||
layout.setComponentAlignment(appIcon, Alignment.MIDDLE_LEFT);
|
||||
}
|
||||
}
|
||||
|
||||
menuBar = createMenuBar();
|
||||
|
@ -35,6 +35,7 @@ public class WebSplitPanel extends com.vaadin.ui.SplitPanel
|
||||
private boolean expandable = true;
|
||||
|
||||
private boolean showHookButton = false;
|
||||
private String defaultPosition = null;
|
||||
|
||||
private IFrame frame;
|
||||
|
||||
@ -43,6 +44,8 @@ public class WebSplitPanel extends com.vaadin.ui.SplitPanel
|
||||
super.paintContent(target);
|
||||
|
||||
target.addAttribute("useHookButton", showHookButton);
|
||||
if (defaultPosition != null)
|
||||
target.addAttribute("defaultPosition", defaultPosition);
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -166,4 +169,12 @@ public class WebSplitPanel extends com.vaadin.ui.SplitPanel
|
||||
public void setShowHookButton(boolean showHookButton) {
|
||||
this.showHookButton = showHookButton;
|
||||
}
|
||||
|
||||
public String getDefaultPosition() {
|
||||
return defaultPosition;
|
||||
}
|
||||
|
||||
public void setDefaultPosition(String defaultPosition) {
|
||||
this.defaultPosition = defaultPosition;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user