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

Unified Diff: third_party/google_input_tools/src/chrome/os/floatingwindow/floatingwindow.js

Issue 1576613002: Update Google Input Tools. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add missing APIs, remove bade dependencies. Created 4 years, 11 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: third_party/google_input_tools/src/chrome/os/floatingwindow/floatingwindow.js
diff --git a/third_party/google_input_tools/src/chrome/os/floatingwindow/floatingwindow.js b/third_party/google_input_tools/src/chrome/os/floatingwindow/floatingwindow.js
index 8881658abf2de0b18192bf85de3b92999ba4bd52..b473cb17d174cdae8767107fa9fbd8666a9c304c 100644
--- a/third_party/google_input_tools/src/chrome/os/floatingwindow/floatingwindow.js
+++ b/third_party/google_input_tools/src/chrome/os/floatingwindow/floatingwindow.js
@@ -15,6 +15,7 @@ goog.provide('i18n.input.chrome.FloatingWindow');
goog.require('goog.dom.DomHelper');
goog.require('goog.dom.TagName');
+goog.require('goog.math.Coordinate');
goog.require('goog.style');
goog.require('goog.ui.Container');
goog.require('i18n.input.chrome.Env');
@@ -128,6 +129,17 @@ FloatingWindow.prototype.reposition = function(position) {
/**
+ * Gets the position of the floating window.
+ *
+ * @return {!goog.math.Coordinate} The top teft coordinate of the screen.
+ */
+FloatingWindow.prototype.getPosition = function() {
+ var outerBounds = this.parentWindow.outerBounds;
+ return new goog.math.Coordinate(outerBounds.left, outerBounds.top);
+};
+
+
+/**
* Changes the size of the floating window.
*
* @param {number} width The width of the new window.

Powered by Google App Engine
This is Rietveld 408576698