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

Side by Side Diff: chrome/browser/extensions/api/declarative/test_rules_registry.cc

Issue 10560013: Persist declarative rules to the extension state store. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: RegisterKey Created 8 years, 6 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
OLDNEW
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 "chrome/browser/extensions/api/declarative/test_rules_registry.h" 5 #include "chrome/browser/extensions/api/declarative/test_rules_registry.h"
6 6
7 namespace extensions { 7 namespace extensions {
8 8
9 TestRulesRegistry::TestRulesRegistry() 9 TestRulesRegistry::TestRulesRegistry()
10 : owner_thread_(content::BrowserThread::UI) {} 10 : RulesRegistryWithCache(NULL),
11 owner_thread_(content::BrowserThread::UI) {}
11 12
12 void TestRulesRegistry::SetOwnerThread( 13 void TestRulesRegistry::SetOwnerThread(
13 content::BrowserThread::ID owner_thread) { 14 content::BrowserThread::ID owner_thread) {
14 owner_thread_ = owner_thread; 15 owner_thread_ = owner_thread;
15 } 16 }
16 17
17 std::string TestRulesRegistry::AddRulesImpl( 18 std::string TestRulesRegistry::AddRulesImpl(
18 const std::string& extension_id, 19 const std::string& extension_id,
19 const std::vector<linked_ptr<RulesRegistry::Rule> >& rules) { 20 const std::vector<linked_ptr<RulesRegistry::Rule> >& rules) {
20 return result_; 21 return result_;
(...skipping 14 matching lines...) Expand all
35 return owner_thread_; 36 return owner_thread_;
36 } 37 }
37 38
38 void TestRulesRegistry::SetResult(const std::string& result) { 39 void TestRulesRegistry::SetResult(const std::string& result) {
39 result_ = result; 40 result_ = result;
40 } 41 }
41 42
42 TestRulesRegistry::~TestRulesRegistry() {} 43 TestRulesRegistry::~TestRulesRegistry() {}
43 44
44 } // namespace extensions 45 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698