Commit Graph

5811 Commits

Author SHA1 Message Date
David Zbarsky
10410114ac Bug 952977: Switch some uses of gfx3DMatrix in nsLayoutUtils to Matrix4x4 r=nical 2014-08-22 09:40:02 -04:00
Simon Montagu
f154063dd2 Bug 1054810: when block size is unconstrained and we aren't setting aDesiredSize.BSize to the computed block size, preserve the original value. r=jfkthame. 2014-08-22 00:04:41 -07:00
Robert O'Callahan
bd73a2178e Bug 1054161. Don't build display items for text with alpha=0. r=dbaron
--HG--
extra : rebase_source : 869a05a652a3bc6e8e122d34fb166ed9fbbdaa5c
2014-08-23 00:08:12 +12:00
Trevor Saunders
86b7aff8fc bug 1047696 - mark a number of classes MOZ_FINAL to get compilers to devirtualize more r=froydnj 2014-08-05 13:33:55 -04:00
Olli Pettay
5218f131a5 Bug 1054773 - Fix crashes in nsProgressFrame.cpp r=wchen 2014-08-20 17:38:01 -07:00
Seth Fowler
7c7839561b Bug 1024454 (Part 1) - Eagerly propagate dirty bits so absolute children of table parts get reflowed reliably. r=dbaron 2014-08-20 17:48:56 -07:00
Ed Morley
ac5b975368 Merge mozilla-central and b2g-inbound 2014-08-20 15:19:45 +01:00
John Daggett
ac15ab77f4 Bug 975744 - unprefix font-feature-settings and font-language-override in tests. r=jfkthame 2014-08-20 16:54:37 +09:00
C.J. Ku
67a5b4b70f Bug 1055040 - Send mouse events base on canvas position and enable this test case on all B2G builds. r=ehsan 2014-08-19 19:38:00 -04:00
Ehsan Akhgari
38a6ed7fd0 Bug 1055519 - Fix some more bad implicit constructors in layout and widget; r=roc 2014-08-20 00:58:22 -04:00
Seth Fowler
2534cf2221 Bug 35168 - Backout 4 changesets (e15a7a0c8f70, 852b5ce53278, f36adee1958f, 479ff28f783f) for B2G bustage and reftest failures ON A CLOSED TREE
--HG--
extra : amend_source : 2be4ad526c51311c6f03b2681dd3961c1502c303
2014-08-19 20:37:14 -07:00
Seth Fowler
d28a953fd4 Bug 35168 (Part 1) - Add GetNormalRect to nsIFrame. r=dbaron 2014-08-19 18:24:57 -07:00
Ehsan Akhgari
81e509cdc8 Backed out changeset 0409c8faca80 because of build bustage on a CLOSED TREE 2014-08-18 13:44:59 -04:00
Ehsan Akhgari
03e222d7d9 Add SetProp to the list of windows.h #defined functions that we need to #undef, no bug 2014-08-18 13:19:16 -04:00
Aryeh Gregor
15ec3ba67b Bug 1053190 - Reduce unnecessary inclusion of nsINode.h in headers; r=ehsan 2014-08-18 17:44:50 +03: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
27a3fe0069 Bug 1048752. Part 19: Create nsCaret::GetPaintGeometry to call during painting. r=tn
This is the start of the changes to caret-drawing proper.

The idea is to combine GetCaretFrame and GetCaretRect into a method
GetPaintGeometry which looks like GetGeometry but returns values
needed for painting (i.e. including bidi decorations, and returning
a null frame if we're not supposed to paint due to specific caret
state, e.g. in the "off" phase of the blink cycle).

Mostly a straightforward refactoring but there are a few interesting changes:
-- nsDisplayCaret stores its bounds instead of getting them from nsCaret on
demand. Eventually those bounds will not be stored in nsCaret at all.
-- nsDisplayCaret::GetBounds returns true for aSnap. nsCaret draws snapped
rects, so why not.
-- I removed "if (caretRect.Intersects(aDirtyRect))" in EnterPresShell.
As far as I can tell, this check is incorrect because it doesn't take
transforms into account. Since there's at most one drawn caret per window,
hence we do this at most once per paint, I don't think there's any real
performance advantage to having this check.

--HG--
extra : rebase_source : c98d3a5994478b482d19cc2e2ac83ab51bd17e00
2014-08-06 17:19:28 +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
912c1e35de Bug 1048752. Part 10: Remove FrameLayerBuilder.h from nsDisplayList.h. r=tn
I was inspired by the previous patch to remove FrameLayerBuilder.h from
nsDisplayList.h too.

--HG--
extra : rebase_source : b34a01bea5865da4737817e2396b98d54cc6d1bf
2014-08-06 17:19:25 +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
Robert O'Callahan
311f843a5a Bug 1048752. Part 3: Make GetCaretFrameForNodeOffset static. r=tn
GetCaretFrameForNodeOffset only uses the nsFrameSelection and mBidiUI
from its nsCaret. For mBidiUI we can just get the pref directly whenever
we need it. By modifying GetCaretFrameForNodeOffset to take nsFrameSelection
as a parameter, we can make it static to make it clear it isn't really
related to the state of the nsCaret.

This may also fix a bug in Selection::GetPrimaryFrameForFocusNode where
things would go unexpectedly wrong if mCaret is temporarily observing
a different selection to the Selection.

--HG--
extra : rebase_source : cdd59f6e20cd1060bc5d2325cb3adb5e5c4a1d2c
2014-08-06 17:19:24 +12:00
Susanna Bowen
845188e8cd Bug 1030993 - Fix assertion failure in reftest css-ruby/ruby-whitespace-1.html. r=dbaron
Fixes the assertion failure with text:
"###!!! ASSERTION: Wrong line container
hint: '!aForFrame || (aLineContainer == FindLineContainer(aForFrame) ||
aLineContainer->GetType() == nsGkAtoms::rubyTextContainerFrame ||
(aLineContainer->GetType() == nsGkAtoms::letterFrame &&
aLineContainer->IsFloating()))', file
/home/sgbowen/builds/mozilla-central/layout/generic/nsTextFrame.cpp, line 1259"
which occasionally appears when opening pages with ruby or when running ruby
reftests.

Updates the manifest for ruby reftests to the current expectations (adjust
assertion counts, etc.)
2014-08-15 10:34:20 -07:00
Susanna Bowen
d4c7a65b4c Bug 1030993 - Basic reflow implementation for ruby frame classes. r=dbaron
To account for spacing between bases or text boxes during reflow, the line
layout which manages the bases updates its inline direction coordinate based on
the preferred inline size for the corresponding text boxes. Next, the base is
reflowed at the correct inline coordinate. Each paired text box is then also
reflowed at the proper inline position determined by (1) the current position of
its corresponding base and (2) its own preferred width.

In computing intrinsic widths, accounting for spacing is less complicated. The
minimum intrinsic width is the width of the widest ruby column, and the
preferred intrinsic width is the sum of all the ruby column widths. Each ruby
column width is the maximum width of its base box and text boxes. These
individual widths are determined using GetPrefISize on the base and text boxes.

Ruby base container frames store a list of pointers to the ruby text container
frames in the segment they denote. This list of pointers is created in the ruby
frame reflow method before calling the reflow method for the ruby base
container. The list exists and is used only during reflow of the main ruby frame
and is cleared before returning from reflow.
2014-08-15 10:34:20 -07:00
Seth Fowler
1694419abc Bug 913586 (Part 7) - Update Maybe users in layout. r=dbaron
--HG--
extra : rebase_source : 1bf45d1356d36269ca951b58ebf1e448313c55c5
2014-08-13 15:42:15 -07:00
L. David Baron
124c99f785 Bug 625289 patch 6 - Store style contexts being reframed in the ReframingStyleContexts struct. r=heycam 2014-08-13 15:39:01 -07:00
Trevor Saunders
434a7cf97c bug 1016545 - Provide an iterator that iterates over all children of an element r=bz 2014-07-16 14:41:57 -04:00
Seth Fowler
ecf35b9b35 Bug 981924 - Update ReportToConsole calls in layout code to use the right category. r=dbaron 2014-08-11 16:52:01 -07:00
Jonathan Kew
0297d08f5d bug 1048050 - ignore region (or other) subtags when checking for language-specific casing behavior. r=smontagu 2014-08-11 09:49:11 +01:00
Markus Stange
dba9e8b356 Backed out changeset 411a075b3624 (bug 987030) because it probably caused timeouts of browser_tabview_expander.js. CLOSED TREE 2014-08-08 18:05:40 +02:00
Robert O'Callahan
ae64bac44a Bug 1050096. Clip scrollparts to the viewport for root scrollframes. r=tnikkel 2014-08-09 01:00:53 +12:00
Markus Stange
f425c9e3e7 Bug 987030 - Fix compressed paint timer scheduling. r=roc 2014-08-08 12:46:50 +02:00
Nicholas Nethercote
8c60d14a1a Bug 1050009 - Initialize pldhash tables with a length, not a capacity. r=roc.
* * *
imported patch rm-dummy-params

