Commit graph

261 commits

Author SHA1 Message Date
Mirko Brodesser
3e015ac7bf Bug 1635709: part 25) const qualify arguments of GetCellLayout and GetCellIndexes. r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D77423
2020-06-02 08:42:49 +00:00
Mirko Brodesser
59fe54586f Bug 1635709: part 24.2) Rename childContent to aChildContent. r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D77254
2020-06-02 09:08:44 +00:00
Mirko Brodesser
ed1b7493ab Bug 1635709: part 24.1) Factor HandleDragSelecting and HandleMouseUpOrDown out from TableSelection::HandleSelection. r=masayuki
`HandleSelection` was too complex.

The arguments of the new methods will be renamed in a separate commit to
simplify reviewing and avoid mistakes.

Differential Revision: https://phabricator.services.mozilla.com/D77253
2020-06-02 09:05:57 +00:00
Mirko Brodesser
17a7e3429d Bug 1635709: part 23) Factor code out to IsContentInActivelyEditableTableCell. r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D77004
2020-05-27 14:39:11 +00:00
Mirko Brodesser
f2aea44084 Bug 1635709: part 22) Rename local cellparent variables to inclusiveTableCellAncestor. r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D75565
2020-05-25 13:54:30 +00:00
Mirko Brodesser
d5b4e47993 Bug 1635709: part 21) Rename TableSelection::mCellParent to mClosestInclusiveTableCellAncestor. r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D75564
2020-05-25 13:54:20 +00:00
Mirko Brodesser
916b42b13c Bug 1635709: part 20) Rename GetCellParent to GetClosestInclusiveTableCellAncestor. r=masayuki
It's more accurate.

Differential Revision: https://phabricator.services.mozilla.com/D75563
2020-05-25 13:54:10 +00:00
Mirko Brodesser
21c40347c1 Bug 1635709: part 19) Clean up a little in nsFrameSelection::MoveCaret. r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D75562
2020-05-25 13:53:59 +00:00
Mirko Brodesser
a07f299f9c Bug 1635709: part 13) Remove stack variable for Selection::mUserInitiated. r=masayuki
Simplifies reasoning about the code when using searchfox.

Differential Revision: https://phabricator.services.mozilla.com/D75057
2020-05-13 11:10:41 +00:00
Mirko Brodesser
d20c4961f6 Bug 1635709: part 12) Factor determining range most distant from anchor out from AutoPrepareFocusRange. r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D74858
2020-05-13 08:01:29 +00:00
Mirko Brodesser
3310444867 Bug 1635709: part 11) Factor removing generated ranges out from AutoPrepareFocusRange. r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D74857
2020-05-13 08:00:51 +00:00
Mirko Brodesser
cb2a7735a3 Bug 1635709: part 10) Factor IsAnchorRelativeOperation out from AutoPrepareFocusRange. r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D74856
2020-05-13 08:00:41 +00:00
Mirko Brodesser
74d02b07c6 Bug 1635709: part 9) Add DesiredCaretPos::Invalidate. r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D74618
2020-05-12 09:42:08 +00:00
Mirko Brodesser
943f40f25e Bug 1635709: part 8) Remove superfluously setting mIsSet in nsFrameSelection's constructor. r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D74617
2020-05-12 09:42:06 +00:00
Mirko Brodesser
676b66d20f Bug 1635709: part 7) Move nsFrameSelection::SetDesiredCaretPos and FetchDesiredCaretPos to DesiredCaretPos. r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D74616
2020-05-12 09:42:16 +00:00
Mirko Brodesser
ca24d8b332 Bug 1635709: part 6) Rename nsFrameSelection::*DesiredPos to *DesiredCaretPos. r=masayuki
`nsFrameSelection` has (too) many responsibilites, this adds some
clarification.

Differential Revision: https://phabricator.services.mozilla.com/D74615
2020-05-12 09:42:01 +00:00
Mirko Brodesser
194a3b964e Bug 1635709: part 5) Annotate Selection::ReplaceAnchorFocusRange with MOZ_CAN_RUN_SCRIPT. r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D74383
2020-05-11 09:39:33 +00:00
Mirko Brodesser
193ee7189e Bug 1635709: part 1) Rename nsFrameSelection::SetCaretBidiLevel to SetCaretBidiLevelAndMaybeSchedulePaint. r=hsivonen
The old name was misleading.

