WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
38344
Remove custom bindings for HTMLInputElement
https://bugs.webkit.org/show_bug.cgi?id=38344
Summary
Remove custom bindings for HTMLInputElement
Adam Barth
Reported
2010-04-29 13:52:04 PDT
Remove custom bindings for HTMLInputElement
Attachments
Patch
(25.06 KB, patch)
2010-04-29 13:54 PDT
,
Adam Barth
no flags
Details
Formatted Diff
Diff
work in progress
(10.09 KB, patch)
2010-05-14 22:06 PDT
,
Adam Barth
no flags
Details
Formatted Diff
Diff
Patch
(12.39 KB, patch)
2010-05-14 23:23 PDT
,
Adam Barth
darin
: review+
Details
Formatted Diff
Diff
Show Obsolete
(2)
View All
Add attachment
proposed patch, testcase, etc.
Adam Barth
Comment 1
2010-04-29 13:54:50 PDT
Created
attachment 54732
[details]
Patch
WebKit Review Bot
Comment 2
2010-04-29 13:58:10 PDT
Attachment 54732
[details]
did not pass style-queue: Failed to run "['WebKitTools/Scripts/check-webkit-style', '--no-squash']" exit_code: 1 WebCore/bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:440: Extra space before ( in function call [whitespace/parens] [4] WebCore/bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:456: Extra space before ( in function call [whitespace/parens] [4] WebCore/bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:481: Extra space before ( in function call [whitespace/parens] [4] WebCore/bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:591: Extra space before ) [whitespace/parens] [2] WebCore/bindings/scripts/test/GObject/WebKitDOMTestObj.cpp:597: Extra space before ) [whitespace/parens] [2] WebCore/bindings/scripts/test/GObject/WebKitDOMTestObj.h:164: Extra space before ( in function call [whitespace/parens] [4] WebCore/bindings/scripts/test/GObject/WebKitDOMTestObj.h:167: Extra space before ( in function call [whitespace/parens] [4] WebCore/bindings/scripts/test/GObject/WebKitDOMTestObj.h:173: Extra space before ( in function call [whitespace/parens] [4] Total errors found: 8 in 15 files If any of these errors are false positives, please file a bug against check-webkit-style.
Yaar Schnitman
Comment 3
2010-04-29 14:34:36 PDT
That's better.
Eric Seidel (no email)
Comment 4
2010-04-30 11:52:30 PDT
Comment on
attachment 54732
[details]
Patch I think HTMLInputElement.h needs a comment as to why we're adding these. But I think this looks OK. Should we be be making selectionStart, etc. virtual and overriding them in HTMLIntputElement as private members? Should we change the baseclass to take an ExceptionCode and only throw it for HTMLInputElement? I think this is OK as is, but I worry that folks could easily use the wrong one.
Darin Adler
Comment 5
2010-04-30 13:13:18 PDT
Comment on
attachment 54732
[details]
Patch Throwing an exception when previously we would silently do nothing could easily be a backward compatibility problem for the Objective-C bindings.
> +int HTMLInputElement::selectionStart(ExceptionCode& ec) > +{ > + if (!canHaveSelection()) { > + ec = TYPE_MISMATCH_ERR; > + return -1; > + }
I think this gives a different exception than before. Probably the new one is correct and the old was incorrect, but since it's a behavior change I'd like to see tests showing the behavior.
Adam Barth
Comment 6
2010-05-02 19:28:11 PDT
We should be able to have the ObjC bindings call the non-ec version of the method. I'm not sure why that didn't work.
Eric Seidel (no email)
Comment 7
2010-05-02 19:33:07 PDT
Attachment 54732
[details]
was posted by a committer and has review+, assigning to Adam Barth for commit.
Adam Barth
Comment 8
2010-05-14 16:34:21 PDT
Committed
r59502
: <
http://trac.webkit.org/changeset/59502
>
Adam Barth
Comment 9
2010-05-14 16:51:33 PDT
I landed the TestObj.idl changes in
http://trac.webkit.org/changeset/59502
. I'm going to post a new patch that addresses Darin's feedback shortly.
Adam Barth
Comment 10
2010-05-14 22:06:51 PDT
Created
attachment 56139
[details]
work in progress
Adam Barth
Comment 11
2010-05-14 23:23:49 PDT
Created
attachment 56141
[details]
Patch
Darin Adler
Comment 12
2010-05-16 12:12:41 PDT
Comment on
attachment 56141
[details]
Patch Good to avoid custom bindings. Awkward to have these two versions of these basic functions side by side. The only other place I can think of where we have that is the Range class. Note the different way these functions are declared in that class compared to what we have in this patch. I think I like the Range style slightly better.
> + // The methods that take ExceptionCodes check canHaveSelection().
Methods is not a C++ term, and I normally avoid using it to mean member function in WebKit code. I would say "The following functions" or "These functions" rather than "The methods".
Eric Seidel (no email)
Comment 13
2010-09-02 13:47:12 PDT
I'm confused why this is open?
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug