Bug 141689. Windows: change mouse handler for notifyicon to mouse down event.
This commit is contained in:
@@ -71,7 +71,8 @@ namespace Novell.CASA.GUI
|
||||
notifyIcon = new System.Windows.Forms.NotifyIcon();
|
||||
try
|
||||
{
|
||||
s = File.OpenRead("../images/CASAIcons.ico");
|
||||
//s = File.OpenRead("../images/CASAIcons.ico");
|
||||
s = File.OpenRead("D:/brandi/Client/App.ico");
|
||||
m_iconNormal = new System.Drawing.Icon(s);
|
||||
notifyIcon.Icon = m_iconNormal;
|
||||
}
|
||||
@@ -113,8 +114,9 @@ namespace Novell.CASA.GUI
|
||||
}
|
||||
}
|
||||
//notifyIcon.Click +=new EventHandler(notifyIcon_Click);
|
||||
notifyIcon.DoubleClick +=new EventHandler(notifyIcon_DoubleClick);
|
||||
notifyIcon.MouseUp +=new System.Windows.Forms.MouseEventHandler(notifyIcon_MouseUp);
|
||||
notifyIcon.DoubleClick +=new EventHandler(notifyIcon_DoubleClick);
|
||||
notifyIcon.MouseDown += new System.Windows.Forms.MouseEventHandler(notifyIcon_MouseDown);
|
||||
|
||||
notifyIcon.Visible = true;
|
||||
|
||||
UpdateTrayIcon(MiCASAStore.IsLocked());
|
||||
@@ -238,11 +240,13 @@ namespace Novell.CASA.GUI
|
||||
Application.Quit(); // quits the application when the users clicks the popup menu
|
||||
}
|
||||
#if W32
|
||||
private void notifyIcon_MouseUp(object sender, System.Windows.Forms.MouseEventArgs e)
|
||||
{
|
||||
|
||||
private void notifyIcon_MouseDown(object sender, System.Windows.Forms.MouseEventArgs e)
|
||||
{
|
||||
if (e.Button == System.Windows.Forms.MouseButtons.Right)
|
||||
ShowContextMenu();
|
||||
ShowContextMenu();
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
public void CasaManagerQuit()
|
||||
@@ -345,6 +349,6 @@ namespace Novell.CASA.GUI
|
||||
#endif
|
||||
Application.Quit();
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user