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

Side by Side Diff: components/payments/content/can_make_payment_query_factory.cc

Issue 2866623003: PaymentRequest.canMakePayment() query quota on desktop. (Closed)
Patch Set: frame 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
OLDNEW
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "components/payments/content/can_make_payment_query_factory.h"
6
7 #include "base/memory/singleton.h"
8 #include "components/keyed_service/content/browser_context_dependency_manager.h"
9 #include "components/payments/core/can_make_payment_query.h"
10
11 namespace payments {
12
13 // static
14 CanMakePaymentQueryFactory* CanMakePaymentQueryFactory::GetInstance() {
15 return base::Singleton<CanMakePaymentQueryFactory>::get();
16 }
17
18 CanMakePaymentQuery* CanMakePaymentQueryFactory::GetForContext(
19 content::BrowserContext* context) {
20 return static_cast<CanMakePaymentQuery*>(
21 GetInstance()->GetServiceForBrowserContext(context, true));
22 }
23
24 CanMakePaymentQueryFactory::CanMakePaymentQueryFactory()
25 : BrowserContextKeyedServiceFactory(
26 "CanMakePaymentQuery",
27 BrowserContextDependencyManager::GetInstance()) {}
28
29 CanMakePaymentQueryFactory::~CanMakePaymentQueryFactory() {}
30
31 KeyedService* CanMakePaymentQueryFactory::BuildServiceInstanceFor(
32 content::BrowserContext* context) const {
33 return new CanMakePaymentQuery;
34 }
35
36 } // namespace payments
OLDNEW
« no previous file with comments | « components/payments/content/can_make_payment_query_factory.h ('k') | components/payments/content/payment_request.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698