mirror of
https://gitee.com/jmix/cuba.git
synced 2024-12-02 19:27:57 +08:00
Havana SCSS theme, Folders pane icon, icons sprite definition #PL-1995
This commit is contained in:
parent
1402160c85
commit
1d5661c9e9
@ -138,7 +138,7 @@ public class FoldersPane extends VerticalLayout {
|
||||
createMenuBarCommand(),
|
||||
firstItem);
|
||||
|
||||
menuItem.setStyleName("cuba-folders-pane");
|
||||
menuItem.setStyleName(getMenuItemStyle());
|
||||
}
|
||||
}
|
||||
|
||||
@ -152,6 +152,7 @@ public class FoldersPane extends VerticalLayout {
|
||||
showFolders(!visible);
|
||||
selectedItem.setText(getMenuItemCaption());
|
||||
selectedItem.setIcon(getMenuItemIcon());
|
||||
selectedItem.setStyleName(getMenuItemStyle());
|
||||
}
|
||||
};
|
||||
}
|
||||
@ -497,10 +498,18 @@ public class FoldersPane extends VerticalLayout {
|
||||
}
|
||||
|
||||
protected Resource getMenuItemIcon() {
|
||||
return null;
|
||||
// if (visible)
|
||||
// return new VersionedThemeResource("icons/folders_pane_icon_active.png");
|
||||
// else
|
||||
// return new VersionedThemeResource("icons/folders_pane_icon.png");
|
||||
}
|
||||
|
||||
protected String getMenuItemStyle() {
|
||||
if (visible)
|
||||
return new VersionedThemeResource("icons/folders_pane_icon_active.png");
|
||||
return "folders-pane-icon-active";
|
||||
else
|
||||
return new VersionedThemeResource("icons/folders_pane_icon.png");
|
||||
return "folders-pane-icon";
|
||||
}
|
||||
|
||||
protected void openFolder(AbstractSearchFolder folder) {
|
||||
|
@ -31,9 +31,31 @@
|
||||
}
|
||||
}
|
||||
|
||||
.v-menubar-menuitem.v-menubar-menuitem-cuba-folders-pane {
|
||||
.v-menubar-menuitem.v-menubar-menuitem-folders-pane-icon,
|
||||
.v-menubar-menuitem.v-menubar-menuitem-folders-pane-icon-active {
|
||||
background: transparent;
|
||||
background-image: url(sprites/folders-pane-icon.png); /** sprite-ref: icons; */
|
||||
}
|
||||
|
||||
.v-menubar-menuitem.v-menubar-menuitem-folders-pane-icon,
|
||||
.v-menubar-menuitem.v-menubar-menuitem-folders-pane-icon-active,
|
||||
.v-menubar-menuitem.v-menubar-menuitem-folders-pane-icon:hover,
|
||||
.v-menubar-menuitem.v-menubar-menuitem-folders-pane-icon-active:hover {
|
||||
padding-bottom: 5px;
|
||||
padding-top: 1px;
|
||||
width: 26px;
|
||||
height: 21px;
|
||||
border: 0;
|
||||
box-sizing: border-box;
|
||||
-webkit-box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
background-clip: border-box;
|
||||
background-origin: border-box;
|
||||
}
|
||||
|
||||
.v-menubar-menuitem.v-menubar-menuitem-folders-pane-icon-active,
|
||||
.v-menubar-menuitem.v-menubar-menuitem-folders-pane-icon-active:hover {
|
||||
border: 2px solid $theme_fieldFocusedBorderColor;
|
||||
}
|
||||
|
||||
.v-label.cuba-folders-pane-caption {
|
||||
|
BIN
modules/web/themes/havana/app/sprites/folders-pane-icon.png
Normal file
BIN
modules/web/themes/havana/app/sprites/folders-pane-icon.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 189 B |
@ -8,6 +8,7 @@
|
||||
// Version: $Id$
|
||||
|
||||
/** sprite: components; sprite-image: url('compiled/components.png'); sprite-layout: vertical */
|
||||
/** sprite: icons; sprite-image: url('compiled/icons.png'); sprite-layout: horizontal */
|
||||
|
||||
// Inherit base theme
|
||||
@import "../base/base";
|
||||
|
Binary file not shown.
Before Width: | Height: | Size: 255 B |
Binary file not shown.
Before Width: | Height: | Size: 278 B |
Loading…
Reference in New Issue
Block a user