diff options
author | Marc Englund <marc.englund@itmill.com> | 2009-05-12 13:08:56 +0000 |
---|---|---|
committer | Marc Englund <marc.englund@itmill.com> | 2009-05-12 13:08:56 +0000 |
commit | 03c3e6adb59d3480564b9d541fdf65ceb0089ed0 (patch) | |
tree | 8b74050537aa5ab6f12374028a83e517b913b44f /src | |
parent | 01f5470edb4c6e23e5c62e9a826116beea0b37ae (diff) | |
download | vaadin-framework-03c3e6adb59d3480564b9d541fdf65ceb0089ed0.tar.gz vaadin-framework-03c3e6adb59d3480564b9d541fdf65ceb0089ed0.zip |
Renaming ITMILL/ -> VAADIN/ part 2 (for #2904)
svn changeset:7765/svn branch:6.0
Diffstat (limited to 'src')
12 files changed, 81 insertions, 85 deletions
diff --git a/src/com/vaadin/automatedtests/featurebrowser/JavaScriptAPIExample.java b/src/com/vaadin/automatedtests/featurebrowser/JavaScriptAPIExample.java index d902eb8323..5956db9853 100644 --- a/src/com/vaadin/automatedtests/featurebrowser/JavaScriptAPIExample.java +++ b/src/com/vaadin/automatedtests/featurebrowser/JavaScriptAPIExample.java @@ -22,7 +22,7 @@ import com.vaadin.ui.Button.ClickEvent; */
public class JavaScriptAPIExample extends CustomComponent {
- public static final String txt = "<p>For advanced client side programmers Toolkit offers a simple method which can be used to force sync client with server. This may be needed for example if another part of a mashup changes things on server.</p> (more examples will be added here as the APIs are made public)<br/><br/><A href=\"javascript:itmill.forceSync();\">javascript:itmill.forceSync();</A>";
+ public static final String txt = "<p>For advanced client side programmers Toolkit offers a simple method which can be used to force sync client with server. This may be needed for example if another part of a mashup changes things on server.</p> (more examples will be added here as the APIs are made public)<br/><br/><A href=\"javascript:vaadin.forceSync();\">javascript:itmill.forceSync();</A>";
private final VerticalLayout main;
private final Label l;
@@ -61,7 +61,7 @@ public class JavaScriptAPIExample extends CustomComponent { Label l = new Label(
"This label will update it's server-side value AFTER it's rendered to the client-side. "
+ "The client will be synchronized on reload, when you click a button, "
- + "or when itmill.forceSync() is called.") {
+ + "or when vaadin.forceSync() is called.") {
@Override
public void paintContent(PaintTarget target) throws PaintException {
diff --git a/src/com/vaadin/demo/coverflow/gwt/client/ui/VCoverflow.java b/src/com/vaadin/demo/coverflow/gwt/client/ui/VCoverflow.java index a09c9b1865..ad92de3d83 100644 --- a/src/com/vaadin/demo/coverflow/gwt/client/ui/VCoverflow.java +++ b/src/com/vaadin/demo/coverflow/gwt/client/ui/VCoverflow.java @@ -1,7 +1,7 @@ /* @ITMillApache2LicenseForJavaFiles@ */ - + package com.vaadin.demo.coverflow.gwt.client.ui; import java.util.ArrayList; @@ -201,23 +201,23 @@ public class VCoverflow extends Composite implements Paintable { * id */ public native void initializeMethods(String id) /*-{ - var app = this; - - if($wnd.itmill.coverflow == null) - var coverflow = []; - else - var coverflow = $wnd.itmill.coverflow; - - coverflow['getCovers_' + id] = function() { - app.@com.vaadin.demo.coverflow.gwt.client.ui.VCoverflow::getCovers()(); - }; - - coverflow['setCurrent_' + id] = function(selected) { - app.@com.vaadin.demo.coverflow.gwt.client.ui.VCoverflow::setCover(Ljava/lang/String;)(selected); - }; - - $wnd.itmill.coverflow = coverflow; - }-*/; + var app = this; + + if($wnd.vaadin.coverflow == null) + var coverflow = []; + else + var coverflow = $wnd.vaadin.coverflow; + + coverflow['getCovers_' + id] = function() { + app.@com.vaadin.demo.coverflow.gwt.client.ui.VCoverflow::getCovers()(); + }; + + coverflow['setCurrent_' + id] = function(selected) { + app.@com.vaadin.demo.coverflow.gwt.client.ui.VCoverflow::setCover(Ljava/lang/String;)(selected); + }; + + $wnd.vaadin.coverflow = coverflow; + }-*/; /** * This function sends all covers to the flash. We cannot do this directly @@ -259,14 +259,14 @@ public class VCoverflow extends Composite implements Paintable { * @param icon */ public native void addCover(String id, String caption, String icon) /*-{ - try { - $doc['fxcoverflow' + id].addCover(caption.toString(), icon.toString()); - } - catch(e) { - $wnd.alert(e.message); - } - - }-*/; + try { + $doc['fxcoverflow' + id].addCover(caption.toString(), icon.toString()); + } + catch(e) { + $wnd.alert(e.message); + } + + }-*/; /** * This function tells the flash which cover should be selected. @@ -275,21 +275,21 @@ public class VCoverflow extends Composite implements Paintable { * @param key */ public native void selectCover(String id, String key) /*-{ - $doc["fxcoverflow" + id].selectCover(key.toString()); - }-*/; + $doc["fxcoverflow" + id].selectCover(key.toString()); + }-*/; public native void setBackgroundColor(String id, String startGradient, String endGradient) /*-{ - $doc["fxcoverflow" + id].setBackgroundColor("0x" + startGradient.toString(), "0x" + endGradient.toString()); - }-*/; + $doc["fxcoverflow" + id].setBackgroundColor("0x" + startGradient.toString(), "0x" + endGradient.toString()); + }-*/; public native void toggleScrollbarVisibility(String id, boolean visibility) /*-{ - $doc["fxcoverflow" + id].toggleScrollbarVisibility(visibility); - }-*/; + $doc["fxcoverflow" + id].toggleScrollbarVisibility(visibility); + }-*/; public native void removeCover(String id, String key) /*-{ - $doc["fxcoverflow" + id].removeCover(key); - }-*/; + $doc["fxcoverflow" + id].removeCover(key); + }-*/; /** * Set the HTML coding of the flash movie. This isn't done until the diff --git a/src/com/vaadin/demo/coverflow/gwt/flex/Coverflow.as b/src/com/vaadin/demo/coverflow/gwt/flex/Coverflow.as index 38d924b7dd..130556a894 100644 --- a/src/com/vaadin/demo/coverflow/gwt/flex/Coverflow.as +++ b/src/com/vaadin/demo/coverflow/gwt/flex/Coverflow.as @@ -99,7 +99,7 @@ package { // that the flash is now ready to accept information of the covers. // The name of the function we're about to call is dynamic, meaning // it is unique for every instance of this widget - ExternalInterface.call("itmill.coverflow['getCovers_" + _pid + "']"); + ExternalInterface.call("vaadin.coverflow['getCovers_" + _pid + "']"); } catch (error:SecurityError) { Alert.show("A SecurityError occurred: " + error.message + "\n"); } catch (error:Error) { @@ -418,7 +418,7 @@ package { // the animation has finished), then send the selected cover's // key to GWT which will then forward it to the server. if (ExternalInterface.available && i == _selected) { - ExternalInterface.call("itmill.coverflow['setCurrent_" + _pid + "']",_coverList[_selected].caption); + ExternalInterface.call("vaadin.coverflow['setCurrent_" + _pid + "']",_coverList[_selected].caption); // Send an event which notifies the scrollbar that the selected cover has changed. _eventHandler.dispatchEvent(new Event(EventHandler.CURRENT_CHANGED)); diff --git a/src/com/vaadin/demo/featurebrowser/JavaScriptAPIExample.java b/src/com/vaadin/demo/featurebrowser/JavaScriptAPIExample.java index 4656263163..42f07648d6 100644 --- a/src/com/vaadin/demo/featurebrowser/JavaScriptAPIExample.java +++ b/src/com/vaadin/demo/featurebrowser/JavaScriptAPIExample.java @@ -22,7 +22,7 @@ import com.vaadin.ui.Button.ClickEvent; */
public class JavaScriptAPIExample extends CustomComponent {
- public static final String txt = "<p>For advanced client side programmers Toolkit offers a simple method which can be used to force sync client with server. This may be needed for example if another part of a mashup changes things on server.</p> (more examples will be added here as the APIs are made public)<br/><br/><A href=\"javascript:itmill.forceSync();\">javascript:itmill.forceSync();</A>";
+ public static final String txt = "<p>For advanced client side programmers Toolkit offers a simple method which can be used to force sync client with server. This may be needed for example if another part of a mashup changes things on server.</p> (more examples will be added here as the APIs are made public)<br/><br/><A href=\"javascript:vaadin.forceSync();\">javascript:itmill.forceSync();</A>";
private final VerticalLayout main;
private final Label l;
@@ -61,7 +61,7 @@ public class JavaScriptAPIExample extends CustomComponent { Label l = new Label(
"This label will update it's server-side value AFTER it's rendered to the client-side. "
+ "The client will be synchronized on reload, when you click a button, "
- + "or when itmill.forceSync() is called.") {
+ + "or when vaadin.forceSync() is called.") {
@Override
public void paintContent(PaintTarget target) throws PaintException {
diff --git a/src/com/vaadin/terminal/gwt/client/ApplicationConfiguration.java b/src/com/vaadin/terminal/gwt/client/ApplicationConfiguration.java index 564a87445e..e27283258a 100644 --- a/src/com/vaadin/terminal/gwt/client/ApplicationConfiguration.java +++ b/src/com/vaadin/terminal/gwt/client/ApplicationConfiguration.java @@ -74,8 +74,8 @@ public class ApplicationConfiguration { /*-{ var id = this.@com.vaadin.terminal.gwt.client.ApplicationConfiguration::id; - if($wnd.itmill.toolkitConfigurations && $wnd.itmill.toolkitConfigurations[id]) { - var jsobj = $wnd.itmill.toolkitConfigurations[id]; + if($wnd.vaadin.toolkitConfigurations && $wnd.vaadin.toolkitConfigurations[id]) { + var jsobj = $wnd.vaadin.toolkitConfigurations[id]; var uri = jsobj.appUri; if(uri[uri.length -1] != "/") { uri = uri + "/"; @@ -173,7 +173,7 @@ public class ApplicationConfiguration { private native static void loadAppIdListFromDOM(ArrayList<String> list) /*-{ var j; - for(j in $wnd.itmill.toolkitConfigurations) { + for(j in $wnd.vaadin.toolkitConfigurations) { list.@java.util.Collection::add(Ljava/lang/Object;)(j); } }-*/; diff --git a/src/com/vaadin/terminal/gwt/client/ApplicationConnection.java b/src/com/vaadin/terminal/gwt/client/ApplicationConnection.java index 51c5c92fe3..1d6fe6d0eb 100755 --- a/src/com/vaadin/terminal/gwt/client/ApplicationConnection.java +++ b/src/com/vaadin/terminal/gwt/client/ApplicationConnection.java @@ -173,11 +173,11 @@ public class ApplicationConnection { return componentLocator.@com.vaadin.terminal.gwt.client.ComponentLocator::getPathForElement(Lcom/google/gwt/user/client/Element;)(element); } - if(!$wnd.itmill.clients) { - $wnd.itmill.clients = {}; + if(!$wnd.vaadin.clients) { + $wnd.vaadin.clients = {}; } - $wnd.itmill.clients[TTAppId] = client; + $wnd.vaadin.clients[TTAppId] = client; }-*/; /** @@ -191,7 +191,7 @@ public class ApplicationConnection { /** * Publishes a JavaScript API for mash-up applications. * <ul> - * <li><code>itmill.forceSync()</code> sends pending variable changes, in + * <li><code>vaadin.forceSync()</code> sends pending variable changes, in * effect synchronizing the server and client state. This is done for all * applications on host page.</li> * </ul> @@ -202,20 +202,20 @@ public class ApplicationConnection { /*-{ var app = this; var oldSync; - if($wnd.itmill.forceSync) { - oldSync = $wnd.itmill.forceSync; + if($wnd.vaadin.forceSync) { + oldSync = $wnd.vaadin.forceSync; } - $wnd.itmill.forceSync = function() { + $wnd.vaadin.forceSync = function() { if(oldSync) { oldSync(); } app.@com.vaadin.terminal.gwt.client.ApplicationConnection::sendPendingVariableChanges()(); } var oldForceLayout; - if($wnd.itmill.forceLayout) { - oldForceLayout = $wnd.itmill.forceLayout; + if($wnd.vaadin.forceLayout) { + oldForceLayout = $wnd.vaadin.forceLayout; } - $wnd.itmill.forceLayout = function() { + $wnd.vaadin.forceLayout = function() { if(oldForceLayout) { oldForceLayout(); } @@ -235,7 +235,7 @@ public class ApplicationConnection { */ public native static boolean isDebugMode() /*-{ - if($wnd.itmill.debug) { + if($wnd.vaadin.debug) { var parameters = $wnd.location.search; var re = /debug[^\/]*$/; return re.test(parameters); diff --git a/src/com/vaadin/terminal/gwt/client/ui/TreeImages.java b/src/com/vaadin/terminal/gwt/client/ui/TreeImages.java index db53653e71..f266f0de8c 100644 --- a/src/com/vaadin/terminal/gwt/client/ui/TreeImages.java +++ b/src/com/vaadin/terminal/gwt/client/ui/TreeImages.java @@ -12,8 +12,7 @@ public interface TreeImages extends com.google.gwt.user.client.ui.TreeImages { * An image indicating an open branch.
*
* @return a prototype of this image
- * @gwt.resource
- * com/itmill/toolkit/terminal/gwt/public/default/tree/img/expanded
+ * @gwt.resource com/vaadin/terminal/gwt/public/default/tree/img/expanded
* .png
*/
AbstractImagePrototype treeOpen();
@@ -22,8 +21,7 @@ public interface TreeImages extends com.google.gwt.user.client.ui.TreeImages { * An image indicating a closed branch.
*
* @return a prototype of this image
- * @gwt.resource
- * com/itmill/toolkit/terminal/gwt/public/default/tree/img/collapsed
+ * @gwt.resource com/vaadin/terminal/gwt/public/default/tree/img/collapsed
* .png
*/
AbstractImagePrototype treeClosed();
diff --git a/src/com/vaadin/terminal/gwt/client/ui/VUnknownComponent.java b/src/com/vaadin/terminal/gwt/client/ui/VUnknownComponent.java index 12faa71992..69af9f43b9 100644 --- a/src/com/vaadin/terminal/gwt/client/ui/VUnknownComponent.java +++ b/src/com/vaadin/terminal/gwt/client/ui/VUnknownComponent.java @@ -21,8 +21,8 @@ public class VUnknownComponent extends Composite implements Paintable { panel.add(caption); panel.add(uidlTree); initWidget(panel); - setStyleName("itmill-unknown"); - caption.setStyleName("itmill-unknown-caption"); + setStyleName("vaadin-unknown"); + caption.setStyleName("vaadin-unknown-caption"); } public void updateFromUIDL(UIDL uidl, ApplicationConnection client) { diff --git a/src/com/vaadin/terminal/gwt/server/AbstractApplicationServlet.java b/src/com/vaadin/terminal/gwt/server/AbstractApplicationServlet.java index 52ac148e76..6180993faa 100644 --- a/src/com/vaadin/terminal/gwt/server/AbstractApplicationServlet.java +++ b/src/com/vaadin/terminal/gwt/server/AbstractApplicationServlet.java @@ -1205,16 +1205,16 @@ public abstract class AbstractApplicationServlet extends HttpServlet { + "'></script>\n"); page.write("<script type=\"text/javascript\">\n"); page.write("//<![CDATA[\n"); - page.write("if(!itmill || !itmill.toolkitConfigurations) {\n " - + "if(!itmill) { var itmill = {}} \n" - + "itmill.toolkitConfigurations = {};\n" - + "itmill.themesLoaded = {}};\n"); + page.write("if(!vaadin || !vaadin.toolkitConfigurations) {\n " + + "if(!vaadin) { var vaadin = {}} \n" + + "vaadin.toolkitConfigurations = {};\n" + + "vaadin.themesLoaded = {}};\n"); if (!isProductionMode()) { - page.write("itmill.debug = true;\n"); + page.write("vaadin.debug = true;\n"); } - page.write("itmill.toolkitConfigurations[\"" + appId + "\"] = {"); + page.write("vaadin.toolkitConfigurations[\"" + appId + "\"] = {"); page.write("appUri:'" + appUrl + "', "); page.write("pathInfo: '" + pathInfo + "', "); if (window != application.getMainWindow()) { @@ -1254,7 +1254,7 @@ public abstract class AbstractApplicationServlet extends HttpServlet { // set page.write("<script type=\"text/javascript\">\n"); page.write("//<![CDATA[\n"); - page.write("if(!itmill.themesLoaded['" + themeName + "']) {\n"); + page.write("if(!vaadin.themesLoaded['" + themeName + "']) {\n"); page .write("var stylesheet = document.createElement('link');\n"); page.write("stylesheet.setAttribute('rel', 'stylesheet');\n"); @@ -1263,7 +1263,7 @@ public abstract class AbstractApplicationServlet extends HttpServlet { + "/styles.css');\n"); page .write("document.getElementsByTagName('head')[0].appendChild(stylesheet);\n"); - page.write("itmill.themesLoaded['" + themeName + page.write("vaadin.themesLoaded['" + themeName + "'] = true;\n}\n"); page.write("//]]>\n</script>\n"); } @@ -1271,12 +1271,12 @@ public abstract class AbstractApplicationServlet extends HttpServlet { } else { page.write("<script type=\"text/javascript\">\n"); page.write("//<![CDATA[\n"); - page.write("if(!itmill || !itmill.toolkitConfigurations) {\n " - + "if(!itmill) { var itmill = {}} \n" - + "itmill.toolkitConfigurations = {};\n" - + "itmill.themesLoaded = {};\n"); + page.write("if(!vaadin || !vaadin.toolkitConfigurations) {\n " + + "if(!vaadin) { var vaadin = {}} \n" + + "vaadin.toolkitConfigurations = {};\n" + + "vaadin.themesLoaded = {};\n"); if (!isProductionMode()) { - page.write("itmill.debug = true;\n"); + page.write("vaadin.debug = true;\n"); } page .write("document.write('<iframe tabIndex=\"-1\" id=\"__gwt_historyFrame\" " @@ -1287,7 +1287,7 @@ public abstract class AbstractApplicationServlet extends HttpServlet { + widgetset + "/" + widgetset + ".nocache.js?" + new Date().getTime() + "'><\\/script>\");\n}\n"); - page.write("itmill.toolkitConfigurations[\"" + appId + "\"] = {"); + page.write("vaadin.toolkitConfigurations[\"" + appId + "\"] = {"); page.write("appUri:'" + appUrl + "', "); page.write("pathInfo: '" + pathInfo + "', "); if (window != application.getMainWindow()) { @@ -1328,7 +1328,7 @@ public abstract class AbstractApplicationServlet extends HttpServlet { // set page.write("<script type=\"text/javascript\">\n"); page.write("//<![CDATA[\n"); - page.write("if(!itmill.themesLoaded['" + themeName + "']) {\n"); + page.write("if(!vaadin.themesLoaded['" + themeName + "']) {\n"); page .write("var stylesheet = document.createElement('link');\n"); page.write("stylesheet.setAttribute('rel', 'stylesheet');\n"); @@ -1337,7 +1337,7 @@ public abstract class AbstractApplicationServlet extends HttpServlet { + "/styles.css');\n"); page .write("document.getElementsByTagName('head')[0].appendChild(stylesheet);\n"); - page.write("itmill.themesLoaded['" + themeName + page.write("vaadin.themesLoaded['" + themeName + "'] = true;\n}\n"); page.write("//]]>\n</script>\n"); } diff --git a/src/com/vaadin/terminal/gwt/server/ApplicationRunnerServlet.java b/src/com/vaadin/terminal/gwt/server/ApplicationRunnerServlet.java index 774b866a44..fe20093e02 100644 --- a/src/com/vaadin/terminal/gwt/server/ApplicationRunnerServlet.java +++ b/src/com/vaadin/terminal/gwt/server/ApplicationRunnerServlet.java @@ -89,9 +89,9 @@ public class ApplicationRunnerServlet extends AbstractApplicationServlet { * Parses application runner URIs. * * If request URL is e.g. - * http://localhost:8080/itmill/run/com.vaadin.demo.Calc then + * http://localhost:8080/vaadin/run/com.vaadin.demo.Calc then * <ul> - * <li>context=itmill</li> + * <li>context=vaadin</li> * <li>Runner servlet=run</li> * <li>Toolkit application=com.vaadin.demo.Calc</li> * </ul> diff --git a/src/com/vaadin/ui/AbstractOrderedLayout.java b/src/com/vaadin/ui/AbstractOrderedLayout.java index e83a71eeaf..573f92c53b 100644 --- a/src/com/vaadin/ui/AbstractOrderedLayout.java +++ b/src/com/vaadin/ui/AbstractOrderedLayout.java @@ -234,9 +234,8 @@ public abstract class AbstractOrderedLayout extends AbstractLayout implements /* * (non-Javadoc) * - * @see - * com.vaadin.ui.Layout.AlignmentHandler#setComponentAlignment(com - * .itmill.toolkit.ui.Component, int, int) + * @see com.vaadin.ui.Layout.AlignmentHandler#setComponentAlignment(com + * .vaadin.ui.Component, int, int) */ public void setComponentAlignment(Component childComponent, int horizontalAlignment, int verticalAlignment) { @@ -266,9 +265,8 @@ public abstract class AbstractOrderedLayout extends AbstractLayout implements /* * (non-Javadoc) * - * @see - * com.vaadin.ui.Layout.AlignmentHandler#getComponentAlignment(com - * .itmill.toolkit.ui.Component) + * @see com.vaadin.ui.Layout.AlignmentHandler#getComponentAlignment(com + * .vaadin.ui.Component) */ public Alignment getComponentAlignment(Component childComponent) { Alignment alignment = componentToAlignment.get(childComponent); diff --git a/src/com/vaadin/ui/LoginForm.java b/src/com/vaadin/ui/LoginForm.java index a9f94bbf54..3a8103e1a6 100644 --- a/src/com/vaadin/ui/LoginForm.java +++ b/src/com/vaadin/ui/LoginForm.java @@ -88,7 +88,7 @@ public class LoginForm extends CustomComponent { private URIHandler uriHandler = new URIHandler() { private final String responce = "<html><body>Login form handeled." - + "<script type='text/javascript'>top.itmill.forceSync();" + + "<script type='text/javascript'>top.vaadin.forceSync();" + "</script></body></html>"; public DownloadStream handleURI(URL context, String relativeUri) { |