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

Unified Diff: webkit/browser/blob/mock_blob_url_request_context.cc

Issue 146963006: Move blob/mock_blob_url_request_context to content/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix duplicate GYPI entries (should fix link errors on Android and Win) Created 6 years, 11 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 | « webkit/browser/blob/mock_blob_url_request_context.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/browser/blob/mock_blob_url_request_context.cc
diff --git a/webkit/browser/blob/mock_blob_url_request_context.cc b/webkit/browser/blob/mock_blob_url_request_context.cc
deleted file mode 100644
index 1794a58eb6264223b7956c80b018a239d0fa22cb..0000000000000000000000000000000000000000
--- a/webkit/browser/blob/mock_blob_url_request_context.cc
+++ /dev/null
@@ -1,49 +0,0 @@
-// 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 "webkit/browser/blob/mock_blob_url_request_context.h"
-
-#include "webkit/browser/blob/blob_storage_context.h"
-#include "webkit/browser/blob/blob_url_request_job.h"
-#include "webkit/browser/blob/blob_url_request_job_factory.h"
-#include "webkit/common/blob/blob_data.h"
-
-
-namespace webkit_blob {
-
-MockBlobURLRequestContext::MockBlobURLRequestContext(
- fileapi::FileSystemContext* file_system_context)
- : blob_storage_context_(new BlobStorageContext) {
- // Job factory owns the protocol handler.
- job_factory_.SetProtocolHandler(
- "blob", new BlobProtocolHandler(blob_storage_context_.get(),
- file_system_context,
- base::MessageLoopProxy::current()));
- set_job_factory(&job_factory_);
-}
-
-MockBlobURLRequestContext::~MockBlobURLRequestContext() {
-}
-
-ScopedTextBlob::ScopedTextBlob(
- const MockBlobURLRequestContext& request_context,
- const std::string& blob_id,
- const std::string& data)
- : blob_id_(blob_id),
- context_(request_context.blob_storage_context()) {
- DCHECK(context_);
- scoped_refptr<BlobData> blob_data(new BlobData(blob_id_));
- if (!data.empty())
- blob_data->AppendData(data);
- handle_ = context_->AddFinishedBlob(blob_data);
-}
-
-ScopedTextBlob::~ScopedTextBlob() {
-}
-
-scoped_ptr<BlobDataHandle> ScopedTextBlob::GetBlobDataHandle() {
- return context_->GetBlobDataFromUUID(blob_id_);
-}
-
-} // namespace webkit_blob
« no previous file with comments | « webkit/browser/blob/mock_blob_url_request_context.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698