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

Unified Diff: views/screen_gtk.cc

Issue 328012: Makes it so that when a folder is open on the bookmark bar and the... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 2 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 | « views/screen.h ('k') | views/screen_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: views/screen_gtk.cc
===================================================================
--- views/screen_gtk.cc (revision 29776)
+++ views/screen_gtk.cc (working copy)
@@ -58,5 +58,19 @@
return gfx::Rect(bounds);
}
+gfx::NativeWindow Screen::GetWindowAtCursorScreenPoint() {
+ GdkWindow* window = gdk_window_at_pointer(NULL, NULL);
+ if (!window)
+ return NULL;
+
+ gpointer data = NULL;
+ gdk_window_get_user_data(window, &data);
+ GtkWidget* widget = reinterpret_cast<GtkWidget*>(data);
+ if (!widget)
+ return NULL;
+ widget = gtk_widget_get_toplevel(widget);
+ return GTK_IS_WINDOW(widget) ? GTK_WINDOW(widget) : NULL;
+}
+
} // namespace
« no previous file with comments | « views/screen.h ('k') | views/screen_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698