Differential Revision: https://phabricator.services.mozilla.com/D74051
2020-05-06 15:26:07 +00:00
Botond Ballo
5cffd06241 Bug 1631568 - Have nsLayoutUtils::GetFrameForPoint() and GetFramesForArea() take a RelativeTo parameter. r=tnikkel
This removes the need for FrameForPointOptions::IsRelativeToLayoutViewport,
and makes sure each call site of these functions indicates whether the
input point/rect is in visual or layout coordinates.

Several call sites were passing in layout coordinates without setting the
IsRelativeToLayoutViewport flag, which this patch corrects.

Differential Revision: https://phabricator.services.mozilla.com/D71705
2020-05-05 15:24:12 +00:00
Mirko Brodesser
a060e2efd4 Bug 1634663: part 4) Declare callers of Selection::GetRangeAt const in layout code. r=masayuki
Depends on D73446

Differential Revision: https://phabricator.services.mozilla.com/D73447
2020-05-02 23:46:01 +00:00
Masayuki Nakano
11af44e544 Bug 1632726 - part 2: Remove some unused nsISelectionController methods r=smaug
Even in comm-central and BlueGriffon, `nsISelectionController::*ForDelete()`
are not used.  Therefore, we can remove them safely.

Differential Revision: https://phabricator.services.mozilla.com/D72296
2020-04-27 06:20:31 +00:00
Masayuki Nakano
adf7a304f3 Bug 1632726 - part 1: Create utility methods to compute delete range from collapsed selection in nsFrameSelection r=smaug
Currently, `EditorBase::ExtendSelectionForDelete()` depends on some
`nsISelectionController` methods to compute extended range for deletion
from collapsed selection.  They are implemented by
`nsFrameSelection::MoveCaret()` and `nsFrameSelection::TakeFocus()`.
Ideally, we should split these methods for computation part and performing
part.  However, they change selection with updating other selection state,
for example, table selection state and bidi information.  Therefore, it's
impossible to split them with simple code.  However, I need to change
`EditorBase::ExtendSelectionForDelete()` just return extended range.

Therefore, this patch creates `nsFrameSelection::PeekOffsetForCaretMove()`
which has the main path in `MoveCaret()` for the `EditorBase` method.

Then, `MoveCaret()` and new `nsFrameSelection::CreateRangeExtendedToSomewhere()`
share the computation code of expanding normal selection.

Finally, this patch wraps `nsFrameSelection::CreateRangeExtendedToSomewhere()`
with new public inline methods for `EditorBase`.

The following patch will remove no-user methods of `nsISelectionController`.

Differential Revision: https://phabricator.services.mozilla.com/D72295
2020-04-30 10:05:35 +00:00
Csoregi Natalia
b073baab86 Backed out 30 changesets (bug 1556556, bug 1631568) for multiple mochitest failures. CLOSED TREE
Backed out changeset edd529f7a9c5 (bug 1631568)
Backed out changeset 1cc0881e244b (bug 1631568)
Backed out changeset ed3c1e85d5e3 (bug 1556556)
Backed out changeset 38ffc6215bbf (bug 1556556)
Backed out changeset 03c2c25d8023 (bug 1556556)
Backed out changeset 9c717eb067b8 (bug 1556556)
Backed out changeset 98e26bc98b85 (bug 1556556)
Backed out changeset 05a6a581e755 (bug 1556556)
Backed out changeset 867946cf05bb (bug 1556556)
Backed out changeset 20d72a334530 (bug 1556556)
Backed out changeset 2c62e61d9054 (bug 1556556)
Backed out changeset 62a223d057d2 (bug 1556556)
Backed out changeset 2c5d55a1f0b1 (bug 1556556)
Backed out changeset 700447945b4e (bug 1556556)
Backed out changeset 93190ae4f5ff (bug 1556556)
Backed out changeset a7bd34d961bb (bug 1556556)
Backed out changeset fccd1d3c7189 (bug 1556556)
Backed out changeset 24056e47183d (bug 1556556)
Backed out changeset 204881474cc1 (bug 1556556)
Backed out changeset 387320881876 (bug 1556556)
Backed out changeset be8f5eb58460 (bug 1556556)
Backed out changeset 629c58a9166b (bug 1556556)
Backed out changeset 4312b2b5dda8 (bug 1556556)
Backed out changeset d11dbf6403a5 (bug 1556556)
Backed out changeset 95c54c023779 (bug 1556556)
Backed out changeset 80fcb7e71188 (bug 1556556)
Backed out changeset d75a4ecb0d47 (bug 1556556)
Backed out changeset 903c4de34e7a (bug 1556556)
Backed out changeset f15334a3e803 (bug 1556556)
Backed out changeset 9553e99137ea (bug 1556556)
2020-04-28 12:43:11 +03:00
Botond Ballo
2cb46cfa4b Bug 1631568 - Have nsLayoutUtils::GetFrameForPoint() and GetFramesForArea() take a RelativeTo parameter. r=tnikkel
This removes the need for FrameForPointOptions::IsRelativeToLayoutViewport,
and makes sure each call site of these functions indicates whether the
input point/rect is in visual or layout coordinates.

