D22512: [Dolphin] Hide tooltip instantly on key press

Piotr Dabrowski noreply at phabricator.kde.org
Thu Jul 18 21:52:53 BST 2019


pdabrowski added inline comments.

INLINE COMMENTS

> pdabrowski wrote in dolphinview.cpp:1427-1435
> Of course a single function was my initial version.
> But then I got errors for connect()s:
> 
>   connect(m_container->horizontalScrollBar(), &QScrollBar::valueChanged, this, &DolphinView::hideToolTip);
>   connect(m_container->verticalScrollBar(), &QScrollBar::valueChanged, this, &DolphinView::hideToolTip);
> 
> 
> 
>   error: static assertion failed: Signal and slot arguments are not compatible.
> 
> Tried solving this with SLOT(), default argument, separate overloaded function with no arguments.
> But to no avail.
> 
> It seems that will require QOverload in every connect() call:
> 
>   connect(m_container->horizontalScrollBar(), &QScrollBar::valueChanged, this, QOverload<>::of(&DolphinView::hideToolTip));
>   connect(m_container->verticalScrollBar(), &QScrollBar::valueChanged, this, QOverload<>::of(&DolphinView::hideToolTip));
> 
> Are you OK with this?

To be precise:
QOverload plus still a separate overloaded DolphinView::hideToolTip() function with no arguments,
which then calls the DolphinView::hideToolTip(...) with the default flag (in .cpp).

REPOSITORY
  R318 Dolphin

REVISION DETAIL
  https://phabricator.kde.org/D22512

To: pdabrowski, #dolphin, ngraham, elvisangelaccio
Cc: broulik, elvisangelaccio, kfm-devel, pdabrowski, aprcela, fprice, fbampaloukas, alexde, feverfew, meven, spoorun, navarromorales, firef, andrebarros, emmanuelp, mikesomov
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.kde.org/mailman/private/kfm-devel/attachments/20190718/e666966b/attachment.htm>


More information about the kfm-devel mailing list