1
0
mirror of https://github.com/qTox/qTox.git synced 2024-03-22 14:00:36 +08:00

Add real buttons for CallConfirmWidget

Still sort of placeholders, those are just upscaled buttons extracted from a screeshot, but those will work in the meantime
This commit is contained in:
Tux3 / Mlkj / !Lev.uXFMLA 2015-01-25 19:12:36 +01:00
parent 279debdab9
commit 328f75ac6d
No known key found for this signature in database
GPG Key ID: 7E086DD661263264
4 changed files with 12 additions and 2 deletions

View File

@ -227,5 +227,7 @@
<file>ui/window/applicationIcon.png</file>
<file>ui/window/statusPanel.css</file>
<file>ui/window/window.css</file>
<file>ui/acceptCall/acceptCall.png</file>
<file>ui/rejectCall/rejectCall.png</file>
</qresource>
</RCC>

View File

@ -12,7 +12,7 @@
CallConfirmWidget::CallConfirmWidget(const QWidget *Anchor) :
QWidget(Widget::getInstance()), anchor(Anchor),
rectW{130}, rectH{90},
rectW{120}, rectH{85},
spikeW{30}, spikeH{15},
roundedFactor{15}
{
@ -26,7 +26,15 @@ CallConfirmWidget::CallConfirmWidget(const QWidget *Anchor) :
QLabel *callLabel = new QLabel(tr("Incoming call..."), this);
callLabel->setAlignment(Qt::AlignHCenter);
QDialogButtonBox *buttonBox = new QDialogButtonBox(Qt::Horizontal, this);
QPushButton *accept = new QPushButton("Accept", this), *reject = new QPushButton("Reject", this);
QPushButton *accept = new QPushButton(this), *reject = new QPushButton(this);
accept->setFlat(true);
reject->setFlat(true);
accept->setStyleSheet("QPushButton{border:none;}");
reject->setStyleSheet("QPushButton{border:none;}");
accept->setIcon(QIcon(":/ui/acceptCall/acceptCall.png"));
reject->setIcon(QIcon(":/ui/rejectCall/rejectCall.png"));
accept->setIconSize(accept->size());
reject->setIconSize(reject->size());
buttonBox->addButton(accept, QDialogButtonBox::AcceptRole);
buttonBox->addButton(reject, QDialogButtonBox::RejectRole);

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB