fix: svgify user card pin button (#6399)

This commit is contained in:
James Upjohn
2025-08-18 00:18:23 +12:00
committed by GitHub
parent b85073e673
commit 565c63d0df
13 changed files with 97 additions and 29 deletions
+4 -7
View File
@@ -1,8 +1,6 @@
#include "widgets/DraggablePopup.hpp"
#include "singletons/Resources.hpp"
#include "singletons/Theme.hpp"
#include "widgets/buttons/PixmapButton.hpp"
#include "buttons/SvgButton.hpp"
#include <QMouseEvent>
@@ -109,18 +107,17 @@ void DraggablePopup::togglePinned()
if (isPinned_)
{
this->windowDeactivateAction = WindowDeactivateAction::Nothing;
this->pinButton_->setPixmap(getResources().buttons.pinEnabled);
this->pinButton_->setSource(this->pinEnabledSource_);
}
else
{
this->windowDeactivateAction = WindowDeactivateAction::Delete;
this->pinButton_->setPixmap(getTheme()->buttons.pin);
this->pinButton_->setSource(this->pinDisabledSource_);
}
}
Button *DraggablePopup::createPinButton()
{
this->pinButton_ = new PixmapButton(this);
this->pinButton_->setPixmap(getTheme()->buttons.pin);
this->pinButton_ = new SvgButton(pinDisabledSource_, this, {3, 3});
this->pinButton_->setScaleIndependentSize(18, 18);
this->pinButton_->setToolTip("Pin Window");