Hi Thomas,
Could you pls elaborate a bit. My code is as follows
Column<HotelSearchDTO, String> bookCol = new Column<HotelSearchDTO,
String>(new ButtonCell()) {
@Override
public String getValue(HotelSearchDTO object) {
return "Normal";
}
};
bookCol.setFieldUpdater(new FieldUpdater<HotelSearchDTO, String>() {
@Override
public void update(int index, HotelSearchDTO object, String value) {
// How to return "Loading..." from this place as this is the only place to
handle click event.
}
});
Thanks
Deepak
On Mon, Nov 5, 2012 at 10:47 PM, Thomas Broyer <[email protected]> wrote:
>
> On Monday, November 5, 2012 5:17:43 PM UTC+1, Deepak Singh wrote:
>>
>> Hi,
>>
>> I have a celltable which has one column as ButtonCell.
>> I am doing some server side work on click of this button.
>> Now, i want that the text should change to 'Loading...' when clicked on
>> this button and should again to its original text after i finish server
>> side work.
>>
>> The point is to show the user that the click has happened and to wait
>> till work in progress.
>>
>> col.setFieldUpdater() has nothing to achieve this.
>>
>> Can you pls give me some solution ...
>>
>
> The "correct" handling of that situation would be that the column's
> getValue can return either the "normal" button text or "Loading…", so that
> it still "works" in case the table is redrawn midway 'til the server
> responds.
> Once you have that, you only need to trigger a redraw of the raw whenever
> the value ("normal" text vs. "Loading…") changes.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/google-web-toolkit/-/AfwGLdy3a6AJ.
> 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.
>
--
Deepak Singh
--
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.