History log of /haiku/src/apps/deskbar/BarView.h
Revision Date Author Comments
# f9b3a3b1 12-Aug-2020 John Scipione <jscipione@gmail.com>

Deskbar: Restore old mini-mode

... with the replicant tray below the menu bar.

Deskbar now has four modes:
1. vertical mini-mode (old mini-mode)
2. horizontal mini-mode (new mini-mode, was vertical)
3. vertical expando-mode (default)
4. horizonal expando-mode

Horizontal mini-mode gets the corner, then it switches to vertical
mini-mode above or below that, then to vertical expando-mode after
that. Horizontal expando mode is in center-screen top and bottom.

Clock vertical centering simplification.

Change-Id: I216008c20feb28f793693046792bbcfdf1e703e3
Reviewed-on: https://review.haiku-os.org/c/haiku/+/3146
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# 0d2645e4 19-Nov-2019 John Scipione <jscipione@gmail.com>

Deskbar: New single line mini-mode

Mini-mode is when Deskbar is in the 4 corners with the application
menu tucked away into the leaf menu bar. This commit changes mini-
mode from putting the clock and replicants below the leaf menu to
attaching them to the side forming a single line.

The main advantage of this is that if Deskbar is in the top right
corner you can maximize a window without losing any access to
Deskbar or any screen real-estate. The other three corners lose screen
real-estate similar to horizontal mode.

Replace team icon with HVIF version kindly donated by meanwhile.
Scale icon size according to font size. Grow the vector rendered icon
size by 1px to match bitmap size. Add Team_Registrar icon to
data/artwork/icons. Tweak Team_Registrar icon to match the area of the
bitmap taken up by the bitmap icon so they will render at the same size.
The bitmap can be now NULL if an invalid icon is passed, handle this
case with an fInitStatus member in BarMenuTitle.

Switch order of leaf and team menus on the left side so that the
team menu is always on the screen edge. The team menu is more in
need of quick corner access than the leaf menu in this mode.

Adjust leaf menu position so that it continues to be cut-off while
allowing the team menu icon to display normally. Center vertically in
horizontal mode but it's still cut-off at 16x16. In vertical mode the
leaf continues to be cut-off at all font sizes. Constrain leaf bitmap
to its menu item frame as it can bleed out into the adjacent team menu
item at larger font sizes.

Grow team menu items to fit the widest label up to the max vertical
expando window width (currently 2x min) before truncating.
LegacyPackageInstaller now fits in the team menu. More on
LegacyPackageInstaller in horizontal mode below.

Update SetSizeLimits for mini-mode - no upper limit on height or width.

Switch to mini-mode using 1/4 screen left and right of screen instead
of using 1/6. Mini mode is now wider and this change makes switching
between mini mode and horizontal mode more reliable.
* Rename frame to screenFrame here for clarity.

Set menu bar height to window tab height in vertical mode. This is
so that when you maximize a window the tab size will match. The menu
bar height is also a few pixels taller (25px vs 21px) than it was in
vertical expando mode at the default 12px font size. The change was
made to match the tab height. 21px was the height of a window tab
on BeOS R5's default decorator.

Adjust the width of the team menu for larger icon sizes. If app
names are hidden limit to half of min width so the menu doesn't
appear too short. SetMaxContentSize to width, this fixes a bug where
the menu item wasn't quite the right size for the menu.

No longer truncate time in vertical mini mode because the time can now
expand itself horizontally without limit (within reason.)

Center replicants vertically in mini-mode based on tab height and max
replicant height. Simplify mini-mode menu width and position calculation.
Fix a bar menu bar placement bug when Deskbar starts hidden in mini-mode.

Fix numerous layout issues. Put replicant tray where it should be in all
modes and then start adjusting things. The Replicant tray is now where
it should be in all modes, any fiddling with replicant icon locations
now can be relegated solely to LocationForReplicant().

Implements bug #5876 step 1.

*** Other related Deskbar improvements also made in this commit ***

Implemented underflow in horizontal mode ExpandoMenuBar to make items
wider when you close a team to take up more of available space. Max item
width is currently set to 1.25x min width so that LegacyPackageInstaller
fits in horizontal mode as well. In team menu it make sense to calculate
the widest label but in horizontal mode it would not be very nice if
ARogueAppWithAVeryVeryLongAndAnnoyingName were to grow all of your team
menu items. 1.25x is a fair compromise that gets us some extra width but
not too much. ExpandoMenuBar will truncate items to minimum width to buy
some space before it turns on the scroll arrows. Eliminate
kMinMenuItemWidth, create convinience methods to calculate limits.

Add BarView pointer to TimeView. Ditch fVertical and SetOrientation
in TTimeView and get the information from BarView instead. This way
we don't have to keep the state in sync. Also pass BarView pointer to
TTeamMenu constructor and use it instead of getting the pointer in a
roundabout way from be_app.

Eliminate kMiniHeight constant, the mini-mode height is now based
on the height of a window tab which changes with be_bold_font size.
Limit maximum height of replicants by be_bold_font size as well.
Also limit team menu and leaf menu icon heights by be_bold_font size.

Eliminate TExpandoMenuBar::fVertical, use fBarView instead. Switch the
order of layout and barView in ctor so that barView can be optional.
Change the ctor vertical param to layout and use the passed-in menu_layout
to pass to BMenuBar only. Once TExpandoMenuBar has been constructed, use
fBarView from then on. In Deskbar the menu_layout can change via
BMenuPrivate::SetLayout, if we needed to know TExpandoMenuBar's menu_layout
for some reason, we can call Layout().

Maintain 2px border around replicants in vertical expando mode on all
sides. Maintain 2px border around replicants in horizontal mode, except for
at 16x16 reduce the border to 1px because we're really short on height.
Improve clock centering in vertical expando mode. Also improve clock
centering in mini-mode across all font sizes. Reduce clock height by 2px
so that it won't draw over the top and bottom borders in horizontal mode.

Refactor TBarView::PlaceTray(). The code is basically the same but the
method is now better layed out. Calculate resize dragger location based
on width setting. This is valid since it is only ever used in vertical
expando mode. Hide the resize control better by moving it off-screen
when not in use. Hide() alone was not enough.

Fix size and position of the drag region to prevent minor drawing glitches
that were occuring in horizontal and left vertical mode because the drag
region was not in quite the right size and place.

Call DrawDragger() from DrawAfterChildren() instead of Draw() (and set
B_DRAW_ON_CHILDREN flag) so that the dragger will always be drawn even if
there are other items on top. In theory this should not be needed but in
practice this fixes a few drawing glitches. Rename DrawDragRegion() to
private DrawDragger() method - the name was confusing and other classes
shouldn't be allowed to draw the dragger directly.

TDragRegion should be renamed to TStatusView since that's what it really is.
Then we should create a new TDragControl class based on TResizeControl that
is a child of TStatusView like everybody else. TDragControl would be
responsible for drawing itself and knowing where its bounds are. For now
DrawAfterChildren() will have to do.

Rework status tray border drawing. It is identical in vertical exando mode
and in the same spirit in horizontal mode just a little bit nicer looking.
Draw hilight on top, left, and bottom edges in horizontal mode. Draw hilight
on top, and left edges in mini-mode this creates the appearance of a shadow.
Best appreciated using Magnify.

May the following (Open Tracker License) code forever be memorialized in
this commit message:

void
TDragRegion::Draw(BRect updateRect)
{
rgb_color menuColor = ViewColor();
rgb_color hilite = tint_color(menuColor, B_DARKEN_1_TINT);
rgb_color ldark = tint_color(menuColor, 1.02);
rgb_color dark = tint_color(menuColor, B_DARKEN_2_TINT);
rgb_color vvdark = tint_color(menuColor, B_DARKEN_4_TINT);
rgb_color light = tint_color(menuColor, B_LIGHTEN_2_TINT);

BRect frame(Bounds());
BeginLineArray(4);

if (be_control_look != NULL) {
if (fBarView->Vertical()) {
AddLine(frame.LeftTop(), frame.RightTop(), dark);
AddLine(BPoint(frame.left, frame.top + 1),
BPoint(frame.right, frame.top + 1), ldark);
AddLine(frame.LeftBottom(), frame.RightBottom(), hilite);
} else if (fBarView->AcrossTop() || fBarView->AcrossBottom()) {
AddLine(frame.LeftTop(),
BPoint(frame.left, frame.bottom), dark);
AddLine(BPoint(frame.left + 1, frame.top + 1),
BPoint(frame.right - 1, frame.top + 1), light);
AddLine(BPoint(frame.right, frame.top + 2),
BPoint(frame.right, frame.bottom), hilite);
AddLine(BPoint(frame.left + 1, frame.bottom),
BPoint(frame.right - 1, frame.bottom), hilite);
}
} else {
if (fBarView->Vertical()) {
AddLine(frame.LeftTop(), frame.RightTop(), light);
AddLine(frame.LeftTop(), frame.LeftBottom(), light);
AddLine(frame.RightBottom(), frame.RightTop(), hilite);
} else if (fBarView->AcrossTop()) {
AddLine(BPoint(frame.left, frame.top + 1),
BPoint(frame.right - 1, frame.top + 1), light);
AddLine(frame.RightTop(), frame.RightBottom(), vvdark);
AddLine(BPoint(frame.right - 1, frame.top + 2),
BPoint(frame.right - 1, frame.bottom - 1), hilite);
AddLine(frame.LeftBottom(),
BPoint(frame.right - 1, frame.bottom), hilite);
} else if (fBarView->AcrossBottom()) {
AddLine(BPoint(frame.left, frame.top + 1), BPoint(frame.right - 1, frame.top + 1), light);
AddLine(frame.LeftBottom(), frame.RightBottom(), hilite);
AddLine(frame.RightTop(), frame.RightBottom(), vvdark);
AddLine(BPoint(frame.right - 1, frame.top + 1),
BPoint(frame.right - 1, frame.bottom - 1), hilite);
}
}

EndLineArray();
}

Refactor mode switching.

Change TDragRegion::SwitchModeForRect() to SwitchModeForRegion() and pass
in BRegion's instead of BRect's. Create a new CalculateRegions() method
which is called once at startup and again on ScreenChanged() instead of
calculating the rect's over and over again inside MouseMoved(). Simplify
calculations using BRegion's.

Get the screen_where parameter from the Window()'s CurrentMessage() instead
of converting the passed in where parameter to screen coordinates. This
makes mode switching work 100% better.

Restore full state, fix all issues, and disable it again.

Fix issue with the window not resizing itself correctly when hiding the
scroller arrows in vertical expando mode because Deskbar was using the
bottom value of a scrolled view rather than its height. We only need to
call CheckForScrolling() once before we resize the window. Consolidate all
the window resizing code into ExpandoMenuBar::SizeWindow(), call
CheckForScrolling() there one time, then resize the window and lay
everything out again.

Simplify expando menu bar background drawing. The only part of this
drawing code that was actually being shown was the part where it stroked a
vertical line like this:

rgb_color menuColor = ui_color(B_MENU_BACKGROUND_COLOR);
SetHighColor(tint_color(menuColor, 1.22));
StrokeLine(bounds.LeftTop(), bounds.LeftBottom());

The rest of the code was never seen. May the following code also be forever
memorialized in this commit message:

void
TExpandoMenuBar::DrawBackground(BRect updateRect)
{
if (Vertical())
return;

BRect bounds(Bounds());
rgb_color menuColor = ui_color(B_MENU_BACKGROUND_COLOR);
rgb_color hilite = tint_color(menuColor, B_DARKEN_1_TINT);
rgb_color vlight = tint_color(menuColor, B_LIGHTEN_2_TINT);

int32 count = CountItems() - 1;
if (count >= 0)
bounds.left = ItemAt(count)->Frame().right + 1;
else
bounds.left = 0;

if (be_control_look != NULL) {
SetHighColor(tint_color(menuColor, 1.22));
StrokeLine(bounds.LeftTop(), bounds.LeftBottom());
bounds.left++;
uint32 borders = BControlLook::B_TOP_BORDER
| BControlLook::B_BOTTOM_BORDER | BControlLook::B_RIGHT_BORDER;

be_control_look->DrawButtonBackground(this, bounds, bounds, menuColor,
0, borders);
} else {
SetHighColor(vlight);
StrokeLine(bounds.LeftTop(), bounds.RightTop());
StrokeLine(BPoint(bounds.left, bounds.top + 1), bounds.LeftBottom());
SetHighColor(hilite);
StrokeLine(BPoint(bounds.left + 1, bounds.bottom),
bounds.RightBottom());
}
}

Change-Id: Id9ddd60c997a785184208ba02938bee1416aeae9
Reviewed-on: https://review.haiku-os.org/c/haiku/+/2253
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>


# 74ceffa8 25-Feb-2020 John Scipione <jscipione@gmail.com>

Deskbar: Reimplement auto-raise/implement auto-lower

This changes auto-raise so that when the mouse moves over the screen edge
within the Deskbar window it raises Deskbar up and when the mouse leaves
the Deskbar window it lowers it back down again as described in #13304.

Activate Deskbar on click only if not in auto-raise mode and not in
always-on-top mode. In auto-raise mode click activates through foreground
windows, which we don't want. We don't ever want to activate Deskbar in
always-on-top mode because Deskbar is already on top and we don't want to
change the active window.

However, if a menu is opened on click in auto-raise Deskbar is raised and
stays on top as long as a menu remains open. Once menu is closed Deskbar
lowers back down again. Only lower Deskbar on menu close in auto-raise mode
if there isn't another menu open.

Don't raise/lower Deskbar if window has been dragged from the outside in
auto-raise mode.

Change bool fShowingMenu to int32 fMenusShown and use it to store a
reference count of open menus. In the previous design menus could be
opened from multiple locations clobbering the bool.

Add an fBarWindow member to BarView and initialize it in AttachedToWindow()
Use this throughout the class so that we don't have to keep getting it over
and over again. Also add an fBarApp member to BarWindow and use that
instead of creating it again and again.

