WebPositive: Remove obsolete code for hiding tab close buttons

No longer needed after hrev59533

Change-Id: Iefcc9d1a4d1481a42a9abfb8174f886ff7735a0b
Reviewed-on: https://review.haiku-os.org/c/haiku/+/10616
Haiku-Format: Haiku-format Bot <[email protected]>
Tested-by: Commit checker robot <[email protected]>
Reviewed-by: nephele nephele <[email protected]>
This commit is contained in:
nipos
2026-04-05 08:58:48 +00:00
committed by nephele nephele
parent 00b9933841
commit e6806c471d
3 changed files with 3 additions and 29 deletions
-1
View File
@@ -1886,7 +1886,6 @@ BrowserWindow::_UpdateTabGroupVisibility()
if (Lock()) {
if (fInterfaceVisible)
fTabGroup->SetVisible(_TabGroupShouldBeVisible());
fTabManager->SetCloseButtonsAvailable(true);
Unlock();
}
}
+3 -27
View File
@@ -398,16 +398,6 @@ public:
void CloseTab(int32 index);
void SetCloseButtonsAvailable(bool available)
{
fCloseButtonsAvailable = available;
}
bool CloseButtonsAvailable() const
{
return fCloseButtonsAvailable;
}
void SetDoubleClickOutsideTabsMessage(const BMessage& message,
const BMessenger& target);
@@ -419,7 +409,6 @@ public:
private:
TabManager* fManager;
TabContainerGroup* fTabContainerGroup;
bool fCloseButtonsAvailable;
BMessage* fDoubleClickOutsideTabsMessage;
BMessenger fTarget;
BString fCurrentToolTip;
@@ -496,8 +485,7 @@ WebTabView::MaxSize()
void
WebTabView::DrawContents(BView* owner, BRect frame, const BRect& updateRect)
{
if (fController->CloseButtonsAvailable())
_DrawCloseButton(owner, frame, updateRect);
_DrawCloseButton(owner, frame, updateRect);
if (fIcon != NULL) {
BRect iconBounds(0, 0, kIconSize - 1, kIconSize - 1);
@@ -545,7 +533,7 @@ WebTabView::MouseDown(BPoint where, uint32 buttons)
}
BRect closeRect = _CloseRectFrame(Frame());
if (!fController->CloseButtonsAvailable() || !closeRect.Contains(where)) {
if (!closeRect.Contains(where)) {
TabView::MouseDown(where, buttons);
return;
}
@@ -577,8 +565,7 @@ WebTabView::MouseMoved(BPoint where, uint32 transit,
BRect closeRect = _CloseRectFrame(Frame());
bool overCloseRect = closeRect.Contains(where);
if (overCloseRect != fOverCloseRect
&& fController->CloseButtonsAvailable()) {
if (overCloseRect != fOverCloseRect) {
fOverCloseRect = overCloseRect;
ContainerView()->Invalidate(closeRect);
}
@@ -683,7 +670,6 @@ TabManagerController::TabManagerController(TabManager* manager)
:
fManager(manager),
fTabContainerGroup(NULL),
fCloseButtonsAvailable(false),
fDoubleClickOutsideTabsMessage(NULL)
{
}
@@ -942,13 +928,3 @@ TabManager::SetTabIcon(const BView* containedView, const BBitmap* icon)
if (tab)
tab->SetIcon(icon);
}
void
TabManager::SetCloseButtonsAvailable(bool available)
{
if (available == fController->CloseButtonsAvailable())
return;
fController->SetCloseButtonsAvailable(available);
fTabContainerView->Invalidate();
}
@@ -61,7 +61,6 @@ public:
const BString& TabLabel(int32);
void SetTabIcon(const BView* containedView,
const BBitmap* icon);
void SetCloseButtonsAvailable(bool available);
private:
#if INTEGRATE_MENU_INTO_TAB_BAR