Bug ID 1188923
Summary Mate-Panel system-tray shows double icons for NetworkManager-applet
Classification openSUSE
Product openSUSE Distribution
Version Leap 15.3
Hardware x86-64
OS openSUSE Leap 15.3
Status NEW
Severity Normal
Priority P5 - None
Component Other
Assignee screening-team-bugs@suse.de
Reporter mateleap@tutanota.com
QA Contact qa-bugs@suse.de
Found By ---
Blocker ---

Created attachment 851435 [details]
Screenshot of the double icons for networkmanager applet in Mate-Panel
system-tray

Upon logging-in to Mate desktop environment on openSUSE Leap 15.3 (x86_64),
NetworkManager-applet (gtk) icon appears twice i.e. double icon in Mate-Panel
system-tray. After long search, it looks like this bug is a result of the
built-in support of libappindicator3.so.1()(64bit) for package
NetworkManager-applet-1.8.24-5.2.x86_64.rpm. This bug also can be generated in
another distribution such as Ubuntu Mate because Ubuntu's nm-applet is built
with appindicator support. However, this bug cannot be generated with Debian
because Debian's nm-applet is not built with appindicator support.

Mate-Panel could be patched to prevent this bug. I found the following code and
it could be a soultion or a work-around for this bug. I'm neither a coder not a
software developer, thus the package maintainer review on the below code is
necessary.

public void register_status_notifier_item(string service, BusName sender)
        {
            var is_path = (service[0]=='/') ? true : false;
            string path, name;
            if (is_path)
            {
                name = (string)sender;
                path = service;
            }
            else
            {
                name = service;
                path = "/StatusNotifierItem";
            }
            var id = get_id(name,path);
            if (id in name_watcher)
            {
                warning("Trying to register already registered item.
Reregistering new...");
                remove(id);
            }
            var name_handler =
Bus.watch_name(BusType.SESSION,name,GLib.BusNameWatcherFlags.NONE,
                                                ()=>{
                                                    try {
                                                        ItemIface ping_iface =
Bus.get_proxy_sync(BusType.SESSION,name,path);
                                                       
ping_iface.notify.connect((pspec)=>{
                                                            if (ping_iface.id
== null ||
                                                            ping_iface.title ==
null ||
                                                           
ping_iface.id.length <= 0 ||
                                                           
ping_iface.title.length <= 0)
                                                               
remove(get_id(name,path));
                                                        });
                                                    } catch (Error e)
{remove(get_id(name,path));}
                                                },
                                                () =>
{remove(get_id(name,path));}
                                                );
            name_watcher.insert(id,name_handler);
            status_notifier_item_registered(id);
            this.notify_property("registered-status-notifier-items");
        }


You are receiving this mail because: