Feature/system76 power integration#313
Conversation
|
I tried to keep the pattern made with the PPD, when creating the backend for the system76-power. Reason for me to do this PR was I LOVED the ideia of automatics switches in the MSI User Mode when the Power Profile is changed. I'm not using PPD (of course kk) so if someone with PPD wants to make a feedback if still working in your system, great! @mutchiko , tried to not break nothing you did. |
maybe you should tell them to add it, since they are trying to replace PPD they could at least try to replicate it's behavior |
|
can you at least make a separate PR for the translation? since different from the main idea of this PR |
|
Yes, i can do that. |
The 'Follow system's power profile' option now tries the native com.system76.PowerDaemon D-Bus interface first and falls back to Power Profiles Daemon/TuneD when system76-power is not available. Translation catalogs refreshed with lupdate.
fe72148 to
4991c90
Compare
|
Hi! I've reworked the branch into a single clean commit — could you take a look and let me know if it's good now? A note on the translation files: although 16
The only real translation included is the pt_BR entry for the new error message, since that string is introduced by this PR. I'll submit the full pt_BR catalog update as a separate PR to keep this one focused on the system76-power integration. |
|
Looking at this PR again, you should fix the system76-power compatibility layer instead of fixing this app. also we cannot implement methods for each power management solution on linux. PPD protocol is the main one, if others expose compatibility layers, they should behave like the original and send So i highly recommend that you open an issue there and tell them about it, you can even link to this repo as a proof. |
Additionally, system76-power registers a PPD compatibility layer on D-Bus (
net.hadess.PowerProfiles), which madeconnectToPowerProfiles()succeed — but the compatibility layer does not emitPropertiesChangedsignals when the profile changes, so the shift mode was never updated. That's why I added native system76-power D-Bus integration viacom.system76.PowerDaemonservice, listening to thePowerProfileSwitchsignal, then changed the connection priority: try system76-power first (native), then fall back to PPDPerformance→ High Performance,Balanced→ Balanced,Battery→ Super BatteryChanges
src/powermonitor.h— Added system76-power methods and slot declarationssrc/powermonitor.cpp— Implemented connect/disconnect/query/signal handler/parser for system76-powersrc/mainwindow.cpp— Prioritize system76-power over PPD, added disconnect callssrc/i18n/MControlCenter_pt_BR.ts— Completed pt_BR translation (80/80 strings)