Bug 14976 - NotifyIcon does not show up
Summary: NotifyIcon does not show up
Status: NEW
Alias: None
Product: Class Libraries
Classification: Mono
Component: Windows.Forms (show other bugs)
Version: 3.2.x
Hardware: PC Linux
: Lowest normal
Target Milestone: Community
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2013-09-24 23:25 UTC by datnhanlz
Modified: 2017-09-01 11:56 UTC (History)
3 users (show)

See Also:
Tags:
Is this bug a regression?: ---
Last known good build:


Attachments
Remove the line from sources (1.05 KB, patch)
2015-06-04 15:00 UTC, Arsen.Shnurkov
Details

Description datnhanlz 2013-09-24 23:25:38 UTC
System.Windows.Forms.NotifyIcon does not show up in the systray (Tested on OS: Fedora, Arch. DE: MATE, Cinnamon)
When I try to fix the problem, I found the following line of code cause the bug:

File: XplatUIX11.cs, method: SystrayAdd, line: 6024
XChangeProperty(DisplayHandle, hwnd.whole_window, _XEMBED_INFO, _XEMBED_INFO, 32, PropertyMode.Replace, atoms, 2);

When I commented out (removed) the line aboved. The icon show up correctly in the systray. Right-click also works as expected. Only minor problem is that the mouse cursor change slightly (I think it change to XServer cursor???)

Because I am a newbie to Linux, hence, I have no knowledge about XServer. I am not sure what that line of code for. I stopped my effort here and report this as a bug in the hope that the experts can fix this faster than me. Personally, I will run my application without that line of code.

(It seems simple, but cost me a lot of time. Trying countless time to compile Mono, MonoDevelop on Fedora to get the latest version of Mono, but always fail. Eventually, I installed Arch Linux to get the newest Mono 3.2.x, and found out the problem still there :D)

Sorry for my English.
Comment 1 Miguel de Icaza [MSFT] 2014-02-12 17:27:06 UTC
Setting priority to lowest, since Windows.Forms is no longer being developed actively.
Comment 2 Arsen.Shnurkov 2015-06-04 15:00:49 UTC
Created attachment 11467 [details]
Remove the line from sources

I have the same behaviour as in this bug (on Calculate Linux/LXDE). Removing that line helps from the first sight. I tested on the sample https://github.com/mono/winforms/blob/master/notifyicon/swf-notifyicon.cs
Comment 3 Timotheus Pokorra 2016-06-27 07:22:39 UTC
possibly duplicate of https://bugzilla.xamarin.com/show_bug.cgi?id=8935

the patch works so far, only on i3 with i3bar extension problems have been reported (https://bugzilla.redhat.com/show_bug.cgi?id=1284609#c14)

Notice (2018-05-21): bugzilla.xamarin.com will be switching to read-only mode on Thursday, 2018-05-25 22:00 UTC.

Please join us on Visual Studio Developer Community and GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs and copy them to the new locations as needed for follow-up. The See Also field on each Bugzilla bug will be updated with a link to its new location when applicable.

After Bugzilla is read-only, if you have new information to add for a bug that does not yet have a matching issue on Developer Community or GitHub, you can create a follow-up issue in the new location. Copy and paste the title and description from this bug, and then add your new details. You can get a pre-formatted version of the title and description here:

In special cases you might also want the comments:

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Note You need to log in before you can comment on or make changes to this bug.