Solved Thanks!! Just modified the class to implement ClickHandler
Captured the onClick event to get the x and y coordinates tatsit!! On Jan 18, 5:23 pm, AmaraSat <[email protected]> wrote: > This is what i have: > > package com.google.gwt.sample.webapplication.client; > > public class WebApplication implements EntryPoint { > > private static final int REFRESH_INTERVAL = 15000; > private VerticalPanel mainPanel = new VerticalPanel(); > privateFlexTablepropertyDisplayTable = newFlexTable(); > > public void onModuleLoad() { > > propertyDisplayTable.setText(0, 0, "PropertyTag"); > propertyDisplayTable.setText(0, 1, "Value"); > propertyDisplayTable.setText(0, 2, "Remove"); > propertyDisplayTable.sinkEvents(Event.ONCLICK); > > Image UpdateImage4 = new Image("./images/redm.png"); > propertyDisplayTable.setWidget(1, 2, UpdateImage4); > > mainPanel.add(propertyDisplayTable); > > } > > private void refreshPropertyList() { > UpdateImage = new Image("./images/redm.png"); > propertyDisplayTable.add(UpdateImage); > > } > > public voidonBrowserEvent(Event event) { > // process the event > switch (DOM.eventGetType(event)) { > case Event.ONCLICK: { > // Save the x and y coordinate of the mouse so we can > position the popup > xCoord = DOM.eventGetClientX(event); > yCoord = DOM.eventGetClientY(event); > break; > } > super.onBrowserEvent(event); > } > } > > } > > On Jan 18, 4:29 pm, Jeff Larsen <[email protected]> wrote: > > > Does your class extend Composite? -- 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.
