How can I do the call to the VKI_attach(elem) function with JSNI? I tried to write $wnd.VKI_attach(name), but I'm getting an error message telling that VKI_attach is not a function.
On Mar 20, 5:46 pm, Thomas Broyer <[email protected]> wrote: > On Tuesday, March 20, 2012 5:41:19 PM UTC+1, dvarrin wrote: > > > Hi, > > > I want to use a virtual keyboard for some input fields on a web page > > of my GWT website. In a normal HTML page, I would need to do the > > following: > > > <html> > > <head> > > <script type="text/javascript" src="keyboard.js" charset="UTF-8"></ > > script> > > <link rel="stylesheet" type="text/css" href="keyboard.css"> > > </head> > > > <body> > > <input type="text" value="" class="keyboardInput"> > > </body> > > > (required files are available here: > >http://www.greywyvern.com/code/javascript/keyboard) > > > There is a javascript file and style sheet to include on the page, and > > then all the input fields on which I want a virtual keyboard to be > > assgned, I've to set their class to "keyboardInput". > > > I've added the keyboard.js and keyboard.css to the html page in my > > application and then in the class creating the view I'm using: > > > <nameOfField>.setStyleName("keyboardInput"); > > > Then the script should add the virtual keyboard image next to each > > field of the class "keyboardInput". > > > when I check the result page, the field has is of the correct class, > > and I've added an alert in the keyboard.js script and it is executed, > > but no virtual keyboard image is displayed next to the field. > > > Any idea? > > See "Advanced Stuff" on the page you linked to: the script runs at > window.onload, and GWT code can run past this event. You'd have to call the > VTI_attach() function via JSNI, passing myWidget.getElement() as the > argument. -- You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