Several call sites were passing in layout coordinates without setting the
IsRelativeToLayoutViewport flag, which this patch corrects.

Differential Revision: https://phabricator.services.mozilla.com/D71705
2020-04-28 01:44:43 +00:00
Masayuki Nakano
6cbea10c99 Bug 1632724 - part 1: Move common methods for handling delete selection to EditorBase r=m_kato
`DeleteSelection*()` are members of `TextEditor`, but they are also used by
`HTMLEditor`.  Therefore, they and pref cache members for them should be
in `EditorBase` too.

Depends on D71911

Differential Revision: https://phabricator.services.mozilla.com/D72290
2020-04-24 14:55:09 +00:00
Kristen Wright
05a7022978 Bug 1626388 - Convert dom.select_events.textcontrols.enabled to static pref r=njn
Converts dom.select_events.textcontrols.enabled to a static pref.

Differential Revision: https://phabricator.services.mozilla.com/D69614

--HG--
extra : moz-landing-system : lando
2020-04-06 23:30:18 +00:00
Mirko Brodesser
e5aee55330 Bug 1626665: part 4) Reorder code in nsFrameSelection::MoveCaret to allow nsPeekOffsetStruct::mDirection to become const. r=hsivonen
`nsPeekOffsetStruct` contains a mixture or input and output members.
This simplifies reasoning about them.

Depends on D69573

Differential Revision: https://phabricator.services.mozilla.com/D69769

--HG--
extra : moz-landing-system : lando
2020-04-06 08:45:01 +00:00
Mirko Brodesser
e7cdb1cf10 Bug 1623858: part 16) Annotate nsFrameSelection::HandleTableSelection with [[nodiscard]]. r=hsivonen
Depends on D68575

Differential Revision: https://phabricator.services.mozilla.com/D68576

--HG--
extra : moz-landing-system : lando
2020-03-30 08:35:36 +00:00
Mirko Brodesser
4c2e63fddc Bug 1623858: part 15) Remove some conditions in nsFrameSelection::TakeFocus which are always true. r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D68575

--HG--
extra : moz-landing-system : lando
2020-03-30 08:32:42 +00:00
Mirko Brodesser
803698911f Bug 1624633: part 1) Move Selection::mRanges to StyledRanges struct. r=hsivonen
This allows methods operating on the ranges to be moved to that struct.

To see where this leads to, consider the following reviews.

Differential Revision: https://phabricator.services.mozilla.com/D68217

--HG--
extra : moz-landing-system : lando
2020-03-27 11:21:25 +00:00
Mirko Brodesser
ad4d7454de Bug 1622752: annotate Selection::ScrollIntoView with MOZ_CAN_RUN_SCRIPT. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D67002