--HG--
extra : rebase_source : c25987eb11bae197218d5fc53b77def19afa36ac
2014-08-06 06:31:21 -07:00
Daniel Holbert
54bcb09759 Bug 1032922 part 2: Rename flex-basis's "auto" keyword to "main-size" (but retain "flex:auto" as shorthand for "1 1 main-size"). r=heycam 2014-08-07 22:11:48 -07:00
Daniel Holbert
e2bfd48301 Bug 1050412 part 2: Assert about frame type before static_casting, and drop useless null-check. r=tn 2014-08-07 22:07:16 -07:00
Daniel Holbert
609c60e648 Bug 1050412 part 1: Use nsFrameList::Enumerator in nsSimplePageSequenceFrame to iterate over child frames. r=tn 2014-08-07 22:07:15 -07:00
Timothy Nikkel
017cd225f7 Bug 1042772. Update the reference frame and current frame offset when moving to outside a transform so that we can use the correct offset to compute the initial visible rect for wrap list display items. r=roc
* * *
The current reference frame is still the same as our reference frame because we set and restore it in nsFrame::BuildDisplayListForChild before this. So we need to actually compute it.
2014-08-07 11:33:18 -05:00
Timothy Nikkel
e2c436edd8 Bug 1042772. offsetToReferenceFrame is always zero when we use it. Remove it. r=mattwoodrow 2014-08-07 11:33:16 -05:00
Timothy Nikkel
9ac497988e Bug 1042772. Set the dirty rect relative to the current frame, not the reference frame. r=roc
The offsetToReferenceFrame is to the reference frame for this, since we are transformed we are the reference frame, so the offset was 0,0. So the computation still produced correct results.
2014-08-07 11:33:14 -05:00
Ehsan Akhgari
5a033b2b9f Bug 1048246 - Fix more bad implicit constructors in layout; r=roc
--HG--
extra : rebase_source : ed828993139bc70232508364a9f046e38b7d3e06
2014-08-07 19:48:38 -04:00
Timothy Nikkel
0ab533dc2d Backout f7a499183de0, 5dfd8d0a0ea6, dec09b1a21e4 (bug 1042772) for reftest failure on CLOSED TREE 2014-08-07 12:49:15 -05:00
Timothy Nikkel
42d7a62943 Bug 1042772. Update the reference frame and current frame offset when moving to outside a transform so that we can use the correct offset to compute the initial visible rect for wrap list display items. r=roc 2014-08-07 11:33:18 -05:00
Timothy Nikkel
ab740d2cd0 Bug 1042772. offsetToReferenceFrame is always zero when we use it. Remove it. r=mattwoodrow 2014-08-07 11:33:16 -05:00
Timothy Nikkel
d5d89be504 Bug 1042772. Set the dirty rect relative to the current frame, not the reference frame. r=roc
The offsetToReferenceFrame is to the reference frame for this, since we are transformed we are the reference frame, so the offset was 0,0. So the computation still produced correct results.
2014-08-07 11:33:14 -05:00
Morris Tseng
7d8540531d Bug 1046498 - Constrain frame to anchor subtree when dragging selection caret. r=roc 2014-08-06 01:55:00 -04:00
Olli Pettay
9a822f87c4 Bug 1026164, improve focus handling in shadow dom, r=wchen
--HG--
extra : rebase_source : 026b9ee49cdce82a703700593d7a1f0e5d27969f
2014-08-06 02:23:02 +03:00
Ryan VanderMeulen
b1ac471f9b Backed out changeset 80d85e3fdf41 (bug 1046573) for bustage.
CLOSED TREE
2014-08-05 13:58:50 -04:00
kernp25@yahoo.com
b8641443b5 Bug 1046573 - Add an observer notification for newly created selection objects; r=ehsan 2014-08-05 13:44:26 -04:00
Morris Tseng
a59488b63d Bug 1023041 - Part 1: Rename SetMouseDownState to SetDragState. r=roc 2014-08-04 00:26:00 -04:00