code review requested -- deprecate get/setAttribute and replace with get/setElementProperty, add get/setElementAttribute

0 vue
Accéder directement au premier message non lu

John Tamplin

non lue,
11 avr. 2007, 19:20:0711/04/2007
à Kelly Norton,Google-Web-Tool...@googlegroups.com
This is essentially Jason Essington's patch, merged into the current trunk and newer uses of get/setAttribute replaced, minus the removeElementAttribute methods.
I have tested it in both Windows and Mac.

It is in /changes/jat/rename-getAttribute and was forked from 823.  To review it, you can switch a clean working copy to it with:
or you can merge it into a clean, recent trunk working copy with

removeElementAttribute was removed in r838, so if you want to see it with that method in, you can also do
to put them back.

Proposed commit message, if you deem it ready:

Mark get/set*Attribute as deprecated and implement them in terms of the new get/setElementProperty*.  Add new get/setElementAttribute which uses elem.getAttribute () to retrieve the value rather than elem[attr].

Patch by: jason.essington, jat
Review by: knorton

--
John A. Tamplin
Software Engineer, Google

John Tamplin

non lue,
13 avr. 2007, 19:47:1413/04/2007
à Kelly Norton,Google-Web-Tool...@googlegroups.com
On 4/11/07, John Tamplin <j...@google.com> wrote:
This is essentially Jason Essington's patch, merged into the current trunk and newer uses of get/setAttribute replaced, minus the removeElementAttribute methods.

Just wanted to make sure this hadn't fallen through the cracks.

Joel Webber

non lue,
16 avr. 2007, 16:22:5916/04/2007
à Google-Web-Tool...@googlegroups.com,Kelly Norton
These changes Look Good To Me. Once they're committed, we'll need to update a couple of the new widgets to reference the non-deprecated attribute accessors, but I see no reason not to do that in a separate pass.

Thanks, John!
joel.
--
joel.

John Tamplin

non lue,
16 avr. 2007, 16:44:1116/04/2007
à Google-Web-Tool...@googlegroups.com
On 4/16/07, Joel Webber <j...@google.com> wrote:
These changes Look Good To Me. Once they're committed, we'll need to update a couple of the new widgets to reference the non-deprecated attribute accessors, but I see no reason not to do that in a separate pass.

I had done that with widgets added since the original patch, but I suppose other widgets may have been commited since the milestone release.

Joel Webber

non lue,
16 avr. 2007, 17:01:0016/04/2007
à Google-Web-Tool...@googlegroups.com
Yeah, that's exactly it. When you commit this, I'll create a patch for the new widgets.

joel.
--
joel.

Joel Webber

non lue,
16 avr. 2007, 18:42:3416/04/2007
à Google-Web-Tool...@googlegroups.com
Kelly, John,

Can I get you guys to CR this patch one last time? I've added to it the changes needed for new widgets to not use the deprecated DOM methods. Otherwise, it's the same as John/Jason's original patch, which looked just fine to me.

Affected files:
M      user/test/com/google/gwt/user/client/ui/CustomButtonTest.java
M      user/src/com/google/gwt/user/client/DOM.java
M      user/src/com/google/gwt/user/client/impl/DOMImpl.java
M      user/src/com/google/gwt/user/client/ui/UIObject.java
M      user/src/com/google/gwt/user/client/ui/Hyperlink.java
M      user/src/com/google/gwt/user/client/ui/FlexTable.java
M      user/src/com/google/gwt/user/client/ui/ScrollPanel.java
M      user/src/com/google/gwt/user/client/ui/HTMLPanel.java
M      user/src/com/google/gwt/user/client/ui/FileUpload.java
M      user/src/com/google/gwt/user/client/ui/StackPanel.java
M      user/src/com/google/gwt/user/client/ui/TextBox.java
M      user/src/com/google/gwt/user/client/ui/VerticalSplitPanel.java
M      user/src/com/google/gwt/user/client/ui/SplitPanel.java
M      user/src/com/google/gwt/user/client/ui/TextArea.java
M      user/src/com/google/gwt/user/client/ui/TreeItem.java
M      user/src/com/google/gwt/user/client/ui/FocusWidget.java
M      user/src/com/google/gwt/user/client/ui/HorizontalSplitPanel.java
M      user/src/com/google/gwt/user/client/ui/CheckBox.java
M      user/src/com/google/gwt/user/client/ui/VerticalPanel.java
M      user/src/com/google/gwt/user/client/ui/Tree.java
M      user/src/com/google/gwt/user/client/ui/HorizontalPanel.java
M      user/src/com/google/gwt/user/client/ui/impl/AbstractItemPickerImpl.java
M      user/src/com/google/gwt/user/client/ui/impl/RichTextAreaImpl.java
M      user/src/com/google/gwt/user/client/ui/impl/ClippedImageImplIE6.java
M      user/src/com/google/gwt/user/client/ui/impl/RichTextAreaImplOpera.java
M      user/src/com/google/gwt/user/client/ui/Image.java
M      user/src/com/google/gwt/user/client/ui/PopupPanel.java
M      user/src/com/google/gwt/user/client/ui/FormPanel.java
M      user/src/com/google/gwt/user/client/ui/TextBoxBase.java
M      user/src/com/google/gwt/user/client/ui/DisclosurePanel.java
M      user/src/com/google/gwt/user/client/ui/CellPanel.java
M      user/src/com/google/gwt/user/client/ui/NamedFrame.java
M      user/src/com/google/gwt/user/client/ui/DockPanel.java
M      user/src/com/google/gwt/user/client/ui/HTMLTable.java
M      user/src/com/google/gwt/user/client/ui/ListBox.java
M      user/src/com/google/gwt/user/client/ui/Frame.java
M      user/src/com/google/gwt/user/client/ui/Hidden.java
M      user/src/com/google/gwt/user/client/ui/AbsolutePanel.java

Review by: jgw, knorton, jat


On 4/16/07, Joel Webber <j...@google.com> wrote:
Yeah, that's exactly it. When you commit this, I'll create a patch for the new widgets.

joel.


On 4/16/07, John Tamplin < j...@google.com> wrote:
On 4/16/07, Joel Webber <j...@google.com> wrote:
These changes Look Good To Me. Once they're committed, we'll need to update a couple of the new widgets to reference the non-deprecated attribute accessors, but I see no reason not to do that in a separate pass.

I had done that with widgets added since the original patch, but I suppose other widgets may have been commited since the milestone release.


--
John A. Tamplin
Software Engineer, Google




--
joel.



--
joel.
deprecateGetAttributeEtc-r880.patch

John Tamplin

non lue,
16 avr. 2007, 19:28:4016/04/2007
à Google-Web-Tool...@googlegroups.com
On 4/16/07, Joel Webber <j...@google.com> wrote:
Can I get you guys to CR this patch one last time? I've added to it the changes needed for new widgets to not use the deprecated DOM methods. Otherwise, it's the same as John/Jason's original patch, which looked just fine to me.

LGTM other than:
  • I assume the unrelated formatting changes were intentional
  • TextBoxBase.java has no newline at the end of the file (not broken in this change, but might as well fix it)
  • HTMLTable.java also has no newline at the end of the file
  • Blank line before closing brace in Hidden.java, line 133

Joel Webber

non lue,
17 avr. 2007, 09:53:0517/04/2007
à Google-Web-Tool...@googlegroups.com
Committed as r884.

On 4/16/07, John Tamplin <j...@google.com> wrote:

Jason Essington

non lue,
17 avr. 2007, 10:43:5617/04/2007
à Google-Web-Tool...@googlegroups.com
Sweet! thanks guys!

-jason

Joel Webber

non lue,
17 avr. 2007, 12:12:1617/04/2007
à Google-Web-Tool...@googlegroups.com
No, thank you :)
Répondre à tous
Répondre à l'auteur
Transférer
0 nouveau message