WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
64118
Move all code related to cachedSelection to HTMLTextFormControlElement
https://bugs.webkit.org/show_bug.cgi?id=64118
Summary
Move all code related to cachedSelection to HTMLTextFormControlElement
Ryosuke Niwa
Reported
2011-07-07 12:21:58 PDT
Right now, HTMLFormControlElement, HTMLInputElement, HTMLTextAreaElement, RenderTextControl, RenderTextControlSingleLine, and RenderTextControlMultipleLine are all aware of cachedSelection. But this simply is an artifact of WML, and we should be able to push all methods and variables related to cachedSelection into HTMLFormControlElement.
Attachments
Removed lots of code
(17.90 KB, patch)
2011-07-07 12:43 PDT
,
Ryosuke Niwa
ap
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Ryosuke Niwa
Comment 1
2011-07-07 12:43:17 PDT
Created
attachment 100020
[details]
Removed lots of code
Ryosuke Niwa
Comment 2
2011-07-07 13:41:29 PDT
Ping reviewers because I have a lot of cleanups to do and this patch is blocking my work.
Alexey Proskuryakov
Comment 3
2011-07-07 13:56:40 PDT
Comment on
attachment 100020
[details]
Removed lots of code View in context:
https://bugs.webkit.org/attachment.cgi?id=100020&action=review
> Source/WebCore/html/HTMLFormControlElement.cpp:715 > + if (!renderer() || !isTextFormControl())
When is HTMLTextFormControlElement not a text form control?
> Source/WebCore/html/HTMLFormControlElement.h:238 > + int m_cachedSelectionStart; > + int m_cachedSelectionEnd;
What prevents these from being private?
Ryosuke Niwa
Comment 4
2011-07-07 14:02:39 PDT
Comment on
attachment 100020
[details]
Removed lots of code View in context:
https://bugs.webkit.org/attachment.cgi?id=100020&action=review
Thanks for the review!
>> Source/WebCore/html/HTMLFormControlElement.cpp:715 >> + if (!renderer() || !isTextFormControl()) > > When is HTMLTextFormControlElement not a text form control?
input[type=checkbox], input[type=radio], etc...
>> Source/WebCore/html/HTMLFormControlElement.h:238 >> + int m_cachedSelectionEnd; > > What prevents these from being private?
Oh, right. Will make them private. I had to make them protected when HTMLInputElement and HTMLTextAreaElement still access those variables directly.
Ryosuke Niwa
Comment 5
2011-07-07 14:03:18 PDT
(In reply to
comment #4
)
> >> Source/WebCore/html/HTMLFormControlElement.cpp:715 > >> + if (!renderer() || !isTextFormControl()) > > > > When is HTMLTextFormControlElement not a text form control? > > input[type=checkbox], input[type=radio], etc...
I agree that it's very confusing and we should probably rename it to isTextField.
Ryosuke Niwa
Comment 6
2011-07-07 14:37:31 PDT
Committed
r90591
: <
http://trac.webkit.org/changeset/90591
>
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