mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
Merged V2.1 to HEAD: 6706 Wizard pages more standards compliant
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@6790 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -80,16 +80,17 @@ public class UIActionLink extends UICommand
|
||||
*/
|
||||
public Object saveState(FacesContext context)
|
||||
{
|
||||
Object values[] = new Object[7];
|
||||
// standard component attributes are saved by the super class
|
||||
values[0] = super.saveState(context);
|
||||
values[1] = this.padding;
|
||||
values[2] = this.image;
|
||||
values[3] = this.showLink;
|
||||
values[4] = this.href;
|
||||
values[5] = this.tooltip;
|
||||
values[6] = this.target;
|
||||
return (values);
|
||||
return new Object[]
|
||||
{
|
||||
super.saveState(context),
|
||||
this.padding,
|
||||
this.image,
|
||||
this.showLink,
|
||||
this.href,
|
||||
this.tooltip,
|
||||
this.target
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -158,15 +159,7 @@ public class UIActionLink extends UICommand
|
||||
this.padding = (Integer)vb.getValue(getFacesContext());
|
||||
}
|
||||
|
||||
if (this.padding != null)
|
||||
{
|
||||
return this.padding.intValue();
|
||||
}
|
||||
else
|
||||
{
|
||||
// return default
|
||||
return 0;
|
||||
}
|
||||
return this.padding != null ? this.padding.intValue() : 0;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -54,7 +54,7 @@ public class UIMenu extends SelfRenderingComponent
|
||||
*/
|
||||
public void encodeBegin(FacesContext context) throws IOException
|
||||
{
|
||||
if (isRendered() == false)
|
||||
if (!isRendered())
|
||||
{
|
||||
return;
|
||||
}
|
||||
@@ -81,7 +81,7 @@ public class UIMenu extends SelfRenderingComponent
|
||||
// output image
|
||||
if (getAttributes().get("image") != null)
|
||||
{
|
||||
out.write(Utils.buildImageTag(context, (String)getAttributes().get("image"), null, "absmiddle"));
|
||||
out.write(Utils.buildImageTag(context, (String)getAttributes().get("image"), null, "middle"));
|
||||
}
|
||||
|
||||
out.write("</a>");
|
||||
@@ -92,7 +92,7 @@ public class UIMenu extends SelfRenderingComponent
|
||||
// NOTE: the use of "*width:0px" is an IE6/7 specific hack to ensure that the CSS is processed
|
||||
// only by IE (which needs the width value) and _not_ FireFox which doesn't...!
|
||||
out.write("' style=\"position:absolute;display:none;padding-left:2px;*width:0px\">");
|
||||
out.write("<table border=0 cellpadding=0");
|
||||
out.write("<table border='0' cellpadding='0'");
|
||||
outputAttribute(out, getAttributes().get("itemSpacing"), "cellspacing");
|
||||
outputAttribute(out, getAttributes().get("menuStyle"), "style");
|
||||
outputAttribute(out, getAttributes().get("menuStyleClass"), "class");
|
||||
@@ -104,7 +104,7 @@ public class UIMenu extends SelfRenderingComponent
|
||||
*/
|
||||
public void encodeEnd(FacesContext context) throws IOException
|
||||
{
|
||||
if (isRendered() == false)
|
||||
if (!isRendered())
|
||||
{
|
||||
return;
|
||||
}
|
||||
@@ -132,12 +132,7 @@ public class UIMenu extends SelfRenderingComponent
|
||||
*/
|
||||
public Object saveState(FacesContext context)
|
||||
{
|
||||
Object values[] = new Object[3];
|
||||
// standard component attributes are saved by the super class
|
||||
values[0] = super.saveState(context);
|
||||
values[1] = this.label;
|
||||
values[2] = this.tooltip;
|
||||
return values;
|
||||
return new Object[] { super.saveState(context), this.label, this.tooltip };
|
||||
}
|
||||
|
||||
|
||||
|
@@ -93,14 +93,14 @@ public class UIStatusMessage extends SelfRenderingComponent
|
||||
*/
|
||||
public Object saveState(FacesContext context)
|
||||
{
|
||||
Object values[] = new Object[5];
|
||||
// standard component attributes are saved by the super class
|
||||
values[0] = super.saveState(context);
|
||||
values[1] = this.border;
|
||||
values[2] = this.bgcolor;
|
||||
values[3] = this.messages;
|
||||
values[4] = Integer.valueOf(this.currentMessage);
|
||||
return values;
|
||||
return new Object[]
|
||||
{
|
||||
super.saveState(context),
|
||||
this.border,
|
||||
this.bgcolor,
|
||||
this.messages,
|
||||
Integer.valueOf(this.currentMessage)
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -108,7 +108,7 @@ public class UIStatusMessage extends SelfRenderingComponent
|
||||
*/
|
||||
public void encodeBegin(FacesContext context) throws IOException
|
||||
{
|
||||
if (isRendered() == false)
|
||||
if (!isRendered())
|
||||
{
|
||||
return;
|
||||
}
|
||||
@@ -131,12 +131,12 @@ public class UIStatusMessage extends SelfRenderingComponent
|
||||
}
|
||||
|
||||
// Previous Message icon image - clicking shows previous message
|
||||
out.write("<table width=100% cellspacing=0 cellpadding=0><tr><td>");
|
||||
out.write("<table style'width:100%;' cellspacing='0' cellpadding='0'><tr><td>");
|
||||
String field = getHiddenFieldName();
|
||||
String leftValue = getClientId(context) + NamingContainer.SEPARATOR_CHAR + Integer.toString(ACTION_PREVIOUS);
|
||||
String leftOnclick = Utils.generateFormSubmit(context, this, field, leftValue);
|
||||
out.write(Utils.buildImageTag(context, WebResources.IMAGE_MOVELEFT, 12, 12, null, leftOnclick, "absmiddle"));
|
||||
out.write("</td><td width=100% align=center>");
|
||||
out.write(Utils.buildImageTag(context, WebResources.IMAGE_MOVELEFT, 12, 12, null, leftOnclick, "middle"));
|
||||
out.write("</td><td style='width:100%;' align='center'>");
|
||||
|
||||
// get messages for the component and crop the stack to the maximum history size
|
||||
Iterator<FacesMessage> msgIterator = context.getMessages(STATUS_MESSAGE);
|
||||
@@ -166,7 +166,7 @@ public class UIStatusMessage extends SelfRenderingComponent
|
||||
style = CSS_WARNING;
|
||||
}
|
||||
|
||||
out.write(Utils.buildImageTag(context, icon, null, "absmiddle"));
|
||||
out.write(Utils.buildImageTag(context, icon, null, "middle"));
|
||||
out.write(" <span class='");
|
||||
out.write(style);
|
||||
out.write("'>");
|
||||
@@ -179,14 +179,14 @@ public class UIStatusMessage extends SelfRenderingComponent
|
||||
// Next Message icon image - clicking shows next message
|
||||
String rightValue = getClientId(context) + NamingContainer.SEPARATOR_CHAR + Integer.toString(ACTION_NEXT);
|
||||
String rightOnclick = Utils.generateFormSubmit(context, this, field, rightValue);
|
||||
out.write(Utils.buildImageTag(context, WebResources.IMAGE_MOVERIGHT, 12, 12, null, rightOnclick, "absmiddle"));
|
||||
out.write(Utils.buildImageTag(context, WebResources.IMAGE_MOVERIGHT, 12, 12, null, rightOnclick, "middle"));
|
||||
out.write("</td></tr></table>");
|
||||
|
||||
if (panel != null)
|
||||
{
|
||||
PanelGenerator.generatePanelEnd(out,
|
||||
context.getExternalContext().getRequestContextPath(),
|
||||
panel);
|
||||
context.getExternalContext().getRequestContextPath(),
|
||||
panel);
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user