--HG--
extra : moz-landing-system : lando
2020-03-16 21:04:46 +00:00
Emilio Cobos Álvarez
04828e3a4a Bug 253870 - Make disabled form controls selectable. r=masayuki,MarcoZ
This rejiggers a bit the way selection focus is handled so that focusing a
disabled form control with the mouse handles selection properly, and hides the
document selection and so on.

This matches the behavior of other browsers as far as I can tell.

Given now readonly and disabled editors behave the same, we can simplify a bit
the surrounding editor code.

Differential Revision: https://phabricator.services.mozilla.com/D66464

--HG--
extra : moz-landing-system : lando
2020-03-19 13:18:16 +00:00
Mirko Brodesser
c602e0e0d7 Bug 1623333: part 4) Assert Selection's type is eNormal in relevant methods accessing mFrameSelection. r=smaug
Helps to determine which methods of `nsFrameSelection` are intended to
be called only for the `eNormal` Selection.

Driven by the idea that state of `nsFrameSelection` relevant only for
the `eNormal` Selection should later move to a `NormalSelection` class.

Differential Revision: https://phabricator.services.mozilla.com/D67445

--HG--
extra : moz-landing-system : lando
2020-03-19 11:08:58 +00:00
Mirko Brodesser
d252ed1175 Bug 1623333: part 2) Declare Selection::mSelectionType const. r=smaug
Simplifies reasoning about it.

Differential Revision: https://phabricator.services.mozilla.com/D67328

--HG--
extra : moz-landing-system : lando
2020-03-19 09:25:02 +00:00
Mirko Brodesser
f7f372d8a6 Bug 1621620: part 2) Declare nsFrameSelection::ConstrainFrameAndPointToAnchorSubtree const. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D66394

--HG--
extra : moz-landing-system : lando
2020-03-18 16:33:13 +00:00
Mirko Brodesser
86eec2f9fe Bug 1623040: split nsRange::SetSelection into RegisterSelection and UnregisterSelection. r=smaug
The name "SetSelection" was misleading, because it did more than a
setter.

Differential Revision: https://phabricator.services.mozilla.com/D67126

--HG--
extra : moz-landing-system : lando
2020-03-18 09:06:10 +00:00
Simon Giesecke
8aa47bcfb7 Bug 1613985 - Use default for equivalent-to-default constructors/destructors in layout. r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D66016

--HG--
extra : moz-landing-system : lando
2020-03-17 09:38:32 +00:00
Mihai Alexandru Michis
58bc354025 Backed out changeset 9eeee9ec66d9 (bug 253870) for causing failures in browser_bug1261299.js
CLOSED TREE
2020-03-16 22:32:41 +02:00
Emilio Cobos Álvarez
9f28f89085 Bug 253870 - Make disabled form controls selectable. r=masayuki,MarcoZ
This rejiggers a bit the way selection focus is handled so that focusing a
disabled form control with the mouse handles selection properly, and hides the
document selection and so on.

This matches the behavior of other browsers as far as I can tell.

Given now readonly and disabled editors behave the same, we can simplify a bit
the surrounding editor code.

Differential Revision: https://phabricator.services.mozilla.com/D66464

--HG--
extra : moz-landing-system : lando
2020-03-16 17:41:07 +00:00
Mirko Brodesser
ec9cb4d8ef Bug 1622199: annotate Selection::AddRangeAndSelectFramesAndNotifyListeners with MOZ_CAN_RUN_SCRIPT. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D66759

--HG--
extra : moz-landing-system : lando
2020-03-13 15:46:13 +00:00
Henri Sivonen
7d98d5c9e0 Bug 1618219 - Use BrowsingContext for activeness check in nsFrameSelection.cpp. r=NeilDeakin
Differential Revision: https://phabricator.services.mozilla.com/D65956

--HG--
extra : moz-landing-system : lando
2020-03-11 15:56:04 +00:00
Mirko Brodesser
76ae1d169f Bug 1620952: part 9) Rename nsFrameSelection::GetBatching to IsBatching. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D66061

--HG--
extra : moz-landing-system : lando
2020-03-11 09:18:18 +00:00
Mirko Brodesser
1535e53831 Bug 1620952: part 7) Group batching members. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D66059

