2 * Copyright(c) 2020 Samsung Electronics Co., Ltd.
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
21 /// The class storing Background extra properties such as CornerRadius, ImageBorder.
23 internal class BackgroundExtraData
25 internal BackgroundExtraData()
29 internal BackgroundExtraData(BackgroundExtraData other)
31 BackgroundImageBorder = other.BackgroundImageBorder;
32 CornerRadius = other.CornerRadius;
35 private Rectangle backgroundImageBorder;
37 /// <summary></summary>
38 internal Rectangle BackgroundImageBorder
40 get => backgroundImageBorder;
41 set => backgroundImageBorder = new Rectangle(value);
44 /// <summary></summary>
45 internal float CornerRadius { get; set; }
49 return CornerRadius == 0 && Rectangle.IsNullOrZero(BackgroundImageBorder);