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: third_party/WebKit/Source/core/css/cssom/CSSStyleImageValue.h

Issue 2746343002: Phase III Step 1: Make ImageResourceContent manage its own ResourceStatus (Closed)
Patch Set: Reflect comments Created 3 years, 7 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/html/HTMLObjectElement.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 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #ifndef CSSStyleImageValue_h 5 #ifndef CSSStyleImageValue_h
6 #define CSSStyleImageValue_h 6 #define CSSStyleImageValue_h
7 7
8 #include "core/CoreExport.h" 8 #include "core/CoreExport.h"
9 #include "core/css/CSSImageValue.h" 9 #include "core/css/CSSImageValue.h"
10 #include "core/css/CSSImageValue.h" 10 #include "core/css/CSSImageValue.h"
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 kDoNotRespectImageOrientation, 1, 63 kDoNotRespectImageOrientation, 1,
64 ImageResourceContent::kIntrinsicSize) 64 ImageResourceContent::kIntrinsicSize)
65 : LayoutSize(0, 0); 65 : LayoutSize(0, 0);
66 } 66 }
67 67
68 virtual bool IsCachePending() const { return image_value_->IsCachePending(); } 68 virtual bool IsCachePending() const { return image_value_->IsCachePending(); }
69 69
70 ResourceStatus Status() const override { 70 ResourceStatus Status() const override {
71 if (IsCachePending()) 71 if (IsCachePending())
72 return ResourceStatus::kNotStarted; 72 return ResourceStatus::kNotStarted;
73 return image_value_->CachedImage()->CachedImage()->GetStatus(); 73 return image_value_->CachedImage()->CachedImage()->GetContentStatus();
74 } 74 }
75 75
76 const CSSImageValue* CssImageValue() const { return image_value_.Get(); }; 76 const CSSImageValue* CssImageValue() const { return image_value_.Get(); };
77 77
78 private: 78 private:
79 PassRefPtr<Image> GetImage() const; 79 PassRefPtr<Image> GetImage() const;
80 80
81 Member<const CSSImageValue> image_value_; 81 Member<const CSSImageValue> image_value_;
82 }; 82 };
83 83
84 } // namespace blink 84 } // namespace blink
85 85
86 #endif // CSSResourceValue_h 86 #endif // CSSResourceValue_h
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/html/HTMLObjectElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698