Commit Graph

46 Commits

Author SHA1 Message Date
Kartikaya Gupta
050bd07ad1 Bug 1137267 - Remove unneeded flags to track touch listeners and touch caret. r=smaug,dvander,botond 2015-03-10 09:29:25 -04:00
Morris Tseng
37830d7edd Bug 1120750 - Part 5: Fix non-unified build bustage. 2015-02-12 21:05:50 -05:00
Morris Tseng
df7cad2964 Bug 1120750 - Part 3: Dispatch taponcaret using selectionstatechanged event. r=roc 2015-01-21 23:42:00 -05:00
Jeremy Chen
fb56ad0713 Bug 1122805 - v3 Update carets' positions based on coordinates of the root frame. r=roc 2015-02-05 01:36:00 +01:00
Jeremy Chen
5b3e2ce70a Bug 1127661 - Disable long tap event from APZ while dragging the touch caret. r=roc 2015-02-03 02:41:00 +01:00
David Zbarsky
1330fc1496 Bug 1125040: Use LayoutDeviceIntPoint for nsLayoutUtils::GetEventCoordinatesRelativeTo and Touch::mRefPoint r=botond 2015-02-01 17:27:31 -05:00
Peter Chang
0315667a8a Bug 1123179 - Bypass touchcaret visibility checking inside scrollable frame when touchcaret drag state is active, r=roc
--HG--
extra : rebase_source : 5370db85347a4ef93d6403e62cf385dc16a23b97
2015-01-28 01:32:00 +01:00
Ting-Yu Lin
ce2cdc6f5d Bug 1067728 - Part 1.1 - Move IsRectVisibleInScrollFrames to nsLayoutUtils. f=mtseng, r=roc 2014-12-08 01:53:00 +01:00
Ting-Yu Lin
6a76eb960c Bug 1067728 Part 1 - Generalize scroll frame boundary checking logic. f=mtseng, r=roc 2014-12-08 01:52:00 +01:00
Morris Tseng
6682e1351f Bug 1101392 - Part 2: Add a command that collapse selection to end after copying. r=roc 2014-11-26 23:06:00 +01:00
Ting-Yu Lin
5f94b5654e Bug 1090785 - Migrate to NSPR logging for touch caret. r=roc 2014-10-29 01:37:00 +01:00
Ryan VanderMeulen
bcc3ab5ec1 Merge m-c to inbound. a=merge 2014-10-29 16:51:39 -04:00
Jonathan Watt
9f3a575470 Bug 1090611 - Make nsCaret::PaintCaret take a Moz2D DrawTarget instead of nsRenderingContext. r=Bas 2014-10-29 17:07:11 +00:00
Ting-Yu Lin
3b4aaaf44c Bug 1059165 - Part 3 - Do not show touch caret when content is empty. r=ehsan
We want HasNonEmptyTextContent() to descend recursively into editingHost
since <div contenteditable="true"><span>123</span></div> should be
considered as non-empty.
2014-10-29 00:34:00 +01:00
Ting-Yu Lin
52a9ab27c8 Bug 1082486 - Part 4 - Check whether nsCaret shows in the scroll frame. r=roc
This patch check whether nsCaret shows in scroll frame. If yes, touch
caret will show, and its position will be clamp to scroll frame as
before. Otherwise, we hide it since the nsCaret will not be seen in this
case.
2014-10-16 22:03:00 +02:00
Ting-Yu Lin
983706ff4b Bug 1082486 - Part 5 - Hide touch caret when PresShell is suppressing painting. r=roc
When loading an html, painting is suppressed in PresShell. Therefore the
rect of nsCaret or the rect of nearest ancestor scroll frames will not
be correct. Touch caret will hide incorrectly because it cannot get the
necessary rect to calculate its position.

