IDEMPIERE-478 Zk: Theme. Added more css class, fixed hardcoded style.

This commit is contained in:
Heng Sin Low 2012-11-01 20:39:52 +08:00
parent 5665ebd487
commit caf21caf61
12 changed files with 112 additions and 7 deletions

View File

@ -202,7 +202,7 @@ DataStatusListener, IADTabpanel
form.setHflex("1");
form.setHeight(null);
form.setVflex(false);
form.setSclass("grid-layout");
form.setSclass("grid-layout adwindow-form");
listPanel = new GridView();
listPanel.getListbox().addEventListener(Events.ON_DOUBLE_CLICK, this);

View File

@ -128,7 +128,7 @@ public class BreadCrumb extends Div implements EventListener<Event>{
btnRecordInfo.setLabel("");
btnRecordInfo.setTooltiptext(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "Who")));
btnRecordInfo.addEventListener(Events.ON_CLICK, this);
btnRecordInfo.setSclass("breadcrumb-record-info");
btnRecordInfo.setSclass("breadcrumb-record-info link");
toolbar.appendChild(btnRecordInfo);
btnNext = createButton("Next", "Next", "Next");
toolbar.appendChild(btnNext);

View File

@ -172,7 +172,7 @@ public class DetailPane extends Panel implements EventListener<Event> {
}
Tabpanel tp = new Tabpanel();
tabpanels.appendChild(tp);
tp.setStyle("background-color: #fff");
tp.setSclass("adwindow-detailpane-tabpanel");
ToolBar toolbar = new ToolBar();
tp.appendChild(toolbar);
ToolBarButton button = new ToolBarButton();

View File

@ -58,6 +58,7 @@ public class DPActivities extends DashboardPanel implements EventListener<Event>
public DPActivities()
{
super();
this.setSclass("activities-box");
this.appendChild(createActivitiesPanel());
}

View File

@ -85,6 +85,7 @@ public class DPFavourites extends DashboardPanel implements EventListener<Event>
Panelchildren favContent = new Panelchildren();
panel.appendChild(favContent);
bxFav = new Vbox();
this.setSclass("favourites-box");
favContent.appendChild(bxFav);
createFavouritesPanel();

View File

@ -70,6 +70,7 @@ public class DPRecentItems extends DashboardPanel implements EventListener<Event
Panelchildren recentItemsContent = new Panelchildren();
panel.appendChild(recentItemsContent);
bxRecentItems = new Vbox();
this.setSclass("recentitems-box");
recentItemsContent.appendChild(bxRecentItems);
createRecentItemsPanel();

View File

