Mercurial > minori
annotate src/gui/widgets/clickable_label.cc @ 291:9a88e1725fd2
*: refactor lots of stuff
I forgot to put this into different commits, oops!
anyway, it doesn't really matter *that* much since this is an
unfinished hobby project anyway. once it starts getting stable
commit history will be more important, but for now it's not
that big of a deal
author | Paper <paper@paper.us.eu.org> |
---|---|
date | Sun, 12 May 2024 16:31:07 -0400 |
parents | b3549da699a6 |
children | b1f625b0227c |
rev | line source |
---|---|
67
442065432549
poster: make posters link to AniList
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
1 #include "gui/widgets/clickable_label.h" |
442065432549
poster: make posters link to AniList
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
2 |
442065432549
poster: make posters link to AniList
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
3 ClickableLabel::ClickableLabel(QWidget* parent) : QLabel(parent) { |
442065432549
poster: make posters link to AniList
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
4 setCursor(Qt::PointingHandCursor); |
442065432549
poster: make posters link to AniList
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
5 } |
442065432549
poster: make posters link to AniList
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
6 |
442065432549
poster: make posters link to AniList
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
7 ClickableLabel::~ClickableLabel() { |
442065432549
poster: make posters link to AniList
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
8 } |
442065432549
poster: make posters link to AniList
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
9 |
442065432549
poster: make posters link to AniList
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
10 void ClickableLabel::mousePressEvent(QMouseEvent*) { |
442065432549
poster: make posters link to AniList
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
11 emit clicked(); |
442065432549
poster: make posters link to AniList
Paper <mrpapersonic@gmail.com>
parents:
diff
changeset
|
12 } |