Skip to content

Commit

Permalink
Bug 1737044 - Include pointer and frame in nsWindow logging. r=stransky
Browse files Browse the repository at this point in the history
  • Loading branch information
emilio committed Oct 21, 2021
1 parent 032ef88 commit c818031
Show file tree
Hide file tree
Showing 7 changed files with 119 additions and 110 deletions.
9 changes: 5 additions & 4 deletions view/nsView.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -148,13 +148,14 @@ void nsView::DestroyWidget() {
}
}

nsView* nsView::GetViewFor(nsIWidget* aWidget) {
MOZ_ASSERT(nullptr != aWidget, "null widget ptr");
nsView* nsView::GetViewFor(const nsIWidget* aWidget) {
MOZ_ASSERT(aWidget, "null widget ptr");

nsIWidgetListener* listener = aWidget->GetWidgetListener();
if (listener) {
nsView* view = listener->GetView();
if (view) return view;
if (nsView* view = listener->GetView()) {
return view;
}
}

listener = aWidget->GetAttachedWidgetListener();
Expand Down
2 changes: 1 addition & 1 deletion view/nsView.h
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ class nsView final : public nsIWidgetListener {
* @return the view the widget belongs to, or null if the widget doesn't
* belong to any view.
*/
static nsView* GetViewFor(nsIWidget* aWidget);
static nsView* GetViewFor(const nsIWidget* aWidget);

/**
* Destroy the view.
Expand Down
Loading

0 comments on commit c818031

Please sign in to comment.