@ -44,6 +44,7 @@ public class DPViews extends DashboardPanel implements EventListener {
public DPViews()
{
super();
setSclass("views-box");
this.appendChild(createViewPanel());
}
@ -54,6 +55,7 @@ public class DPViews extends DashboardPanel implements EventListener {
if (MRole.getDefault().isAllow_Info_Product())
{
ToolBarButton btnViewItem = new ToolBarButton("InfoProduct");
btnViewItem.setSclass("link");
btnViewItem.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "InfoProduct")));
btnViewItem.setImage("/images/InfoProduct16.png");
btnViewItem.addEventListener(Events.ON_CLICK, this);
@ -62,6 +64,7 @@ public class DPViews extends DashboardPanel implements EventListener {
if (MRole.getDefault().isAllow_Info_BPartner())
{
ToolBarButton btnViewItem = new ToolBarButton("InfoBPartner");
btnViewItem.setSclass("link");
btnViewItem.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "InfoBPartner")));
btnViewItem.setImage("/images/InfoBPartner16.png");
btnViewItem.addEventListener(Events.ON_CLICK, this);
@ -70,6 +73,7 @@ public class DPViews extends DashboardPanel implements EventListener {
if (MRole.getDefault().isShowAcct() && MRole.getDefault().isAllow_Info_Account())
{
ToolBarButton btnViewItem = new ToolBarButton("InfoAccount");
btnViewItem.setSclass("link");
btnViewItem.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "InfoAccount")));
btnViewItem.setImage("/images/InfoAccount16.png");
btnViewItem.addEventListener(Events.ON_CLICK, this);
@ -78,6 +82,7 @@ public class DPViews extends DashboardPanel implements EventListener {
if (MRole.getDefault().isAllow_Info_Schedule())
{
ToolBarButton btnViewItem = new ToolBarButton("InfoSchedule");
btnViewItem.setSclass("link");
btnViewItem.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "InfoSchedule")));
btnViewItem.setImage("/images/InfoSchedule16.png");
btnViewItem.addEventListener(Events.ON_CLICK, this);
@ -87,6 +92,7 @@ public class DPViews extends DashboardPanel implements EventListener {
if (MRole.getDefault().isAllow_Info_Order())
{
ToolBarButton btnViewItem = new ToolBarButton("InfoOrder");
btnViewItem.setSclass("link");
btnViewItem.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "InfoOrder")));
btnViewItem.setImage("/images/Info16.png");
btnViewItem.addEventListener(Events.ON_CLICK, this);
@ -95,6 +101,7 @@ public class DPViews extends DashboardPanel implements EventListener {
if (MRole.getDefault().isAllow_Info_Invoice())
{
ToolBarButton btnViewItem = new ToolBarButton("InfoInvoice");
btnViewItem.setSclass("link");
btnViewItem.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "InfoInvoice")));
btnViewItem.setImage("/images/Info16.png");
btnViewItem.addEventListener(Events.ON_CLICK, this);
@ -103,6 +110,7 @@ public class DPViews extends DashboardPanel implements EventListener {
if (MRole.getDefault().isAllow_Info_InOut())
{
ToolBarButton btnViewItem = new ToolBarButton("InfoInOut");
btnViewItem.setSclass("link");
btnViewItem.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "InfoInOut")));
btnViewItem.setImage("/images/Info16.png");
btnViewItem.addEventListener(Events.ON_CLICK, this);
@ -111,6 +119,7 @@ public class DPViews extends DashboardPanel implements EventListener {
if (MRole.getDefault().isAllow_Info_Payment())
{
ToolBarButton btnViewItem = new ToolBarButton("InfoPayment");
btnViewItem.setSclass("link");
btnViewItem.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "InfoPayment")));
btnViewItem.setImage("/images/Info16.png");
btnViewItem.addEventListener(Events.ON_CLICK, this);
@ -127,6 +136,7 @@ public class DPViews extends DashboardPanel implements EventListener {
if (MRole.getDefault().isAllow_Info_Resource())
{
ToolBarButton btnViewItem = new ToolBarButton("InfoAssignment");
btnViewItem.setSclass("link");
btnViewItem.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "InfoAssignment")));
btnViewItem.setImage("/images/Info16.png");
btnViewItem.addEventListener(Events.ON_CLICK, this);
@ -135,6 +145,7 @@ public class DPViews extends DashboardPanel implements EventListener {
if (MRole.getDefault().isAllow_Info_Asset())
{
ToolBarButton btnViewItem = new ToolBarButton("InfoAsset");
btnViewItem.setSclass("link");
btnViewItem.setLabel(Util.cleanAmp(Msg.getMsg(Env.getCtx(), "InfoAsset")));
btnViewItem.setImage("/images/Info16.png");
btnViewItem.addEventListener(Events.ON_CLICK, this);

View File

@ -69,7 +69,6 @@ public class HeaderPanel extends Panel implements EventListener<Event>
image = new Image(ThemeManager.getSmallLogo());
image.addEventListener(Events.ON_CLICK, this);
image.setStyle("cursor: pointer;");
image.setWidth("100px");
Borderlayout layout = new Borderlayout();
LayoutUtils.addSclass("desktop-header", layout);

View File

@ -124,6 +124,7 @@ public class LoginPanel extends Window implements EventListener<Event>
initComponents();
init();
this.setId("loginPanel");
this.setSclass("login-box");
txtUserId.setEnabled(false);
txtPassword.setEnabled(false);
@ -238,7 +239,7 @@ public class LoginPanel extends Window implements EventListener<Event>
div = new Div();
div.setSclass(ITheme.LOGIN_BOX_FOOTER_CLASS);
ConfirmPanel pnlButtons = new ConfirmPanel();
ConfirmPanel pnlButtons = new ConfirmPanel(false, false, false, false, false, false, true);
pnlButtons.addActionListener(this);
Button helpButton = pnlButtons.createButton(ConfirmPanel.A_HELP);

View File

@ -115,6 +115,7 @@ public class RolePanel extends Window implements EventListener, Deferrable
initComponents();
init();
this.setId("rolePanel");
this.setSclass("login-box");
if (m_show) {
AuFocus auf = null;
@ -222,7 +223,7 @@ public class RolePanel extends Window implements EventListener, Deferrable
div = new Div();
div.setSclass(ITheme.LOGIN_BOX_FOOTER_CLASS);
ConfirmPanel pnlButtons = new ConfirmPanel(true);
ConfirmPanel pnlButtons = new ConfirmPanel(true, false, false, false, false, false, true);
pnlButtons.addActionListener(this);
LayoutUtils.addSclass(ITheme.LOGIN_BOX_FOOTER_PANEL_CLASS, pnlButtons);
pnlButtons.setWidth(null);

View File

@ -78,14 +78,17 @@ public class UserPanel extends Vbox implements EventListener<Event>
lblUserNameValue.setValue(getUserName() + "@" + getClientName() + "." + getOrgName()+"/"+this.getRoleName());
lblUserNameValue.addEventListener(Events.ON_CLICK, this);
LayoutUtils.addSclass("desktop-header-font", lblUserNameValue);
LayoutUtils.addSclass("desktop-header-username", lblUserNameValue);
vbox.appendChild(lblUserNameValue);
Hbox hbox = new Hbox();
vbox.appendChild(hbox);
hbox.setAlign("center");
preference.setLabel(Msg.getMsg(Env.getCtx(), "Preference"));
preference.setLabel(Msg.getMsg(Env.getCtx(), "Preference"));
preference.addEventListener(Events.ON_CLICK, this);
LayoutUtils.addSclass("desktop-header-font", preference);
LayoutUtils.addSclass("link", preference);
preference.setParent(hbox);
Separator sep = new Separator("vertical");
@ -96,6 +99,7 @@ public class UserPanel extends Vbox implements EventListener<Event>
changeRole.setLabel(Msg.getMsg(Env.getCtx(), "changeRole"));
changeRole.addEventListener(Events.ON_CLICK, this);
LayoutUtils.addSclass("desktop-header-font", changeRole);
LayoutUtils.addSclass("link", changeRole);
changeRole.setParent(hbox);
sep = new Separator("vertical");
@ -106,6 +110,7 @@ public class UserPanel extends Vbox implements EventListener<Event>
logout.setLabel(Msg.getMsg(Env.getCtx(),"Logout"));
logout.addEventListener(Events.ON_CLICK, this);
LayoutUtils.addSclass("desktop-header-font", logout);
LayoutUtils.addSclass("link", logout);
logout.setParent(hbox);
}

View File

@ -126,14 +126,17 @@ html,body {
font-weight: normal;
color: #333 !important;
text-decoration: none !important;
padding-right: 4px;
}
.menu-href:hover, .menu-href:active {
text-decoration: underline !important;
color: blue !important;
}
.menu-href img {
padding: 2px;
padding-right: 4px;
}
.fav-new-btn {
@ -315,6 +318,23 @@ div.wc-modal, div.wc-modal-none, div.wc-highlighted, div.wc-highlighted-none {
.desktop-home-tabpanel {
background-color: #FFFFFF;
width: 99% !important;
}
.link.z-toolbarbutton-over {
border: none;
padding: 1px 0;
}
.link.z-toolbarbutton-over .z-toolbarbutton-body {
border: none;
padding: 0 1px;
}
.link.z-toolbarbutton-over .z-toolbarbutton-cnt {
background-image: none;
color: blue;
text-decoration: underline;
}
<%-- dashlet --%>
@ -383,6 +403,67 @@ div.wc-modal, div.wc-modal-none, div.wc-highlighted, div.wc-highlighted-none {
height: 90%;
}
.favourites-box {
width: 90%;
margin: auto;
padding: 5px 0px 5px 0px;
}
.favourites-box .z-vbox {
width: 100%;
}
.favourites-box .z-hbox {
padding: 2px 0px;
width: 100%;
}
.recentitems-box {
width: 90%;
margin: auto;
padding: 5px 0px 5px 0px;
}
.recentitems-box A {
display: block;
width: 100%;
padding: 2px 0px;
}
.views-box {
width: 90%;
margin: auto;
padding: 5px 0px 5px 0px;
}
.views-box .z-vbox {
width: 100%;
}
.views-box .z-toolbarbutton {
width: 100%;
padding: 2px 0px;
}
.activities-box {
width: 90%;
margin: auto;
padding: 5px 0px 5px 0px;
}
.activities-box .z-vbox {
width: 100%;
}
.activities-box .z-button .z-button-cm {
text-align: left;
}
.recentitems-box .z-toolbar, .favourites-box .z-toolbar {
margin-top: 5px;
margin-bottom: 5px;
}
<%-- adwindow and form --%>
.adwindow-layout {
position:absolute;
@ -428,6 +509,10 @@ div.wc-modal, div.wc-modal-none, div.wc-highlighted, div.wc-highlighted-none {
min-height: 200px; width: 100%; overflow-y: visible;
}
.adwindow-detailpane-tabpanel {
background-color: #fff
}
.adwindow-detailpane-toolbar {
border: none;
}