Change order of methods in BarView to MouseDown(), MouseMoved(), then
MouseUp() because that order is both logical and alphabetical.

Fixes #15678, #13304

Change-Id: I076a452b26250d9eb9a4eccb4a6aa6f939e11d34
Reviewed-on: https://review.haiku-os.org/c/haiku/+/2281
Reviewed-by: Sergei Reznikov <diver@gelios.net>
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
Reviewed-by: humdinger <humdingerb@gmail.com>


# 15eb397e 19-Jul-2018 John Scipione <jscipione@gmail.com>

Deskbar: Adjust team menu items with font size.

The Deskbar team menu should look the same at 12pt but much better
at larger (and smaller) font sizes.

Determine team menu item height in TBarView instead of
TTeamMenuItem::GetContentSize() because it is needed earlier in the
process, and also call method in GetContentSize().

The clock is centered horizontally in the first replicant row and the
width can grow to push the replicant icons better at larger font sizes.

The replicant tray and clock go to the bottom in horizontal bottom mode
and go to the top in horizontal top mode for Fitt's Law convinience and
go in the center of the first row in vertical mode.

Grow horizontal team item widths with font size, and shrink them
down to 1/2 of full width to fit more, or 1/2 padding for icon-only.

In horizontal mode the menu item size increases so that you can fit
approximate the same amount of label text based on icon and font size.
hit the width limit the items shrink and the label gets truncated
(like before.)

Scale team menu with font size. Reduce to half width for hide labels.

Change-Id: I93ecc8acded274b994728e7247768455862e31c5
Reviewed-on: https://review.haiku-os.org/c/haiku/+/345
Reviewed-by: waddlesplash <waddlesplash@gmail.com>


# efafab64 02-Nov-2018 Axel Dörfler <axeld@pinc-software.de>

Deskbar: Resizable tray

* Adds max width and height arguments to
instantiate_deskbar_(item|entry).
* Old applications just stay with a 16x16 scaled icon, though.
* All used apps within the repository are converted to the new call
besides the input_server input method icon (that will need further
API changes in the input_server).

Change-Id: I29cc439396917be2c24135888459d31364997dff
Reviewed-on: https://review.haiku-os.org/656
Reviewed-by: waddlesplash <waddlesplash@gmail.com>


# 1bb2e623 01-Mar-2013 John Scipione <jscipione@gmail.com>

Deskbar: variable width Deskbar in vertical mode

Feature to make Deskbar width variable via a dragger.

Resize Deskbar by clicking and dragging the mouse on the
horizontal side of Deskbar opposite the screen's edge.
(left side for default top right).

The resize dragger is hidden in horizontal mode.

Details below:
* ExpandoMenuBar is resized with rest of window.
* Rename where to whereScreen to make it clear that the variable
is in screen coordinates.
* Lock focus on window while resizing
* Resize via TResizeControl class which is based on TDragRegion
* Set default width to minimum so everything stays the same.
- don't set the width setting to 0 on quit, use the new setting.
* Set max tray width based on setting
* Make clock area a bit wider preventing replicant icons from
overrunning the clock area.
* Leave more room left of clock makes replicants wrap earlier,
leaving icon gap width between replicants and clock. Before it
would butt flush against the clock before moving down a row.
* Remove FrameMoved from TDragRegion, we are already doing this
in BarView -- no reason to do it twice.
* Need to redraw the drag region after moving or it will be half
drawn.
* Hide resize control in horizontal mode
* Add room for resize dragger when placing replicants
* Update width setting unless window is hidden
- This prevents Deskbar from being set to minimum width after it
is hidden.

Also, constrain width setting within limits but not width of the
BarView which we want to track the window width. In practice they
should be the same but it is possible for them to get out of sync
and that's okay. Obvious example of the setting and actual width
of the window being out of sync is in the hidden case.

unify dragger width and kDragWidth vars

Make drag regions pixel perfect:
* Vertical mode status tray reduced in height by 1px to match height
in horizontal mode exactly.
* move icons over by 2px in horizontal mode so that there is a bit more space
on the left and so that it matches pixel perfect with vertical mode.
- to see this quickly switch between bottom right vertical at the minimum width
and horizontal mode then notice how the icons don't move

Draw drag background then menu color when not active to get rid of drawing
glitches in horizontal mode on the top pixel.

Add some more room between last icon and clock in horizontal mode.


# deaae5fc 07-Jan-2014 John Scipione <jscipione@gmail.com>

Deskbar: Persist ExpandoMenuBar

Add private BMenu::_SetMenuLayout() method. Set TExpandoMenuBar
as a friend class in BMenu to call this method. A little hacky,
but, this keeps SetMenuLayout() from being exposed as part of
the public API.

Don't destroy and rebuild the ExpandoMenuBar when switching from
horizontal to vertical mode. Instead build the TExpandoMenuBar
when the application starts and then switch it from B_ITEMS_IN_ROW
to B_ITEMS_IN_COLUMNS by using the newly added _SetMenuLayout()
method.

When we resize from vertical to horizontal, recalc the max
menu item widths, this resizes the application menu items so
that they take up the right amount of space.

Since we no longer destroy the menu bar we no longer have to
save whether menu items are expanded or not in a separate list.
Instead we can store that information in directly in
TExpandoMenuBar. This removes a lot of code.

Fixes #9350


# 251ece3c 14-Apr-2013 John Scipione <jscipione@gmail.com>

Style fixes in BarView.h


# 777fffe8 14-Apr-2013 John Scipione <jscipione@gmail.com>

Build the fBarMenu object in the BarView constructor

... then resize it and move it to the desired size and location on update.

* Create an fBarApp pointer and use it, this is easier than having to keep casting to TBarApp.


# ee78e4de 13-Apr-2013 John Scipione <jscipione@gmail.com>

Convert state variable from a uint32 to an int32


# fe624b39 13-Apr-2013 John Scipione <jscipione@gmail.com>

Style fixes only

Most indentation and newlines with a few comment updates


# 53ec5d1f 11-Mar-2013 John Scipione <jscipione@gmail.com>

Rebuild application menu bar less. Fixes #8539 (I hope)

Instead of destroying and rebuilding the application menu bar each time we
change state, create it at startup and then only update it from there on. This
means that bugs that rely on the app bar being constantly destroyed and rebuilt
will be much less likely to occur.

Unfortunatly, there is still one case where the application menu bar is being
destroyed and recreated and that is when you are switching between horizontal
and vertical mode, and that is because a menu bar cannot be altered from
B_ITEMS_IN_ROWS to B_ITEMS_IN_COLUMNS anywhere but in the constructor.

* Renamed fExpando to fExpandoMenuBar
* Updated TExpandoMenuBar to be more flexible after construction, the menu
items are built in the new BuildItems() method. Also, don't pass the BarView
object in at contruction, that can happen in AttachedToWindow(). Also, set
fDeskbarMenuWidth just once at constructor, no reason to keep setting it over and over again.