I added a condition in IsDisplayable() to skip when painting is
suppressed. Touch caret should sync its visibility with nsCaret again
when painting is unsuppressed, and those rects needed by touch caret
should be ready then.
2014-10-16 05:08:00 +02:00
Ting-Yu Lin
4b96620846 Bug 1082486 - Part 3 - Refactor UpdatePosition(). r=roc
GetTouchCaretPosition() is needed in a later patch.
2014-10-15 03:05:00 +02:00
Ting-Yu Lin
c4fac6802d Bug 1082486 - Part 2 - Make GetCanvasFrame() returns nsCanvasFrame*. r=roc
PresShell::GetCanvasFrame() already returns nsCanvasFrame*, and it's
needed to access nsCanvasFrame's method in a later patch.
2014-10-14 03:07:00 +02:00
Ting-Yu Lin
54d2ea8f5c Bug 1082486 - Part 1 - Clean up for Mozilla coding style. r=roc
Also, check mVisible before calling UpdatePosition() in
SyncVisibilityWithCaret().
2014-10-14 03:07:00 +02:00
Morris Tseng
50aae8d054 Bug 1067231 - Send touch caret tap event. r=ehsan 2014-10-12 23:44:00 +02:00
Ryan VanderMeulen
3754733bed Backed out changeset 0f7fe4800ace (bug 1027631) for non-unified bustage.
CLOSED TREE
2014-10-09 13:16:32 -04:00
Morris Tseng
12a3c15a2e Bug 1067231 - Send touch caret tap event. r=ehsan
DONTBUILD

--HG--
extra : rebase_source : 0dfc843425bccd13da56fd17d9d854352b07f9a3
2014-10-07 02:28:00 -04:00
Ryan VanderMeulen
2042f213da Backed out changeset 0f7fe4800ace for landing with the wrong bug number.
--HG--
extra : rebase_source : fe37a4e6b566cb2121079ad95bfdce99ab997d33
2014-10-09 11:39:12 -04:00
Morris Tseng
94997ac196 Bug 1027631 - Send touch caret tap event. r=ehsan 2014-10-07 02:28:00 -04:00
Ting-Yu Lin
89889ef13d Bug 1078991 - Add TouchCaret::GetCaretFocusFrame(). r=roc 2014-10-06 21:02:00 -04:00
Ting-Yu Lin
5d804d7cd5 Bug 1065244 - Part 3 - Fix SelectionCarets::SelectWord() is hard to trigger. f=mtseng, r=roc
Fix this issue by deploying the same logic as selection carets in
TouchCaret::IsOnTouchCaret().
2014-09-15 02:58:00 +02:00
Ting-Yu Lin
88ac0a85b6 Bug 1065244 - Part 1 - Add GetRectRelativeToFrame to nsLayoutUtils. f=mtseng, r=roc 2014-09-15 17:07:00 +02:00
Ting-Yu Lin
75ae3bce11 Bug 1057256 - Part 2 - Add null pointer check for touch and selection carets. r=roc
TouchCaret::IsDisplayable() contains more null pointer check. It covers
what's original there in TouchCaret::HandleEvent().
2014-08-25 02:50:00 +02:00
Robert O'Callahan
70c695fa57 Bug 1048752. Part 24: Rename and deCOM Set/GetCaretVisible. r=tn
--HG--
extra : rebase_source : 04249e9b22a62b8f2952515fa48f4ba3227e235e
2014-08-06 17:19:29 +12:00
Robert O'Callahan
9780343dd6 Bug 1048752. Part 17: Rename Get/SetCaretDOMSelection to Get/SetSelection. r=tn
The forward declaration of Selection in nsCaret.h will be used in later patches.

--HG--
extra : rebase_source : d1b749adac983c04d3365bb6bfb76a50101beeb5
2014-08-06 17:19:27 +12:00
Robert O'Callahan
ae6a16193a Bug 1048752. Part 16: Move nsFrameSelection::HINT to CaretAssociationHint.h. r=tn
This patch started an attempt to remove nsFrameSelection.h from nsCaret.h
and metastasized into a rather large refactoring patch that removed it
from some other header files as well, and changed nsFrameSelection::HINT
into a global-scope enum with better names. I also converted bools
into CaretAssociationHint in a few places where that was appropriate,
but there are still some more places (GetChildFrameContainingOffset)
where bools need to be converted. I figured this patch was big enough already.

--HG--
extra : rebase_source : cc618ef60e707e1360644340a2648de389383da0
2014-08-06 17:19:27 +12:00
Robert O'Callahan
922821fdc8 Bug 1048752. Part 14: Split GetGeometry into a static and a non-static version. r=tn
GetGeometry is used in two different ways. Sometimes it's used to get
information about a particular caret. Sometimes it's used to get
information about a particular selection that's not associated with
a caret. Splitting GetGeometry into a non-static version for the former
and a static version for the latter makes this more clear. Also it saves
code since for the latter version we don't have to get an nsCaret first.

