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

Unified Diff: ui/gfx/shadow_value.h

Issue 854713003: More old files deletion. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Fix tryjobs? Created 5 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/gfx/selection_model.cc ('k') | ui/gfx/shadow_value.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gfx/shadow_value.h
diff --git a/ui/gfx/shadow_value.h b/ui/gfx/shadow_value.h
deleted file mode 100644
index 60b601e63bd7c75b413253f076b1399f58889002..0000000000000000000000000000000000000000
--- a/ui/gfx/shadow_value.h
+++ /dev/null
@@ -1,62 +0,0 @@
-// Copyright (c) 2012 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef UI_GFX_SHADOW_VALUE_H_
-#define UI_GFX_SHADOW_VALUE_H_
-
-#include <string>
-#include <vector>
-
-#include "third_party/skia/include/core/SkColor.h"
-#include "ui/gfx/gfx_export.h"
-#include "ui/gfx/point.h"
-
-namespace gfx {
-
-class Insets;
-
-class ShadowValue;
-typedef std::vector<ShadowValue> ShadowValues;
-
-// ShadowValue encapsulates parameters needed to define a shadow, including the
-// shadow's offset, blur amount and color.
-class GFX_EXPORT ShadowValue {
- public:
- ShadowValue();
- ShadowValue(const gfx::Point& offset, double blur, SkColor color);
- ~ShadowValue();
-
- int x() const { return offset_.x(); }
- int y() const { return offset_.y(); }
- const gfx::Point& offset() const { return offset_; }
- double blur() const { return blur_; }
- SkColor color() const { return color_; }
-
- ShadowValue Scale(float scale) const;
-
- std::string ToString() const;
-
- // Gets margin space needed for shadows. Note that values in returned Insets
- // are negative because shadow margins are outside a boundary.
- static Insets GetMargin(const ShadowValues& shadows);
-
- private:
- gfx::Point offset_;
-
- // Blur amount of the shadow in pixels. If underlying implementation supports
- // (e.g. Skia), it can have fraction part such as 0.5 pixel. The value
- // defines a range from full shadow color at the start point inside the
- // shadow to fully transparent at the end point outside it. The range is
- // perpendicular to and centered on the shadow edge. For example, a blur
- // amount of 4.0 means to have a blurry shadow edge of 4 pixels that
- // transitions from full shadow color to fully transparent and with 2 pixels
- // inside the shadow and 2 pixels goes beyond the edge.
- double blur_;
-
- SkColor color_;
-};
-
-} // namespace gfx
-
-#endif // UI_GFX_SHADOW_VALUE_H_
« no previous file with comments | « ui/gfx/selection_model.cc ('k') | ui/gfx/shadow_value.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698