summaryrefslogtreecommitdiffstats
path: root/views/widget/widget_gtk.h
diff options
context:
space:
mode:
Diffstat (limited to 'views/widget/widget_gtk.h')
-rw-r--r--views/widget/widget_gtk.h14
1 files changed, 10 insertions, 4 deletions
diff --git a/views/widget/widget_gtk.h b/views/widget/widget_gtk.h
index 91b8024..8c0cacd 100644
--- a/views/widget/widget_gtk.h
+++ b/views/widget/widget_gtk.h
@@ -40,7 +40,7 @@ class NativeWidgetDelegate;
// Widget implementation for GTK.
class WidgetGtk : public Widget,
- public NativeWidget,
+ public internal::NativeWidget,
public ui::ActiveWindowWatcherX::Observer {
public:
// Type of widget.
@@ -137,10 +137,16 @@ class WidgetGtk : public Widget,
// gets created. This will not be called on a TYPE_CHILD widget.
virtual void SetInitialFocus() {}
+ // Gets the WidgetGtk in the userdata section of the widget.
+ static WidgetGtk* GetViewForNative(GtkWidget* widget);
+
// Sets the drop target to NULL. This is invoked by DropTargetGTK when the
// drop is done.
void ResetDropTarget();
+ // Returns the RootView for |widget|.
+ static RootView* GetRootViewForWidget(GtkWidget* widget);
+
// Gets the requested size of the widget. This can be the size
// stored in properties for a GtkViewsFixed, or in the requisitioned
// size of other kinds of widgets.
@@ -163,6 +169,7 @@ class WidgetGtk : public Widget,
virtual gfx::NativeView GetNativeView() const;
virtual void SetOpacity(unsigned char opacity);
virtual void SetAlwaysOnTop(bool on_top);
+ virtual Widget* GetRootWidget() const;
virtual bool IsVisible() const;
virtual bool IsActive() const;
virtual bool IsAccessibleWidget() const;
@@ -200,9 +207,6 @@ class WidgetGtk : public Widget,
static void EnableDebugPaint();
protected:
- // Overridden from NativeWidget:
- virtual Widget* GetWidget();
-
// If widget contains another widget, translates event coordinates to the
// contained widget's coordinates, else returns original event coordinates.
template<class Event> bool GetContainedWidgetEventCoordinates(Event* event,
@@ -302,6 +306,8 @@ class WidgetGtk : public Widget,
// Process scroll event.
bool ProcessScroll(GdkEventScroll* event);
+ static void SetRootViewForWidget(GtkWidget* widget, RootView* root_view);
+
// Returns the first ancestor of |widget| that is a window.
static Window* GetWindowImpl(GtkWidget* widget);