summaryrefslogtreecommitdiffstats
path: root/chrome/browser/ui/webui
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/ui/webui')
-rw-r--r--chrome/browser/ui/webui/chrome_web_ui_factory.cc4
-rw-r--r--chrome/browser/ui/webui/extension_icon_source.cc6
-rw-r--r--chrome/browser/ui/webui/favicon_source.cc9
-rw-r--r--chrome/browser/ui/webui/history2_ui.cc9
-rw-r--r--chrome/browser/ui/webui/history_ui.cc9
-rw-r--r--chrome/browser/ui/webui/ntp/app_launcher_handler.cc2
-rw-r--r--chrome/browser/ui/webui/ntp/favicon_webui_handler.cc5
7 files changed, 27 insertions, 17 deletions
diff --git a/chrome/browser/ui/webui/chrome_web_ui_factory.cc b/chrome/browser/ui/webui/chrome_web_ui_factory.cc
index 09f06cb..bcf2008 100644
--- a/chrome/browser/ui/webui/chrome_web_ui_factory.cc
+++ b/chrome/browser/ui/webui/chrome_web_ui_factory.cc
@@ -340,9 +340,7 @@ void ChromeWebUIFactory::GetFaviconForURL(
favicon.known_icon = favicon.image_data.get() != NULL &&
favicon.image_data->size() > 0;
favicon.icon_type = history::FAVICON;
- request->ForwardResultAsync(
- FaviconService::FaviconDataCallback::TupleType(request->handle(),
- favicon));
+ request->ForwardResultAsync(request->handle(), favicon);
}
}
diff --git a/chrome/browser/ui/webui/extension_icon_source.cc b/chrome/browser/ui/webui/extension_icon_source.cc
index f896457..81b0c833 100644
--- a/chrome/browser/ui/webui/extension_icon_source.cc
+++ b/chrome/browser/ui/webui/extension_icon_source.cc
@@ -4,7 +4,8 @@
#include "chrome/browser/ui/webui/extension_icon_source.h"
-#include "base/callback.h"
+#include "base/bind.h"
+#include "base/bind_helpers.h"
#include "base/memory/ref_counted_memory.h"
#include "base/stl_util.h"
#include "base/string_number_conversions.h"
@@ -241,7 +242,8 @@ void ExtensionIconSource::LoadFaviconImage(int request_id) {
favicon_url,
history::FAVICON,
&cancelable_consumer_,
- NewCallback(this, &ExtensionIconSource::OnFaviconDataAvailable));
+ base::Bind(&ExtensionIconSource::OnFaviconDataAvailable,
+ base::Unretained(this)));
cancelable_consumer_.SetClientData(favicon_service, handle, request_id);
}
diff --git a/chrome/browser/ui/webui/favicon_source.cc b/chrome/browser/ui/webui/favicon_source.cc
index 7b66fb7..480c2f5 100644
--- a/chrome/browser/ui/webui/favicon_source.cc
+++ b/chrome/browser/ui/webui/favicon_source.cc
@@ -4,7 +4,8 @@
#include "chrome/browser/ui/webui/favicon_source.h"
-#include "base/callback.h"
+#include "base/bind.h"
+#include "base/bind_helpers.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/common/url_constants.h"
#include "grit/ui_resources.h"
@@ -41,7 +42,8 @@ void FaviconSource::StartDataRequest(const std::string& path,
GURL(path.substr(8)),
history::FAVICON,
&cancelable_consumer_,
- NewCallback(this, &FaviconSource::OnFaviconDataAvailable));
+ base::Bind(&FaviconSource::OnFaviconDataAvailable,
+ base::Unretained(this)));
} else {
GURL url;
@@ -63,7 +65,8 @@ void FaviconSource::StartDataRequest(const std::string& path,
url,
icon_types_,
&cancelable_consumer_,
- NewCallback(this, &FaviconSource::OnFaviconDataAvailable));
+ base::Bind(&FaviconSource::OnFaviconDataAvailable,
+ base::Unretained(this)));
}
// Attach the ChromeURLDataManager request ID to the history request.
cancelable_consumer_.SetClientData(favicon_service, handle, request_id);
diff --git a/chrome/browser/ui/webui/history2_ui.cc b/chrome/browser/ui/webui/history2_ui.cc
index 7b80a82..48cb4fa 100644
--- a/chrome/browser/ui/webui/history2_ui.cc
+++ b/chrome/browser/ui/webui/history2_ui.cc
@@ -150,7 +150,8 @@ void BrowsingHistoryHandler2::HandleGetHistory(const ListValue* args) {
hs->QueryHistory(search_text_,
options,
&cancelable_search_consumer_,
- NewCallback(this, &BrowsingHistoryHandler2::QueryComplete));
+ base::Bind(&BrowsingHistoryHandler2::QueryComplete,
+ base::Unretained(this)));
}
void BrowsingHistoryHandler2::HandleSearchHistory(const ListValue* args) {
@@ -175,7 +176,8 @@ void BrowsingHistoryHandler2::HandleSearchHistory(const ListValue* args) {
hs->QueryHistory(search_text_,
options,
&cancelable_search_consumer_,
- NewCallback(this, &BrowsingHistoryHandler2::QueryComplete));
+ base::Bind(&BrowsingHistoryHandler2::QueryComplete,
+ base::Unretained(this)));
}
void BrowsingHistoryHandler2::HandleRemoveURLsOnOneDay(const ListValue* args) {
@@ -216,7 +218,8 @@ void BrowsingHistoryHandler2::HandleRemoveURLsOnOneDay(const ListValue* args) {
Profile::FromWebUI(web_ui_)->GetHistoryService(Profile::EXPLICIT_ACCESS);
hs->ExpireHistoryBetween(
urls_to_be_deleted_, begin_time, end_time, &cancelable_delete_consumer_,
- NewCallback(this, &BrowsingHistoryHandler2::RemoveComplete));
+ base::Bind(&BrowsingHistoryHandler2::RemoveComplete,
+ base::Unretained(this)));
}
void BrowsingHistoryHandler2::HandleClearBrowsingData(const ListValue* args) {
diff --git a/chrome/browser/ui/webui/history_ui.cc b/chrome/browser/ui/webui/history_ui.cc
index f88d4db..ba1a648 100644
--- a/chrome/browser/ui/webui/history_ui.cc
+++ b/chrome/browser/ui/webui/history_ui.cc
@@ -181,7 +181,8 @@ void BrowsingHistoryHandler::HandleGetHistory(const ListValue* args) {
hs->QueryHistory(search_text_,
options,
&cancelable_search_consumer_,
- NewCallback(this, &BrowsingHistoryHandler::QueryComplete));
+ base::Bind(&BrowsingHistoryHandler::QueryComplete,
+ base::Unretained(this)));
}
void BrowsingHistoryHandler::HandleSearchHistory(const ListValue* args) {
@@ -206,7 +207,8 @@ void BrowsingHistoryHandler::HandleSearchHistory(const ListValue* args) {
hs->QueryHistory(search_text_,
options,
&cancelable_search_consumer_,
- NewCallback(this, &BrowsingHistoryHandler::QueryComplete));
+ base::Bind(&BrowsingHistoryHandler::QueryComplete,
+ base::Unretained(this)));
}
void BrowsingHistoryHandler::HandleRemoveURLsOnOneDay(const ListValue* args) {
@@ -242,7 +244,8 @@ void BrowsingHistoryHandler::HandleRemoveURLsOnOneDay(const ListValue* args) {
Profile::FromWebUI(web_ui_)->GetHistoryService(Profile::EXPLICIT_ACCESS);
hs->ExpireHistoryBetween(
urls, begin_time, end_time, &cancelable_delete_consumer_,
- NewCallback(this, &BrowsingHistoryHandler::RemoveComplete));
+ base::Bind(&BrowsingHistoryHandler::RemoveComplete,
+ base::Unretained(this)));
}
void BrowsingHistoryHandler::HandleClearBrowsingData(const ListValue* args) {
diff --git a/chrome/browser/ui/webui/ntp/app_launcher_handler.cc b/chrome/browser/ui/webui/ntp/app_launcher_handler.cc
index 111f9a7..3651009 100644
--- a/chrome/browser/ui/webui/ntp/app_launcher_handler.cc
+++ b/chrome/browser/ui/webui/ntp/app_launcher_handler.cc
@@ -792,7 +792,7 @@ void AppLauncherHandler::HandleGenerateAppForLink(const ListValue* args) {
FaviconService::Handle h = favicon_service->GetFaviconForURL(
launch_url, history::FAVICON, &favicon_consumer_,
- NewCallback(this, &AppLauncherHandler::OnFaviconForApp));
+ base::Bind(&AppLauncherHandler::OnFaviconForApp, base::Unretained(this)));
favicon_consumer_.SetClientData(favicon_service, h, install_info.release());
}
diff --git a/chrome/browser/ui/webui/ntp/favicon_webui_handler.cc b/chrome/browser/ui/webui/ntp/favicon_webui_handler.cc
index f4e9688..0ae6443 100644
--- a/chrome/browser/ui/webui/ntp/favicon_webui_handler.cc
+++ b/chrome/browser/ui/webui/ntp/favicon_webui_handler.cc
@@ -5,7 +5,7 @@
#include "chrome/browser/ui/webui/ntp/favicon_webui_handler.h"
#include "base/bind.h"
-#include "base/callback_old.h"
+#include "base/bind_helpers.h"
#include "base/string_split.h"
#include "base/string_util.h"
#include "base/stringprintf.h"
@@ -77,7 +77,8 @@ void FaviconWebUIHandler::HandleGetFaviconDominantColor(const ListValue* args) {
GURL(path),
history::FAVICON,
&consumer_,
- NewCallback(this, &FaviconWebUIHandler::OnFaviconDataAvailable));
+ base::Bind(&FaviconWebUIHandler::OnFaviconDataAvailable,
+ base::Unretained(this)));
consumer_.SetClientData(favicon_service, handle, id_++);
}