diff options
24 files changed, 0 insertions, 118 deletions
diff --git a/chrome/browser/renderer_host/render_widget_host_view_gtk.cc b/chrome/browser/renderer_host/render_widget_host_view_gtk.cc index 5098093..af80e4a 100644 --- a/chrome/browser/renderer_host/render_widget_host_view_gtk.cc +++ b/chrome/browser/renderer_host/render_widget_host_view_gtk.cc @@ -1114,14 +1114,6 @@ void RenderWidgetHostViewGtk::SetVisuallyDeemphasized( } } -bool RenderWidgetHostViewGtk::ContainsNativeView( - gfx::NativeView native_view) const { - // TODO(port) - NOTREACHED() << - "RenderWidgetHostViewGtk::ContainsNativeView not implemented."; - return false; -} - void RenderWidgetHostViewGtk::AcceleratedCompositingActivated(bool activated) { GtkPreserveWindow* widget = reinterpret_cast<GtkPreserveWindow*>(view_.get()); diff --git a/chrome/browser/renderer_host/render_widget_host_view_gtk.h b/chrome/browser/renderer_host/render_widget_host_view_gtk.h index b26fc52..e5a2b34 100644 --- a/chrome/browser/renderer_host/render_widget_host_view_gtk.h +++ b/chrome/browser/renderer_host/render_widget_host_view_gtk.h @@ -94,7 +94,6 @@ class RenderWidgetHostViewGtk : public RenderWidgetHostView, virtual void DestroyPluginContainer(gfx::PluginWindowHandle id) OVERRIDE; virtual void SetVisuallyDeemphasized(const SkColor* color, bool animate) OVERRIDE; - virtual bool ContainsNativeView(gfx::NativeView native_view) const OVERRIDE; virtual void AcceleratedCompositingActivated(bool activated) OVERRIDE; virtual gfx::PluginWindowHandle GetCompositingSurface() OVERRIDE; diff --git a/chrome/browser/renderer_host/render_widget_host_view_mac.h b/chrome/browser/renderer_host/render_widget_host_view_mac.h index 93862f8..47850a7 100644 --- a/chrome/browser/renderer_host/render_widget_host_view_mac.h +++ b/chrome/browser/renderer_host/render_widget_host_view_mac.h @@ -215,7 +215,6 @@ class RenderWidgetHostViewMac : public RenderWidgetHostView { virtual void SetWindowVisibility(bool visible) OVERRIDE; virtual void WindowFrameChanged() OVERRIDE; virtual void SetBackground(const SkBitmap& background) OVERRIDE; - virtual bool ContainsNativeView(gfx::NativeView native_view) const OVERRIDE; virtual void OnAccessibilityNotifications( const std::vector<ViewHostMsg_AccessibilityNotification_Params>& params diff --git a/chrome/browser/renderer_host/render_widget_host_view_mac.mm b/chrome/browser/renderer_host/render_widget_host_view_mac.mm index 7a3b55b..075c6d2 100644 --- a/chrome/browser/renderer_host/render_widget_host_view_mac.mm +++ b/chrome/browser/renderer_host/render_widget_host_view_mac.mm @@ -1017,14 +1017,6 @@ void RenderWidgetHostViewMac::SetBackground(const SkBitmap& background) { render_widget_host_->routing_id(), background)); } -bool RenderWidgetHostViewMac::ContainsNativeView( - gfx::NativeView native_view) const { - // TODO(port) - NOTREACHED() << - "RenderWidgetHostViewMac::ContainsNativeView not implemented."; - return false; -} - void RenderWidgetHostViewMac::OnAccessibilityNotifications( const std::vector<ViewHostMsg_AccessibilityNotification_Params>& params) { if (!browser_accessibility_manager_.get()) { diff --git a/chrome/browser/renderer_host/render_widget_host_view_views.cc b/chrome/browser/renderer_host/render_widget_host_view_views.cc index 76b46ea..d211089 100644 --- a/chrome/browser/renderer_host/render_widget_host_view_views.cc +++ b/chrome/browser/renderer_host/render_widget_host_view_views.cc @@ -330,14 +330,6 @@ void RenderWidgetHostViewViews::SetVisuallyDeemphasized( // TODO(anicolao) } -bool RenderWidgetHostViewViews::ContainsNativeView( - gfx::NativeView native_view) const { - // TODO(port) - NOTREACHED() << - "RenderWidgetHostViewViews::ContainsNativeView not implemented."; - return false; -} - std::string RenderWidgetHostViewViews::GetClassName() const { return kViewClassName; } diff --git a/chrome/browser/renderer_host/render_widget_host_view_views.h b/chrome/browser/renderer_host/render_widget_host_view_views.h index 86ea396..4d9df3a 100644 --- a/chrome/browser/renderer_host/render_widget_host_view_views.h +++ b/chrome/browser/renderer_host/render_widget_host_view_views.h @@ -88,7 +88,6 @@ class RenderWidgetHostViewViews : public RenderWidgetHostView, #endif virtual void SetVisuallyDeemphasized(const SkColor* color, bool animate) OVERRIDE; - virtual bool ContainsNativeView(gfx::NativeView native_view) const OVERRIDE; #if defined(TOOLKIT_USES_GTK) virtual void AcceleratedCompositingActivated(bool activated) OVERRIDE; #endif diff --git a/chrome/browser/renderer_host/render_widget_host_view_win.cc b/chrome/browser/renderer_host/render_widget_host_view_win.cc index f2c5e33..74e1277 100644 --- a/chrome/browser/renderer_host/render_widget_host_view_win.cc +++ b/chrome/browser/renderer_host/render_widget_host_view_win.cc @@ -743,23 +743,6 @@ void RenderWidgetHostViewWin::SetBackground(const SkBitmap& background) { background)); } -bool RenderWidgetHostViewWin::ContainsNativeView( - gfx::NativeView native_view) const { - if (m_hWnd == native_view) - return true; - - // Traverse the set of parents of the given view to determine if native_view - // is a descendant of this window. - HWND parent_window = ::GetParent(native_view); - while (parent_window) { - if (parent_window == m_hWnd) - return true; - parent_window = ::GetParent(parent_window); - } - - return false; -} - void RenderWidgetHostViewWin::SetVisuallyDeemphasized(const SkColor* color, bool animate) { // |animate| is not yet implemented, and currently isn't used. diff --git a/chrome/browser/renderer_host/render_widget_host_view_win.h b/chrome/browser/renderer_host/render_widget_host_view_win.h index d557f97..df8b45c 100644 --- a/chrome/browser/renderer_host/render_widget_host_view_win.h +++ b/chrome/browser/renderer_host/render_widget_host_view_win.h @@ -163,7 +163,6 @@ class RenderWidgetHostViewWin virtual void SetTooltipText(const std::wstring& tooltip_text) OVERRIDE; virtual BackingStore* AllocBackingStore(const gfx::Size& size) OVERRIDE; virtual void SetBackground(const SkBitmap& background) OVERRIDE; - virtual bool ContainsNativeView(gfx::NativeView native_view) const OVERRIDE; virtual void SetVisuallyDeemphasized(const SkColor* color, bool animate) OVERRIDE; virtual gfx::PluginWindowHandle GetCompositingSurface() OVERRIDE; diff --git a/content/browser/renderer_host/render_widget_host_view.h b/content/browser/renderer_host/render_widget_host_view.h index 41cb005..6b0cd7a 100644 --- a/content/browser/renderer_host/render_widget_host_view.h +++ b/content/browser/renderer_host/render_widget_host_view.h @@ -300,10 +300,6 @@ class RenderWidgetHostView { virtual void SetBackground(const SkBitmap& background); const SkBitmap& background() const { return background_; } - // Returns true if the native view, |native_view|, is contained within in the - // widget associated with this RenderWidgetHostView. - virtual bool ContainsNativeView(gfx::NativeView native_view) const = 0; - virtual void UpdateAccessibilityTree( const webkit_glue::WebAccessibility& tree) { } virtual void OnAccessibilityNotifications( diff --git a/content/browser/renderer_host/test_render_view_host.cc b/content/browser/renderer_host/test_render_view_host.cc index 00b29ac..ab228d9 100644 --- a/content/browser/renderer_host/test_render_view_host.cc +++ b/content/browser/renderer_host/test_render_view_host.cc @@ -254,11 +254,6 @@ gfx::PluginWindowHandle TestRenderWidgetHostView::GetCompositingSurface() { return gfx::kNullPluginWindow; } -bool TestRenderWidgetHostView::ContainsNativeView( - gfx::NativeView native_view) const { - return false; -} - TestRenderViewHostFactory::TestRenderViewHostFactory( RenderProcessHostFactory* rph_factory) : render_process_host_factory_(rph_factory) { diff --git a/content/browser/renderer_host/test_render_view_host.h b/content/browser/renderer_host/test_render_view_host.h index ada421f..224a0eb 100644 --- a/content/browser/renderer_host/test_render_view_host.h +++ b/content/browser/renderer_host/test_render_view_host.h @@ -151,8 +151,6 @@ class TestRenderWidgetHostView : public RenderWidgetHostView { virtual gfx::PluginWindowHandle GetCompositingSurface(); - virtual bool ContainsNativeView(gfx::NativeView native_view) const; - bool is_showing() const { return is_showing_; } private: diff --git a/views/controls/native/native_view_host.cc b/views/controls/native/native_view_host.cc index c9fd990..616ad69 100644 --- a/views/controls/native/native_view_host.cc +++ b/views/controls/native/native_view_host.cc @@ -180,19 +180,6 @@ void NativeViewHost::OnFocus() { this, ui::AccessibilityTypes::EVENT_FOCUS, true); } -bool NativeViewHost::ContainsNativeView(gfx::NativeView native_view) const { - if (native_view == native_view_) - return true; - if (!native_view_) - return false; - - views::Widget* widget = views::Widget::GetWidgetForNativeView(native_view); - if (widget && widget->ContainsNativeView(native_view)) - return true; - - return View::ContainsNativeView(native_view); -} - gfx::NativeViewAccessible NativeViewHost::GetNativeViewAccessible() { if (native_wrapper_.get()) { gfx::NativeViewAccessible accessible_view = diff --git a/views/controls/native/native_view_host.h b/views/controls/native/native_view_host.h index 30e4ddc..cb711cd 100644 --- a/views/controls/native/native_view_host.h +++ b/views/controls/native/native_view_host.h @@ -81,7 +81,6 @@ class NativeViewHost : public View { virtual void OnPaint(gfx::Canvas* canvas); virtual void VisibilityChanged(View* starting_from, bool is_visible); virtual void OnFocus(); - virtual bool ContainsNativeView(gfx::NativeView native_view) const; virtual gfx::NativeViewAccessible GetNativeViewAccessible(); protected: diff --git a/views/view.cc b/views/view.cc index 98ae12b..5f5b52c 100644 --- a/views/view.cc +++ b/views/view.cc @@ -245,15 +245,6 @@ int View::GetIndexOf(const View* view) const { return i != children_.end() ? static_cast<int>(i - children_.begin()) : -1; } -// TODO(beng): remove -bool View::ContainsNativeView(gfx::NativeView native_view) const { - for (int i = 0, count = child_count(); i < count; ++i) { - if (GetChildViewAt(i)->ContainsNativeView(native_view)) - return true; - } - return false; -} - // Size and disposition -------------------------------------------------------- void View::SetBounds(int x, int y, int width, int height) { diff --git a/views/view.h b/views/view.h index cb71d74..d94a086 100644 --- a/views/view.h +++ b/views/view.h @@ -155,11 +155,6 @@ class View : public AcceleratorTarget { // Returns the index of |view|, or -1 if |view| is not a child of this view. int GetIndexOf(const View* view) const; - // TODO(beng): REMOVE (TBD) - // Returns true if the native view |native_view| is contained in the view - // hierarchy beneath this view. - virtual bool ContainsNativeView(gfx::NativeView native_view) const; - // Size and disposition ------------------------------------------------------ // Methods for obtaining and modifying the position and size of the view. // Position is in the coordinate system of the view's parent. diff --git a/views/widget/native_widget_gtk.cc b/views/widget/native_widget_gtk.cc index 199160e..3e372f5 100644 --- a/views/widget/native_widget_gtk.cc +++ b/views/widget/native_widget_gtk.cc @@ -1231,12 +1231,6 @@ bool NativeWidgetGtk::IsAccessibleWidget() const { return false; } -bool NativeWidgetGtk::ContainsNativeView(gfx::NativeView native_view) const { - // TODO(port) See implementation in NativeWidgetWin::ContainsNativeView. - NOTREACHED() << "NativeWidgetGtk::ContainsNativeView is not implemented."; - return false; -} - void NativeWidgetGtk::RunShellDrag(View* view, const ui::OSExchangeData& data, int operation) { diff --git a/views/widget/native_widget_gtk.h b/views/widget/native_widget_gtk.h index b346e26..00e0bed 100644 --- a/views/widget/native_widget_gtk.h +++ b/views/widget/native_widget_gtk.h @@ -221,7 +221,6 @@ class NativeWidgetGtk : public internal::NativeWidgetPrivate, virtual void SetOpacity(unsigned char opacity) OVERRIDE; virtual void SetUseDragFrame(bool use_drag_frame) OVERRIDE; virtual bool IsAccessibleWidget() const OVERRIDE; - virtual bool ContainsNativeView(gfx::NativeView native_view) const OVERRIDE; virtual void RunShellDrag(View* view, const ui::OSExchangeData& data, int operation) OVERRIDE; diff --git a/views/widget/native_widget_private.h b/views/widget/native_widget_private.h index f9ba979..6bba0dd 100644 --- a/views/widget/native_widget_private.h +++ b/views/widget/native_widget_private.h @@ -199,7 +199,6 @@ class NativeWidgetPrivate : public NativeWidget { virtual void SetOpacity(unsigned char opacity) = 0; virtual void SetUseDragFrame(bool use_drag_frame) = 0; virtual bool IsAccessibleWidget() const = 0; - virtual bool ContainsNativeView(gfx::NativeView native_view) const = 0; virtual void RunShellDrag(View* view, const ui::OSExchangeData& data, int operation) = 0; diff --git a/views/widget/native_widget_views.cc b/views/widget/native_widget_views.cc index f92627e..c073b9d 100644 --- a/views/widget/native_widget_views.cc +++ b/views/widget/native_widget_views.cc @@ -375,11 +375,6 @@ bool NativeWidgetViews::IsAccessibleWidget() const { return false; } -bool NativeWidgetViews::ContainsNativeView(gfx::NativeView native_view) const { - NOTIMPLEMENTED(); - return GetParentNativeWidget()->ContainsNativeView(native_view); -} - void NativeWidgetViews::RunShellDrag(View* view, const ui::OSExchangeData& data, int operation) { diff --git a/views/widget/native_widget_views.h b/views/widget/native_widget_views.h index e3d3edc..79a6205 100644 --- a/views/widget/native_widget_views.h +++ b/views/widget/native_widget_views.h @@ -108,7 +108,6 @@ class NativeWidgetViews : public internal::NativeWidgetPrivate { virtual void SetOpacity(unsigned char opacity) OVERRIDE; virtual void SetUseDragFrame(bool use_drag_frame) OVERRIDE; virtual bool IsAccessibleWidget() const OVERRIDE; - virtual bool ContainsNativeView(gfx::NativeView native_view) const OVERRIDE; virtual void RunShellDrag(View* view, const ui::OSExchangeData& data, int operation) OVERRIDE; diff --git a/views/widget/native_widget_win.cc b/views/widget/native_widget_win.cc index 83e6126..56d12dc 100644 --- a/views/widget/native_widget_win.cc +++ b/views/widget/native_widget_win.cc @@ -1031,10 +1031,6 @@ bool NativeWidgetWin::IsAccessibleWidget() const { return screen_reader_active_; } -bool NativeWidgetWin::ContainsNativeView(gfx::NativeView native_view) const { - return hwnd() == native_view || ::IsChild(hwnd(), native_view); -} - void NativeWidgetWin::RunShellDrag(View* view, const ui::OSExchangeData& data, int operation) { diff --git a/views/widget/native_widget_win.h b/views/widget/native_widget_win.h index 53457dc..52dbb5c 100644 --- a/views/widget/native_widget_win.h +++ b/views/widget/native_widget_win.h @@ -259,7 +259,6 @@ class NativeWidgetWin : public ui::WindowImpl, virtual void SetOpacity(unsigned char opacity) OVERRIDE; virtual void SetUseDragFrame(bool use_drag_frame) OVERRIDE; virtual bool IsAccessibleWidget() const OVERRIDE; - virtual bool ContainsNativeView(gfx::NativeView native_view) const OVERRIDE; virtual void RunShellDrag(View* view, const ui::OSExchangeData& data, int operation) OVERRIDE; diff --git a/views/widget/widget.cc b/views/widget/widget.cc index e668042..a3f5c02 100644 --- a/views/widget/widget.cc +++ b/views/widget/widget.cc @@ -537,16 +537,6 @@ InputMethod* Widget::GetInputMethod() { toplevel_widget->native_widget_->GetInputMethodNative() : NULL; } -bool Widget::ContainsNativeView(gfx::NativeView native_view) { - if (native_widget_->ContainsNativeView(native_view)) - return true; - - // A views::NativeViewHost may contain the given native view, without it being - // an ancestor of hwnd(), so traverse the views::View hierarchy looking for - // such views. - return GetRootView()->ContainsNativeView(native_view); -} - void Widget::RunShellDrag(View* view, const ui::OSExchangeData& data, int operation) { dragged_view_ = view; diff --git a/views/widget/widget.h b/views/widget/widget.h index 3021518..bc16530 100644 --- a/views/widget/widget.h +++ b/views/widget/widget.h @@ -369,11 +369,6 @@ class Widget : public internal::NativeWidgetDelegate, // Note that all widgets in a widget hierarchy share the same input method. InputMethod* GetInputMethod(); - // Returns true if the native view |native_view| is contained in the - // views::View hierarchy rooted at this widget. - // TODO(beng): const. - bool ContainsNativeView(gfx::NativeView native_view); - // Starts a drag operation for the specified view. This blocks until the drag // operation completes. |view| can be NULL. // If the view is non-NULL it can be accessed during the drag by calling |