Allow zooming error pages.
This CL operates by providing a mechanism in HostZoomMap to convert urls
into the error-page url when an error page is loaded. The error-page
url is used to track the zoom-levels for error pages. Callers to
HostZoomMap::SetZoomLevelForHost*() functions are expected to convert
URLs obtained from NavigationEntrys before setting zoom levels.
HostZoomMap is also modified to add a function to transmit the zoom
level for a newly loaded error page, since it doesn't follow the usual
loading pathway. The transmission of the zoom level is triggered
when an error page is detected in
NavigationControllerImpl::RendererDidNavigateToNewPage().
The CL also creates a localization string to represent error pages in
the Content Settings page list of hosts with non-default zooms, this
since the internal url representations for error pages are not suitable
to be displayed to a user.
BUG=417699
Review URL: https://codereview.chromium.org/678963003
Cr-Commit-Position: refs/heads/master@{#301707}
diff --git a/content/browser/host_zoom_map_impl.h b/content/browser/host_zoom_map_impl.h
index d2a8a67c..78d643d 100644
--- a/content/browser/host_zoom_map_impl.h
+++ b/content/browser/host_zoom_map_impl.h
@@ -86,6 +86,8 @@
const NotificationSource& source,
const NotificationDetails& details) override;
+ void SendErrorPageZoomLevelRefresh();
+
private:
typedef std::map<std::string, double> HostZoomLevels;
typedef std::map<std::string, HostZoomLevels> SchemeHostZoomLevels;