OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "ui/gfx/image/image_skia.h" | 5 #include "ui/gfx/image/image_skia.h" |
6 | 6 |
| 7 #include <stddef.h> |
| 8 |
7 #include <algorithm> | 9 #include <algorithm> |
8 #include <cmath> | 10 #include <cmath> |
9 #include <limits> | 11 #include <limits> |
10 | 12 |
11 #include "base/command_line.h" | 13 #include "base/command_line.h" |
12 #include "base/logging.h" | 14 #include "base/logging.h" |
13 #include "base/memory/scoped_ptr.h" | 15 #include "base/memory/scoped_ptr.h" |
14 #include "base/threading/non_thread_safe.h" | 16 #include "base/threading/non_thread_safe.h" |
| 17 #include "build/build_config.h" |
15 #include "ui/gfx/geometry/rect.h" | 18 #include "ui/gfx/geometry/rect.h" |
16 #include "ui/gfx/geometry/size.h" | 19 #include "ui/gfx/geometry/size.h" |
17 #include "ui/gfx/geometry/size_conversions.h" | 20 #include "ui/gfx/geometry/size_conversions.h" |
18 #include "ui/gfx/image/image_skia_operations.h" | 21 #include "ui/gfx/image/image_skia_operations.h" |
19 #include "ui/gfx/image/image_skia_source.h" | 22 #include "ui/gfx/image/image_skia_source.h" |
20 #include "ui/gfx/skia_util.h" | 23 #include "ui/gfx/skia_util.h" |
21 #include "ui/gfx/switches.h" | 24 #include "ui/gfx/switches.h" |
22 | 25 |
23 namespace gfx { | 26 namespace gfx { |
24 namespace { | 27 namespace { |
(...skipping 467 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
492 bool ImageSkia::CanModify() const { | 495 bool ImageSkia::CanModify() const { |
493 return !storage_.get() || storage_->CanModify(); | 496 return !storage_.get() || storage_->CanModify(); |
494 } | 497 } |
495 | 498 |
496 void ImageSkia::DetachStorageFromThread() { | 499 void ImageSkia::DetachStorageFromThread() { |
497 if (storage_.get()) | 500 if (storage_.get()) |
498 storage_->DetachFromThread(); | 501 storage_->DetachFromThread(); |
499 } | 502 } |
500 | 503 |
501 } // namespace gfx | 504 } // namespace gfx |
OLD | NEW |