Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • P Plasma PulseAudio Applet
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Bugzilla
    • Bugzilla
  • Merge requests 15
    • Merge requests 15
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • PlasmaPlasma
  • Plasma PulseAudio Applet
  • Merge requests
  • !2

WIP: Give users the ability to enable/disable the microphone indicator

  • Review changes

  • Download
  • Email patches
  • Plain diff
Open Giusy Margarita requested to merge kurmikon/plasma-pa:optional_micindicator into master May 24, 2020
  • Overview 13
  • Commits 2
  • Pipelines 0
  • Changes 6

Plasma is an high customizable desktop environment. When it comes to system tray, you can disable battery indicator, volume applet, touchpad indicator, notification applet, etc. Some of these actions are pointless, why someone would disable the volume applet not showing it, not only in the tray, but also in the dropdown menu, since it's crucial to system?

But Plasma gives you this opportunity because it's customizable. However, when it come to microphone indicator: no, you can't do nothing. It stays there, you can only hide it, but it's still present in the dropdown menu, even when you don't want it, even when you don't need it, even when it's frustrating while you're using PulseEffects and it tells you something wrong (see here and here).

Maybe you want to disable it, but unfortunately who made it didn't think to add this ability. The funny thing is that the MicrophoneIndicator class has an enabledChanged signal unused, so maybe they were planning to add the feature to enable/disable it, but that was never done.

So this MR adds this option showing a checkbox inside general configuration.

Screenshot_20200522_193809

I made different attempts to achieve this. The class was imagined like a singleton, but it's not really a singleton, anyway it's initialized by the volume applet and it stays there having only one instance.

Exposing it inside the configuration window made some issues because multiple instances where showing and, consequently, more indicators appeared in the tray.

So i modified it like a real singleton. Registering it inside the config window was correctly done but, unfortunately, the engine was destroyng the class when the window was closed, leaving the other one in the applet pointing to nowhere and the system crashed.

Then I made an interface to act on it being able to enable/disable the indicator. The engine could construct and destroy the interface many times, but the singleton is always alive.

I tested it on my system and it's working. Please, test on yours. If there's a better method to do this, discuss here, Thanks.

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: optional_micindicator