summaryrefslogtreecommitdiffstats
path: root/src/com/vaadin/ui
diff options
context:
space:
mode:
authorLeif Åstrand <leif@vaadin.com>2012-06-29 15:38:03 +0300
committerLeif Åstrand <leif@vaadin.com>2012-06-29 15:38:22 +0300
commit570401eea6984a9c822a68f0139eba5b4826045f (patch)
tree27d98d19e7ab0350a05e4a5bef0a5af67df75172 /src/com/vaadin/ui
parentc13a5b75a4de7953aa9321d775262c90a4389499 (diff)
downloadvaadin-framework-570401eea6984a9c822a68f0139eba5b4826045f.tar.gz
vaadin-framework-570401eea6984a9c822a68f0139eba5b4826045f.zip
Restore static helper for executing JS that somehow went missing (#8907)
Diffstat (limited to 'src/com/vaadin/ui')
-rw-r--r--src/com/vaadin/ui/JavaScript.java10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/com/vaadin/ui/JavaScript.java b/src/com/vaadin/ui/JavaScript.java
index d256717711..5905b56bfb 100644
--- a/src/com/vaadin/ui/JavaScript.java
+++ b/src/com/vaadin/ui/JavaScript.java
@@ -115,6 +115,16 @@ public class JavaScript extends AbstractExtension {
}
/**
+ * Executes the given JavaScript code in the browser.
+ *
+ * @param script
+ * The JavaScript code to run.
+ */
+ public static void eval(String script) {
+ getCurrent().execute(script);
+ }
+
+ /**
* Get the JavaScript object for the current Page, or null if there is no
* current page.
*