| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/ui/gtk/gtk_util.h" | 5 #include "chrome/browser/ui/gtk/gtk_util.h" |
| 6 | 6 |
| 7 #include <cairo/cairo.h> | 7 #include <cairo/cairo.h> |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 #include <cstdarg> | 10 #include <cstdarg> |
| (...skipping 267 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 278 event); | 278 event); |
| 279 } | 279 } |
| 280 g_list_free(children); | 280 g_list_free(children); |
| 281 | 281 |
| 282 return TRUE; | 282 return TRUE; |
| 283 } | 283 } |
| 284 | 284 |
| 285 WebContents* GetBrowserWindowSelectedWebContents(BrowserWindow* window) { | 285 WebContents* GetBrowserWindowSelectedWebContents(BrowserWindow* window) { |
| 286 BrowserWindowGtk* browser_window = static_cast<BrowserWindowGtk*>( | 286 BrowserWindowGtk* browser_window = static_cast<BrowserWindowGtk*>( |
| 287 window); | 287 window); |
| 288 return browser_window->browser()->GetSelectedWebContents(); | 288 return browser_window->browser()->GetActiveWebContents(); |
| 289 } | 289 } |
| 290 | 290 |
| 291 GtkWidget* GetBrowserWindowFocusedWidget(BrowserWindow* window) { | 291 GtkWidget* GetBrowserWindowFocusedWidget(BrowserWindow* window) { |
| 292 return gtk_window_get_focus(window->GetNativeWindow()); | 292 return gtk_window_get_focus(window->GetNativeWindow()); |
| 293 } | 293 } |
| 294 | 294 |
| 295 } // namespace | 295 } // namespace |
| 296 | 296 |
| 297 namespace event_utils { | 297 namespace event_utils { |
| 298 | 298 |
| (...skipping 871 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1170 | 1170 |
| 1171 void DoCopy(BrowserWindow* window) { | 1171 void DoCopy(BrowserWindow* window) { |
| 1172 DoCutCopyPaste(window, &RenderWidgetHost::Copy, "copy-clipboard"); | 1172 DoCutCopyPaste(window, &RenderWidgetHost::Copy, "copy-clipboard"); |
| 1173 } | 1173 } |
| 1174 | 1174 |
| 1175 void DoPaste(BrowserWindow* window) { | 1175 void DoPaste(BrowserWindow* window) { |
| 1176 DoCutCopyPaste(window, &RenderWidgetHost::Paste, "paste-clipboard"); | 1176 DoCutCopyPaste(window, &RenderWidgetHost::Paste, "paste-clipboard"); |
| 1177 } | 1177 } |
| 1178 | 1178 |
| 1179 } // namespace gtk_util | 1179 } // namespace gtk_util |
| OLD | NEW |