--HG--
extra : moz-landing-system : lando
2020-03-11 09:18:02 +00:00
Mirko Brodesser
c1d76e9941 Bug 1620952: part 6) Group mDesiredPos and mDesiredPosSet. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D65961

--HG--
extra : moz-landing-system : lando
2020-03-11 09:17:55 +00:00
Mirko Brodesser
2ab206b6d4 Bug 1620952: part 5) Group limiter members in nsFrameSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D65960

--HG--
extra : moz-landing-system : lando
2020-03-11 09:17:47 +00:00
Mirko Brodesser
9aa383b1f7 Bug 1620952: part 4) Group caret members in nsFrameSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D65959

--HG--
extra : moz-landing-system : lando
2020-03-10 14:08:11 +00:00
Mirko Brodesser
b4e19dc9cb Bug 1620952: part 3) Group delayed mouse event members in nsFrameSelection. r=jfkthame
Simplifies analyzing and further refactoring `nsFrameSelection`.

Differential Revision: https://phabricator.services.mozilla.com/D65957

--HG--
extra : moz-landing-system : lando
2020-03-10 12:41:13 +00:00
Mirko Brodesser
b58f603d3f Bug 1620952: part 2) Remove nsFrameSelection::Init. r=jfkthame
Will allow to declare some members const.

Differential Revision: https://phabricator.services.mozilla.com/D65954

--HG--
extra : moz-landing-system : lando
2020-03-10 12:41:05 +00:00
Mirko Brodesser
f48facbc7d Bug 1619549: part 6) Factor out code from nsFrameSelection::HandleDrag to MaintainedRange::AdjustContentOffsets. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D65297

--HG--
extra : moz-landing-system : lando
2020-03-09 14:19:39 +00:00
Mirko Brodesser
6679773961 Bug 1619549: part 5) Move core of nsFrameSelection::MaintainSelection to MaintainedRange. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D65120

--HG--
extra : moz-landing-system : lando
2020-03-09 14:19:29 +00:00
Mirko Brodesser
4deab48718 Bug 1619549: part 4) Move nsFrameSelection::AdjustForMaintainedSelection to MaintainedRange. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D65119

--HG--
extra : moz-landing-system : lando
2020-03-09 14:19:26 +00:00
Mirko Brodesser
410e3284f4 Bug 1619549: part 3) Use RefPtr in nsFrameSelection::HandleClick. r=jfkthame
Simplifies following simplifications.

Differential Revision: https://phabricator.services.mozilla.com/D65118

--HG--
extra : moz-landing-system : lando
2020-03-09 14:19:10 +00:00
Mirko Brodesser
b1ecc4e48d Bug 1619549: part 2) Add assertion to nsFrameSelection::HandleClick. r=jfkthame
Helps reasoning about it.

Differential Revision: https://phabricator.services.mozilla.com/D65117

--HG--
extra : moz-landing-system : lando
2020-03-09 14:19:02 +00:00
Mirko Brodesser
1dcf5265e1 Bug 1619549: part 1) Group mMaintainRange and mMaintainedAmount in MaintainedRange. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D65106

--HG--
extra : moz-landing-system : lando
2020-03-09 14:18:55 +00:00
Mirko Brodesser
3b935e0da5 Bug 1619617: part 2) Annotate UnselectCells with MOZ_CAN_RUN_SCRIPT. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D65512

--HG--
extra : moz-landing-system : lando
2020-03-06 12:03:30 +00:00
Mirko Brodesser
efbaffc13c Bug 1615581: part 19) Decouple UpdateSelectionCacheOnRepaintSelection from nsFrameSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63482

--HG--
extra : moz-landing-system : lando
2020-03-03 09:15:22 +00:00
Mirko Brodesser
2e40a7367b Bug 1615581: part 18) Move core of nsFrameSelection::HandleTableSelection to TableSelection::HandleSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63481

--HG--
extra : moz-landing-system : lando
2020-03-02 15:09:34 +00:00
Mirko Brodesser
4e70ce992b Bug 1615581: part 17) Correct style in nsFrameSelection::HandleTableSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63480

