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

Unified Diff: content/browser/host_zoom_map_impl.cc

Issue 11340029: Move remaining files in content\browser to the content namespace. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 years, 2 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
Index: content/browser/host_zoom_map_impl.cc
===================================================================
--- content/browser/host_zoom_map_impl.cc (revision 164795)
+++ content/browser/host_zoom_map_impl.cc (working copy)
@@ -23,9 +23,6 @@
#include "third_party/WebKit/Source/WebKit/chromium/public/WebView.h"
using WebKit::WebView;
-using content::BrowserThread;
-using content::RenderProcessHost;
-using content::RenderViewHost;
static const char* kHostZoomMapKeyName = "content_host_zoom_map";
@@ -41,13 +38,11 @@
return rv;
}
-} // namespace content
-
HostZoomMapImpl::HostZoomMapImpl()
: default_zoom_level_(0.0) {
registrar_.Add(
- this, content::NOTIFICATION_RENDER_VIEW_HOST_WILL_CLOSE_RENDER_VIEW,
- content::NotificationService::AllSources());
+ this, NOTIFICATION_RENDER_VIEW_HOST_WILL_CLOSE_RENDER_VIEW,
tfarina 2012/10/30 22:19:06 this fits above now.
+ NotificationService::AllSources());
}
void HostZoomMapImpl::CopyFrom(HostZoomMap* copy_interface) {
@@ -77,7 +72,7 @@
{
base::AutoLock auto_lock(lock_);
- if (content::ZoomValuesEqual(level, default_zoom_level_))
+ if (ZoomValuesEqual(level, default_zoom_level_))
host_zoom_levels_.erase(host);
else
host_zoom_levels_[host] = level;
@@ -94,10 +89,10 @@
}
}
- content::NotificationService::current()->Notify(
- content::NOTIFICATION_ZOOM_LEVEL_CHANGED,
- content::Source<HostZoomMap>(this),
- content::Details<const std::string>(&host));
+ NotificationService::current()->Notify(
+ NOTIFICATION_ZOOM_LEVEL_CHANGED,
tfarina 2012/10/30 22:19:06 fits above;
+ Source<HostZoomMap>(this),
+ Details<const std::string>(&host));
}
double HostZoomMapImpl::GetDefaultZoomLevel() const {
@@ -150,23 +145,21 @@
}
std::string host;
- content::NotificationService::current()->Notify(
- content::NOTIFICATION_ZOOM_LEVEL_CHANGED,
- content::Source<HostZoomMap>(this),
- content::Details<const std::string>(&host));
+ NotificationService::current()->Notify(
+ NOTIFICATION_ZOOM_LEVEL_CHANGED,
tfarina 2012/10/30 22:19:06 fits above.
+ Source<HostZoomMap>(this),
+ Details<const std::string>(&host));
}
-void HostZoomMapImpl::Observe(
- int type,
- const content::NotificationSource& source,
- const content::NotificationDetails& details) {
+void HostZoomMapImpl::Observe(int type,
+ const NotificationSource& source,
+ const NotificationDetails& details) {
switch (type) {
- case content::NOTIFICATION_RENDER_VIEW_HOST_WILL_CLOSE_RENDER_VIEW: {
+ case NOTIFICATION_RENDER_VIEW_HOST_WILL_CLOSE_RENDER_VIEW: {
base::AutoLock auto_lock(lock_);
- int render_view_id =
- content::Source<RenderViewHost>(source)->GetRoutingID();
+ int render_view_id = Source<RenderViewHost>(source)->GetRoutingID();
int render_process_id =
- content::Source<RenderViewHost>(source)->GetProcess()->GetID();
+ Source<RenderViewHost>(source)->GetProcess()->GetID();
for (size_t i = 0; i < temporary_zoom_levels_.size(); ++i) {
if (temporary_zoom_levels_[i].render_process_id == render_process_id &&
@@ -184,3 +177,5 @@
HostZoomMapImpl::~HostZoomMapImpl() {
}
+
+} // namespace content

Powered by Google App Engine
This is Rietveld 408576698