Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

System tray custom click function #3201

Open
2 tasks done
GavinTan opened this issue Aug 11, 2022 · 5 comments
Open
2 tasks done

System tray custom click function #3201

GavinTan opened this issue Aug 11, 2022 · 5 comments

Comments

@GavinTan
Copy link

Checklist

  • I have searched the issue tracker for open issues that relate to the same feature, before opening a new one.
  • This issue only relates to a single feature. I will open new issues for any other features.

Is your feature request related to a problem?

The left mouse button and right button click on the tray icon by default to display the menu. If you want to customize the left and right click and double click to achieve different functions, no relevant methods have been found.

Is it possible to construct a solution with the existing API?

No response

Describe the solution you'd like to see.

System tray supports custom click events

@andydotxyz
Copy link
Member

Probably depends upon fyne-io/systray#23.
Though it also needs a use-case to fulfil a Fyne feature request, otherwise it could be confusing to users as some OS assume a popup from the icon on tap.

@Roemer
Copy link
Contributor

Roemer commented Jul 21, 2023

Also specifying a function for a double click would be great as Windows users expect the application to show when the tray icon is double-clicked in most cases.

@andydotxyz
Copy link
Member

If the expectation is to set up the app to show on double click for Windows maybe we should do that.
Different platforms have different expectations for these interactions so exposing the actual events may not be the best way to deliver a cross platform consistent experience.

@ZHOUYue67
Copy link

I have a use case for exposing the click event/action:

I show some running status as menu items in tray menu. I want to be able to refresh the latest states when user click the systray icon.

@andydotxyz
Copy link
Member

I want to be able to refresh the latest states when user click the systray icon.

Why would you not refresh the display when the state changes, instead of requiring the user to interact to see its update?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants