From f290b766707b386d72e2eaadd35cc3d999405077 Mon Sep 17 00:00:00 2001 From: Augustin Cavalier Date: Thu, 20 Apr 2017 15:46:33 -0400 Subject: [PATCH] People: Enclose PeopleView in a BScrollView. People uses a customizeable set of attributes, and on my install that has a lot of old BeOS applications, the window is too tall for the screen. So now it will be possible to scroll it. Depends on the prior change to BScrollView to auto-update scrollbar limits when the window size changes, as otherwise you will not be able to scroll properly. As you can see by the date, I've had this patch sitting around for almost 2 years now, waiting for BScrollView layouted behavior to be fixed... Change-Id: Iee7a691771d3b17efb2f6aba8c5011986ad0e36b Reviewed-on: https://review.haiku-os.org/c/894 Reviewed-by: waddlesplash --- src/apps/people/PersonWindow.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/apps/people/PersonWindow.cpp b/src/apps/people/PersonWindow.cpp index 3a99669e4d..3abcb6d993 100644 --- a/src/apps/people/PersonWindow.cpp +++ b/src/apps/people/PersonWindow.cpp @@ -29,6 +29,7 @@ #include #include #include +#include #include #include #include @@ -107,9 +108,14 @@ PersonWindow::PersonWindow(BRect frame, const char* title, fView = new PersonView("PeopleView", categoryAttribute, fRef); + BScrollView* scrollView = new BScrollView("PeopleScrollView", fView, 0, + false, true, B_NO_BORDER); + scrollView->SetExplicitMinSize(BSize(scrollView->MinSize().width, 0)); + BLayoutBuilder::Group<>(this, B_VERTICAL, 0) + .SetInsets(0, 0, -1, 0) .Add(menuBar) - .Add(fView); + .Add(scrollView); fRevert->SetTarget(fView); selectAllItem->SetTarget(fView);