summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorArtur Signell <artur.signell@itmill.com>2011-03-25 07:45:51 +0000
committerArtur Signell <artur.signell@itmill.com>2011-03-25 07:45:51 +0000
commit66f7282862aeddd9a0eb37bb1a522fdd501ff649 (patch)
tree5f6f376489edd9c37bfa386cd8c1fa93fcb572fd
parent8ac824d4891b3db91ab3be14507e68a03a82eeea (diff)
downloadvaadin-framework-66f7282862aeddd9a0eb37bb1a522fdd501ff649.tar.gz
vaadin-framework-66f7282862aeddd9a0eb37bb1a522fdd501ff649.zip
Merged bugfixes and test updates from 6.5
svn changeset:17929/svn branch:6.6
-rw-r--r--WebContent/VAADIN/themes/base/common/common.css2
-rw-r--r--WebContent/VAADIN/themes/base/styles.css6
-rw-r--r--WebContent/VAADIN/themes/liferay/styles.css6
-rw-r--r--WebContent/VAADIN/themes/reindeer/styles.css6
-rw-r--r--WebContent/VAADIN/themes/runo/styles.css6
-rw-r--r--src/com/vaadin/terminal/gwt/client/ui/VTree.java31
-rw-r--r--src/com/vaadin/terminal/gwt/client/ui/VView.java11
-rw-r--r--src/com/vaadin/terminal/gwt/server/AbstractApplicationPortlet.java7
-rw-r--r--src/com/vaadin/terminal/gwt/server/AbstractApplicationServlet.java6
-rw-r--r--tests/src/com/vaadin/tests/components/table/Footer.html132
-rw-r--r--tests/src/com/vaadin/tests/components/tree/TreeWithIcons.html62
-rw-r--r--tests/src/com/vaadin/tests/components/tree/TreeWithIcons.java69
-rw-r--r--tests/test.xml2
13 files changed, 197 insertions, 149 deletions
diff --git a/WebContent/VAADIN/themes/base/common/common.css b/WebContent/VAADIN/themes/base/common/common.css
index 4e0747538c..27bc57dd00 100644
--- a/WebContent/VAADIN/themes/base/common/common.css
+++ b/WebContent/VAADIN/themes/base/common/common.css
@@ -23,6 +23,8 @@ div.v-app-loading {
background-image: url(img/loading-indicator.gif);
background-repeat: no-repeat;
background-position: 50%;
+ width: 100%;
+ height: 100%;
}
.v-view {
height: 100%;
diff --git a/WebContent/VAADIN/themes/base/styles.css b/WebContent/VAADIN/themes/base/styles.css
index 0d5e79acbf..875df0b097 100644
--- a/WebContent/VAADIN/themes/base/styles.css
+++ b/WebContent/VAADIN/themes/base/styles.css
@@ -1,5 +1,5 @@
-.v-theme-version:after {content:"6_5_2_dev-20110303";}
-.v-theme-version-6_5_2_dev-20110303 {display: none;}
+.v-theme-version:after {content:"6_5_4_dev-20110324";}
+.v-theme-version-6_5_4_dev-20110324 {display: none;}
/* Automatically compiled css file from subdirectories. */
.v-absolutelayout-wrapper {
@@ -276,6 +276,8 @@ div.v-app-loading {
background-image: url(common/img/loading-indicator.gif);
background-repeat: no-repeat;
background-position: 50%;
+ width: 100%;
+ height: 100%;
}
.v-view {
height: 100%;
diff --git a/WebContent/VAADIN/themes/liferay/styles.css b/WebContent/VAADIN/themes/liferay/styles.css
index 115119e797..4dbf9aafff 100644
--- a/WebContent/VAADIN/themes/liferay/styles.css
+++ b/WebContent/VAADIN/themes/liferay/styles.css
@@ -1,5 +1,5 @@
-.v-theme-version:after {content:"6_5_2_dev-20110303";}
-.v-theme-version-6_5_2_dev-20110303 {display: none;}
+.v-theme-version:after {content:"6_5_4_dev-20110324";}
+.v-theme-version-6_5_4_dev-20110324 {display: none;}
/* Automatically compiled css file from subdirectories. */
.v-absolutelayout-wrapper {
@@ -276,6 +276,8 @@ div.v-app-loading {
background-image: url(../base/common/img/loading-indicator.gif);
background-repeat: no-repeat;
background-position: 50%;
+ width: 100%;
+ height: 100%;
}
.v-view {
height: 100%;
diff --git a/WebContent/VAADIN/themes/reindeer/styles.css b/WebContent/VAADIN/themes/reindeer/styles.css
index b0c54c8ec4..e960a6abea 100644
--- a/WebContent/VAADIN/themes/reindeer/styles.css
+++ b/WebContent/VAADIN/themes/reindeer/styles.css
@@ -1,5 +1,5 @@
-.v-theme-version:after {content:"6_5_2_dev-20110303";}
-.v-theme-version-6_5_2_dev-20110303 {display: none;}
+.v-theme-version:after {content:"6_5_4_dev-20110324";}
+.v-theme-version-6_5_4_dev-20110324 {display: none;}
/* Automatically compiled css file from subdirectories. */
.v-absolutelayout-wrapper {
@@ -276,6 +276,8 @@ div.v-app-loading {
background-image: url(../base/common/img/loading-indicator.gif);
background-repeat: no-repeat;
background-position: 50%;
+ width: 100%;
+ height: 100%;
}
.v-view {
height: 100%;
diff --git a/WebContent/VAADIN/themes/runo/styles.css b/WebContent/VAADIN/themes/runo/styles.css
index 120c4daa53..326f0525cf 100644
--- a/WebContent/VAADIN/themes/runo/styles.css
+++ b/WebContent/VAADIN/themes/runo/styles.css
@@ -1,5 +1,5 @@
-.v-theme-version:after {content:"6_5_2_dev-20110303";}
-.v-theme-version-6_5_2_dev-20110303 {display: none;}
+.v-theme-version:after {content:"6_5_4_dev-20110324";}
+.v-theme-version-6_5_4_dev-20110324 {display: none;}
/* Automatically compiled css file from subdirectories. */
.v-absolutelayout-wrapper {
@@ -276,6 +276,8 @@ div.v-app-loading {
background-image: url(../base/common/img/loading-indicator.gif);
background-repeat: no-repeat;
background-position: 50%;
+ width: 100%;
+ height: 100%;
}
.v-view {
height: 100%;
diff --git a/src/com/vaadin/terminal/gwt/client/ui/VTree.java b/src/com/vaadin/terminal/gwt/client/ui/VTree.java
index 305b0c3ebe..71e4b1ec03 100644
--- a/src/com/vaadin/terminal/gwt/client/ui/VTree.java
+++ b/src/com/vaadin/terminal/gwt/client/ui/VTree.java
@@ -103,6 +103,15 @@ public class VTree extends SimpleFocusablePanel implements Paintable,
private boolean selectionHasChanged = false;
+ public VLazyExecutor iconLoaded = new VLazyExecutor(50,
+ new ScheduledCommand() {
+
+ public void execute() {
+ Util.notifyParentOfSizeChange(VTree.this, true);
+ }
+
+ });
+
public VTree() {
super();
setStyleName(CLASSNAME);
@@ -514,6 +523,11 @@ public class VTree extends SimpleFocusablePanel implements Paintable,
private boolean focused = false;
+ /**
+ * Track onload events as IE6 sends two
+ */
+ private boolean onloadHandled = false;
+
public TreeNode() {
constructDom();
sinkEvents(Event.ONCLICK | Event.ONDBLCLICK | Event.MOUSEEVENTS
@@ -684,11 +698,23 @@ public class VTree extends SimpleFocusablePanel implements Paintable,
@Override
public void onBrowserEvent(Event event) {
super.onBrowserEvent(event);
+ final int type = DOM.eventGetType(event);
+ final Element target = DOM.eventGetTarget(event);
+
+ if (type == Event.ONLOAD && target == icon.getElement()) {
+ if (onloadHandled) {
+ return;
+ }
+ if (BrowserInfo.get().isIE6()) {
+ fixWidth();
+ }
+ iconLoaded.trigger();
+ onloadHandled = true;
+ }
+
if (disabled) {
return;
}
- final int type = DOM.eventGetType(event);
- final Element target = DOM.eventGetTarget(event);
final boolean inCaption = target == nodeCaptionSpan
|| (icon != null && target == icon.getElement());
if (inCaption
@@ -891,6 +917,7 @@ public class VTree extends SimpleFocusablePanel implements Paintable,
if (uidl.hasAttribute("icon")) {
if (icon == null) {
+ onloadHandled = false;
icon = new Icon(client);
DOM.insertBefore(DOM.getFirstChild(nodeCaptionDiv),
icon.getElement(), nodeCaptionSpan);
diff --git a/src/com/vaadin/terminal/gwt/client/ui/VView.java b/src/com/vaadin/terminal/gwt/client/ui/VView.java
index 5d7cc18945..b2be2a6daf 100644
--- a/src/com/vaadin/terminal/gwt/client/ui/VView.java
+++ b/src/com/vaadin/terminal/gwt/client/ui/VView.java
@@ -675,9 +675,16 @@ public class VView extends SimplePanel implements Container, ResizeHandler,
DOM.setElementProperty(getElement(), "tabIndex", "1");
RootPanel root = RootPanel.get(rootPanelId);
- root.add(this);
+
+ // Remove the v-app-loading or any splash screen added inside the div by
+ // the user
+ root.getElement().setInnerHTML("");
+ // For backwards compatibility with static index pages only.
+ // No longer added by AbstractApplicationServlet/Portlet
root.removeStyleName("v-app-loading");
+ root.add(this);
+
BrowserInfo browser = BrowserInfo.get();
// set focus to iview element by default to listen possible keyboard
@@ -708,7 +715,7 @@ public class VView extends SimplePanel implements Container, ResizeHandler,
}
public void focus() {
- getElement().focus();
+ getElement().focus();
}
}
diff --git a/src/com/vaadin/terminal/gwt/server/AbstractApplicationPortlet.java b/src/com/vaadin/terminal/gwt/server/AbstractApplicationPortlet.java
index 4f93afff56..e64cd6f243 100644
--- a/src/com/vaadin/terminal/gwt/server/AbstractApplicationPortlet.java
+++ b/src/com/vaadin/terminal/gwt/server/AbstractApplicationPortlet.java
@@ -926,8 +926,7 @@ public abstract class AbstractApplicationPortlet extends GenericPortlet
String themeClass = "v-theme-"
+ themeName.replaceAll("[^a-zA-Z0-9]", "");
- String classNames = "v-app v-app-loading " + themeClass + " "
- + appClass;
+ String classNames = "v-app " + themeClass + " " + appClass;
String style = getApplicationProperty(PORTLET_PARAMETER_STYLE);
String divStyle = "";
@@ -1225,7 +1224,9 @@ public abstract class AbstractApplicationPortlet extends GenericPortlet
RenderResponse response, final BufferedWriter writer, String id,
String classNames, String divStyle) throws IOException {
writer.write("<div id=\"" + id + "\" class=\"" + classNames + "\" "
- + divStyle + "></div>\n");
+ + divStyle + ">");
+ writer.write("<div class=\"v-app-loading\"></div>");
+ writer.write("</div>\n");
writer.write("<noscript>" + getNoScriptMessage() + "</noscript>");
}
diff --git a/src/com/vaadin/terminal/gwt/server/AbstractApplicationServlet.java b/src/com/vaadin/terminal/gwt/server/AbstractApplicationServlet.java
index 36dd30e364..a9e5f2c827 100644
--- a/src/com/vaadin/terminal/gwt/server/AbstractApplicationServlet.java
+++ b/src/com/vaadin/terminal/gwt/server/AbstractApplicationServlet.java
@@ -1660,7 +1660,7 @@ public abstract class AbstractApplicationServlet extends HttpServlet implements
+ getDefaultTheme().replaceAll("[^a-zA-Z0-9]", "");
}
- String classNames = "v-app v-app-loading " + themeClass + " "
+ String classNames = "v-app " + themeClass + " "
+ appClass;
String divStyle = null;
@@ -1744,7 +1744,9 @@ public abstract class AbstractApplicationServlet extends HttpServlet implements
String appId, String classNames, String divStyle, HttpServletRequest request)
throws IOException {
page.write("<div id=\"" + appId + "\" class=\"" + classNames + "\" "
- + (divStyle != null ? divStyle : "") + "></div>\n");
+ + (divStyle != null ? divStyle : "") + ">");
+ page.write("<div class=\"v-app-loading\"></div>");
+ page.write("</div>\n");
page.write("<noscript>" + getNoScriptMessage() + "</noscript>");
}
diff --git a/tests/src/com/vaadin/tests/components/table/Footer.html b/tests/src/com/vaadin/tests/components/table/Footer.html
index d933e6472f..dbbdef2f9c 100644
--- a/tests/src/com/vaadin/tests/components/table/Footer.html
+++ b/tests/src/com/vaadin/tests/components/table/Footer.html
@@ -22,11 +22,6 @@
<td>926,229</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>screenCapture</td>
<td></td>
<td>initial</td>
@@ -47,21 +42,11 @@
<td>Footer3</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>mouseClick</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VCheckBox[0]/domChild[0]</td>
<td>11,8</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>screenCapture</td>
<td></td>
<td>no-footer</td>
@@ -72,11 +57,6 @@
<td>6,8</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>screenCapture</td>
<td></td>
<td>footer-col1-col2-col3-a</td>
@@ -102,21 +82,11 @@
<td>9,10</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>mouseClick</td>
- <td>//td[@id='gwt-uid-3']/span/div</td>
+ <td>vaadin=runcomvaadintestscomponentstableFooter::Root/VContextMenu[0]#option1</td>
<td>0,9</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>screenCapture</td>
<td></td>
<td>footer-col1-col3</td>
@@ -127,21 +97,11 @@
<td>12,13</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>mouseClick</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VContextMenu[0]#option1</td>
<td>10,7</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>screenCapture</td>
<td></td>
<td>footer-col1-col2-col3-b</td>
@@ -152,31 +112,16 @@
<td>-45,13</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>enterCharacter</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[1]/VHorizontalLayout[0]/ChildComponentContainer[0]/VTextField[0]</td>
<td>fuu</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>click</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[1]/VHorizontalLayout[0]/ChildComponentContainer[1]/VButton[0]/domChild[0]/domChild[0]</td>
<td></td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>assertText</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[0]/VScrollTable[0]/domChild[2]/domChild[0]/domChild[0]/domChild[0]/domChild[0]/domChild[0]/domChild[0]/domChild[0]</td>
<td>fuu</td>
@@ -187,31 +132,16 @@
<td>-61,2</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>enterCharacter</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[2]/VHorizontalLayout[0]/ChildComponentContainer[0]/VTextField[0]</td>
<td>bar</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>click</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[2]/VHorizontalLayout[0]/ChildComponentContainer[1]/VButton[0]/domChild[0]/domChild[0]</td>
<td></td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>assertText</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[0]/VScrollTable[0]/domChild[2]/domChild[0]/domChild[0]/domChild[0]/domChild[0]/domChild[0]/domChild[1]/domChild[0]</td>
<td>bar</td>
@@ -222,31 +152,16 @@
<td>-21,9</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>type</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[3]/VHorizontalLayout[0]/ChildComponentContainer[0]/VTextField[0]</td>
<td></td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>click</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[3]/VHorizontalLayout[0]/ChildComponentContainer[1]/VButton[0]/domChild[0]/domChild[0]</td>
<td></td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>assertText</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[0]/VScrollTable[0]/domChild[2]/domChild[0]/domChild[0]/domChild[0]/domChild[0]/domChild[0]/domChild[2]</td>
<td></td>
@@ -257,91 +172,46 @@
<td>-18,9</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>enterCharacter</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[1]/VHorizontalLayout[0]/ChildComponentContainer[0]/VTextField[0]</td>
<td>Footer1</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>mouseClick</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[2]/VHorizontalLayout[0]/ChildComponentContainer[0]/VTextField[0]</td>
<td>-56,-4</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>enterCharacter</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[2]/VHorizontalLayout[0]/ChildComponentContainer[0]/VTextField[0]</td>
<td>Footer2</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>mouseClick</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[3]/VHorizontalLayout[0]/ChildComponentContainer[0]/VTextField[0]</td>
<td>124,17</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>enterCharacter</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[3]/VHorizontalLayout[0]/ChildComponentContainer[0]/VTextField[0]</td>
<td>Footer3</td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>click</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[1]/VHorizontalLayout[0]/ChildComponentContainer[1]/VButton[0]/domChild[0]/domChild[0]</td>
<td></td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>click</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[2]/VHorizontalLayout[0]/ChildComponentContainer[1]/VButton[0]/domChild[0]/domChild[0]</td>
<td></td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>click</td>
<td>vaadin=runcomvaadintestscomponentstableFooter::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VHorizontalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[3]/VHorizontalLayout[0]/ChildComponentContainer[1]/VButton[0]/domChild[0]/domChild[0]</td>
<td></td>
</tr>
<tr>
- <td>waitForVaadin</td>
- <td></td>
- <td></td>
-</tr>
-<tr>
<td>screenCapture</td>
<td></td>
<td>footer-col1-col2-col3-c</td>
diff --git a/tests/src/com/vaadin/tests/components/tree/TreeWithIcons.html b/tests/src/com/vaadin/tests/components/tree/TreeWithIcons.html
new file mode 100644
index 0000000000..0b01807054
--- /dev/null
+++ b/tests/src/com/vaadin/tests/components/tree/TreeWithIcons.html
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head profile="http://selenium-ide.openqa.org/profiles/test-case">
+<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
+<link rel="selenium.base" href="" />
+<title>New Test</title>
+</head>
+<body>
+<table cellpadding="1" cellspacing="1" border="1">
+<thead>
+<tr><td rowspan="1" colspan="3">New Test</td></tr>
+</thead><tbody>
+<tr>
+ <td>open</td>
+ <td>/run/com.vaadin.tests.components.tree.TreeWithIcons?restartApplication</td>
+ <td></td>
+</tr>
+<tr>
+ <td>pause</td>
+ <td>100</td>
+ <td></td>
+</tr>
+<tr>
+ <td>screenCapture</td>
+ <td></td>
+ <td>large-icon</td>
+</tr>
+<tr>
+ <td>mouseClick</td>
+ <td>vaadin=runcomvaadintestscomponentstreeTreeWithIcons::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VPanel[0]/VHorizontalLayout[0]/ChildComponentContainer[0]/VTree[0]#n[0]/expand</td>
+ <td>9,6</td>
+</tr>
+<tr>
+ <td>pause</td>
+ <td>100</td>
+ <td></td>
+</tr>
+<tr>
+ <td>screenCapture</td>
+ <td></td>
+ <td>two-large-icons</td>
+</tr>
+<tr>
+ <td>mouseClick</td>
+ <td>vaadin=runcomvaadintestscomponentstreeTreeWithIcons::/VVerticalLayout[0]/ChildComponentContainer[1]/VVerticalLayout[0]/ChildComponentContainer[0]/VPanel[0]/VHorizontalLayout[0]/ChildComponentContainer[0]/VTree[0]#n[1]/expand</td>
+ <td>8,9</td>
+</tr>
+<tr>
+ <td>pause</td>
+ <td>100</td>
+ <td></td>
+</tr>
+<tr>
+ <td>screenCapture</td>
+ <td></td>
+ <td>huge-and-two-large-icons</td>
+</tr>
+
+</tbody></table>
+</body>
+</html>
diff --git a/tests/src/com/vaadin/tests/components/tree/TreeWithIcons.java b/tests/src/com/vaadin/tests/components/tree/TreeWithIcons.java
new file mode 100644
index 0000000000..fbf4a3c1d1
--- /dev/null
+++ b/tests/src/com/vaadin/tests/components/tree/TreeWithIcons.java
@@ -0,0 +1,69 @@
+package com.vaadin.tests.components.tree;
+
+import java.util.Date;
+
+import com.vaadin.terminal.Sizeable;
+import com.vaadin.terminal.ThemeResource;
+import com.vaadin.tests.components.TestBase;
+import com.vaadin.tests.util.LoremIpsum;
+import com.vaadin.ui.HorizontalLayout;
+import com.vaadin.ui.Panel;
+import com.vaadin.ui.Tree;
+import com.vaadin.ui.themes.Reindeer;
+
+public class TreeWithIcons extends TestBase {
+
+ @Override
+ protected void setup() {
+ ThemeResource notCachedFolderIconHuge = new ThemeResource(
+ "../runo/icons/64/folder.png?" + new Date().getTime());
+ ThemeResource notCachedFolderIconLarge = new ThemeResource(
+ "../runo/icons/32/folder.png?" + new Date().getTime());
+ ThemeResource notCachedFolderIconLargeOther = new ThemeResource(
+ "../runo/icons/32/ok.png?" + new Date().getTime());
+ Tree t = new Tree();
+ t.setImmediate(true);
+
+ t.addItem("Root 1");
+ t.addItem("Root 11");
+ t.addItem("Root 111");
+ t.addItem("Root 1111");
+ t.addItem("Sub 1");
+ t.setItemIcon("Sub 1", notCachedFolderIconLargeOther);
+ t.setParent("Sub 1", "Root 1");
+ String longItemId = LoremIpsum.get(50);
+ t.addItem(longItemId);
+ t.setItemIcon(longItemId, notCachedFolderIconHuge);
+ t.setParent(longItemId, "Root 11");
+ t.addItem("abcdefghijklmn");
+
+ String first = "abcdefghijklmnop";
+ String second = "abcdefghijklmnopqrst";
+ t.addItem(first);
+ t.addItem(second);
+ t.setParent(second, first);
+ t.setItemIcon(first, notCachedFolderIconLarge);
+
+ HorizontalLayout hlay = new HorizontalLayout();
+ hlay.setStyleName(Reindeer.LAYOUT_BLUE);
+ hlay.addComponent(t);
+ hlay.setWidth(-1, Sizeable.UNITS_PIXELS);
+
+ Panel p = new Panel();
+ p.setSizeUndefined();
+ p.setContent(hlay);
+
+ addComponent(p);
+ }
+
+ @Override
+ protected String getDescription() {
+ return "A tree with icons should resize itself correctly so the nodes are not cut either horizontally or vertically.";
+ }
+
+ @Override
+ protected Integer getTicketNumber() {
+ return 3529;
+ }
+
+} \ No newline at end of file
diff --git a/tests/test.xml b/tests/test.xml
index c7ee860840..d35d7c8980 100644
--- a/tests/test.xml
+++ b/tests/test.xml
@@ -5,7 +5,7 @@
<!-- Configuration -->
<!-- ================================================================== -->
<!-- Browsers to use for testing -->
- <property name="browsers-windows" value="winxp-ie6,winxp-ie7,winxp-ie8,winxp-firefox36,winxp-safari4,winxp-safari5,winxp-googlechrome-stable,winxp-opera1060,winxp-opera11" />
+ <property name="browsers-windows" value="winxp-ie6,winxp-ie7,winxp-ie8,win7-ie9,winxp-firefox36,winxp-firefox4,winxp-safari4,winxp-safari5,winxp-googlechrome-stable,winxp-opera1060,winxp-opera11" />
<property name="browsers-linux" value="linux-firefox3,linux-opera10,linux-googlechrome8" />
<property name="browsers-mac" value="osx-firefox3,osx-opera10,osx-googlechrome8,osx-safari4,osx-safari5" />