[Mono-bugs] [Bug 74095][Wis] Changed - Creating an Icon instance from embedded resource

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Fri, 25 Mar 2005 11:04:16 -0500 (EST)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by rogerio.araujo@gmail.com.

http://bugzilla.ximian.com/show_bug.cgi?id=74095

--- shadow/74095	2005-03-25 11:02:53.000000000 -0500
+++ shadow/74095.tmp.32309	2005-03-25 11:04:16.000000000 -0500
@@ -1,14 +1,14 @@
 Bug#: 74095
 Product: Mono: Class Libraries
 Version: 1.0
-OS: 
+OS: unknown
 OS Details: 
 Status: NEW   
 Resolution: 
-Severity: 
+Severity: Unknown
 Priority: Wishlist
 Component: Sys.Drawing.
 AssignedTo: mono-bugs@ximian.com                            
 ReportedBy: rogerio.araujo@gmail.com               
 QAContact: mono-bugs@ximian.com
 TargetMilestone: ---
@@ -55,6 +55,23 @@
 I'm attaching the patch with a proposal fix for this bug.
 
 ------- Additional Comments From rogerio.araujo@gmail.com  2005-03-25 11:02 -------
 Created an attachment (id=14764)
 The Icon patch with embedded resource support
 
+
+------- Additional Comments From rogerio.araujo@gmail.com  2005-03-25 11:04 -------
+//This piece of code can be used as testcase
+
+//setting the notify icon
+MenuItem itemOpen 	= new MenuItem("Open");
+MenuItem itemExit 	= new MenuItem("Exit");
+itemExit.Click 		+= new EventHandler(notify_menuExit);
+	
+MenuItem[] items = new MenuItem[] {itemOpen, itemExit};
+menu = new ContextMenu(items);
+		
+notify 		    = new NotifyIcon();
+notify.Icon         = new Icon(GetType(), "Namespace.Filename.ico");
+notify.Text 	    = "FtpMWF";
+notify.Visible 	    = true;
+notify.ContextMenu  = menu;