--HG--
extra : rebase_source : b7730dac56b308a82b79b175749234c9a92b6f59
2014-08-06 17:19:26 +12:00
Robert O'Callahan
7ea822125b Bug 1048752. Part 9: Remove nsCaret.h from nsDisplayList.h. r=tn
I got tired of slow build turnarounds every time I modified nsCaret.h.

--HG--
extra : rebase_source : 0c4598c4881ab8de0a636b08c70fb801bb912247
2014-08-06 17:19:25 +12:00
Ting-Yu Lin
3fb776e5cc Bug 1046732 - Part 1: Fix incorrect event message used in TouchCaret.cpp. r=ehsan
NS_WHEEL_EVENT_START isn't a specific event message for compairing in
the switch case. Since we would like to hide touch caret whenever
receving wheel events, all the wheel event types are added.
2014-08-07 01:26:00 -04:00
Ting-Yu Lin
f6297bc01f Bug 1016184 - Part 3b: Revise touch caret visibility logic. f=pchang, r=ehsan
* Refactor UpdateTouchCaret() into smaller functions.
* Update touch caret in PresShell::DidDoReflow() and
  PresShell::UnsuppressAndInvalidate() if needed.
2014-07-27 00:15:00 +02:00
Ting-Yu Lin
f42a1a8202 Bug 1016184 - Part 3a: Fix typos and minor style changes. r=ehsan
Also group the private section together, and remove the protect section
since TouchCaret is a MOZ_FINAL class.
2014-07-27 00:13:00 +02:00
Morris Tseng
2ad09f0cd9 Bug 1023041 - Part 2: Generate correct event when dragging touch caret. r=roc 2014-08-04 00:24:00 -04:00
Ryan VanderMeulen
94be6c5efa Backed out 9 changesets (bug 1016184) for frequent OSX Gip timeouts.
Backed out changeset 0893f2ef4b9a (bug 1016184)
Backed out changeset 93587ce1162b (bug 1016184)
Backed out changeset a52c9d674927 (bug 1016184)
Backed out changeset ca2fd0f41a12 (bug 1016184)
Backed out changeset 84dacf014e39 (bug 1016184)
Backed out changeset 16854e321f23 (bug 1016184)
Backed out changeset 8acd5e707c83 (bug 1016184)
Backed out changeset d0513eae0c97 (bug 1016184)
Backed out changeset 0d03cd217c64 (bug 1016184)
2014-07-31 13:29:30 -04:00
Ting-Yu Lin
5fcaec2856 Bug 1016184 part 3b - Revise touch caret visibility logic. f=pchang, r=ehsan
* Refactor UpdateTouchCaret() into smaller functions.
* Update touch caret in PresShell::DidDoReflow() and
  PresShell::UnsuppressAndInvalidate() if needed.
2014-07-27 00:15:00 +02:00
Ting-Yu Lin
c388911523 Bug 1016184 part 3a - Fix typos and minor style changes. r=ehsan
Also group the private section together, and remove the protect section
since TouchCaret is a MOZ_FINAL class.
2014-07-27 00:13:00 +02:00
Ting-Yu Lin
ec54b26220 Bug 1016184 - part 2 - Add debug logs to touch caret. r=ehsan 2014-07-13 21:29:00 +02:00
Kartikaya Gupta
4ff5fbdfab Bug 1036444 - Kill touchenter and touchleave events. r=smaug 2014-07-09 10:27:00 -04:00
Ting-Yu Lin
b97f8e986a Bug 1020261 - Part 1: Fix touch event handling for touch caret. r=roc
For touch events generated by marionette, the touch id is not started
from 0. Therefore, instead of getting the event position of touch id 0
directly in HandleTouchDownEvent(), we should loop over all the touch
ids to get their positions.
2014-06-12 22:58:00 -04:00
Morris Tseng
508f746be3 Bug 987718 - Part 5: Add SelectionCarets; r=roc 2014-06-04 22:57:00 +02:00
Phoebe Chang
943fc38329 Bug 924692 - Part 4: Hooks up event handling to TouchCaret; r=roc, bugs 2014-06-03 15:08:54 +08:00
Phoebe Chang
5413497932 Bug 924692 - Part 3: Add TouchCaret; r=roc, bugs 2014-06-03 15:08:45 +08:00