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

Unified Diff: third_party/WebKit/Source/core/fetch/ResourceLoader.h

Issue 1751203003: Merge ResourceLoader's ResourceLoaderState and ConnectionState enums (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove spurious newline Created 4 years, 10 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 | « no previous file | third_party/WebKit/Source/core/fetch/ResourceLoader.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/fetch/ResourceLoader.h
diff --git a/third_party/WebKit/Source/core/fetch/ResourceLoader.h b/third_party/WebKit/Source/core/fetch/ResourceLoader.h
index 320c896a8e68f35be43f7d2469ba7dda0077ac80..2a5cb1cdb9faa8fcef648ccce4dc1c6d0f602e5a 100644
--- a/third_party/WebKit/Source/core/fetch/ResourceLoader.h
+++ b/third_party/WebKit/Source/core/fetch/ResourceLoader.h
@@ -87,7 +87,6 @@ public:
const KURL& url() const { return m_request.url(); }
bool isLoadedBy(ResourceFetcher*) const;
- bool reachedTerminalState() const { return m_state == Terminated; }
const ResourceRequest& request() const { return m_request; }
bool loadingMultipartContent() const { return m_loadingMultipartContent; }
@@ -118,12 +117,6 @@ private:
ResourceRequest m_deferredRequest;
ResourceLoaderOptions m_options;
- enum ResourceLoaderState {
- Initialized,
- Finishing,
- Terminated
- };
-
enum ConnectionState {
ConnectionStateNew,
ConnectionStateStarted,
@@ -132,14 +125,15 @@ private:
ConnectionStateFinishedLoading,
ConnectionStateCanceled,
ConnectionStateFailed,
+ ConnectionStateReleased
};
+ bool isFinishing() { return m_state >= ConnectionStateFinishedLoading && m_state <= ConnectionStateFailed; }
RefPtrWillBeMember<Resource> m_resource;
- ResourceLoaderState m_state;
// Used for sanity checking to make sure we don't experience illegal state
// transitions.
- ConnectionState m_connectionState;
+ ConnectionState m_state;
};
} // namespace blink
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/fetch/ResourceLoader.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698