HOWTO change the value of a cell in a celltable
Hi: I have an EditTextCell whose value must be edited after the user presses Enter. The edited value must be redisplayed in the Cell. For example, if the value is 1,2,3, then the value must be edited to be 1,2 and that new value must be displayed in the cell table. I almost have this solved. The problem is that the new value does not display until the next round of the cell refresh, which occurs when I focus on the cell, then press enter. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: HOWTO change the value of a cell in a celltable
If I understand, when you sethttp://google-web-toolkit.googlecode.com/svn/javadoc/2.1/com/google/gwt/cell/client/FieldUpdater.htmlthe new value you must call to *yourTable.redraw();* Regards. 2011/8/10 Jeff Chimene jchim...@gmail.com Hi: I have an EditTextCell whose value must be edited after the user presses Enter. The edited value must be redisplayed in the Cell. For example, if the value is 1,2,3, then the value must be edited to be 1,2 and that new value must be displayed in the cell table. I almost have this solved. The problem is that the new value does not display until the next round of the cell refresh, which occurs when I focus on the cell, then press enter. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- El precio es lo que pagas. El valor es lo que recibes. Warren Buffet -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: HOWTO change the value of a cell in a celltable
On 08/10/2011 04:36 AM, Adolfo Panizo Touzon wrote: If I understand, when you set http://google-web-toolkit.googlecode.com/svn/javadoc/2.1/com/google/gwt/cell/client/FieldUpdater.html the new value you must call to /yourTable.redraw();/ Exactly. However, the new value isn't displaying until the next focus/blur cycle. I have other cells in the cell table whose values are updated. This is the only cell whose value is read, then written. It has something to do with the EditTextCell edit cycle. It seems like whoever wrote this widget did not consider the case where there would be additional edits after the user pressed enter to commit the value. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: HOWTO change the value of a cell in a celltable
Hi, maybe another solution is use the TextInputCell, have you tried ?? 2011/8/10 Jeff Chimene jchim...@gmail.com On 08/10/2011 04:36 AM, Adolfo Panizo Touzon wrote: If I understand, when you set http://google-web-toolkit.googlecode.com/svn/javadoc/2.1/com/google/gwt/cell/client/FieldUpdater.html the new value you must call to /yourTable.redraw();/ Exactly. However, the new value isn't displaying until the next focus/blur cycle. I have other cells in the cell table whose values are updated. This is the only cell whose value is read, then written. It has something to do with the EditTextCell edit cycle. It seems like whoever wrote this widget did not consider the case where there would be additional edits after the user pressed enter to commit the value. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- El precio es lo que pagas. El valor es lo que recibes. Warren Buffet -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: HOWTO change the value of a cell in a celltable
On 08/10/2011 04:56 AM, Adolfo Panizo Touzon wrote: Hi, maybe another solution is use the TextInputCell, have you tried ?? No, I really need EditTextCell, as it has the UI stuff that I need for this particular cell. I'm on the track of instantiating an EditTextCell (rather than use ColumnC,V(new EditTextCell()) , then using the ClearViewData method to reset it while still in the edit loop. I'll post back w/ results. 2011/8/10 Jeff Chimene jchim...@gmail.com mailto:jchim...@gmail.com On 08/10/2011 04:36 AM, Adolfo Panizo Touzon wrote: If I understand, when you set http://google-web-toolkit.googlecode.com/svn/javadoc/2.1/com/google/gwt/cell/client/FieldUpdater.html the new value you must call to /yourTable.redraw();/ Exactly. However, the new value isn't displaying until the next focus/blur cycle. I have other cells in the cell table whose values are updated. This is the only cell whose value is read, then written. It has something to do with the EditTextCell edit cycle. It seems like whoever wrote this widget did not consider the case where there would be additional edits after the user pressed enter to commit the value. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com mailto:google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com mailto:google-web-toolkit%2bunsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- El precio es lo que pagas. El valor es lo que recibes. Warren Buffet -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: HOWTO change the value of a cell in a celltable
On 08/10/2011 04:59 AM, Jeff Chimene wrote: On 08/10/2011 04:56 AM, Adolfo Panizo Touzon wrote: Hi, maybe another solution is use the TextInputCell, have you tried ?? No, I really need EditTextCell, as it has the UI stuff that I need for this particular cell. I'm on the track of instantiating an EditTextCell (rather than use ColumnC,V(new EditTextCell()) , then using the ClearViewData method to reset it while still in the edit loop. I'll post back w/ results. Yeah, that was it: Instantiate the EditTextCell in a separate class, so that there exists an instance with which to call ClearViewData inside the FieldUpdate method. There is a reference to this in the example set of CellTable. The other trick is to call the editor outside the EditTextCell edit loop, so that there is no simultaneous modification of the list data. viz: predecessorColumn.setFieldUpdater(new FieldUpdaterActivity, String() { @Override public void update(final int index, final Activity activity, final String value) { predecessorCell.clearViewData(activity); com.google.gwt.core.client.Scheduler.get().scheduleDeferred(new ScheduledCommand() { @Override public void execute() { getUiHandlers().onPredecessorChange(activity, value); cellTable.redraw(); } }); } }); 2011/8/10 Jeff Chimene jchim...@gmail.com mailto:jchim...@gmail.com On 08/10/2011 04:36 AM, Adolfo Panizo Touzon wrote: If I understand, when you set http://google-web-toolkit.googlecode.com/svn/javadoc/2.1/com/google/gwt/cell/client/FieldUpdater.html the new value you must call to /yourTable.redraw();/ Exactly. However, the new value isn't displaying until the next focus/blur cycle. I have other cells in the cell table whose values are updated. This is the only cell whose value is read, then written. It has something to do with the EditTextCell edit cycle. It seems like whoever wrote this widget did not consider the case where there would be additional edits after the user pressed enter to commit the value. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com mailto:google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com mailto:google-web-toolkit%2bunsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- El precio es lo que pagas. El valor es lo que recibes. Warren Buffet -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
Re: HOWTO change the value of a cell in a celltable
:) 2011/8/10 Jeff Chimene jchim...@gmail.com On 08/10/2011 04:59 AM, Jeff Chimene wrote: On 08/10/2011 04:56 AM, Adolfo Panizo Touzon wrote: Hi, maybe another solution is use the TextInputCell, have you tried ?? No, I really need EditTextCell, as it has the UI stuff that I need for this particular cell. I'm on the track of instantiating an EditTextCell (rather than use ColumnC,V(new EditTextCell()) , then using the ClearViewData method to reset it while still in the edit loop. I'll post back w/ results. Yeah, that was it: Instantiate the EditTextCell in a separate class, so that there exists an instance with which to call ClearViewData inside the FieldUpdate method. There is a reference to this in the example set of CellTable. The other trick is to call the editor outside the EditTextCell edit loop, so that there is no simultaneous modification of the list data. viz: predecessorColumn.setFieldUpdater(new FieldUpdaterActivity, String() { @Override public void update(final int index, final Activity activity, final String value) { predecessorCell.clearViewData(activity); com.google.gwt.core.client.Scheduler.get().scheduleDeferred(new ScheduledCommand() { @Override public void execute() { getUiHandlers().onPredecessorChange(activity, value); cellTable.redraw(); } }); } }); 2011/8/10 Jeff Chimene jchim...@gmail.com mailto:jchim...@gmail.com On 08/10/2011 04:36 AM, Adolfo Panizo Touzon wrote: If I understand, when you set http://google-web-toolkit.googlecode.com/svn/javadoc/2.1/com/google/gwt/cell/client/FieldUpdater.html the new value you must call to /yourTable.redraw();/ Exactly. However, the new value isn't displaying until the next focus/blur cycle. I have other cells in the cell table whose values are updated. This is the only cell whose value is read, then written. It has something to do with the EditTextCell edit cycle. It seems like whoever wrote this widget did not consider the case where there would be additional edits after the user pressed enter to commit the value. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com mailto:google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com mailto:google-web-toolkit%2bunsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- El precio es lo que pagas. El valor es lo que recibes. Warren Buffet -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en. -- El precio es lo que pagas. El valor es lo que recibes. Warren Buffet -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To post to this group, send email to google-web-toolkit@googlegroups.com. To unsubscribe from this group, send email to google-web-toolkit+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.