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

Side by Side Diff: content/browser/web_contents/web_contents_view_gtk.h

Issue 12252016: Prevented connecting drag drop events to a SwappedOut RenderViewHost in WebContentsViewGtk (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Oops. Fix compile error. Created 7 years, 9 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 unified diff | Download patch
« no previous file with comments | « no previous file | content/browser/web_contents/web_contents_view_gtk.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #ifndef CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_VIEW_GTK_H_ 5 #ifndef CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_VIEW_GTK_H_
6 #define CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_VIEW_GTK_H_ 6 #define CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_VIEW_GTK_H_
7 7
8 #include <gtk/gtk.h> 8 #include <gtk/gtk.h>
9 9
10 #include <vector> 10 #include <vector>
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
90 virtual void GotFocus() OVERRIDE; 90 virtual void GotFocus() OVERRIDE;
91 virtual void TakeFocus(bool reverse) OVERRIDE; 91 virtual void TakeFocus(bool reverse) OVERRIDE;
92 92
93 private: 93 private:
94 // Insert the given widget into the content area. Should only be used for 94 // Insert the given widget into the content area. Should only be used for
95 // web pages and the like (including interstitials and sad tab). Note that 95 // web pages and the like (including interstitials and sad tab). Note that
96 // this will be perfectly happy to insert overlapping render views, so care 96 // this will be perfectly happy to insert overlapping render views, so care
97 // should be taken that the correct one is hidden/shown. 97 // should be taken that the correct one is hidden/shown.
98 void InsertIntoContentArea(GtkWidget* widget); 98 void InsertIntoContentArea(GtkWidget* widget);
99 99
100 // Replaces, or updates, the existing WebDragDestGtk with one for |new_host|.
101 // This must be called when swapping in, or creating a swapped in, RVH.
102 void UpdateDragDest(RenderViewHost* new_host);
103
100 // Handle focus traversal on the render widget native view. Can be overridden 104 // Handle focus traversal on the render widget native view. Can be overridden
101 // by subclasses. 105 // by subclasses.
102 CHROMEGTK_CALLBACK_1(WebContentsViewGtk, gboolean, OnFocus, GtkDirectionType); 106 CHROMEGTK_CALLBACK_1(WebContentsViewGtk, gboolean, OnFocus, GtkDirectionType);
103 107
104 // Used to adjust the size of its children when the size of |expanded_| is 108 // Used to adjust the size of its children when the size of |expanded_| is
105 // changed. 109 // changed.
106 CHROMEGTK_CALLBACK_2(WebContentsViewGtk, void, OnChildSizeRequest, 110 CHROMEGTK_CALLBACK_2(WebContentsViewGtk, void, OnChildSizeRequest,
107 GtkWidget*, GtkRequisition*); 111 GtkWidget*, GtkRequisition*);
108 112
109 // Used to propagate the size change of |expanded_| to our RWHV to resize the 113 // Used to propagate the size change of |expanded_| to our RWHV to resize the
(...skipping 25 matching lines...) Expand all
135 // The size we want the view to be. We keep this in a separate variable 139 // The size we want the view to be. We keep this in a separate variable
136 // because resizing in GTK+ is async. 140 // because resizing in GTK+ is async.
137 gfx::Size requested_size_; 141 gfx::Size requested_size_;
138 142
139 DISALLOW_COPY_AND_ASSIGN(WebContentsViewGtk); 143 DISALLOW_COPY_AND_ASSIGN(WebContentsViewGtk);
140 }; 144 };
141 145
142 } // namespace content 146 } // namespace content
143 147
144 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_VIEW_GTK_H_ 148 #endif // CONTENT_BROWSER_WEB_CONTENTS_WEB_CONTENTS_VIEW_GTK_H_
OLDNEW
« no previous file with comments | « no previous file | content/browser/web_contents/web_contents_view_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698