File tree Expand file tree Collapse file tree 2 files changed +10
-1
lines changed
src/main/java/com/osiris/desku/ui Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -148,6 +148,13 @@ public static void remove(Thread... threads) {
148148 */
149149 public abstract void plusY (int y ) throws InterruptedException , InvocationTargetException ;
150150
151+ /**
152+ * @see #executeJavaScriptSafely(String, String, int)
153+ */
154+ public void executeJavaScriptSafely (String jsCode ) {
155+ executeJavaScriptSafely (jsCode , "internal" , 0 );
156+ }
157+
151158 /**
152159 * Executes {@link #executeJavaScript(String, String, int)} only once the UI is loaded and after
153160 * some internals JS dependencies are loaded.
Original file line number Diff line number Diff line change 11package com .osiris .desku .ui .layout ;
22
33import com .osiris .desku .ui .Component ;
4+ import com .osiris .desku .ui .UI ;
45
56public class Tooltip {
67 public Component <?, ?> parent ;
@@ -15,7 +16,8 @@ public Tooltip attachToParent(){
1516 parent .atr ("data-bs-toggle" , "tooltip" );
1617 parent .atr ("data-bs-title" , content );
1718
18- parent .executeJS ("new bootstrap.Tooltip(comp)" );
19+ UI ui = UI .get ();
20+ ui .executeJavaScriptSafely (ui .jsGetComp ("comp" , parent .id ) + "new bootstrap.Tooltip(comp)" );
1921 return this ;
2022 }
2123}
You can’t perform that action at this time.
0 commit comments