Index: content/renderer/disambiguation_popup_helper.h |
diff --git a/content/renderer/disambiguation_popup_helper.h b/content/renderer/disambiguation_popup_helper.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..84eb1b5a6eafacf5ac8c8aec030f9795ad7ef5b5 |
--- /dev/null |
+++ b/content/renderer/disambiguation_popup_helper.h |
@@ -0,0 +1,29 @@ |
+// Copyright (c) 2012 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#ifndef CONTENT_RENDERER_DISAMBIGUATION_POPUP_HELPER_H_ |
+#define CONTENT_RENDERER_DISAMBIGUATION_POPUP_HELPER_H_ |
+ |
+#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebVector.h" |
+ |
+namespace gfx { |
+class Rect; |
+class Size; |
+} |
+ |
+namespace WebKit { |
+class WebRect; |
+} |
+ |
+// Contains functions to calculate proper scaling factor and popup size |
+class DisambiguationPopupHelper { |
darin (slow to review)
2012/10/08 21:03:46
nit: this should be in the content namespace
trchen
2012/10/11 23:54:05
Done.
|
+public: |
darin (slow to review)
2012/10/08 21:03:46
nit: indent by 1 space
trchen
2012/10/11 23:54:05
Done.
|
+ static float ComputeZoomAreaAndScaleFactor( |
+ const gfx::Rect& tap_rect, |
+ const WebKit::WebVector<WebKit::WebRect>& target_rects, |
+ const gfx::Size& viewport_size, |
+ gfx::Rect* zoom_rect); |
+}; |
+ |
+#endif // CONTENT_RENDERER_DISAMBIGUATION_POPUP_HELPER_H_ |