--HG--
extra : moz-landing-system : lando
2020-03-02 15:09:36 +00:00
Mirko Brodesser
b0148d9b7a Bug 1615581: part 16) Move nsFrameSelection::SelectRowOrColumn to TableSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63324

--HG--
extra : moz-landing-system : lando
2020-03-02 15:09:38 +00:00
Mirko Brodesser
88584c4608 Bug 1615581: part 15) Update style in nsFrameSelection::SelectRowOrColumn. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63323

--HG--
extra : moz-landing-system : lando
2020-03-02 15:09:17 +00:00
Mirko Brodesser
b2c626c5ff Bug 1615581: part 14) Move SelectBlockOfCells to TableSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63307

--HG--
extra : moz-landing-system : lando
2020-03-02 15:09:19 +00:00
Mirko Brodesser
4b67e294f7 Bug 1615581: part 13) Move mDragSelectingCells to TableSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63297

--HG--
extra : moz-landing-system : lando
2020-03-02 15:09:22 +00:00
Mirko Brodesser
e8f4f2644a Bug 1615581: part 12) Decouple AddCellsToSelection from nsFrameSelection. r=jfkthame
Simplifies reasoning about `nsFrameSelection` and allows to decouple
more code from it.

Differential Revision: https://phabricator.services.mozilla.com/D63296

--HG--
extra : moz-landing-system : lando
2020-03-02 15:09:24 +00:00
Mirko Brodesser
7ee453e1fb Bug 1615581: part 11) Use free function SelectCellElement in AddCellsToSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63295

--HG--
extra : moz-landing-system : lando
2020-03-02 15:09:26 +00:00
Mirko Brodesser
eb1d4d2a75 Bug 1615581: part 10) Update style in nsFrameSelection::AddCellsToSelection. r=jfkthame
Simplifies reviewing the following part.

Differential Revision: https://phabricator.services.mozilla.com/D63294

--HG--
extra : moz-landing-system : lando
2020-03-02 15:09:29 +00:00
Narcis Beleuzu
44ec37a8cf Backed out 10 changesets (bug 1615581) for bustages on nsFrameSelection.cpp . CLOSED TREE
Backed out changeset 47087b5b4e42 (bug 1615581)
Backed out changeset 1489a8cb97e9 (bug 1615581)
Backed out changeset 1f89d7b3668a (bug 1615581)
Backed out changeset ea9869a4fb04 (bug 1615581)
Backed out changeset 9678a5d6a970 (bug 1615581)
Backed out changeset 13fd32562d0c (bug 1615581)
Backed out changeset c3c657e53988 (bug 1615581)
Backed out changeset 5272f4d02c88 (bug 1615581)
Backed out changeset 83dbbfb4b4e8 (bug 1615581)
Backed out changeset 9aa0aef619ed (bug 1615581)
2020-03-02 17:05:00 +02:00
Mirko Brodesser
523f549231 Bug 1617165: part 2) Rename nsFrameSelection::PostReason and PopReason. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63668

--HG--
extra : moz-landing-system : lando
2020-03-02 13:48:24 +00:00
Mirko Brodesser
bbb9d9ba21 Bug 1615581: part 19) Decouple UpdateSelectionCacheOnRepaintSelection from nsFrameSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63482

--HG--
extra : moz-landing-system : lando
2020-03-02 10:25:56 +00:00
Mirko Brodesser
c5f6e249b8 Bug 1615581: part 18) Move core of nsFrameSelection::HandleTableSelection to TableSelection::HandleSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63481

--HG--
extra : moz-landing-system : lando
2020-03-02 10:25:54 +00:00
Mirko Brodesser
4a5e298cee Bug 1615581: part 17) Correct style in nsFrameSelection::HandleTableSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63480

--HG--
extra : moz-landing-system : lando
2020-03-02 10:25:51 +00:00
Mirko Brodesser
9cb478e6df Bug 1615581: part 16) Move nsFrameSelection::SelectRowOrColumn to TableSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63324

--HG--
extra : moz-landing-system : lando
2020-03-02 10:25:44 +00:00
Mirko Brodesser
6b59f98679 Bug 1615581: part 15) Update style in nsFrameSelection::SelectRowOrColumn. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63323

