[haiku-development] Re: BMenuBar scrolling support

From: Axel Dörfler <axeld@xxxxxxxxxxxxxxxx>

To: haiku-development@xxxxxxxxxxxxx

Date: Wed, 28 Dec 2011 10:02:55 +0100

On 27.12.2011 23:01, John Scipione wrote:

I would like to implement the functionality I introduced in my
BScrollMenu class directly into BMenu next. Ultimately this means
BMenuWindow will go away and be replaced by a regular BWindow since the
scrolling functionality will live in BMenu instead.

I'm not sure this is a good idea. I think the approach should be similar
to a BScrollView instead, possibly even by using a BScrollView (which
should be able to only show its scroll bars on demand, anyway). While
BMenu could provide this functionality for convenience, that's not
easily possible with the current API.
The scroll buttons used by BMenu should become a thing of the past; they
aren't really usable for larger menus.

as well as two new public methods:
EnableScrolling(bool enable)
ScrollingEnabled()

As a general naming scheme, this should be:
SetScrollingEnabled(bool enable)
IsScrollingEnabled() const
Bye,
Axel.