[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-devel
Subject: Re: KF6 porting. KSelectAction::triggered signal
From: Albert Astals Cid <aacid () kde ! org>
Date: 2024-01-03 22:24:18
Message-ID: 3210963.57advpyson () xps15
[Download RAW message or body]
El dimecres, 3 de gener de 2024, a les 9:01:11 (CET), Sune Vuorela va
escriure:
> Hi
>
> I just - during KF6 porting of an app - fall in an api trap:
>
> Original code:
> | connect(d->aZoom, QOverload<QAction *>::of(&KSelectAction::triggered),
> | this, &PageView::slotZoom);
>
> The wrong porting code:
> | connect(d->aZoom, &KSelectAction::triggered, this, &PageView::slotZoom);
>
> The gotcha is that the QAction* overload, while with the same name, is
> emitted under different rules than the only remaining triggered function
> (from QAction)
>
> The correct porting would have been:
> | connect(d->aZoom, &KSelectAction::actionTriggered, this,
> | &PageView::slotZoom);
>
> So, just a heads up to whomever might hit this as well. (I wonder if one
> has enough sources checked out to be able to grep this to see what might
> be relevant.
scripty has everything checked out so if you tell me what to grep for, I can
run a query on it.
Cheers,
Albert
>
> /Sune
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic