Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1207)

Side by Side Diff: sky/engine/core/rendering/style/NinePieceImage.h

Issue 893093002: Delete remaining masks dead code. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org)
3 * (C) 2000 Antti Koivisto (koivisto@kde.org) 3 * (C) 2000 Antti Koivisto (koivisto@kde.org)
4 * (C) 2000 Dirk Mueller (mueller@kde.org) 4 * (C) 2000 Dirk Mueller (mueller@kde.org)
5 * Copyright (C) 2003, 2005, 2006, 2007, 2008, 2013 Apple Inc. All rights reserv ed. 5 * Copyright (C) 2003, 2005, 2006, 2007, 2008, 2013 Apple Inc. All rights reserv ed.
6 * 6 *
7 * This library is free software; you can redistribute it and/or 7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Library General Public 8 * modify it under the terms of the GNU Library General Public
9 * License as published by the Free Software Foundation; either 9 * License as published by the Free Software Foundation; either
10 * version 2 of the License, or (at your option) any later version. 10 * version 2 of the License, or (at your option) any later version.
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 { 103 {
104 m_data.access()->outset = other.m_data->outset; 104 m_data.access()->outset = other.m_data->outset;
105 } 105 }
106 106
107 void copyRepeatFrom(const NinePieceImage& other) 107 void copyRepeatFrom(const NinePieceImage& other)
108 { 108 {
109 m_data.access()->horizontalRule = other.m_data->horizontalRule; 109 m_data.access()->horizontalRule = other.m_data->horizontalRule;
110 m_data.access()->verticalRule = other.m_data->verticalRule; 110 m_data.access()->verticalRule = other.m_data->verticalRule;
111 } 111 }
112 112
113 void setMaskDefaults()
114 {
115 m_data.access()->imageSlices = LengthBox(0);
116 m_data.access()->fill = true;
117 m_data.access()->borderSlices = BorderImageLengthBox(Length(Auto));
118 }
119
120 static LayoutUnit computeOutset(const BorderImageLength& outsetSide, LayoutU nit borderSide) 113 static LayoutUnit computeOutset(const BorderImageLength& outsetSide, LayoutU nit borderSide)
121 { 114 {
122 if (outsetSide.isNumber()) 115 if (outsetSide.isNumber())
123 return outsetSide.number() * borderSide; 116 return outsetSide.number() * borderSide;
124 return outsetSide.length().value(); 117 return outsetSide.length().value();
125 } 118 }
126 119
127 private: 120 private:
128 DataRef<NinePieceImageData> m_data; 121 DataRef<NinePieceImageData> m_data;
129 }; 122 };
130 123
131 } // namespace blink 124 } // namespace blink
132 125
133 #endif // SKY_ENGINE_CORE_RENDERING_STYLE_NINEPIECEIMAGE_H_ 126 #endif // SKY_ENGINE_CORE_RENDERING_STYLE_NINEPIECEIMAGE_H_
OLDNEW
« no previous file with comments | « sky/engine/core/rendering/style/FillLayer.cpp ('k') | sky/engine/core/rendering/style/RenderStyle.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698