WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
63037
Make instantiation of legacy editing position more explicit
https://bugs.webkit.org/show_bug.cgi?id=63037
Summary
Make instantiation of legacy editing position more explicit
Ryosuke Niwa
Reported
2011-06-20 19:42:42 PDT
Instead of keeping old constructor, we should make the way to instantiate a legacy editing position more explicit so that people will pay more attention to the deprecated code.
Attachments
cleanup; likely to fail build on various ports
(24.98 KB, patch)
2011-06-20 21:02 PDT
,
Ryosuke Niwa
no flags
Details
Formatted Diff
Diff
createDeprecatedLegacyEditingPosition to createLegacyEditingPosition; fixed gtk build
(25.40 KB, patch)
2011-06-21 09:57 PDT
,
Ryosuke Niwa
darin
: review+
Details
Formatted Diff
Diff
Show Obsolete
(1)
View All
Add attachment
proposed patch, testcase, etc.
Ryosuke Niwa
Comment 1
2011-06-20 19:43:12 PDT
This step is also necessary to add a new Position constructor that takes Text* and offset.
Ryosuke Niwa
Comment 2
2011-06-20 21:02:53 PDT
Created
attachment 97924
[details]
cleanup; likely to fail build on various ports
Martin Robinson
Comment 3
2011-06-20 21:35:01 PDT
Comment on
attachment 97924
[details]
cleanup; likely to fail build on various ports
Attachment 97924
[details]
did not pass gtk-ews (gtk): Output:
http://queues.webkit.org/results/8909844
Ryosuke Niwa
Comment 4
2011-06-20 22:40:18 PDT
(In reply to
comment #3
)
> (From update of
attachment 97924
[details]
) >
Attachment 97924
[details]
did not pass gtk-ews (gtk): > Output:
http://queues.webkit.org/results/8909844
http://trac.webkit.org/browser/trunk/Source/WebCore/accessibility/gtk/AXObjectCacheAtk.cpp
: Range::create(node->document(), Position(node->parentNode(), 0), Position(node, 0)); This is terrible :(
Eric Seidel (no email)
Comment 5
2011-06-20 22:44:06 PDT
Comment on
attachment 97924
[details]
cleanup; likely to fail build on various ports View in context:
https://bugs.webkit.org/attachment.cgi?id=97924&action=review
> Source/WebCore/dom/Position.cpp:272 > + return createDeprecatedLegacyEditingPosition(n, uncheckedPreviousOffsetForBackwardDeletion(n, o));
Huh? Why not just createLegacyEditingPosition? The deprecated seems redundant here.
Ryosuke Niwa
Comment 6
2011-06-20 22:47:48 PDT
(In reply to
comment #5
)
> (From update of
attachment 97924
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=97924&action=review
> > > Source/WebCore/dom/Position.cpp:272 > > + return createDeprecatedLegacyEditingPosition(n, uncheckedPreviousOffsetForBackwardDeletion(n, o)); > > Huh? Why not just createLegacyEditingPosition? The deprecated seems redundant here.
Sure. I can do that.
Darin Adler
Comment 7
2011-06-21 09:02:55 PDT
Comment on
attachment 97924
[details]
cleanup; likely to fail build on various ports Looks like the only failure EWS found is: dom/Position.h: In member function ‘void WebCore::AXObjectCache::nodeTextChangePlatformNotification(WebCore::AccessibilityObject*, WebCore::AXObjectCache::AXTextChange, unsigned int, unsigned int)’: dom/Position.h:73:9: error: ‘WebCore::Position::LegacyEditingOffset::LegacyEditingOffset(int)’ is private accessibility/gtk/AXObjectCacheAtk.cpp:190:90: error: within this context dom/Position.h:73:9: error: ‘WebCore::Position::LegacyEditingOffset::LegacyEditingOffset(int)’ is private accessibility/gtk/AXObjectCacheAtk.cpp:190:109: error: within this context
Ryosuke Niwa
Comment 8
2011-06-21 09:07:09 PDT
(In reply to
comment #7
)
> (From update of
attachment 97924
[details]
) > Looks like the only failure EWS found is: > > dom/Position.h: In member function ‘void WebCore::AXObjectCache::nodeTextChangePlatformNotification(WebCore::AccessibilityObject*, WebCore::AXObjectCache::AXTextChange, unsigned int, unsigned int)’: > dom/Position.h:73:9: error: ‘WebCore::Position::LegacyEditingOffset::LegacyEditingOffset(int)’ is private > accessibility/gtk/AXObjectCacheAtk.cpp:190:90: error: within this context > dom/Position.h:73:9: error: ‘WebCore::Position::LegacyEditingOffset::LegacyEditingOffset(int)’ is private > accessibility/gtk/AXObjectCacheAtk.cpp:190:109: error: within this context
Right. See
comment #4
. AXObjectCacheAtk.cpp is instantiating a Range with two legacy editing positions.
Ryosuke Niwa
Comment 9
2011-06-21 09:57:55 PDT
Created
attachment 98002
[details]
createDeprecatedLegacyEditingPosition to createLegacyEditingPosition; fixed gtk build
Ryosuke Niwa
Comment 10
2011-06-22 08:52:54 PDT
Ping reviewers
Darin Adler
Comment 11
2011-06-22 09:33:26 PDT
Comment on
attachment 98002
[details]
createDeprecatedLegacyEditingPosition to createLegacyEditingPosition; fixed gtk build View in context:
https://bugs.webkit.org/attachment.cgi?id=98002&action=review
> Source/WebCore/dom/Position.h:70 > + int value() { return m_offset; }
Maybe make this const?
> Source/WebCore/dom/Position.h:73 > + LegacyEditingOffset(int offset) : m_offset(offset) { }
Maybe make this explicit too?
Ryosuke Niwa
Comment 12
2011-06-22 09:35:24 PDT
Thanks for the review. (In reply to
comment #11
)
> (From update of
attachment 98002
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=98002&action=review
> > > Source/WebCore/dom/Position.h:70 > > + int value() { return m_offset; } > > Maybe make this const? > > > Source/WebCore/dom/Position.h:73 > > + LegacyEditingOffset(int offset) : m_offset(offset) { } > > Maybe make this explicit too?
Will fix.
Ryosuke Niwa
Comment 13
2011-06-22 09:45:52 PDT
Committed
r89440
: <
http://trac.webkit.org/changeset/89440
>
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