From 015b5dd659e2751c67c6e91d7aa93e1e25b03140 Mon Sep 17 00:00:00 2001 From: John Scipione Date: Thu, 16 Nov 2017 16:30:19 -0800 Subject: [PATCH] Deskbar: replicant tray width adjust for 2 draggers Revision of last commit, everything I said about how we needed to use 8px instead of 12px for the drag width and replicant tray padding was correct, BUT, because we are subtracting from the window width setting we need to account for the width of BOTH draggers, so it becomes 2 * 8px or 16px that needs to be subtracted -- sorry about that. The minimum Deskbar width was calculated to fit 6 replicant icons, however, this calculation doesn't take into account the extra width taken up by the recently added second dragger. Consequently only 5 16x16 replicants currently fit. However you can expand Deskbar to fit 6 (or more) icons now so it is not a big deal. Would it be desirable to adjust the minimum Deskbar width to fix 6 replicant icons again? --- src/apps/deskbar/StatusView.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/apps/deskbar/StatusView.cpp b/src/apps/deskbar/StatusView.cpp index 8c99421cc3..06ffe414a9 100644 --- a/src/apps/deskbar/StatusView.cpp +++ b/src/apps/deskbar/StatusView.cpp @@ -1165,7 +1165,7 @@ TReplicantTray::LocationForReplicant(int32 index, float replicantWidth) // determine free space in this row BRect rowRect(loc.x, loc.y, loc.x + static_cast(be_app)->Settings()->width - - kTrayPadding - kDragWidth - kGutter, + - (kTrayPadding + kDragWidth + kGutter) * 2, loc.y + kMaxReplicantHeight); if (row == 0 && !fTime->IsHidden()) rowRect.right -= kClockMargin + fTime->Frame().Width();