# e6d8c22a 26-Jul-2012 John Scipione <jscipione@gmail.com>

WIP: Add support for horizontal scrolling.


# 32f840b7 25-Jul-2012 John Scipione <jscipione@gmail.com>

Rename ScrollArrowView to InlineScrollView

InlineScrollView takes a BView instead of a BMenu as well, and it
no longer has flags to do drawing respond to frame changes since
this view does neither of those things.


# fcfe60b0 24-Jul-2012 John Scipione <jscipione@gmail.com>

Renamed BMenuScrollView to TScrollArrowView and moved it into Deskbar

Also gave the Up Arrow and Down Arrow a scroll arrow. The up arrow works
but the down arrow doesn't because the sibling menu is stealing the
MouseDown event."


# 49ff476d 19-Jul-2012 John Scipione <jscipione@gmail.com>

Make ScrollMenu not rely on Menu.cpp

Rename ScrollMenu.cpp to MenuScrollView.cpp

Half step towards making this class work as part of Deskbar without
extending any other classes. Scrolling works both with mouse and
scroll wheel. Redraws on scroll, need to make that work better.
Also need to move classes out of the Interface Kit and into Deskbar.


# cb55ef9f 27-Jun-2011 John Scipione <jscipione@gmail.com>

WIP: Created a BScrollMenu class that works like BMenuWindow but works on a view instead of a window. Use this to implement a scrollable BarMenuBar in Deskbar. The basics work but there are issues still with sizing and other issues.

Modify the ScrollMenu class to use the layout kit by adding a constructor that doesn't take a view.

Get the BScrollMenu class to follow the size of the BMenu it is a parent of. Adjust the scrollers to appear in the right places. This is a WIP but it works in Deskbar, next step is to integrate this directly into BMenu with the scrollers as children of the menu instead of as children of the BScroller class.

Rebase changes on top of master

Deskbar scrolling works for the most part, just need to fix the
bottom arrow and clean up a bit.


# d7ed9414 22-Jul-2012 Rene Gollent <anevilyak@gmail.com>

Fix #8523.

- When the message filter would receive and process a mouse moved message,
if the message resulted in causing the deskbar to relocate or reorient
itself, it was possible for the expando view to become detached from
the looper. Consequently, if the intercepted mouse moved happened to have
come from the latter, when returning out of the filter the view would no
longer have a target looper, triggering a debugger condition in BLooper.
In order to prevent this situation, we now dispatch a message asking for
the layout change to occur asynchronously.


# 22812ba2 05-May-2012 Rene Gollent <anevilyak@gmail.com>

Fix ticket #8497.

- Rework Deskbar's handling for the autoraise/autohide cases to not
need event masks. This prevents various problems that would occur
if one happened to be working in another window that overlapped part
of Deskbar, as reported in #8497. Instead, we now use a message filter
to redirect the messages as needed.


# 1cd61330 02-May-2012 John Scipione <jscipione@gmail.com>

Style fixes including reordering #include's in Deskbar

* Reorder includes according to the Style Guide.
* Whitespace changes, mostly making sure there are 2 newlines
between things and making sure there is 1 newline at the end of
each file.
* Make end of header files all in the style of
#endif\t/* _HEADER_GAURD_H_ */
* The one change that is not purely style is to #include <Path.h>
in DeskbarUtils.h instead of DeskbarUtils.cpp because it is used
to define entry_ref for the AddRefsToDeskbarMenu() prototype.


# 3cf2d117 14-Apr-2012 John Scipione <jscipione@gmail.com>

Change Time Format Options in Deskbar preferences.

Added two new methods to the Locale Kit in order to create a custom time
formats from a format string. One method is outputs into a char* array,
the other into a BString() and you can set the timezone.

These methods should be cleaned up, we only need 2, one to get
the time in a predefined style, the other to get a custom time format.
Also should probably do the same for dates and datetimes. But I'll let
this go for now.

I added myself to the Locale.cpp file. I retained the copyright instead
of assigning it to Haiku, Inc. because the file is under the OpenBeOS
license and I don't know what the concequences of copyright sharing are
for that license, unlike MIT.

These new methods are used to generate custom time formats in Deskbar.
Instead of using a set of Radio Buttons to choose between the predefined
time options I build my own by creating a format string and passing it
to the Locale Kit. The format string is generated from 3 checkboxes,
show seconds, show day of week, and show time zone. You can mix and match
between them choose any that you like. By default they are all off.

There are 3 new deskbar settings associated with these new options:
showSeconds, showDayOfWeek, and showTimeZone. timeFormat has gone away.

The time format string gets cached and updated only when Update() gets called
on the TimeView class.

In order to fit all the options in (there is 1 more than before) I had to
reduce the font size of the clock to 11pt when all options are turned on in
12 hour mode. For those with no imagination it looks like this:

http://imagebin.org/208162

Renamed "Open time preferences..." menuitem to "Time preferences...".
Renamed "Show Time" and "Hide Time" to "Show time" and "Hide time".

Other changes include refactoring the header files a bit. There were a lot
of headers included by header files uneccessarily. For instance BarWindow.h
now only includes <Window.h> and <Deskbar.h>. This change is mainly to
to speed up the compile time since it takes a while right now.

I copy the fBarView pointer from BarWindow in the BarApp constructor and then
use that throughout the file rather than getting the pointer from the window
each time by calling BarView(). BarView() is still available in the header
for other classes though.

I moved some message constants around since it was getting a bit jumbled.
Most of the messages related to settings are in PreferenceWindow.h.
fChangeState is moved to BarView.h since that is where the ChangeState()
function is and BarView.cpp uses that constant.

The time interval and format constants are in TimeView.h.

Make some methods public in their respective classes where it made sense.
The preference window methods to update dependent items are public, that
might get called from BarWindow when a message gets received at some point.

Also made ShowHideTime() and Time() public in StatusView.h. These methods
activate showing and hiding the clock and return the fTime clock object.
No reason they should be private.

I reindented the StatusView.h and PreferenceWindow.h headers to the standard
style. Question here, are the public: protected: and private: lines inside
of classes suppose to get indented 1 tab or not? I've seen both, the style
guide says no indent but 1 indent seems reasonable and looks pretty good.

Style fixes here and there. That's enough for one commit I think.


# 573f748c 09-Apr-2012 John Scipione <jscipione@gmail.com>

Add 12/24 hour and time formatting options to Deskbar.

* 12/24 hour settings come from and alter BLocale
* Time formats are short, medium, long. Short is default. Come from
Locale kit.
* Don't delete fClock (now fTime) when hiding, just hide and show
the view.
* BarView now has nothing to do with setting or keeping track of
time settings. This is all handled in TTimeView. TReplicantTray
is responsible for updating the replicant tray and doing showing
and hiding. TTimeView is responsible for drawing according to the
clock settings.
* Remove fShowInterval and fShowSeconds from BarView
* Remove ampmMode setting and replace it with timeFormat.
* Reset targets in DeskbarMenu.

Originally I was trying to solve a bug where the TTimeView
was relying on the Deskbar settings too much. The settings
should only by set on quit and accessed on startup or a crash can
cause Deskbar to be in an unusual state.

