|
|
@ -48,7 +48,7 @@ bool CursorTracker::eventFilter(TQObject* object, TQEvent* _event) {
|
|
|
|
switch (_event->type()) {
|
|
|
|
switch (_event->type()) {
|
|
|
|
case TQEvent::MouseMove: {
|
|
|
|
case TQEvent::MouseMove: {
|
|
|
|
TQMouseEvent* event=TQT_TQMOUSEEVENT(_event);
|
|
|
|
TQMouseEvent* event=TQT_TQMOUSEEVENT(_event);
|
|
|
|
if (TQT_TQRECT_OBJECT(widget->rect()).contains(event->pos()) || (event->stateAfter() & Qt::LeftButton)) {
|
|
|
|
if (widget->rect().contains(event->pos()) || (event->stateAfter() & Qt::LeftButton)) {
|
|
|
|
show();
|
|
|
|
show();
|
|
|
|
move(event->globalPos().x() + 15, event->globalPos().y() + 15);
|
|
|
|
move(event->globalPos().x() + 15, event->globalPos().y() + 15);
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
@ -59,7 +59,7 @@ bool CursorTracker::eventFilter(TQObject* object, TQEvent* _event) {
|
|
|
|
|
|
|
|
|
|
|
|
case TQEvent::MouseButtonRelease: {
|
|
|
|
case TQEvent::MouseButtonRelease: {
|
|
|
|
TQMouseEvent* event=TQT_TQMOUSEEVENT(_event);
|
|
|
|
TQMouseEvent* event=TQT_TQMOUSEEVENT(_event);
|
|
|
|
if ( !TQT_TQRECT_OBJECT(widget->rect()).contains(event->pos()) ) {
|
|
|
|
if ( !widget->rect().contains(event->pos()) ) {
|
|
|
|
hide();
|
|
|
|
hide();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|