Indicator Applet Complete & Useless right button

For a long time I used MATE on 16.04 then 17.04 and Notification Area was a very convenient tray because I use a large number of messengers. Now installed 20.04 and I'm really disappointed with how the interaction with the tray works now. Now all messengers icons are in Indicator Applet Complete and working with them is not so convenient.

  • One left click now opens the application menu, instead of just opening and minimizing its window. This is plus one useless action when you need just open or hide the window.

  • One right click opens the applet menu, instead of opening the application menu. Doesn’t matter where the right click was made, on the application icon or in the empty space between the icons, it opens the applet menu everywhere.

So I have such a question or request.
How to make the icons of applications such as Telegram, Whatsdesk etc appear in the Notification Area instead of Indicator Applet Complete without starting them with sudo?

P.S. When I starts a Telegram or Whatsdesk with sudo, its icons is displayed in the Notification Area.

I'm not sure this will work for you, but I suspect it will: As an experiment, I first want you to post the output of this command:
sudo env | grep -q 'DBUS' && echo 'That liar Gord Squash is! Environment variables for D-Bus are preserved when you sudo!' || echo 'Well, I guess Gord Squash was right! Environment variables are NOT preserved when you sudo!'

Translation: Last time I checked, the Indicator Applet uses D-Bus to communicate with applications. D-Bus is a protocol for passing messages and commands from one graphical application to another, part of the Free Desktop specification. It uses UNIX sockets to communicate with applications, in a manner not dissimilar to the way the X Protocol works, to an extent. Anyway, the Indicator Applet uses D-Bus, whereas the Notification Area uses the X Protocol. In order for applications to connect to D-Bus, a set of environment variables must be set when the application is run. Among them is the environment variable: DBUS_SESSION_BUS_ADDRESS. By default on most systems (I've tried it on Ubuntu MATE in the past and I just tried it on this Gentoo system a few seconds ago), sudo deletes certain environment variables from the command about to be run as root, because otherwise said commands could cause a lot of havoc to your setup. So sudo deletes the environment variable DBUS_SESSION_BUS_ADDRESS from the environment, and then the application run as superuser cannot connect with D-Bus. Thus the application can't use the Indicator Applet, and voila! It falls back to the X Protocol-driven Notification Area. (Most distributions of GNU / Linux, including Ubuntu MATE, add a special exception to the "unset the environment variables" rule so that sudo does not unset the environment variables involved in establishing a connection to an X server. That's why applications work at all running as superuser.)

Short version: To launch an application in the Notification Area instead of in the Indicator Applet, launch the application like this:
env --unset=DBUS_SESSION_BUS_ADDRESS [name of application here]

This might cause other problems, but let's see how that works for you.

Good luck!

Thanks for the response!

Output:
[email protected]:~$ sudo env | grep -q 'DBUS' && echo 'That liar Gord Squash is! Environment variables for D-Bus are preserved when you sudo!' || echo 'Well, I guess Gord Squash was right! Environment variables are NOT preserved when you sudo!'
[sudo] пароль для maxim:
Well, I guess Gord Squash was right! Environment variables are NOT preserved when you sudo!

Telegram
[email protected]:~env --unset=DBUS_SESSION_BUS_ADDRESS /opt/Telegram/Telegram
Gtk-Message: 09:30:31.628: Failed to load module "appmenu-gtk-module"
Didn't bring result. Telegram icon is still displayed in IA

WhatsDesk
[email protected]:~$ env --unset=DBUS_SESSION_BUS_ADDRESS whatsdesk
/bin/sh: 1: update-alternatives: Permission denied
Gtk-Message: 09:20:23.682: Failed to load module "appmenu-gtk-module"
Error in load script [events.js]: Error: An object could not be cloned.
at EventEmitter../lib/renderer/ipc-renderer-internal.ts.exports.ipcRendererInternal.send (electron/js2c/renderer_init.js:1841:20)
at EventEmitter.<anonymous> (electron/js2c/renderer_init.js:1803:26)
Error in load script [menucontextual.js]: Error: An object could not be cloned.
at EventEmitter../lib/renderer/ipc-renderer-internal.ts.exports.ipcRendererInternal.send (electron/js2c/renderer_init.js:1841:20)
at EventEmitter.<anonymous> (electron/js2c/renderer_init.js:1803:26)
And WhatsDesk icon is not displayed anywhere. Neither in IA nor in NA.

I also tried to launch a flameshot for the experiment.
[email protected]:~$ env --unset=DBUS_SESSION_BUS_ADDRESS flameshot
Gtk-Message: 09:27:18.970: Failed to load module "appmenu-gtk-module"
Icon displayed in IA

UPD
It works for skype.
env --unset=DBUS_SESSION_BUS_ADDRESS skypeforlinux
Starts skype and the icon appears in NA.

Sorry that it didn't work for you. I'll check up on it again. You said you can make any of these appear in the NA if you run them as sudo?