Closed
Bug 762862
Opened 12 years ago
Closed 12 years ago
Rename nsTypedSelection to mozilla::Selection
Categories
(Core :: DOM: Selection, enhancement)
Core
DOM: Selection
Tracking
()
RESOLVED
FIXED
mozilla16
People
(Reporter: ayg, Assigned: ayg)
Details
Attachments
(1 file)
114.44 KB,
patch
|
ehsan.akhgari
:
review+
|
Details | Diff | Splinter Review |
What does "Typed" mean? Nobody knows. (At least, nobody I've spoken to.) Now that nsTypedSelections are being more widely used -- see bug 693933, bug 762841 -- it makes sense to have a less mysterious name.
Flags: in-testsuite-
Assignee | ||
Updated•12 years ago
|
Component: Editor → Selection
QA Contact: editor → selection
Assignee | ||
Comment 1•12 years ago
|
||
https://tbpl.mozilla.org/?tree=Try&rev=90743cdfeaa5 Hurry up before it bitrots! :) One thing I was unsure about: nsSelectionIterator was previously declared as "friend class nsSelectionIterator;" in nsTypedSelection.h inside nsTypedSelection, and otherwise only declared in nsSelection.cpp. But when I changed nsTypedSelection to be in a namespace, it thought I meant mozilla::nsSelectionIterator. But when I changed it to "friend class ::nsSelectionIterator;", it said that that doesn't name a type. So I wound up forward-declaring "class nsSelectionIterator;" at the top of Selection.h. Tell me if I should be doing something different -- I suspect I should.
Attachment #631360 -
Flags: review?(ehsan)
Comment 2•12 years ago
|
||
(In reply to Aryeh Gregor from comment #0) > What does "Typed" mean? Nobody knows. (At least, nobody I've spoken to.) > Now that nsTypedSelections are being more widely used -- see bug 693933, bug > 762841 -- it makes sense to have a less mysterious name. A selection class that you "type" in to your code? ;-)
Updated•12 years ago
|
Attachment #631360 -
Flags: review?(ehsan) → review+
Comment 3•12 years ago
|
||
(In reply to Aryeh Gregor from comment #1) > Created attachment 631360 [details] [diff] [review] > Patch v1 > > https://tbpl.mozilla.org/?tree=Try&rev=90743cdfeaa5 > > Hurry up before it bitrots! :) > > One thing I was unsure about: nsSelectionIterator was previously declared as > "friend class nsSelectionIterator;" in nsTypedSelection.h inside > nsTypedSelection, and otherwise only declared in nsSelection.cpp. But when > I changed nsTypedSelection to be in a namespace, it thought I meant > mozilla::nsSelectionIterator. But when I changed it to "friend class > ::nsSelectionIterator;", it said that that doesn't name a type. So I wound > up forward-declaring "class nsSelectionIterator;" at the top of Selection.h. > Tell me if I should be doing something different -- I suspect I should. Yeah, "friend class" can only implicitly forward-declare the class if it's in the same namespace. Now stop complaining about how C++ is not intuitive and whatnot! :D
Assignee | ||
Comment 4•12 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/dcd70e227b96 I rebased this to not be on top of bug 762841, so that I could push it ASAP and avoid bitrot. (I already had to resolve one conflict.)
Target Milestone: --- → mozilla16
Comment 5•12 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/dcd70e227b96
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•