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

Unified Diff: pdf/instance.cc

Issue 569403004: Check whether a number is passed as an argument to kJSSetZoomLevel rather than a double. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pdf/instance.cc
diff --git a/pdf/instance.cc b/pdf/instance.cc
index d700be8757d679f00d98f86329a649308e64bfef..bb13fcc210eba34fdd4a03dde8fe5c9ff6b73ad0 100644
--- a/pdf/instance.cc
+++ b/pdf/instance.cc
@@ -1768,7 +1768,7 @@ pp::Var Instance::CallScriptableMethod(const pp::Var& method,
return pp::Var();
}
if (method_str == kJSSetZoomLevel) {
- if (args.size() == 1 && args[0].is_double())
+ if (args.size() == 1 && args[0].is_number())
SetZoom(ZOOM_SCALE, args[0].AsDouble());
return pp::Var();
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698