--HG--
extra : moz-landing-system : lando
2020-03-02 10:25:41 +00:00
Mirko Brodesser
795f2590f4 Bug 1615581: part 14) Move SelectBlockOfCells to TableSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63307

--HG--
extra : moz-landing-system : lando
2020-03-02 10:59:37 +00:00
Mirko Brodesser
ee9cbbd1d4 Bug 1615581: part 13) Move mDragSelectingCells to TableSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63297

--HG--
extra : moz-landing-system : lando
2020-03-02 10:25:37 +00:00
Mirko Brodesser
49b48fa2d9 Bug 1615581: part 12) Decouple AddCellsToSelection from nsFrameSelection. r=jfkthame
Simplifies reasoning about `nsFrameSelection` and allows to decouple
more code from it.

Differential Revision: https://phabricator.services.mozilla.com/D63296

--HG--
extra : moz-landing-system : lando
2020-03-02 10:25:34 +00:00
Mirko Brodesser
2e1d8cdbbf Bug 1615581: part 11) Use free function SelectCellElement in AddCellsToSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63295

--HG--
extra : moz-landing-system : lando
2020-03-02 10:25:30 +00:00
Mirko Brodesser
e71876a917 Bug 1615581: part 10) Update style in nsFrameSelection::AddCellsToSelection. r=jfkthame
Simplifies reviewing the following part.

Differential Revision: https://phabricator.services.mozilla.com/D63294

--HG--
extra : moz-landing-system : lando
2020-03-02 10:25:27 +00:00
Sylvestre Ledru
ca6530131a Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan,kvark
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D63787

