add some properties and isDown()
svn path=/trunk/KDE/kdelibs/; revision=1023016
This commit is contained in:
parent
f2af7e8087
commit
1730d86a73
@ -292,6 +292,11 @@ bool PushButton::isChecked() const
|
|||||||
return nativeWidget()->isChecked();
|
return nativeWidget()->isChecked();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool PushButton::isDown() const
|
||||||
|
{
|
||||||
|
return nativeWidget()->isDown();
|
||||||
|
}
|
||||||
|
|
||||||
KPushButton *PushButton::nativeWidget() const
|
KPushButton *PushButton::nativeWidget() const
|
||||||
{
|
{
|
||||||
return static_cast<KPushButton*>(widget());
|
return static_cast<KPushButton*>(widget());
|
||||||
|
@ -49,6 +49,8 @@ class PLASMA_EXPORT PushButton : public QGraphicsProxyWidget
|
|||||||
Q_PROPERTY(KPushButton *nativeWidget READ nativeWidget)
|
Q_PROPERTY(KPushButton *nativeWidget READ nativeWidget)
|
||||||
Q_PROPERTY(QAction *action READ action WRITE setAction)
|
Q_PROPERTY(QAction *action READ action WRITE setAction)
|
||||||
Q_PROPERTY(QIcon icon READ icon WRITE setIcon)
|
Q_PROPERTY(QIcon icon READ icon WRITE setIcon)
|
||||||
|
Q_PROPERTY(bool checked READ isChecked WRITE setChecked);
|
||||||
|
Q_PROPERTY(bool down READ isDown);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
explicit PushButton(QGraphicsWidget *parent = 0);
|
explicit PushButton(QGraphicsWidget *parent = 0);
|
||||||
@ -163,6 +165,12 @@ public:
|
|||||||
*/
|
*/
|
||||||
bool isChecked() const;
|
bool isChecked() const;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return true if the button is pressed down
|
||||||
|
* @since 4.4
|
||||||
|
*/
|
||||||
|
bool isDown() const;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return the native widget wrapped by this PushButton
|
* @return the native widget wrapped by this PushButton
|
||||||
*/
|
*/
|
||||||
|
Loading…
Reference in New Issue
Block a user