| 60 | { |
| 61 | Q_D(const ElaLineEdit); |
| 62 | return d->_pIsClearButtonEnable; |
| 63 | } |
| 64 | |
| 65 | void ElaLineEdit::focusInEvent(QFocusEvent* event) |
| 66 | { |
| 67 | Q_D(ElaLineEdit); |
| 68 | Q_EMIT focusIn(this->text()); |
| 69 | if (event->reason() != Qt::PopupFocusReason) |
| 70 | { |
| 71 | if (d->_pIsClearButtonEnable) |
| 72 | { |
| 73 | setClearButtonEnabled(true); |
| 74 | } |
| 75 | } |
| 76 | QLineEdit::focusInEvent(event); |
| 77 | update(); |
| 78 | } |
| 79 | |
| 80 | void ElaLineEdit::focusOutEvent(QFocusEvent* event) |
| 81 | { |
| 82 | Q_D(ElaLineEdit); |
| 83 | Q_EMIT focusOut(this->text()); |
| 84 | if (event->reason() != Qt::PopupFocusReason) |
| 85 | { |
| 86 | if (d->_pIsClearButtonEnable) |
nothing calls this directly
no outgoing calls
no test coverage detected