Bug 1303623 - Part1. Style const changes. r=heycam
authorEthan Lin <ethlin@mozilla.com>
Wed, 19 Oct 2016 15:45:05 +0800
changeset 355187 a5d992a04bfc84c9b89685a509b2d413323787d2
parent 355133 66465b966647794ea87387babf30b2607519a569
child 355188 e5a2498583f11ab5f34cb9b396437e17aac072a1
push id10621
push userjlund@mozilla.com
push dateMon, 23 Jan 2017 16:02:43 +0000
treeherdermozilla-aurora@dca7b42e6c67 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersheycam
bugs1303623
milestone53.0a1
Bug 1303623 - Part1. Style const changes. r=heycam MozReview-Commit-ID: 7QfVXegiiqc
layout/style/nsCSSKeywordList.h
layout/style/nsStyleConsts.h
--- a/layout/style/nsCSSKeywordList.h
+++ b/layout/style/nsCSSKeywordList.h
@@ -399,16 +399,17 @@ CSS_KEY(mm, mm)
 CSS_KEY(monospace, monospace)
 CSS_KEY(move, move)
 CSS_KEY(ms, ms)
 CSS_KEY(multiply, multiply)
 CSS_KEY(n-resize, n_resize)
 CSS_KEY(narrower, narrower)
 CSS_KEY(ne-resize, ne_resize)
 CSS_KEY(nesw-resize, nesw_resize)
+CSS_KEY(no-clip, no_clip)
 CSS_KEY(no-close-quote, no_close_quote)
 CSS_KEY(no-common-ligatures, no_common_ligatures)
 CSS_KEY(no-contextual, no_contextual)
 CSS_KEY(no-discretionary-ligatures, no_discretionary_ligatures)
 CSS_KEY(no-drag, no_drag)
 CSS_KEY(no-drop, no_drop)
 CSS_KEY(no-historical-ligatures, no_historical_ligatures)
 CSS_KEY(no-open-quote, no_open_quote)
--- a/layout/style/nsStyleConsts.h
+++ b/layout/style/nsStyleConsts.h
@@ -329,34 +329,45 @@ enum class FillMode : uint32_t;
 
 // See nsStyleImageLayers
 #define NS_STYLE_IMAGELAYER_ATTACHMENT_SCROLL        0
 #define NS_STYLE_IMAGELAYER_ATTACHMENT_FIXED         1
 #define NS_STYLE_IMAGELAYER_ATTACHMENT_LOCAL         2
 
 // See nsStyleImageLayers
 // Code depends on these constants having the same values as IMAGELAYER_ORIGIN_*
+// The *CLIP_FILL, *CLIP_STROKE, *CLIP_VIEW, *CLIP_NO_CLIP are only
+// supported by mask-clip, not background-clip.
 #define NS_STYLE_IMAGELAYER_CLIP_BORDER              0
 #define NS_STYLE_IMAGELAYER_CLIP_PADDING             1
 #define NS_STYLE_IMAGELAYER_CLIP_CONTENT             2
+#define NS_STYLE_IMAGELAYER_CLIP_FILL                3
+#define NS_STYLE_IMAGELAYER_CLIP_STROKE              4
+#define NS_STYLE_IMAGELAYER_CLIP_VIEW                5
+#define NS_STYLE_IMAGELAYER_CLIP_NO_CLIP             6
 // One extra constant which does not exist in IMAGELAYER_ORIGIN_*
-#define NS_STYLE_IMAGELAYER_CLIP_TEXT                3
+#define NS_STYLE_IMAGELAYER_CLIP_TEXT                7
 
 // A magic value that we use for our "pretend that background-clip is
 // 'padding' when we have a solid border" optimization.  This isn't
 // actually equal to NS_STYLE_IMAGELAYER_CLIP_PADDING because using that
 // causes antialiasing seams between the background and border.  This
 // is a backend-only value.
 #define NS_STYLE_IMAGELAYER_CLIP_MOZ_ALMOST_PADDING  127
 
 // See nsStyleImageLayers
 // Code depends on these constants having the same values as BG_CLIP_*
+// The *ORIGIN_FILL, *ORIGIN_STROKE, *ORIGIN_VIEW are only
+// supported by mask-clip, not background-clip.
 #define NS_STYLE_IMAGELAYER_ORIGIN_BORDER            0
 #define NS_STYLE_IMAGELAYER_ORIGIN_PADDING           1
 #define NS_STYLE_IMAGELAYER_ORIGIN_CONTENT           2
+#define NS_STYLE_IMAGELAYER_ORIGIN_FILL              3
+#define NS_STYLE_IMAGELAYER_ORIGIN_STROKE            4
+#define NS_STYLE_IMAGELAYER_ORIGIN_VIEW              5
 
 // See nsStyleImageLayers
 // The parser code depends on |ing these values together.
 #define NS_STYLE_IMAGELAYER_POSITION_CENTER          (1<<0)
 #define NS_STYLE_IMAGELAYER_POSITION_TOP             (1<<1)
 #define NS_STYLE_IMAGELAYER_POSITION_BOTTOM          (1<<2)
 #define NS_STYLE_IMAGELAYER_POSITION_LEFT            (1<<3)
 #define NS_STYLE_IMAGELAYER_POSITION_RIGHT           (1<<4)