1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
|
// Copyright (c) 2012 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.
#include "content/common_child/indexed_db/proxy_webidbfactory_impl.h"
#include "content/common/child_thread.h"
#include "content/common_child/indexed_db/indexed_db_dispatcher.h"
#include "third_party/WebKit/public/platform/WebString.h"
using WebKit::WebIDBCallbacks;
using WebKit::WebIDBDatabase;
using WebKit::WebIDBDatabaseCallbacks;
using WebKit::WebString;
namespace content {
RendererWebIDBFactoryImpl::RendererWebIDBFactoryImpl() {
}
RendererWebIDBFactoryImpl::~RendererWebIDBFactoryImpl() {
}
void RendererWebIDBFactoryImpl::getDatabaseNames(
WebIDBCallbacks* callbacks,
const WebString& database_identifier,
const WebString& data_dir_unused) {
IndexedDBDispatcher* dispatcher =
IndexedDBDispatcher::ThreadSpecificInstance();
dispatcher->RequestIDBFactoryGetDatabaseNames(
callbacks, database_identifier);
}
void RendererWebIDBFactoryImpl::open(
const WebString& name,
long long version,
long long transaction_id,
WebIDBCallbacks* callbacks,
WebIDBDatabaseCallbacks* database_callbacks,
const WebString& database_identifier,
const WebString& data_dir) {
// Don't send the data_dir. We know what we want on the Browser side of
// things.
IndexedDBDispatcher* dispatcher =
IndexedDBDispatcher::ThreadSpecificInstance();
dispatcher->RequestIDBFactoryOpen(
name, version, transaction_id, callbacks, database_callbacks,
database_identifier);
}
void RendererWebIDBFactoryImpl::deleteDatabase(
const WebString& name,
WebIDBCallbacks* callbacks,
const WebString& database_identifier,
const WebString& data_dir) {
// Don't send the data_dir. We know what we want on the Browser side of
// things.
IndexedDBDispatcher* dispatcher =
IndexedDBDispatcher::ThreadSpecificInstance();
dispatcher->RequestIDBFactoryDeleteDatabase(
name, callbacks, database_identifier);
}
} // namespace content
|