When I use buttons, I can just call button.click () to simulate a click. Now I have a link to HasClickHandlers (maybe a button, maybe an image, etc.), but I canβt figure out how to click it!
Is it possible? I am using GWT 2.1
You can use the following and fill in the fields as needed, such as the position of the screen, etc.
DomEvent.fireNativeEvent(Document.get().createClickEvent(0, 0, 0, 0, 0, false, false, false, false), button);
Can't you call fireEvent() from the HasHandlers superinterface?
fireEvent()
HasHandlers
Also, see post .
Source: https://habr.com/ru/post/1334424/More articles:Visual Studio 2010: how can I create a project, not its dependencies? - buildIn Java, what is the best way to capture the keystroke ? - javaHow to intentionally crash a COM object - c #WebGL Benchmark - What Tests Should I Create? - javascriptUnable to save UTF-8 to RDS despite setting up a new parameter group using Rails on Heroku - ruby-on-railsDelete file after sharing with intent - androidManipulating an HTTP Response - asp.netZed Shaw Learn Python Hard Tutorial - pythonHibernate generating two different sequence identifiers for inserting PostgreSQL - postgresqlASP.NET Themes and Static Content - cssAll Articles