--HG--
extra : moz-landing-system : lando
2020-02-24 15:33:38 +00:00
Mirko Brodesser
34837d9fc2 Bug 1615581: part 9) Decouple SelectCellElement core from nsFrameSelection. r=jfkthame
Allows to move `nsFrameSelection::AddCellsToSelection`, a caller of
`SelectCellElement, from `nsFrameSelection` to `TableSelection` in a
subsequent step.

Differential Revision: https://phabricator.services.mozilla.com/D63158

--HG--
extra : moz-landing-system : lando
2020-02-20 15:03:26 +00:00
Mirko Brodesser
7b16ca222e Bug 1615581: part 8) Decouple CreateAndAddRange from nsFrameSelection. r=jfkthame
Preparation to move `SelectCellElement` to `TableSelection`.

Differential Revision: https://phabricator.services.mozilla.com/D63157

--HG--
extra : moz-landing-system : lando
2020-02-20 15:03:19 +00:00
Mirko Brodesser
8308badf1c Bug 1615581: part 7) Move UnselectCells to TableSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63063

--HG--
extra : moz-landing-system : lando
2020-02-20 14:06:30 +00:00
Mirko Brodesser
c308359bf2 Bug 1615581: part 6) Move GetFirstCellRange to TableSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63061

--HG--
extra : moz-landing-system : lando
2020-02-18 12:52:08 +00:00
Mirko Brodesser
ea6f268216 Bug 1615581: part 5) Move GetNextCellRange to TableSelection. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D63060

--HG--
extra : moz-landing-system : lando
2020-02-18 12:48:44 +00:00
Mirko Brodesser
63edde2d24 Bug 1615581: part 4) Declare GetFirstCellNodeInRange's range argument const. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D62905

--HG--
extra : moz-landing-system : lando
2020-02-18 12:29:07 +00:00
Mirko Brodesser
ed3750ee94 Bug 1615581: part 3) Rename mSelectingTableCellMode to mMode. r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D62904

--HG--
extra : moz-landing-system : lando
2020-02-18 12:28:59 +00:00
Mirko Brodesser
7471880b9b Bug 1615581: part 2) Group table-cell-selection related members in common struct. r=jfkthame
Simplifies reasoning about table-cell related code, because it's less
coupled with `nsFrameSelection`.

Differential Revision: https://phabricator.services.mozilla.com/D62903

--HG--
extra : moz-landing-system : lando
2020-02-18 12:28:52 +00:00
Mirko Brodesser
f170973369 Bug 1615581: part 1) Rename TableSelection to TableSelectionMode. r=jfkthame
See part 2) why this is necessary.

Differential Revision: https://phabricator.services.mozilla.com/D62902

--HG--
extra : moz-landing-system : lando
2020-02-18 12:28:45 +00:00
Mirko Brodesser
4688607b42 Bug 1615581: part 0) Correct style around TableSelection usage. r=jfkthame
Preparatory step for the following parts.

Differential Revision: https://phabricator.services.mozilla.com/D63058

--HG--
extra : moz-landing-system : lando
2020-02-18 12:28:32 +00:00
Mirko Brodesser
3d79d25cdf Bug 1615304: part 1) Move nsFrameSelection::DeleteFromDocument to Selection. r=smaug
Helps to clarify the role of `nsFrameSelection`.

Differential Revision: https://phabricator.services.mozilla.com/D62879

--HG--
extra : moz-landing-system : lando
2020-02-14 10:58:06 +00:00
Simon Giesecke
b50347f917 Bug 1611415 - Prefer using std::move over forget. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D60980

--HG--
extra : moz-landing-system : lando
2020-02-13 14:38:48 +00:00
shindli
91aa0518dd Backed out changeset 0c982bc69cb3 (bug 1611415) for causing build bustages in /builds/worker/workspace/build/src/obj-firefox/dist/include/nsCOMPtr CLOSED TREE 2020-02-12 20:13:29 +02:00
Simon Giesecke
f604a47fa5 Bug 1611415 - Applied FixItHints from mozilla-non-std-move. r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D60980

--HG--
extra : moz-landing-system : lando
2020-02-12 17:24:41 +00:00
Mirko Brodesser
ea1f257885 Bug 1614636: simplify arguments of nsFrameSelection::HandleClick. r=jfkthame
Simplifies understanding its dependent methods.

Differential Revision: https://phabricator.services.mozilla.com/D62433

--HG--
extra : moz-landing-system : lando
2020-02-11 15:12:26 +00:00
Mirko Brodesser
4a2c7022b1 Bug 1613378: part 6) Remove copy&pasted IsValidSelectionPoint function. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D62039

--HG--
extra : moz-landing-system : lando
2020-02-11 10:50:57 +00:00
Brindusan Cristian
a68356b907 Backed out 5 changesets (bug 1613378) for mochitest failures at test_general.html. CLOSED TREE
Backed out changeset f38b806ee78b (bug 1613378)
Backed out changeset cee4bbabc4b5 (bug 1613378)
Backed out changeset e3a2ab6d7267 (bug 1613378)
Backed out changeset 6fe76439f1d3 (bug 1613378)
Backed out changeset f3baf3407cbe (bug 1613378)
2020-02-11 12:27:49 +02:00
Mirko Brodesser
dd99b9338c Bug 1613378: part 6) Remove copy&pasted IsValidSelectionPoint function. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D62039

--HG--
extra : moz-landing-system : lando
2020-02-10 13:25:03 +00:00
Mirko Brodesser
ce8bf8cde1 Bug 1613378: part 4) Declare some methods in nsFrameSelection static. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D62037

--HG--
extra : moz-landing-system : lando
2020-02-07 16:13:27 +00:00
Mirko Brodesser
6c8a08fecb Bug 1613378: part 2) Remove unnecessary dependency from nsFrameSelection::GetCellLayout to mPresShell and declare it static. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D61692

--HG--
extra : moz-landing-system : lando
2020-02-07 09:24:43 +00:00
Mirko Brodesser
a205cfcd91 Bug 1613071: rename RangeData to StyledRange and move it to separate file. r=smaug
Breaks the dependency from Selection.h. Allows reuse for Selection
across the Shadow DOM boundary, which will require styled ranges to be
stored in `DocumentOrShadowRoot` too.

Differential Revision: https://phabricator.services.mozilla.com/D61549

--HG--
extra : moz-landing-system : lando
2020-02-05 09:12:23 +00:00
Cosmin Sabou
8833c36c14 Backed out changeset 6c68992f760e (bug 1613071) for build bustages on XPathGenerator.cpp
CLOSED TREE
2020-02-04 16:40:28 +02:00