Creating Event and Event Handler Classes
To create a GWT event and event handler
- In the Project view, right-click the client package.
- From the context menu, select .
- In the Create GWT Event and Handler Classes dialog box that opens, specify the names of the event class, the event handler interface, and the abstract "callback" method for callers to override.
Actually, you do not need to specify all the three names manually. As soon as you type the event class name in the Event class name text box, IntelliJ IDEA automatically completes the names of the handler interface and the "callback" method and displays the suggestions in the Handler class name and Handle method name text boxes respectively. This ensures that the generated stubs will be generated in accordance with GWT Google API libraries.
- When you click OK, IntelliJ IDEA generates the stubs for the event class and event handler interface and opens them in the editor. Populate the generated stubs as necessary.