GUI: Add MouseMoved to trigger MouseEntered

This commit is contained in:
av-dx 2021-06-26 17:28:10 +05:30 committed by Eugene Sandulenko
parent c58c89b391
commit 598336710b
2 changed files with 7 additions and 0 deletions

View File

@ -126,6 +126,12 @@ void GridItemWidget::handleMouseLeft(int button) {
}
}
void GridItemWidget::handleMouseMoved(int x, int y, int button) {
if (!isHighlighted) {
handleMouseEntered(button);
}
}
void GridItemWidget::handleMouseDown(int x, int y, int button, int clickCount) {
if (isHighlighted) {
// Work in progress

View File

@ -218,6 +218,7 @@ public:
void handleMouseEntered(int button) override;
void handleMouseLeft(int button) override;
void handleMouseDown(int x, int y, int button, int clickCount) override;
void handleMouseMoved(int x, int y, int button) override;
};
} // End of namespace GUI