tray

C# - Calling function from another form

一曲冷凌霜 提交于 2020-04-30 07:51:08
问题 I need a tray notify from another form. ControlPanel.cs (default form, notifyicon here): ... public partial class ControlPanel : Form { public string TrayP { get { return ""; } set { TrayPopup(value, "test");} } public void TrayPopup(string message, string title) { TrayIcon.BalloonTipText = message; TrayIcon.BalloonTipTitle = title; TrayIcon.ShowBalloonTip(1); } Form1.cs (another form): ... public partial class Form1 : Form { public ControlPanel cp; .... private void mouse_Up(object sender,

Electron App Error: EACCES: permission denied, open

帅比萌擦擦* 提交于 2020-01-07 05:28:12
问题 [20:25:45] Using gulpfile ~/Desktop/GitHub/electra/gulpfile.js [20:25:45] Starting 'build-client-bundles'... [20:25:45] Starting 'build-client-scss'... [20:25:45] Starting 'build-client-html'... [20:25:45] Starting 'build-client-assets'... [20:25:45] Starting 'build-server'... [20:25:45] Starting 'watch-client'... [20:25:45] Finished 'watch-client' after 16 ms [20:25:45] Starting 'watch-server'... [20:25:45] Finished 'watch-server' after 1.58 ms [20:25:45] Starting 'watch'... [20:25:45]

How to always show program tray icons in Windows by *default*?

元气小坏坏 提交于 2019-12-30 04:21:21
问题 If a program is executed for the first time in Windows 7, it automatically hides the icon. Is there any manifest setting or option to force Windows 7 to always show the icon by default? 回答1: In .NET Rocks podcast, not long time ago, Kate Gregory from Microsoft was saying that it is impossible. She said something like: "If user wants it (tray icon) he/she will put it there". Reason for this is to prevent mess in the tray area. 回答2: If you really want to show your tray-icon, you can popup a

Detect if Windows closing or application tries to close from system menu (WM_CLOSE)

不打扰是莪最后的温柔 提交于 2019-12-30 02:09:12
问题 I'm having Tray application. Onj FormCloseQuery I check if program should goto tray and instead of closing it I put it in tray (CanClose := False) But if Windows tries to close my application because of Windows shutdown I want not to move my app into tray but to close it. Win7 terminates my app, but XP doesn't close because my app remains in Tray. How can I detect if Windows is some "shutting down" mode or not? Thanks! 回答1: Your problems stem from the use of OnCloseQuery which is the wrong

How do I get a PopupMenu to show up when I left-click on a TrayIcon in Java?

柔情痞子 提交于 2019-12-29 01:31:06
问题 Currently, the PopupMenu will show up when I right-click on the TrayIcon in the SystemTray. However, I want it to do the same when I left-click on the TrayIcon. I thought I might accomplish this by using a mouseListener on the TrayIcon, but I don't know what method to invoke in the mouseClicked event to achieve the desired results. icon = new TrayIcon(img, tooltip, popup); icon.addMouseListener( new MouseAdapter() { public void mouseClicked(MouseEvent e) { popup.setEnabled(true); } }); Using

MS Windows- Main window no response when show menu on a tray notify icon(use a hidden window to process message)

こ雲淡風輕ζ 提交于 2019-12-25 10:54:11
问题 I implemented an class, this class will show an tray icon. to handle the message from the icon, I have to create a hidden window. Eevery thing works fine, except if You click outside of the icon, icon will not disappear. I have fixed this by adding code below: SetForegroundWindow(message-only-hiden-window) // added TrackPopupMenu() RESOLUTION:To correct the first behavior, you need to make the current window the foreground window before calling TrackPopupMenu or TrackPopupMenuEx. Now I get

Java Look-And-Feel for Tray Messages on Ubuntu

人走茶凉 提交于 2019-12-24 04:07:36
问题 I'm displaying messages on the system tray via trayIcon.displayMessage(...) but they don't look nice. I tried to change their look and feel to the system standard, but calling UIManager.setLookAndFeel(...) before creating the icon didn't change anything. UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName()); tray = SystemTray.getSystemTray(); popup = new PopupMenu(); trayIcon = new TrayIcon(image, "Tray Demo", popup); tray.add(trayIcon); trayIcon.displayMessage("Tray Test",

Tkinter: How to make a system tray application?

余生颓废 提交于 2019-12-19 00:25:12
问题 i have a small application. I want my target users(windows,linux) to be able to start and exit the application from the system tray. I intend to use Tkinter because of its low footprint but, i dont know how to implement it. Can tkinter do this or are there better alternatives. I need a GUI library that won't change my 1MB program to a 5MB program. Please sample codes will be appreciated Thanks 回答1: I don't know any direct examples but I found a TCL/Tk extension to use the systray over here

Printing with advanced options (tray selection, duplex, staple)

有些话、适合烂在心里 提交于 2019-12-17 19:29:37
问题 We have a project of managing printing documents. At first I wonder why printing options couldn't be set up in single place. For example printer tray selection for first page and for other pages can be done using MS Word automation : var doc = _applicationObject.Documents.OpenNoRepairDialog(FileName: ref sourceFile, ReadOnly: ref readOnly, AddToRecentFiles: ref addToRecentFiles, Visible: ref visible); doc.PageSetup.FirstPageTray = (WdPaperTray) firstPageTrayCode; doc.PageSetup.OtherPagesTray

Start a Qt tray process without dock icon on Mac

梦想的初衷 提交于 2019-12-12 19:19:50
问题 I have a bundle with a GUI, service and tray. Note they are three separate processes. It may sound weird, the tray is a representation of the service and users can open the GUI which would create a tray if none exits. So in my GUI code I have something like below: QProcess::startDetached("my-tray"); The whole bundle is configured as the GUI is the main executable. THE PROBLEM IS: when the GUI starts a tray, I can see two icons in dock. What I want is starting the tray without any extra icon