32 #include <QAbstractSpinBox> 35 #include <QMouseEvent> 95 if (cb->isEditable() && cb->lineEdit())
121 if (m_pressed &&
rect().contains(ev->
pos()))
135 bool m_pressed =
false;
139 #endif // BUDDYLABEL_H QWidget * buddy() const const
void mouseDoubleClickEvent(QMouseEvent *ev)
QEvent::Type type() const const
bool disconnect(const QObject *sender, const char *signal, const QObject *receiver, const char *method)
bool eventFilter(QObject *obj, QEvent *ev)
The filter monitors for tool tip changes on the buddy.
void setBuddy(QWidget *buddy)
void mouseReleaseEvent(QMouseEvent *ev)
void installEventFilter(QObject *filterObj)
void doubleClicked()
Emitted when label is double-clicked with left mouse button (or something emulating one).
void mousePressEvent(QMouseEvent *ev)
void clicked()
Emitted when label is clicked with left mouse button (or something emulating one).
bool contains(const QRect &rectangle, bool proper) const const
QLabel(QWidget *parent, Qt::WindowFlags f)
virtual void connectBuddy(QWidget *buddy)
Override this method for custom connections.
virtual void mouseReleaseEvent(QMouseEvent *ev) override
void setBuddy(QWidget *buddy)
Overrides the QLabel::setBuddy() method, which isn't virtual. Calls the base class implementation as ...
The BuddyLabel class is a QLabel with enhanced "buddy" capabilities.
QMetaObject::Connection connect(const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type)
void removeEventFilter(QObject *obj)
virtual void mousePressEvent(QMouseEvent *ev) override
virtual void disconnectBuddy(QWidget *buddy)
Hook for custom disconnections. We already disconnect ourselves from all slots in buddy in the main h...