Commit Graph

535 Commits

Author SHA1 Message Date
Masatoshi Kimura
86502e6537 Bug 1111290 - Part 2: Non-mechanical changes. r=waldo 2015-01-26 07:22:08 +09:00
Trevor Saunders
85227ffecb bug 1122065 - use MOZ_OVERRIDE more in gfxish things r=jrmuizel 2015-01-19 17:41:12 -05:00
Jonathan Kew
8699f8544e Bug 1113216 - Avoid assertions/crashes by treating enumerated block-size values as auto, pending proper implementation of all the values. r=dbaron 2015-01-15 11:56:51 +00:00
Xidorn Quan
1bf1df7b1e Bug 1055667 part 2 - Remove unnecessary param of SetBSizeFromFontMetrics. r=dbaron
--HG--
extra : source : aa79c8cebf3e2ab0fd4335eaa3c630a43dbe81f2
2015-01-15 20:02:11 +11:00
L. David Baron
25c494ef46 Bug 1110277 patch 2 - Add nsLayoutUtils::LastContinuationOrIBSplitSibling(). r=bzbarsky
This is used in patch 3.
2015-01-11 15:43:10 -08:00
Geoff Lankow
125624cd03 Bug 1114297 - Improve performance of nsTreeBodyFrame::AdjustForCellText for very long strings; r=smontagu 2015-01-11 00:07:58 +13:00
Ting-Yu Lin
9ce9133a81 Bug 1067728 - Part 3 - Expose FindNearestCommonAncestorFrame. r=roc 2014-12-10 19:52:00 +01:00
Ting-Yu Lin
48139f3c66 Bug 1067728 - Part 1.1 - Move IsRectVisibleInScrollFrames to nsLayoutUtils. f=mtseng, r=roc 2014-12-08 01:53:00 +01:00
Kartikaya Gupta
d159ec1172 Bug 1105823 - Ensure we find a scrollable ancestor even for fixed-position items. r=botond 2014-11-28 12:25:40 -05:00
Jonathan Kew
f8c40475ef Bug 1105268 - part 1 - Fix the logical/physical confusion with min- and max- dimensions in nsFrame::ComputeSize(). r=smontagu 2014-11-27 15:01:11 +00:00
Daniel Holbert
c7ce74a52e Bug 1098417 part 1: Add optional anchor-point arg to nsLayoutUtils::ComputeObjectDestRect() and nsLayoutUtils::DrawSingleImage(). r=seth 2014-11-21 18:25:46 -08:00
Kartikaya Gupta
0611166ee2 Bug 918288 - Ensure we set a displayport on elements that we get touch-start events for. r=botond 2014-11-21 21:36:25 -05:00
Kartikaya Gupta
911702f6c3 Bug 918288 - Add code to TabChild to dispatch the SetTargetAPZC notification. r=roc,botond 2014-11-21 21:36:25 -05:00
David Anderson
0965889407 Cache the current animated geometry root in nsDisplayListBuilder. (bug 1101260 part 1, r=roc) 2014-11-20 16:58:18 -08:00
Mats Palmgren
b0f013a10d Bug 907396 - Make RestyleManager::RestyleElement and nsCSSFrameConstructor::MaybeRecreateFramesForElement deal with display:contents elements. r=bzbarsky 2014-11-20 18:24:10 +00:00
Daniel Holbert
9f4cb9be39 Bug 624647 part 1: Add utility method nsLayoutUtils::ComputeObjectDestRect() to handle object-fit/object-position. r=seth 2014-11-14 16:45:23 -08:00
Benoit Girard
aa2eeb8ec1 Bug 1094442 - Part 1: Refactor how tile w/h is queried r=kats
--HG--
extra : rebase_source : 70ef00318a718e2ce3149955d2908615d6125cf3
2014-11-12 17:54:29 -05:00
Botond Ballo
c854025367 Bug 1076163 - Basic APZ support for css-driven resolution. r=kats,tn
This makes APZ behave nicely with most uses of a css transform:scale.

Summary of changes:
  - FrameMetrics::mCumulativeResolution now includes the css-driven resolution
    in addition to the pres-shell resolution.
  - Displayports are now stored in Screen pixels rather than Layer pixels.
    This is what we want anyways (as we'd like the displayport size to remain
    constant as a fraction of the screen size), but it was necessary to make
    this change as part of this patch because continuing to store them in
    Layer pixels in the presence of a css-driven resolution would have
    required a bunch of infrastructure to implement correctly.

Remaining work:
  - Layout painting a scrollable layer at a resolution different from the
    scale induced by the css transform causes problems. These will go away
    with bug 1076192.
  - Different resolutions on the x and y axes are not supported. This is
    tracked by bug 1039967.
2014-10-24 15:49:38 -04:00
Carsten "Tomcat" Book
8894f4319e Backed out changeset fbb9dc943109 (bug 1076163) for Android 4.0 Crashes on a CLOSED TREE 2014-11-13 11:47:57 +01:00
Jonathan Kew
34fea182cd Bug 1093553 - Improve handling of line-height metrics, block ascent, etc., in vertical writing mode. r=smontagu 2014-11-13 08:58:06 +00:00
Botond Ballo
57adf459d4 Bug 1076163 - Basic APZ support for css-driven resolution. r=kats,tn
This makes APZ behave nicely with most uses of a css transform:scale.

Summary of changes:
  - FrameMetrics::mCumulativeResolution now includes the css-driven resolution
    in addition to the pres-shell resolution.
  - Displayports are now stored in Screen pixels rather than Layer pixels.
    This is what we want anyways (as we'd like the displayport size to remain
    constant as a fraction of the screen size), but it was necessary to make
    this change as part of this patch because continuing to store them in
    Layer pixels in the presence of a css-driven resolution would have
    required a bunch of infrastructure to implement correctly.

Remaining work:
  - Layout painting a scrollable layer at a resolution different from the
    scale induced by the css transform causes problems. These will go away
    with bug 1076192.
  - Different resolutions on the x and y axes are not supported. This is
    tracked by bug 1039967.
2014-10-24 15:49:38 -04:00
Morris Tseng
8733cb18e1 Bug 1094056 - Use nsCaret::GetGeometryForFrame to determine position of selection carets. r=roc 2014-11-11 22:54:00 +01:00
Kartikaya Gupta
7644286079 Bug 1078029 - Add code to reposition input event coordinates into the target frame. r=roc
The PositionedEventTargeting code allows input events to be dispatched to a
target not directly under the input event point. However, the coordinates of the
input event can then end up outside the bounding rect of the event target. This
state is generally unexpected by web content and may cause compatibility issues.
Fennec's front-end code used to deal with this by repositioning the input event
coordinates to be inside the bounding rect; now that Fennec is using the shared
C++ code we need to have that code here. This behaviour is guarded by a pref and
disabled by default (but enabled on Fennec).
2014-11-04 09:52:16 -05:00
Jonathan Watt
f6f8d40041 Bug 1091794 - Replace gfxCornerSizes with Moz2D's RectCornerRadii. r=mattwoodrow 2014-11-01 10:45:10 +00:00
Jonathan Watt
53f338200b Bug 1091323 - Convert the nsLayoutUtils helpers that paint images and take an nsRenderingContext to take a gfxContext instead. r=seth 2014-11-01 10:45:09 +00:00
Jonathan Watt
1d2c31c63d Bug 1088781 - Rename nsLayoutUtils::GetStringWidth to nsLayoutUtils::AppUnitWidthOfStringBidi. r=dholbert 2014-10-26 17:57:49 +00:00
Botond Ballo
eea9473d65 Bug 1085569 - When calculating the composition bounds based on the frame size, use the cumulative resolution rather than the parent resolution everywhere. r=tn
--HG--
extra : amend_source : c72888ce19795e203e5dafa7d0b68065d6b668eb
2014-10-20 15:53:29 -04:00
Jonathan Watt
1c3326bede Bug 1088625, part 2 - Pass nsFontMetrics objects through to code that needs it instead of storing it on the nsRenderingContext. r=mstange 2014-10-24 16:28:14 +01:00
Jonathan Watt
35505a8b96 Bug 1088599 - Move nsRenderingContext::GetBoundingMetrics to nsLayoutUtils. r=mstange 2014-10-24 16:28:14 +01:00
Jonathan Watt
08ae0a017c Bug 1088550 - Move nsRenderingContext's remaining GetWidth methods to nsLayoutUtils. r=mstange 2014-10-24 16:28:13 +01:00
Jonathan Watt
2994c1b237 Bug 1088071, part 2 - Move the nsRenderingContext::DrawString code to nsLayoutUtils::DrawUniDirString. r=jfkthame 2014-10-24 11:00:23 +01:00
Jonathan Watt
0e920978be Bug 1088071, part 1 - Wrap the callers of the final nsRenderingContext::DrawString method up in a new nsLayoutUtils::DrawUniDirString method. r=jfkthame 2014-10-24 11:00:23 +01:00
Matt Woodrow
93f050183f Bug 1078337 - Correctly respect the source rect in DrawSingleImage. r=seth
--HG--
extra : rebase_source : c00951d46388585731340cf41c15520fc0592800
2014-10-23 11:41:14 +13:00
Jonathan Watt
09f54bbbb9 Bug 1086708 - Rename the snapping variant of NSRectToRect to NSRectToSnappedRect. r=mattwoodrow 2014-10-22 12:29:06 +01:00
Benoit Girard
4f2c7cdb80 Bug 961871 - Part 2: Refactor will-change scroll, pass through a nsDisplayListBuilder. r=mattwoodrow 2014-10-21 21:54:06 -04:00
Jonathan Watt
c972886b3e Bug 1085159 - Port the code that uses nsRenderingContext::DrawLine() to Moz2D. r=mattwoodrow
--HG--
extra : rebase_source : 70553292850517d695994c0a3422fab8ea0b760a
2014-10-20 10:55:48 +01:00
Jonathan Watt
9e43325322 Bug 1083597, part 2 - Add a variant of NSRectToRect that snaps to device pixels, and have nsTableCellFrame::DecorateForSelection use it to restore its snapping behavior. 2014-10-19 11:47:22 +01:00
Jonathan Watt
e20775a0d6 Bug 1083557 - Port the code that uses nsRenderingContext::FillPolygon() to Moz2D. r=mattwoodrow 2014-10-17 15:06:34 +01:00
Jonathan Watt
4c7c510aca Bug 1083761 - Use Color::FromABGR in more places that to the conversion by hand and remove nsLayoutUtils::NSColorToColor(). r=mstange 2014-10-17 12:53:16 +01:00
Jonathan Watt
3a8b0e745a Bug 1083215, part 2 - Convert drawing of HTML image map area focus to Moz2D. r=mattwoodrow 2014-10-16 10:51:14 +01:00
Michael Wu
71bba5063f Bug 1083393 - Remove unused thebes things in nsLayoutUtils, r=mattwoodrow 2014-10-15 17:13:14 -04:00
Brian Birtles
d77b5db74f Bug 1046055 part 4 - Add HasCurrentAnimationsForProperty to nsLayoutUtils; r=dbaron
This patch adds a method to nsLayoutUtils, alongside the existing
HasCurrentAnimations, that returns true if there exists an unfinished animation
on the element for the specified property.
2014-10-02 15:14:14 +09:00
Brian Birtles
2bfde3e79a Bug 1046055 part 1 - Remove nsPresContext parameter from nsLayoutUtils::HasCurrentAnimations; r=dbaron 2014-10-02 15:14:13 +09:00
Dirk Schulze
a028173cff Bug 1072894 - Implement polygon() parsing for clip-path. r=heycam 2014-09-28 01:56:00 +02:00
Markus Stange
7d5a3be591 Bug 1073103 - Rename ThebesLayer to PaintedLayer. r=roc
--HG--
rename : gfx/layers/basic/BasicThebesLayer.cpp => gfx/layers/basic/BasicPaintedLayer.cpp
rename : gfx/layers/basic/BasicThebesLayer.h => gfx/layers/basic/BasicPaintedLayer.h
rename : gfx/layers/client/ClientThebesLayer.cpp => gfx/layers/client/ClientPaintedLayer.cpp
rename : gfx/layers/client/ClientThebesLayer.h => gfx/layers/client/ClientPaintedLayer.h
rename : gfx/layers/client/ClientTiledThebesLayer.cpp => gfx/layers/client/ClientTiledPaintedLayer.cpp
rename : gfx/layers/client/ClientTiledThebesLayer.h => gfx/layers/client/ClientTiledPaintedLayer.h
rename : gfx/layers/composite/ThebesLayerComposite.cpp => gfx/layers/composite/PaintedLayerComposite.cpp
rename : gfx/layers/composite/ThebesLayerComposite.h => gfx/layers/composite/PaintedLayerComposite.h
rename : gfx/layers/d3d10/ThebesLayerD3D10.cpp => gfx/layers/d3d10/PaintedLayerD3D10.cpp
rename : gfx/layers/d3d10/ThebesLayerD3D10.h => gfx/layers/d3d10/PaintedLayerD3D10.h
rename : gfx/layers/d3d9/ThebesLayerD3D9.cpp => gfx/layers/d3d9/PaintedLayerD3D9.cpp
rename : gfx/layers/d3d9/ThebesLayerD3D9.h => gfx/layers/d3d9/PaintedLayerD3D9.h
2014-09-26 13:06:08 -04:00
Kartikaya Gupta
c34ad0fe01 Bug 1071367 - Fix the composition bounds for the root content document on OS X. r=tn
According to roc the content viewer position doesn't mean much; only the size is
set to anything meaningful. Therefore using the position from the content viewer
bounds is not a good idea, and we should use the position from the frame bounds
instead. This patch also changes GetContentViewerBounds to GetContentViewerSize
so that it's harder to accidentally use the position in other places.
2014-09-23 12:17:36 -04:00
Ting-Yu Lin
e3debbffab Bug 1065244 - Part 2 - Refactor event point on frame logic for SelectionCarets. f=mtseng, r=roc 2014-09-15 02:57:00 +02:00
Ting-Yu Lin
fc63f147e7 Bug 1065244 - Part 1 - Add GetRectRelativeToFrame to nsLayoutUtils. f=mtseng, r=roc 2014-09-15 17:07:00 +02:00
Daniel Holbert
23f4653cb5 (no bug) Some comment-only cleanup in nsLayoutUtils.h. (no review, comment-only)
DONTBUILD

In particular:
 - Rewrapped a few lines to 80 characters.
 - Fixed a few typos.
 - Added a terminal period character at the end of @param/@return lines, in cases where the rest of the function's documentation follows that convention.
2014-09-09 16:12:13 -07:00
Jonathan Watt
7b475bb2b2 Bug 932771, part 2 - Add an inline nsLayoutUtils::PointToGfxPoint helper method. r=longsonr 2014-08-19 22:17:49 +01:00