diff options
author | michaeln@google.com <michaeln@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-09-12 18:26:31 +0000 |
---|---|---|
committer | michaeln@google.com <michaeln@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-09-12 18:26:31 +0000 |
commit | 78f7350ed13da5d6211acc91778978f4930338f6 (patch) | |
tree | a22d233fc99969e6d6f0e2e16b53514197d71e3a /webkit/appcache/appcache_thread.h | |
parent | 9a221b999a98e0855e1d966b66655a56a0f4ca91 (diff) | |
download | chromium_src-78f7350ed13da5d6211acc91778978f4930338f6.zip chromium_src-78f7350ed13da5d6211acc91778978f4930338f6.tar.gz chromium_src-78f7350ed13da5d6211acc91778978f4930338f6.tar.bz2 |
Replace ancient crufty AppCacheThread with much improved MessageLoopProxy usage.
Review URL: http://codereview.chromium.org/7863009
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@100726 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/appcache/appcache_thread.h')
-rw-r--r-- | webkit/appcache/appcache_thread.h | 52 |
1 files changed, 0 insertions, 52 deletions
diff --git a/webkit/appcache/appcache_thread.h b/webkit/appcache/appcache_thread.h deleted file mode 100644 index b4e46ca..0000000 --- a/webkit/appcache/appcache_thread.h +++ /dev/null @@ -1,52 +0,0 @@ -// Copyright (c) 2009 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 WEBKIT_APPCACHE_APPCACHE_THREAD_H_ -#define WEBKIT_APPCACHE_APPCACHE_THREAD_H_ - -#include "base/task.h" - -namespace tracked_objects { -class Location; -} - -namespace appcache { - -// The appcache system uses two threads, an IO thread and a DB thread. -// It does not create these threads, the embedder is responsible for -// providing them to the appcache library by providing a concrete -// implementation of the PostTask and CurrentlyOn methods declared here, -// and by calling the Init method prior to using the appcache library. -class AppCacheThread { - public: - static void Init(int db, int io) { - db_ = db; - io_ = io; - } - static int db() { return db_; } - static int io() { return io_; } - - static bool PostTask(int id, - const tracked_objects::Location& from_here, - Task* task); - static bool CurrentlyOn(int id); - - template <class T> - static bool DeleteSoon(int id, - const tracked_objects::Location& from_here, - T* object) { - return PostTask(id, from_here, new DeleteTask<T>(object)); - } - - private: - AppCacheThread(); - ~AppCacheThread(); - - static int db_; - static int io_; -}; - -} // namespace appcache - -#endif // WEBKIT_APPCACHE_APPCACHE_THREAD_H_ |