first re-commit.
This commit is contained in:
43
swdialbutton.cpp
Normal file
43
swdialbutton.cpp
Normal file
@@ -0,0 +1,43 @@
|
||||
/***************************************************************************
|
||||
|
||||
source::worx raDIYo
|
||||
Copyright © 2020-2022 c.holzheuer
|
||||
chris@sourceworx.org
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
***************************************************************************/
|
||||
|
||||
|
||||
|
||||
#include <swdialbutton.h>
|
||||
#include <QDebug>
|
||||
|
||||
/**
|
||||
* @brief Standardkostruktor.
|
||||
*/
|
||||
|
||||
SWDialButton::SWDialButton( QWidget* parent )
|
||||
: QPushButton( parent )
|
||||
{
|
||||
setAcceptDial( false );
|
||||
// clicks auf mich weiterleiten
|
||||
connect( this, &QPushButton::clicked, this, [=]{ emit widgetClicked(this); } );
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Zeichnet diesen Button. Überschriebene Methode, ruft zusätzlich zu
|
||||
* @see QPushButton::paintEvent( event ) auch @drawMark() auf, um
|
||||
* den Button ggf. als 'aktiviert', als Bereit zur Eingabe per RotaryDial,
|
||||
* darzustellen.
|
||||
*/
|
||||
|
||||
void SWDialButton::paintEvent( QPaintEvent *event )
|
||||
{
|
||||
QPushButton::paintEvent( event );
|
||||
drawMark( this );
|
||||
}
|
Reference in New Issue
Block a user