Commit 38826959 authored by Adrienne Walker's avatar Adrienne Walker Committed by Commit Bot

indexeddb: remove unneeded includes from IndexedDBContextImpl

These includes will not be valid when idb moves to the storage service.
Additionally, the size is not used as in the web ui so it is safe to
save it as a double instead of a formatted string.  (base::Value does
not support int64_t.)  It could also be potentially removed in the
future.

Bug: 1015214
Change-Id: I943fe6f89672560097b99f6883f7999d2a811495
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2091710
Auto-Submit: enne <enne@chromium.org>
Reviewed-by: default avatarDaniel Murphy <dmurph@chromium.org>
Commit-Queue: enne <enne@chromium.org>
Cr-Commit-Position: refs/heads/master@{#747923}
parent 9f09267e
...@@ -28,7 +28,6 @@ ...@@ -28,7 +28,6 @@
#include "components/services/storage/indexed_db/leveldb/leveldb_factory.h" #include "components/services/storage/indexed_db/leveldb/leveldb_factory.h"
#include "components/services/storage/indexed_db/scopes/varint_coding.h" #include "components/services/storage/indexed_db/scopes/varint_coding.h"
#include "components/services/storage/indexed_db/transactional_leveldb/transactional_leveldb_database.h" #include "components/services/storage/indexed_db/transactional_leveldb/transactional_leveldb_database.h"
#include "content/browser/browser_main_loop.h"
#include "content/browser/indexed_db/indexed_db_class_factory.h" #include "content/browser/indexed_db/indexed_db_class_factory.h"
#include "content/browser/indexed_db/indexed_db_connection.h" #include "content/browser/indexed_db/indexed_db_connection.h"
#include "content/browser/indexed_db/indexed_db_database.h" #include "content/browser/indexed_db/indexed_db_database.h"
...@@ -45,7 +44,6 @@ ...@@ -45,7 +44,6 @@
#include "third_party/blink/public/mojom/indexeddb/indexeddb.mojom.h" #include "third_party/blink/public/mojom/indexeddb/indexeddb.mojom.h"
#include "third_party/blink/public/mojom/quota/quota_types.mojom.h" #include "third_party/blink/public/mojom/quota/quota_types.mojom.h"
#include "third_party/zlib/google/zip.h" #include "third_party/zlib/google/zip.h"
#include "ui/base/text/bytes_formatting.h"
#include "url/origin.h" #include "url/origin.h"
using base::DictionaryValue; using base::DictionaryValue;
...@@ -291,7 +289,7 @@ void IndexedDBContextImpl::GetAllOriginsDetails( ...@@ -291,7 +289,7 @@ void IndexedDBContextImpl::GetAllOriginsDetails(
std::unique_ptr<base::DictionaryValue> info( std::unique_ptr<base::DictionaryValue> info(
std::make_unique<base::DictionaryValue>()); std::make_unique<base::DictionaryValue>());
info->SetString("url", origin.Serialize()); info->SetString("url", origin.Serialize());
info->SetString("size", ui::FormatBytes(GetOriginDiskUsage(origin))); info->SetDouble("size", static_cast<double>(GetOriginDiskUsage(origin)));
info->SetDouble("last_modified", GetOriginLastModified(origin).ToJsTime()); info->SetDouble("last_modified", GetOriginLastModified(origin).ToJsTime());
auto paths = std::make_unique<base::ListValue>(); auto paths = std::make_unique<base::ListValue>();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment