[Differential] [Commented On] D2419: [backlight helper] Support setting backlight through leds subclass

broulik (Kai Uwe Broulik) noreply at phabricator.kde.org
Fri Aug 12 09:04:11 UTC 2016


broulik added inline comments.

INLINE COMMENTS

> backlighthelper.cpp:102
> +    ledsFilters << QStringLiteral("*lcd*") << QStringLiteral("*wled*");
> +    ledsDir.setNameFilters(ledsFilters);
> +

You could simplify this to ledsDir.setNameFilters({QStringLiteral("*lcd*"), QStringLiteral("*wled*")});

> backlighthelper.cpp:122
> +    if (!ledInterfaces.isEmpty()) {
> +        m_dirname = LED_SYSFS_PATH + ledInterfaces.first();
>          return;

Either make ledInterfaces const or use constFirst here (I know the existing code does it wrong)

REPOSITORY
  rPOWERDEVIL Powerdevil

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

EMAIL PREFERENCES
  https://phabricator.kde.org/settings/panel/emailpreferences/

To: bshah, #plasma, broulik
Cc: plasma-devel, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20160812/fa1e18ba/attachment.html>


More information about the Plasma-devel mailing list