I realize that the timezone is not very helpful. I'd like to provide
the day of week in a short format instead, i.e. Wed for Wednesday or
similar based on your locale. Blame the Locale Kit for now allowing
me to be able to use a custom TimeFormat. Once a custom TimeFormats
becomes possible from the Locale Kit Deskbar can be updated to use
them.


# d0a49328 07-Apr-2012 John Scipione <jscipione@gmail.com>

Fix a few more bugs in Deskbar, find a new one too.

Hiding in horizontal mode was leaving behind a white bar because the
window was getting hidden but the view not resized. Now fixed.

Moved simple state and member access function implementations from
BarView.cpp to BarView.h. Always use the local variable in BarView.cpp
to avoid a function call.

Rename Expando() to ExpandoState() and add FullState() and MiniState()
methods to BarView.h.

Call just PlaceApplicationBar() in vertical expando mode when resizing
icons. Call the full UpdatePlacement() in horizontal mode because I need
to update the height of the status tray when icons resize. Do not call
any method in MiniState because the icons will get resized when the
menu gets opened later.

The new bug I found is a little subtle. If you hide the clock by right
clicking on the clock and selecting Hide clock then quit deskbar with
'hey Deskbar QUIT' and restart Deskbar with 'Deskbar' the Show seconds
checkbox in the preference is disabled correctly, however, right clicking
Show Clock doesn't undisable the checkbox so you can no longer hide
seconds anymore. I'll fix this in a bit.


# 363a49a6 07-Apr-2012 John Scipione <jscipione@gmail.com>

Fix memory leak and an optimization in Deskbar

When resizing Deskbar icons, delete the icon bitmap before rebuilding
it with a new icon, was leaking the bitmap.

For several actions including:
- Sorting running apps
- Setting Tracker first
- Showing/hiding application expander
- Expanding new applications
- Resizing icons
- Hiding and showing application names

It is not necessary to rebuild all of Deskbar, just rebuild the
application bar. Should also help but not complete fix Ticket #532.


# 2ce9bab8 27-Jun-2011 John Scipione <jscipione@gmail.com>

Fisher Price Deskbar icon support

Implements the feature described in #7132
Also fixes #2387 (menu items too big in horizontal mode when font size > 12)

Adds a slider to Deskbar preferences which allows you to resize your Deskbar
team icons from 16x16 to 96x96. The default is 16x16. This works both in vertical
and horizontal mode.

In vertical mode when icon sizes are greater than 32x32 the label moves
underneath the icon where there is more room. In horizontal mode the width of
the menu item increases to make room for the icon while keeping room for the
label the same. As many applications are added the labels are truncated as usual.

This patch also adds a checkbox to the Deskbar preferences to hide application
names to make more room for icons if you wish. It doesn't make a lot of sense
at 16x16 but does >32x32.

If the kResizeTeamIcons message gets dropped, don't resize to current value,
just do nothing. This fixes a bug where sometimes the slider wouldn't trigger
a resize. Fix a spelling error in a comment. Take out a redundant paren pair.


# 323b6546 21-Nov-2011 Oliver Tappe <zooey@hirschkaefer.de>

Filtered flat import of Oliver's svn package management branch

Bring the changes that aren't package management related and the ones
that are but don't take effect as long as they are ignored by the build
system into the master.

Summary of changes:
* Introduce private header <directories.h> with constants for a good
deal of paths that should usually be retrieved via find_directory().
* Replace hard-coded paths by using find_directory() or the
<directories.h> constants (e.g. in drivers and the kernel).
* Add find_directory() constants needed for package management.
* Add __HAIKU_ABI_NAME and B_HAIKU_ABI_NAME macros.
* src/apps/deskbar: BeMenu.* -> DeskbarMenu.*,
DeskBarUtils.* -> DeskbarUtils.*
* Change deskbar menu settings directory from ~/config/be to
~/config/settings/deskbar.
* Other smaller cleanups, changes, and fixes.


# 001f3799 01-Nov-2011 John Scipione <jscipione@gmail.com>

This commit fixes a bug described in ticket #7051 where Deskbar forgets expanded
items when you switch away from expando mode. It does this by keeping a list of
expanded item signatures in a fExpandedItems BList on the BarView class. I
can't use team_id because there can be more than one team per application.

If you have checked the 'Expand new applications' option in the Deskbar
preferences then the signatures of new applications will be added to the
fExpandedItems list expanding the item. If you open a new application while
not in expando mode then the app will be expanded upon returning to expando
mode.

Since 'Expand new applications' automatically adds any new item's signature
to the fExpandedItems list Tracker is expanded on startup since it is 'new'.
Also if Deskbar is restarted all applications will be considered 'new' so they
are expanded. This fixes ticket #4830

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@43092 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 3e6ff860 30-Oct-2011 Rene Gollent <anevilyak@gmail.com>

Rework Deskbar's tray replicant support a bit. Instead of relying on a live query
for be:deskbar_item_status in order to determine which replicants are supposed to
be living in the tray, a list of entry refs is now stored. While the former approach
was cool, it doesn't really work in either a multiuser or a package-aware world, where
executables are generally read-only. Note this means you'll lose your existing replicants
the first time you run this new revision, and need to re-add them.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@43004 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 3dfd9cb9 16-Jun-2011 Oliver Tappe <zooey@hirschkaefer.de>

Flat commit of all changes from package-management branch in svn


# e2700599 06-Jul-2011 Axel Dörfler <axeld@pinc-software.de>

* Applied a patch of x-ist that implements auto hide functionality with minor
coding style changes by myself.
* Thanks, and sorry for the long delay!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42383 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4ec67d2b 05-Mar-2011 Fredrik Holmqvist <fredrik.holmqvist@gmail.com>

Patches from John Scipione as part of bug 7052.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40815 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ca9acc20 21-May-2010 Axel Dörfler <axeld@pinc-software.de>

* The Deskbar will now intercept control+alt-clicks, and will start to move the
Deskbar around as other windows do (more or less), as suggested in ticket
#6029.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36889 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 71bd3ba5 30-Sep-2009 Jonas Sundström <jonas@kirilla.com>

Removing ifdefs and code for non-Haiku build targets. Partial clean-up. Enforcing the 80-char limit, renaming constants, newline at end of file.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33377 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 290c9039 29-Sep-2009 Jonas Sundström <jonas@kirilla.com>

Partial clean-up. Asterisks and k-prefix constants.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33366 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 21f3e082 29-Sep-2009 Jonas Sundström <jonas@kirilla.com>

Moving Deskbar options to a dedicated preferences window. Adding a preference application that simply tells Deskbar to open that window. Adjusting default settings Recent Folders from off to 10, and Auto-raise from on to off.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33363 a95241bf-73f2-0310-859d-f6bbb57e9c96


# cb6afcb1 21-Mar-2009 Stephan Aßmus <superstippi@gmx.de>

