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

Side by Side Diff: Source/platform/graphics/ScaledImageFragment.h

Issue 27140003: Move ScaledImageFragment.cpp/.h to platform/ (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 2 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 | Annotate | Revision Log
« no previous file with comments | « Source/platform/blink_platform.gypi ('k') | Source/platform/graphics/ScaledImageFragment.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 12 matching lines...) Expand all
23 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 23 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
24 */ 24 */
25 25
26 #ifndef ScaledImageFragment_h 26 #ifndef ScaledImageFragment_h
27 #define ScaledImageFragment_h 27 #define ScaledImageFragment_h
28 28
29 #include "SkBitmap.h" 29 #include "SkBitmap.h"
30 #include "SkRect.h" 30 #include "SkRect.h"
31 #include "SkSize.h" 31 #include "SkSize.h"
32 32
33 #include "platform/PlatformExport.h"
33 #include "wtf/PassOwnPtr.h" 34 #include "wtf/PassOwnPtr.h"
34 35
35 namespace WebCore { 36 namespace WebCore {
36 37
37 // ScaledImageFragment is a scaled version of an image. 38 // ScaledImageFragment is a scaled version of an image.
38 class ScaledImageFragment { 39 class PLATFORM_EXPORT ScaledImageFragment {
39 public: 40 public:
40 enum ImageGeneration { 41 enum ImageGeneration {
41 CompleteImage = 0, 42 CompleteImage = 0,
42 FirstPartialImage = 1, 43 FirstPartialImage = 1,
43 }; 44 };
44 45
45 static PassOwnPtr<ScaledImageFragment> createComplete(const SkISize& scaledS ize, size_t index, const SkBitmap& bitmap) 46 static PassOwnPtr<ScaledImageFragment> createComplete(const SkISize& scaledS ize, size_t index, const SkBitmap& bitmap)
46 { 47 {
47 return adoptPtr(new ScaledImageFragment(scaledSize, index, CompleteImage , bitmap)); 48 return adoptPtr(new ScaledImageFragment(scaledSize, index, CompleteImage , bitmap));
48 } 49 }
(...skipping 16 matching lines...) Expand all
65 private: 66 private:
66 SkISize m_scaledSize; 67 SkISize m_scaledSize;
67 size_t m_index; 68 size_t m_index;
68 size_t m_generation; 69 size_t m_generation;
69 SkBitmap m_bitmap; 70 SkBitmap m_bitmap;
70 }; 71 };
71 72
72 } // namespace WebCore 73 } // namespace WebCore
73 74
74 #endif 75 #endif
OLDNEW
« no previous file with comments | « Source/platform/blink_platform.gypi ('k') | Source/platform/graphics/ScaledImageFragment.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698