summaryrefslogtreecommitdiffstats
path: root/chrome/browser/gtk/options
diff options
context:
space:
mode:
authorbauerb@chromium.org <bauerb@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-09-24 15:32:42 +0000
committerbauerb@chromium.org <bauerb@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-09-24 15:32:42 +0000
commit3cc47d6ba4dd8f5522e0b1939c3906742d964d94 (patch)
tree07b371fb4d1c5079a826e159756d63b0451a034b /chrome/browser/gtk/options
parent6cb60aa4474b7bd3680f5ce36aaf08bf0484dbea (diff)
downloadchromium_src-3cc47d6ba4dd8f5522e0b1939c3906742d964d94.zip
chromium_src-3cc47d6ba4dd8f5522e0b1939c3906742d964d94.tar.gz
chromium_src-3cc47d6ba4dd8f5522e0b1939c3906742d964d94.tar.bz2
Add IndexedDB to cookie tree.
XIB changes: Add another view with IndexedDB details to CookieDetailsView.xib. BUG=56248 TEST=CookiesTreeModelTest.*:CookiesDetailsTest.*:CookiesViewTest.*: Review URL: http://codereview.chromium.org/3429020 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@60470 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/gtk/options')
-rw-r--r--chrome/browser/gtk/options/cookie_filter_page_gtk.cc10
-rw-r--r--chrome/browser/gtk/options/cookies_view.cc21
-rw-r--r--chrome/browser/gtk/options/cookies_view.h10
-rw-r--r--chrome/browser/gtk/options/cookies_view_unittest.cc110
4 files changed, 95 insertions, 56 deletions
diff --git a/chrome/browser/gtk/options/cookie_filter_page_gtk.cc b/chrome/browser/gtk/options/cookie_filter_page_gtk.cc
index 4bf3701..f60bebd 100644
--- a/chrome/browser/gtk/options/cookie_filter_page_gtk.cc
+++ b/chrome/browser/gtk/options/cookie_filter_page_gtk.cc
@@ -193,12 +193,10 @@ void CookieFilterPageGtk::OnShowCookiesClicked(GtkWidget* button) {
UserMetricsRecordAction(UserMetricsAction("Options_ShowCookies"), NULL);
CookiesView::Show(GTK_WINDOW(gtk_widget_get_toplevel(button)),
profile(),
- new BrowsingDataDatabaseHelper(
- profile()),
- new BrowsingDataLocalStorageHelper(
- profile()),
- new BrowsingDataAppCacheHelper(
- profile()));
+ new BrowsingDataDatabaseHelper(profile()),
+ new BrowsingDataLocalStorageHelper(profile()),
+ new BrowsingDataAppCacheHelper(profile()),
+ BrowsingDataIndexedDBHelper::Create(profile()));
}
void CookieFilterPageGtk::OnFlashLinkClicked(GtkWidget* button) {
diff --git a/chrome/browser/gtk/options/cookies_view.cc b/chrome/browser/gtk/options/cookies_view.cc
index aee19d7..415dedb 100644
--- a/chrome/browser/gtk/options/cookies_view.cc
+++ b/chrome/browser/gtk/options/cookies_view.cc
@@ -50,11 +50,13 @@ void CookiesView::Show(
Profile* profile,
BrowsingDataDatabaseHelper* browsing_data_database_helper,
BrowsingDataLocalStorageHelper* browsing_data_local_storage_helper,
- BrowsingDataAppCacheHelper* browsing_data_appcache_helper) {
+ BrowsingDataAppCacheHelper* browsing_data_appcache_helper,
+ BrowsingDataIndexedDBHelper* browsing_data_indexed_db_helper) {
DCHECK(profile);
DCHECK(browsing_data_database_helper);
DCHECK(browsing_data_local_storage_helper);
DCHECK(browsing_data_appcache_helper);
+ DCHECK(browsing_data_indexed_db_helper);
// If there's already an existing editor window, activate it.
if (instance_) {
@@ -64,7 +66,8 @@ void CookiesView::Show(
profile,
browsing_data_database_helper,
browsing_data_local_storage_helper,
- browsing_data_appcache_helper);
+ browsing_data_appcache_helper,
+ browsing_data_indexed_db_helper);
}
}
@@ -73,11 +76,13 @@ CookiesView::CookiesView(
Profile* profile,
BrowsingDataDatabaseHelper* browsing_data_database_helper,
BrowsingDataLocalStorageHelper* browsing_data_local_storage_helper,
- BrowsingDataAppCacheHelper* browsing_data_appcache_helper)
+ BrowsingDataAppCacheHelper* browsing_data_appcache_helper,
+ BrowsingDataIndexedDBHelper* browsing_data_indexed_db_helper)
: profile_(profile),
browsing_data_database_helper_(browsing_data_database_helper),
browsing_data_local_storage_helper_(browsing_data_local_storage_helper),
browsing_data_appcache_helper_(browsing_data_appcache_helper),
+ browsing_data_indexed_db_helper_(browsing_data_indexed_db_helper),
filter_update_factory_(this),
destroy_dialog_in_destructor_(false) {
Init(parent);
@@ -90,7 +95,7 @@ CookiesView::CookiesView(
gtk_chrome_cookie_view_clear(GTK_CHROME_COOKIE_VIEW(cookie_display_));
}
-void CookiesView::TestDestroySyncrhonously() {
+void CookiesView::TestDestroySynchronously() {
g_signal_handler_disconnect(dialog_, destroy_handler_);
destroy_dialog_in_destructor_ = true;
}
@@ -188,7 +193,8 @@ void CookiesView::Init(GtkWindow* parent) {
browsing_data_database_helper_,
browsing_data_local_storage_helper_,
NULL,
- browsing_data_appcache_helper_));
+ browsing_data_appcache_helper_,
+ browsing_data_indexed_db_helper_));
cookies_tree_adapter_.reset(
new gtk_tree::TreeAdapter(this, cookies_tree_model_.get()));
tree_ = gtk_tree_view_new_with_model(
@@ -270,6 +276,11 @@ void CookiesView::EnableControls() {
gtk_chrome_cookie_view_display_app_cache(
GTK_CHROME_COOKIE_VIEW(cookie_display_),
*detailed_info.appcache_info);
+ } else if (detailed_info.node_type ==
+ CookieTreeNode::DetailedInfo::TYPE_INDEXED_DB) {
+ gtk_chrome_cookie_view_display_indexed_db(
+ GTK_CHROME_COOKIE_VIEW(cookie_display_),
+ *detailed_info.indexed_db_info);
} else {
gtk_chrome_cookie_view_clear(GTK_CHROME_COOKIE_VIEW(cookie_display_));
}
diff --git a/chrome/browser/gtk/options/cookies_view.h b/chrome/browser/gtk/options/cookies_view.h
index 2d58b61..27c0e0f 100644
--- a/chrome/browser/gtk/options/cookies_view.h
+++ b/chrome/browser/gtk/options/cookies_view.h
@@ -17,6 +17,7 @@
#include "base/task.h"
#include "chrome/browser/browsing_data_appcache_helper.h"
#include "chrome/browser/browsing_data_database_helper.h"
+#include "chrome/browser/browsing_data_indexed_db_helper.h"
#include "chrome/browser/browsing_data_local_storage_helper.h"
#include "chrome/browser/gtk/gtk_chrome_cookie_view.h"
#include "chrome/browser/gtk/gtk_tree.h"
@@ -43,7 +44,8 @@ class CookiesView : public gtk_tree::TreeAdapter::Delegate {
Profile* profile,
BrowsingDataDatabaseHelper* browsing_data_database_helper,
BrowsingDataLocalStorageHelper* browsing_data_local_storage_helper,
- BrowsingDataAppCacheHelper* browsing_data_appcache_helper);
+ BrowsingDataAppCacheHelper* browsing_data_appcache_helper,
+ BrowsingDataIndexedDBHelper* browsing_data_indexed_db_helper);
// gtk_tree::TreeAdapter::Delegate implementation.
virtual void OnAnyModelUpdateStart();
@@ -55,11 +57,12 @@ class CookiesView : public gtk_tree::TreeAdapter::Delegate {
Profile* profile,
BrowsingDataDatabaseHelper* browsing_data_database_helper,
BrowsingDataLocalStorageHelper* browsing_data_local_storage_helper,
- BrowsingDataAppCacheHelper* browsing_data_appcache_helper);
+ BrowsingDataAppCacheHelper* browsing_data_appcache_helper,
+ BrowsingDataIndexedDBHelper* browsing_data_indexed_db_helper);
// A method only used in unit tests that sets a bit inside this class that
// lets it be stack allocated.
- void TestDestroySyncrhonously();
+ void TestDestroySynchronously();
// Initialize the dialog contents and layout.
void Init(GtkWindow* parent);
@@ -112,6 +115,7 @@ class CookiesView : public gtk_tree::TreeAdapter::Delegate {
scoped_refptr<BrowsingDataLocalStorageHelper>
browsing_data_local_storage_helper_;
scoped_refptr<BrowsingDataAppCacheHelper> browsing_data_appcache_helper_;
+ scoped_refptr<BrowsingDataIndexedDBHelper> browsing_data_indexed_db_helper_;
// A factory to construct Runnable Methods so that we can be called back to
// re-evaluate the model after the search query string changes.
diff --git a/chrome/browser/gtk/options/cookies_view_unittest.cc b/chrome/browser/gtk/options/cookies_view_unittest.cc
index a32d5f4..2a71eea6 100644
--- a/chrome/browser/gtk/options/cookies_view_unittest.cc
+++ b/chrome/browser/gtk/options/cookies_view_unittest.cc
@@ -12,6 +12,7 @@
#include "base/string_util.h"
#include "chrome/browser/mock_browsing_data_appcache_helper.h"
#include "chrome/browser/mock_browsing_data_database_helper.h"
+#include "chrome/browser/mock_browsing_data_indexed_db_helper.h"
#include "chrome/browser/mock_browsing_data_local_storage_helper.h"
#include "chrome/browser/gtk/gtk_chrome_cookie_view.h"
#include "chrome/common/net/url_request_context_getter.h"
@@ -36,12 +37,15 @@ class CookiesViewTest : public testing::Test {
new MockBrowsingDataLocalStorageHelper(profile_.get());
mock_browsing_data_appcache_helper_ =
new MockBrowsingDataAppCacheHelper(profile_.get());
+ mock_browsing_data_indexed_db_helper_ =
+ new MockBrowsingDataIndexedDBHelper(profile_.get());
}
void CheckDetailsSensitivity(gboolean expected_cookies,
gboolean expected_database,
gboolean expected_local_storage,
gboolean expected_appcache,
+ gboolean expected_indexed_db,
const CookiesView& cookies_view) {
GtkChromeCookieView* display = GTK_CHROME_COOKIE_VIEW(
cookies_view.cookie_display_);
@@ -84,6 +88,15 @@ class CookiesViewTest : public testing::Test {
GTK_WIDGET_SENSITIVE(display->appcache_created_entry_));
EXPECT_EQ(expected_appcache,
GTK_WIDGET_SENSITIVE(display->appcache_last_accessed_entry_));
+ // IndexedDB
+ EXPECT_EQ(expected_indexed_db,
+ GTK_WIDGET_SENSITIVE(display->indexed_db_name_entry_));
+ EXPECT_EQ(expected_indexed_db,
+ GTK_WIDGET_SENSITIVE(display->indexed_db_origin_entry_));
+ EXPECT_EQ(expected_indexed_db,
+ GTK_WIDGET_SENSITIVE(display->indexed_db_size_entry_));
+ EXPECT_EQ(expected_indexed_db,
+ GTK_WIDGET_SENSITIVE(display->indexed_db_last_modified_entry_));
}
// Get the cookie names in the cookie list, as a comma seperated string.
@@ -194,6 +207,8 @@ class CookiesViewTest : public testing::Test {
mock_browsing_data_local_storage_helper_;
scoped_refptr<MockBrowsingDataAppCacheHelper>
mock_browsing_data_appcache_helper_;
+ scoped_refptr<MockBrowsingDataIndexedDBHelper>
+ mock_browsing_data_indexed_db_helper_;
};
TEST_F(CookiesViewTest, Empty) {
@@ -201,11 +216,12 @@ TEST_F(CookiesViewTest, Empty) {
profile_.get(),
mock_browsing_data_database_helper_,
mock_browsing_data_local_storage_helper_,
- mock_browsing_data_appcache_helper_);
- cookies_view.TestDestroySyncrhonously();
+ mock_browsing_data_appcache_helper_,
+ mock_browsing_data_indexed_db_helper_);
+ cookies_view.TestDestroySynchronously();
EXPECT_EQ(FALSE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(FALSE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
- CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, FALSE, cookies_view);
EXPECT_STREQ("", GetDisplayedCookies(cookies_view).c_str());
}
@@ -222,8 +238,9 @@ TEST_F(CookiesViewTest, Noop) {
profile_.get(),
mock_browsing_data_database_helper_,
mock_browsing_data_local_storage_helper_,
- mock_browsing_data_appcache_helper_);
- cookies_view.TestDestroySyncrhonously();
+ mock_browsing_data_appcache_helper_,
+ mock_browsing_data_indexed_db_helper_);
+ cookies_view.TestDestroySynchronously();
mock_browsing_data_database_helper_->AddDatabaseSamples();
mock_browsing_data_database_helper_->Notify();
mock_browsing_data_local_storage_helper_->AddLocalStorageSamples();
@@ -238,7 +255,7 @@ TEST_F(CookiesViewTest, Noop) {
GetDisplayedCookies(cookies_view).c_str());
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
- CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, FALSE, cookies_view);
}
TEST_F(CookiesViewTest, RemoveAll) {
@@ -249,8 +266,9 @@ TEST_F(CookiesViewTest, RemoveAll) {
profile_.get(),
mock_browsing_data_database_helper_,
mock_browsing_data_local_storage_helper_,
- mock_browsing_data_appcache_helper_);
- cookies_view.TestDestroySyncrhonously();
+ mock_browsing_data_appcache_helper_,
+ mock_browsing_data_indexed_db_helper_);
+ cookies_view.TestDestroySynchronously();
mock_browsing_data_database_helper_->AddDatabaseSamples();
mock_browsing_data_database_helper_->Notify();
mock_browsing_data_local_storage_helper_->AddLocalStorageSamples();
@@ -263,7 +281,7 @@ TEST_F(CookiesViewTest, RemoveAll) {
SCOPED_TRACE("Before removing");
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(FALSE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
- CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, FALSE, cookies_view);
EXPECT_STREQ("foo,_Cookies,__A,foo2,_Cookies,__B,"
"gdbhost1,_Web Databases,__db1,"
"gdbhost2,_Web Databases,__db2,"
@@ -281,7 +299,7 @@ TEST_F(CookiesViewTest, RemoveAll) {
EXPECT_EQ(0u, monster->GetAllCookies().size());
EXPECT_EQ(FALSE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(FALSE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
- CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, FALSE, cookies_view);
EXPECT_STREQ("", GetDisplayedCookies(cookies_view).c_str());
EXPECT_TRUE(mock_browsing_data_database_helper_->AllDeleted());
EXPECT_TRUE(mock_browsing_data_local_storage_helper_->AllDeleted());
@@ -296,8 +314,9 @@ TEST_F(CookiesViewTest, RemoveAllWithDefaultSelected) {
profile_.get(),
mock_browsing_data_database_helper_,
mock_browsing_data_local_storage_helper_,
- mock_browsing_data_appcache_helper_);
- cookies_view.TestDestroySyncrhonously();
+ mock_browsing_data_appcache_helper_,
+ mock_browsing_data_indexed_db_helper_);
+ cookies_view.TestDestroySynchronously();
mock_browsing_data_database_helper_->AddDatabaseSamples();
mock_browsing_data_database_helper_->Notify();
mock_browsing_data_local_storage_helper_->AddLocalStorageSamples();
@@ -309,7 +328,7 @@ TEST_F(CookiesViewTest, RemoveAllWithDefaultSelected) {
SCOPED_TRACE("Before removing");
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
- CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, FALSE, cookies_view);
EXPECT_STREQ("foo,_Cookies,__A,foo2,_Cookies,__B,"
"gdbhost1,_Web Databases,__db1,"
"gdbhost2,_Web Databases,__db2,"
@@ -327,7 +346,7 @@ TEST_F(CookiesViewTest, RemoveAllWithDefaultSelected) {
EXPECT_EQ(0u, monster->GetAllCookies().size());
EXPECT_EQ(FALSE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(FALSE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
- CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, FALSE, cookies_view);
EXPECT_STREQ("", GetDisplayedCookies(cookies_view).c_str());
EXPECT_EQ(0,
gtk_tree_selection_count_selected_rows(cookies_view.selection_));
@@ -345,8 +364,9 @@ TEST_F(CookiesViewTest, Remove) {
profile_.get(),
mock_browsing_data_database_helper_,
mock_browsing_data_local_storage_helper_,
- mock_browsing_data_appcache_helper_);
- cookies_view.TestDestroySyncrhonously();
+ mock_browsing_data_appcache_helper_,
+ mock_browsing_data_indexed_db_helper_);
+ cookies_view.TestDestroySynchronously();
mock_browsing_data_database_helper_->AddDatabaseSamples();
mock_browsing_data_database_helper_->Notify();
mock_browsing_data_local_storage_helper_->AddLocalStorageSamples();
@@ -359,7 +379,7 @@ TEST_F(CookiesViewTest, Remove) {
SCOPED_TRACE("First selection");
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
- CheckDetailsSensitivity(TRUE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(TRUE, FALSE, FALSE, FALSE, FALSE, cookies_view);
EXPECT_STREQ("foo1,_Cookies,__A,foo2,+Cookies,++B,++C,"
"gdbhost1,_Web Databases,__db1,"
"gdbhost2,_Web Databases,__db2,"
@@ -382,7 +402,7 @@ TEST_F(CookiesViewTest, Remove) {
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
EXPECT_STREQ("1:0:0", GetSelectedPath(cookies_view).c_str());
- CheckDetailsSensitivity(TRUE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(TRUE, FALSE, FALSE, FALSE, FALSE, cookies_view);
}
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
@@ -400,7 +420,7 @@ TEST_F(CookiesViewTest, Remove) {
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(FALSE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
EXPECT_STREQ("", GetSelectedPath(cookies_view).c_str());
- CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, FALSE, cookies_view);
}
ASSERT_TRUE(ExpandByPath(cookies_view, "0"));
@@ -419,7 +439,7 @@ TEST_F(CookiesViewTest, Remove) {
EXPECT_EQ(0u, monster->GetAllCookies().size());
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(FALSE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
- CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, FALSE, cookies_view);
EXPECT_STREQ("gdbhost1,_Web Databases,__db1,"
"gdbhost2,_Web Databases,__db2,"
"host1,_Local Storage,__http://host1:1/,"
@@ -442,7 +462,7 @@ TEST_F(CookiesViewTest, Remove) {
EXPECT_EQ(0u, monster->GetAllCookies().size());
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(FALSE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
- CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, FALSE, cookies_view);
EXPECT_STREQ("gdbhost2,_Web Databases,__db2,"
"host1,_Local Storage,__http://host1:1/,"
"host2,_Local Storage,__http://host2:2/",
@@ -467,7 +487,7 @@ TEST_F(CookiesViewTest, Remove) {
EXPECT_EQ(0u, monster->GetAllCookies().size());
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(FALSE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
- CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, FALSE, cookies_view);
EXPECT_STREQ("gdbhost2,_Web Databases,__db2,"
"host2,_Local Storage,__http://host2:2/",
GetDisplayedCookies(cookies_view).c_str());
@@ -489,8 +509,9 @@ TEST_F(CookiesViewTest, RemoveCookiesByType) {
profile_.get(),
mock_browsing_data_database_helper_,
mock_browsing_data_local_storage_helper_,
- mock_browsing_data_appcache_helper_);
- cookies_view.TestDestroySyncrhonously();
+ mock_browsing_data_appcache_helper_,
+ mock_browsing_data_indexed_db_helper_);
+ cookies_view.TestDestroySynchronously();
mock_browsing_data_database_helper_->AddDatabaseSamples();
mock_browsing_data_database_helper_->Notify();
mock_browsing_data_local_storage_helper_->AddLocalStorageSamples();
@@ -624,8 +645,9 @@ TEST_F(CookiesViewTest, RemoveByDomain) {
profile_.get(),
mock_browsing_data_database_helper_,
mock_browsing_data_local_storage_helper_,
- mock_browsing_data_appcache_helper_);
- cookies_view.TestDestroySyncrhonously();
+ mock_browsing_data_appcache_helper_,
+ mock_browsing_data_indexed_db_helper_);
+ cookies_view.TestDestroySynchronously();
mock_browsing_data_database_helper_->AddDatabaseSamples();
mock_browsing_data_database_helper_->Notify();
mock_browsing_data_local_storage_helper_->AddLocalStorageSamples();
@@ -750,8 +772,9 @@ TEST_F(CookiesViewTest, RemoveDefaultSelection) {
profile_.get(),
mock_browsing_data_database_helper_,
mock_browsing_data_local_storage_helper_,
- mock_browsing_data_appcache_helper_);
- cookies_view.TestDestroySyncrhonously();
+ mock_browsing_data_appcache_helper_,
+ mock_browsing_data_indexed_db_helper_);
+ cookies_view.TestDestroySynchronously();
mock_browsing_data_database_helper_->AddDatabaseSamples();
mock_browsing_data_database_helper_->Notify();
mock_browsing_data_local_storage_helper_->AddLocalStorageSamples();
@@ -858,8 +881,9 @@ TEST_F(CookiesViewTest, Filter) {
profile_.get(),
mock_browsing_data_database_helper_,
mock_browsing_data_local_storage_helper_,
- mock_browsing_data_appcache_helper_);
- cookies_view.TestDestroySyncrhonously();
+ mock_browsing_data_appcache_helper_,
+ mock_browsing_data_indexed_db_helper_);
+ cookies_view.TestDestroySynchronously();
mock_browsing_data_database_helper_->AddDatabaseSamples();
mock_browsing_data_database_helper_->Notify();
mock_browsing_data_local_storage_helper_->AddLocalStorageSamples();
@@ -928,8 +952,9 @@ TEST_F(CookiesViewTest, FilterRemoveAll) {
profile_.get(),
mock_browsing_data_database_helper_,
mock_browsing_data_local_storage_helper_,
- mock_browsing_data_appcache_helper_);
- cookies_view.TestDestroySyncrhonously();
+ mock_browsing_data_appcache_helper_,
+ mock_browsing_data_indexed_db_helper_);
+ cookies_view.TestDestroySynchronously();
mock_browsing_data_database_helper_->AddDatabaseSamples();
mock_browsing_data_database_helper_->Notify();
mock_browsing_data_local_storage_helper_->AddLocalStorageSamples();
@@ -997,8 +1022,9 @@ TEST_F(CookiesViewTest, FilterRemove) {
profile_.get(),
mock_browsing_data_database_helper_,
mock_browsing_data_local_storage_helper_,
- mock_browsing_data_appcache_helper_);
- cookies_view.TestDestroySyncrhonously();
+ mock_browsing_data_appcache_helper_,
+ mock_browsing_data_indexed_db_helper_);
+ cookies_view.TestDestroySynchronously();
mock_browsing_data_database_helper_->AddDatabaseSamples();
mock_browsing_data_database_helper_->Notify();
mock_browsing_data_local_storage_helper_->AddLocalStorageSamples();
@@ -1047,7 +1073,7 @@ TEST_F(CookiesViewTest, FilterRemove) {
SCOPED_TRACE("First selection");
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
- CheckDetailsSensitivity(TRUE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(TRUE, FALSE, FALSE, FALSE, FALSE, cookies_view);
}
gtk_button_clicked(GTK_BUTTON(cookies_view.remove_button_));
@@ -1061,7 +1087,7 @@ TEST_F(CookiesViewTest, FilterRemove) {
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
EXPECT_STREQ("1:0:0", GetSelectedPath(cookies_view).c_str());
- CheckDetailsSensitivity(TRUE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(TRUE, FALSE, FALSE, FALSE, FALSE, cookies_view);
}
gtk_button_clicked(GTK_BUTTON(cookies_view.remove_button_));
@@ -1073,7 +1099,7 @@ TEST_F(CookiesViewTest, FilterRemove) {
GetDisplayedCookies(cookies_view).c_str());
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(FALSE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
- CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, FALSE, cookies_view);
}
ASSERT_TRUE(ExpandByPath(cookies_view, "0"));
@@ -1086,7 +1112,7 @@ TEST_F(CookiesViewTest, FilterRemove) {
EXPECT_STREQ("C,B", GetMonsterCookies(monster).c_str());
EXPECT_EQ(FALSE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(FALSE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
- CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, FALSE, cookies_view);
EXPECT_STREQ("", GetDisplayedCookies(cookies_view).c_str());
}
@@ -1132,7 +1158,7 @@ TEST_F(CookiesViewTest, FilterRemove) {
SCOPED_TRACE("First selection");
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
- CheckDetailsSensitivity(FALSE, TRUE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(FALSE, TRUE, FALSE, FALSE, FALSE, cookies_view);
}
gtk_button_clicked(GTK_BUTTON(cookies_view.remove_button_));
@@ -1146,7 +1172,7 @@ TEST_F(CookiesViewTest, FilterRemove) {
GetDisplayedCookies(cookies_view).c_str());
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(FALSE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
- CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, FALSE, cookies_view);
}
ASSERT_TRUE(ExpandByPath(cookies_view, "2"));
@@ -1160,7 +1186,7 @@ TEST_F(CookiesViewTest, FilterRemove) {
SCOPED_TRACE("First selection");
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
- CheckDetailsSensitivity(FALSE, FALSE, TRUE, FALSE, cookies_view);
+ CheckDetailsSensitivity(FALSE, FALSE, TRUE, FALSE, FALSE, cookies_view);
}
gtk_button_clicked(GTK_BUTTON(cookies_view.remove_button_));
@@ -1173,6 +1199,6 @@ TEST_F(CookiesViewTest, FilterRemove) {
GetDisplayedCookies(cookies_view).c_str());
EXPECT_EQ(TRUE, GTK_WIDGET_SENSITIVE(cookies_view.remove_all_button_));
EXPECT_EQ(FALSE, GTK_WIDGET_SENSITIVE(cookies_view.remove_button_));
- CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, cookies_view);
+ CheckDetailsSensitivity(FALSE, FALSE, FALSE, FALSE, FALSE, cookies_view);
}
}