* Give Deskbar a refreshed and cleaner look.
* Fixed a bunch of problems in layouting the various views. (For example,
the last app menu entry is no longer one pixel too short, but there was
more...)
* Fixed Deskbar being not wide enough for the Haiku logo in certain modes.
* Enabled the mount menu. I think it's a good idea to have at a more prominent
location where new Haiku users may look for it (Gnome also has this in
the main panel).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29631 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 80fa95ad 14-Oct-2008 Stefano Ceccherini <stefano.ceccherini@gmail.com>

no need to use private libbe variables anymore

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28073 a95241bf-73f2-0310-859d-f6bbb57e9c96


# dc69d5e2 14-Aug-2007 Axel Dörfler <axeld@pinc-software.de>

Added an auto-raise feature.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21954 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 2c7fad57 17-May-2006 Stephan Aßmus <superstippi@gmx.de>

synced to rev 1.9 and 1.4 from OpenTracker CVS

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@17495 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7da06231 01-Jan-2006 Axel Dörfler <axeld@pinc-software.de>

Imported Deskbar from OpenTracker-current.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15774 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 41281cf3 22-May-2005 Axel Dörfler <axeld@pinc-software.de>

Added Tracker and Deskbar from OpenTracker-current to the repository.
They both build fine.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12773 a95241bf-73f2-0310-859d-f6bbb57e9c96


# deaae5fc20b5cf44115441d34a1e33436df885b2 07-Jan-2014 John Scipione <jscipione@gmail.com>

Deskbar: Persist ExpandoMenuBar

Add private BMenu::_SetMenuLayout() method. Set TExpandoMenuBar
as a friend class in BMenu to call this method. A little hacky,
but, this keeps SetMenuLayout() from being exposed as part of
the public API.

Don't destroy and rebuild the ExpandoMenuBar when switching from
horizontal to vertical mode. Instead build the TExpandoMenuBar
when the application starts and then switch it from B_ITEMS_IN_ROW
to B_ITEMS_IN_COLUMNS by using the newly added _SetMenuLayout()
method.

When we resize from vertical to horizontal, recalc the max
menu item widths, this resizes the application menu items so
that they take up the right amount of space.

Since we no longer destroy the menu bar we no longer have to
save whether menu items are expanded or not in a separate list.
Instead we can store that information in directly in
TExpandoMenuBar. This removes a lot of code.

Fixes #9350


# 251ece3c7492f7909025a2926c4084df1bf292a0 14-Apr-2013 John Scipione <jscipione@gmail.com>

Style fixes in BarView.h


# 777fffe8f75e05cc7b13c59404036b840794890e 14-Apr-2013 John Scipione <jscipione@gmail.com>

Build the fBarMenu object in the BarView constructor

... then resize it and move it to the desired size and location on update.

* Create an fBarApp pointer and use it, this is easier than having to keep casting to TBarApp.


# ee78e4de9f1ee2293d9e1c4b8b44db1bcf981530 13-Apr-2013 John Scipione <jscipione@gmail.com>

Convert state variable from a uint32 to an int32


# fe624b3937dc8b7a4551dbc66b5e5c81dfb468d6 13-Apr-2013 John Scipione <jscipione@gmail.com>

Style fixes only

Most indentation and newlines with a few comment updates


# 53ec5d1f33912441da3ad5786dfd300282cdfcf0 11-Mar-2013 John Scipione <jscipione@gmail.com>

Rebuild application menu bar less. Fixes #8539 (I hope)

Instead of destroying and rebuilding the application menu bar each time we
change state, create it at startup and then only update it from there on. This
means that bugs that rely on the app bar being constantly destroyed and rebuilt
will be much less likely to occur.

Unfortunatly, there is still one case where the application menu bar is being
destroyed and recreated and that is when you are switching between horizontal
and vertical mode, and that is because a menu bar cannot be altered from
B_ITEMS_IN_ROWS to B_ITEMS_IN_COLUMNS anywhere but in the constructor.

* Renamed fExpando to fExpandoMenuBar
* Updated TExpandoMenuBar to be more flexible after construction, the menu
items are built in the new BuildItems() method. Also, don't pass the BarView
object in at contruction, that can happen in AttachedToWindow(). Also, set
fDeskbarMenuWidth just once at constructor, no reason to keep setting it over and over again.


# e6d8c22a7d78f0e47be55db2338083ada4766b2a 26-Jul-2012 John Scipione <jscipione@gmail.com>

WIP: Add support for horizontal scrolling.


# 32f840b7684012009c47338da6e00a202388126b 25-Jul-2012 John Scipione <jscipione@gmail.com>

Rename ScrollArrowView to InlineScrollView

InlineScrollView takes a BView instead of a BMenu as well, and it
no longer has flags to do drawing respond to frame changes since
this view does neither of those things.


# fcfe60b02ec06525dbe76eedc110d20b7eb808f7 24-Jul-2012 John Scipione <jscipione@gmail.com>

Renamed BMenuScrollView to TScrollArrowView and moved it into Deskbar

Also gave the Up Arrow and Down Arrow a scroll arrow. The up arrow works
but the down arrow doesn't because the sibling menu is stealing the
MouseDown event."


# 49ff476d139dc28ebaa95d65b7820423b6061d60 19-Jul-2012 John Scipione <jscipione@gmail.com>

Make ScrollMenu not rely on Menu.cpp

Rename ScrollMenu.cpp to MenuScrollView.cpp

Half step towards making this class work as part of Deskbar without
extending any other classes. Scrolling works both with mouse and
scroll wheel. Redraws on scroll, need to make that work better.
Also need to move classes out of the Interface Kit and into Deskbar.


# cb55ef9fb597a3f3bc91e53017360b18b20dd27b 27-Jun-2011 John Scipione <jscipione@gmail.com>

WIP: Created a BScrollMenu class that works like BMenuWindow but works on a view instead of a window. Use this to implement a scrollable BarMenuBar in Deskbar. The basics work but there are issues still with sizing and other issues.

Modify the ScrollMenu class to use the layout kit by adding a constructor that doesn't take a view.

Get the BScrollMenu class to follow the size of the BMenu it is a parent of. Adjust the scrollers to appear in the right places. This is a WIP but it works in Deskbar, next step is to integrate this directly into BMenu with the scrollers as children of the menu instead of as children of the BScroller class.

Rebase changes on top of master

Deskbar scrolling works for the most part, just need to fix the
bottom arrow and clean up a bit.


# d7ed9414a3260efaed0fa9de5dde9bb8c0bc11ef 22-Jul-2012 Rene Gollent <anevilyak@gmail.com>

Fix #8523.

- When the message filter would receive and process a mouse moved message,
if the message resulted in causing the deskbar to relocate or reorient
itself, it was possible for the expando view to become detached from
the looper. Consequently, if the intercepted mouse moved happened to have
come from the latter, when returning out of the filter the view would no
longer have a target looper, triggering a debugger condition in BLooper.
In order to prevent this situation, we now dispatch a message asking for
the layout change to occur asynchronously.


# 22812ba24ffdc5c1a1f30257bc01ce9b4b211d47 05-May-2012 Rene Gollent <anevilyak@gmail.com>

Fix ticket #8497.

- Rework Deskbar's handling for the autoraise/autohide cases to not
need event masks. This prevents various problems that would occur
if one happened to be working in another window that overlapped part
of Deskbar, as reported in #8497. Instead, we now use a message filter
to redirect the messages as needed.


# 1cd61330ecd8257551d58f204332d00145c855ec 02-May-2012 John Scipione <jscipione@gmail.com>

Style fixes including reordering #include's in Deskbar

* Reorder includes according to the Style Guide.
* Whitespace changes, mostly making sure there are 2 newlines
between things and making sure there is 1 newline at the end of
each file.
* Make end of header files all in the style of
#endif\t/* _HEADER_GAURD_H_ */
* The one change that is not purely style is to #include <Path.h>
in DeskbarUtils.h instead of DeskbarUtils.cpp because it is used
to define entry_ref for the AddRefsToDeskbarMenu() prototype.


# 3cf2d117e570356c8487e67a0e38b09b1639ab6c 14-Apr-2012 John Scipione <jscipione@gmail.com>

Change Time Format Options in Deskbar preferences.

Added two new methods to the Locale Kit in order to create a custom time
formats from a format string. One method is outputs into a char* array,
the other into a BString() and you can set the timezone.

These methods should be cleaned up, we only need 2, one to get
the time in a predefined style, the other to get a custom time format.
Also should probably do the same for dates and datetimes. But I'll let
this go for now.

I added myself to the Locale.cpp file. I retained the copyright instead
of assigning it to Haiku, Inc. because the file is under the OpenBeOS
license and I don't know what the concequences of copyright sharing are
for that license, unlike MIT.

These new methods are used to generate custom time formats in Deskbar.
Instead of using a set of Radio Buttons to choose between the predefined
time options I build my own by creating a format string and passing it
to the Locale Kit. The format string is generated from 3 checkboxes,
show seconds, show day of week, and show time zone. You can mix and match
between them choose any that you like. By default they are all off.

There are 3 new deskbar settings associated with these new options:
showSeconds, showDayOfWeek, and showTimeZone. timeFormat has gone away.

The time format string gets cached and updated only when Update() gets called
on the TimeView class.

In order to fit all the options in (there is 1 more than before) I had to
reduce the font size of the clock to 11pt when all options are turned on in
12 hour mode. For those with no imagination it looks like this:

http://imagebin.org/208162

Renamed "Open time preferences..." menuitem to "Time preferences...".
Renamed "Show Time" and "Hide Time" to "Show time" and "Hide time".

Other changes include refactoring the header files a bit. There were a lot
of headers included by header files uneccessarily. For instance BarWindow.h
now only includes <Window.h> and <Deskbar.h>. This change is mainly to
to speed up the compile time since it takes a while right now.

I copy the fBarView pointer from BarWindow in the BarApp constructor and then
use that throughout the file rather than getting the pointer from the window
each time by calling BarView(). BarView() is still available in the header
for other classes though.

I moved some message constants around since it was getting a bit jumbled.
Most of the messages related to settings are in PreferenceWindow.h.
fChangeState is moved to BarView.h since that is where the ChangeState()
function is and BarView.cpp uses that constant.

The time interval and format constants are in TimeView.h.

Make some methods public in their respective classes where it made sense.
The preference window methods to update dependent items are public, that
might get called from BarWindow when a message gets received at some point.

Also made ShowHideTime() and Time() public in StatusView.h. These methods
activate showing and hiding the clock and return the fTime clock object.
No reason they should be private.

I reindented the StatusView.h and PreferenceWindow.h headers to the standard
style. Question here, are the public: protected: and private: lines inside
of classes suppose to get indented 1 tab or not? I've seen both, the style
guide says no indent but 1 indent seems reasonable and looks pretty good.

Style fixes here and there. That's enough for one commit I think.


# 573f748c5f8fb7ed75beb0ceb7eb097d3ab0c038 09-Apr-2012 John Scipione <jscipione@gmail.com>

Add 12/24 hour and time formatting options to Deskbar.

* 12/24 hour settings come from and alter BLocale
* Time formats are short, medium, long. Short is default. Come from
Locale kit.
* Don't delete fClock (now fTime) when hiding, just hide and show
the view.
* BarView now has nothing to do with setting or keeping track of
time settings. This is all handled in TTimeView. TReplicantTray
is responsible for updating the replicant tray and doing showing
and hiding. TTimeView is responsible for drawing according to the
clock settings.
* Remove fShowInterval and fShowSeconds from BarView
* Remove ampmMode setting and replace it with timeFormat.
* Reset targets in DeskbarMenu.

Originally I was trying to solve a bug where the TTimeView
was relying on the Deskbar settings too much. The settings
should only by set on quit and accessed on startup or a crash can
cause Deskbar to be in an unusual state.

I realize that the timezone is not very helpful. I'd like to provide
the day of week in a short format instead, i.e. Wed for Wednesday or
similar based on your locale. Blame the Locale Kit for now allowing
me to be able to use a custom TimeFormat. Once a custom TimeFormats
becomes possible from the Locale Kit Deskbar can be updated to use
them.


# d0a49328634b3702d647e27b8704a3ce706074b8 07-Apr-2012 John Scipione <jscipione@gmail.com>

Fix a few more bugs in Deskbar, find a new one too.

Hiding in horizontal mode was leaving behind a white bar because the
window was getting hidden but the view not resized. Now fixed.

Moved simple state and member access function implementations from
BarView.cpp to BarView.h. Always use the local variable in BarView.cpp
to avoid a function call.

Rename Expando() to ExpandoState() and add FullState() and MiniState()
methods to BarView.h.

Call just PlaceApplicationBar() in vertical expando mode when resizing
icons. Call the full UpdatePlacement() in horizontal mode because I need
to update the height of the status tray when icons resize. Do not call
any method in MiniState because the icons will get resized when the
menu gets opened later.

The new bug I found is a little subtle. If you hide the clock by right
clicking on the clock and selecting Hide clock then quit deskbar with
'hey Deskbar QUIT' and restart Deskbar with 'Deskbar' the Show seconds
checkbox in the preference is disabled correctly, however, right clicking
Show Clock doesn't undisable the checkbox so you can no longer hide
seconds anymore. I'll fix this in a bit.


# 363a49a64e0c4a009b2b9549c117782f2080e39c 07-Apr-2012 John Scipione <jscipione@gmail.com>

Fix memory leak and an optimization in Deskbar

When resizing Deskbar icons, delete the icon bitmap before rebuilding
it with a new icon, was leaking the bitmap.

For several actions including:
- Sorting running apps
- Setting Tracker first
- Showing/hiding application expander
- Expanding new applications
- Resizing icons
- Hiding and showing application names

It is not necessary to rebuild all of Deskbar, just rebuild the
application bar. Should also help but not complete fix Ticket #532.


# 2ce9bab873e024bb515a95faf384df62b88bbb8c 27-Jun-2011 John Scipione <jscipione@gmail.com>

Fisher Price Deskbar icon support

Implements the feature described in #7132
Also fixes #2387 (menu items too big in horizontal mode when font size > 12)

Adds a slider to Deskbar preferences which allows you to resize your Deskbar
team icons from 16x16 to 96x96. The default is 16x16. This works both in vertical
and horizontal mode.

In vertical mode when icon sizes are greater than 32x32 the label moves
underneath the icon where there is more room. In horizontal mode the width of
the menu item increases to make room for the icon while keeping room for the
label the same. As many applications are added the labels are truncated as usual.

This patch also adds a checkbox to the Deskbar preferences to hide application
names to make more room for icons if you wish. It doesn't make a lot of sense
at 16x16 but does >32x32.

If the kResizeTeamIcons message gets dropped, don't resize to current value,
just do nothing. This fixes a bug where sometimes the slider wouldn't trigger
a resize. Fix a spelling error in a comment. Take out a redundant paren pair.


# 323b65468e5836bb27a5e373b14027d902349437 21-Nov-2011 Oliver Tappe <zooey@hirschkaefer.de>

Filtered flat import of Oliver's svn package management branch

Bring the changes that aren't package management related and the ones
that are but don't take effect as long as they are ignored by the build
system into the master.

Summary of changes:
* Introduce private header <directories.h> with constants for a good
deal of paths that should usually be retrieved via find_directory().
* Replace hard-coded paths by using find_directory() or the
<directories.h> constants (e.g. in drivers and the kernel).
* Add find_directory() constants needed for package management.
* Add __HAIKU_ABI_NAME and B_HAIKU_ABI_NAME macros.
* src/apps/deskbar: BeMenu.* -> DeskbarMenu.*,
DeskBarUtils.* -> DeskbarUtils.*
* Change deskbar menu settings directory from ~/config/be to
~/config/settings/deskbar.
* Other smaller cleanups, changes, and fixes.


# 001f379993c2a6b597c9469b9de66d372ee3ef8a 01-Nov-2011 John Scipione <jscipione@gmail.com>

This commit fixes a bug described in ticket #7051 where Deskbar forgets expanded
items when you switch away from expando mode. It does this by keeping a list of
expanded item signatures in a fExpandedItems BList on the BarView class. I
can't use team_id because there can be more than one team per application.

If you have checked the 'Expand new applications' option in the Deskbar
preferences then the signatures of new applications will be added to the
fExpandedItems list expanding the item. If you open a new application while
not in expando mode then the app will be expanded upon returning to expando
mode.

Since 'Expand new applications' automatically adds any new item's signature
to the fExpandedItems list Tracker is expanded on startup since it is 'new'.
Also if Deskbar is restarted all applications will be considered 'new' so they
are expanded. This fixes ticket #4830

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@43092 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 3e6ff860b4f9cd789a091250a8923023bbe0ce91 30-Oct-2011 Rene Gollent <anevilyak@gmail.com>

Rework Deskbar's tray replicant support a bit. Instead of relying on a live query
for be:deskbar_item_status in order to determine which replicants are supposed to
be living in the tray, a list of entry refs is now stored. While the former approach
was cool, it doesn't really work in either a multiuser or a package-aware world, where
executables are generally read-only. Note this means you'll lose your existing replicants
the first time you run this new revision, and need to re-add them.



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@43004 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 3dfd9cb95ce45f59160d50975210bc55e3fc0709 16-Jun-2011 Oliver Tappe <zooey@hirschkaefer.de>

Flat commit of all changes from package-management branch in svn


# e27005998f2cb3d61a7a95e97ff9b5bcbd3eadd6 06-Jul-2011 Axel Dörfler <axeld@pinc-software.de>

* Applied a patch of x-ist that implements auto hide functionality with minor
coding style changes by myself.
* Thanks, and sorry for the long delay!


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@42383 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 4ec67d2b37f3100924230787b6ca2170ad31b586 05-Mar-2011 Fredrik Holmqvist <fredrik.holmqvist@gmail.com>

Patches from John Scipione as part of bug 7052.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40815 a95241bf-73f2-0310-859d-f6bbb57e9c96


# ca9acc20e8829812353a19093c3e9cfa076a06b1 21-May-2010 Axel Dörfler <axeld@pinc-software.de>

* The Deskbar will now intercept control+alt-clicks, and will start to move the
Deskbar around as other windows do (more or less), as suggested in ticket
#6029.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36889 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 71bd3ba59c06b130115c3ddd44457d8f9dd78997 30-Sep-2009 Jonas Sundström <jonas@kirilla.com>

Removing ifdefs and code for non-Haiku build targets. Partial clean-up. Enforcing the 80-char limit, renaming constants, newline at end of file.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33377 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 290c903985a449fa86c501366b6fcddf7f55b46a 29-Sep-2009 Jonas Sundström <jonas@kirilla.com>

Partial clean-up. Asterisks and k-prefix constants.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33366 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 21f3e082b187190910950714d14427b71e91e72c 29-Sep-2009 Jonas Sundström <jonas@kirilla.com>

Moving Deskbar options to a dedicated preferences window. Adding a preference application that simply tells Deskbar to open that window. Adjusting default settings Recent Folders from off to 10, and Auto-raise from on to off.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@33363 a95241bf-73f2-0310-859d-f6bbb57e9c96


# cb6afcb1464e92f0134232e6179215295e17bc79 21-Mar-2009 Stephan Aßmus <superstippi@gmx.de>

* Give Deskbar a refreshed and cleaner look.
* Fixed a bunch of problems in layouting the various views. (For example,
the last app menu entry is no longer one pixel too short, but there was
more...)
* Fixed Deskbar being not wide enough for the Haiku logo in certain modes.
* Enabled the mount menu. I think it's a good idea to have at a more prominent
location where new Haiku users may look for it (Gnome also has this in
the main panel).


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29631 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 80fa95ad77bd33130e9b05cf0bb5626b62853d6f 14-Oct-2008 Stefano Ceccherini <stefano.ceccherini@gmail.com>

no need to use private libbe variables anymore

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28073 a95241bf-73f2-0310-859d-f6bbb57e9c96


# dc69d5e23365ca14b8e8e2354a52dcae8b91f1c8 14-Aug-2007 Axel Dörfler <axeld@pinc-software.de>

Added an auto-raise feature.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21954 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 2c7fad579cac4999f7bc96d4d94844e158499bbb 17-May-2006 Stephan Aßmus <superstippi@gmx.de>

synced to rev 1.9 and 1.4 from OpenTracker CVS

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@17495 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 7da062312a13b77ed1aac63bdd67c44c44ad5824 01-Jan-2006 Axel Dörfler <axeld@pinc-software.de>

Imported Deskbar from OpenTracker-current.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@15774 a95241bf-73f2-0310-859d-f6bbb57e9c96


# 41281cf362916855e6eb9ad1d728d919863a1e81 22-May-2005 Axel Dörfler <axeld@pinc-software.de>

Added Tracker and Deskbar from OpenTracker-current to the repository.
They both build fine.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@12773 a95241bf-73f2-0310-859d-f6bbb57e9c96