Index: content/browser/web_contents/web_contents_impl.cc |
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc |
index 2e9e6d9e1622487022ead2c89b2be2086afeb901..b83951e0979c0b3cd0ebd039c20f7db0dea77a72 100644 |
--- a/content/browser/web_contents/web_contents_impl.cc |
+++ b/content/browser/web_contents/web_contents_impl.cc |
@@ -637,6 +637,8 @@ bool WebContentsImpl::OnMessageReceived(RenderViewHost* render_view_host, |
OnDidRunInsecureContent) |
IPC_MESSAGE_HANDLER(ViewHostMsg_GoToEntryAtOffset, OnGoToEntryAtOffset) |
IPC_MESSAGE_HANDLER(ViewHostMsg_UpdateZoomLimits, OnUpdateZoomLimits) |
+ IPC_MESSAGE_HANDLER(ViewHostMsg_PageScaleFactorChanged, |
+ OnPageScaleFactorChanged) |
IPC_MESSAGE_HANDLER(ViewHostMsg_EnumerateDirectory, OnEnumerateDirectory) |
IPC_MESSAGE_HANDLER(FrameHostMsg_RegisterProtocolHandler, |
OnRegisterProtocolHandler) |
@@ -2622,6 +2624,10 @@ int WebContentsImpl::GetMaximumZoomPercent() const { |
return maximum_zoom_percent_; |
} |
+void WebContentsImpl::SetPageScale(float page_scale_factor) { |
+ Send(new ViewMsg_SetPageScale(GetRoutingID(), page_scale_factor)); |
+} |
+ |
void WebContentsImpl::ResetPageScale() { |
Send(new ViewMsg_ResetPageScale(GetRoutingID())); |
} |
@@ -3120,6 +3126,12 @@ void WebContentsImpl::OnUpdateZoomLimits(int minimum_percent, |
maximum_zoom_percent_ = maximum_percent; |
} |
+void WebContentsImpl::OnPageScaleFactorChanged(float page_scale_factor) { |
+ FOR_EACH_OBSERVER(WebContentsObserver, |
+ observers_, |
+ OnPageScaleFactorChanged(page_scale_factor)); |
+} |
+ |
void WebContentsImpl::OnEnumerateDirectory(int request_id, |
const base::FilePath& path) { |
if (!delegate_) |