[SailfishDevel] SDK auto setter/getter

Dylan Van Assche dylan.van.assche at protonmail.com
Mon Oct 30 17:45:14 UTC 2017


Hi Martin,

Now it works! Thanks, my life just got a lot easier.

Kind regards,
Dylan Van Assche

> -------- Original Message --------
> Subject: RE: [SailfishDevel] SDK auto setter/getter
> Local Time: 30 October 2017 10:18 AM
> UTC Time: 30 October 2017 09:18
> From: martin.kampas at jolla.com
> To: Dylan Van Assche <dylan.van.assche at protonmail.com>, Sailfish OS Developers <devel at lists.sailfishos.org>
>
> Hi Dylan,
>
> Tried with Sailfish OS SDK 1709 on Linux. It works for me. Whenever I had cursor on the identifier (not after semicolon or before preceding space) the menu popped up on ALT+ENTER. It didn't pop up when the getter and setter already existed.
>
> BR,
> Martin
>
> ---------------------------------------------------------------
>
> From: Devel [devel-bounces at lists.sailfishos.org] on behalf of Dylan Van Assche via Devel [devel at lists.sailfishos.org]
> Sent: Friday, October 27, 2017 6:03 PM
> To: Sailfish OS Developers mailing list
> Subject: [SailfishDevel] SDK auto setter/getter
>
> Hi,
>
> I'm rewriting my Sailfish OS apps with a C++ backend by following the encapsulation rules.
> This implies that I need a get/set for each C++ class so I searched online if QtCreator cannot generate these automatically and it should do it: https://stackoverflow.com/questions/21142940/how-to-make-getter-and-setter-methods-in-qt-creator-automatically
> However, the Sailfish OS QtCreator doesn't seem to do this when I press ALT + ENTER on a member variable, the same for the Refactor option.
>
> Is it disabled or am I doing something wrong?
> Writing each setter/getter myself takes a lot of time...
>
> Kind regards,
> Dylan Van Assche
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.sailfishos.org/pipermail/devel/attachments/20171030/9dd436c2/attachment.html>


More information about the Devel mailing list