Code Monkey home page Code Monkey logo

Comments (6)

lencx avatar lencx commented on May 18, 2024 2

I came up with a better form of interaction.

  • If the app is still in the dock there are two ways to hide it:
    • Triggered by the menu item Menu -> Preferences -> Hide Dock Icon
    • triggered by a right-click event on the system tray icon
  • When it needs to be in the dock there is only one way: it can only be restored by a right-click event on the system tray icon

Simply put, a right-click on the system tray icon is a two-way event (show ⇋ hide)

chat-hide-dock

from chatgpt.

lencx avatar lencx commented on May 18, 2024 1

This is possible, but once implemented, both dock and menu will disappear (shortcuts will still be available, but without menus as hints, it will be difficult for users to remember them). If the menu is placed on the system tray, they would be stacked on top of each other, it will affect the user experience. I haven't thought of a good form of interaction yet.

#[cfg(target_os = "macos")]
app.set_activation_policy(tauri::ActivationPolicy::Prohibited);

tray-menu

from chatgpt.

lencx avatar lencx commented on May 18, 2024 1

If a system tray right-click menu is required, it would be a simple version of:

  • Control Center
  • Show Dock icon
  • Quit

Control Center is important and I am implementing exciting features for it.

from chatgpt.

PascalPixel avatar PascalPixel commented on May 18, 2024

This is great! Some other macOS menubar apps I have that have the option to 'disable the dock icon and app switcher', seem to follow the pattern of:

  • are you sure you want this mode? restart is required (ok)
  • menu item left-click to toggle window
  • menu item right-click to get app menu

from chatgpt.

PascalPixel avatar PascalPixel commented on May 18, 2024

Thanks @lencx !

from chatgpt.

lencx avatar lencx commented on May 18, 2024

You can check out readme, which also adds more exciting features, but was released in a bit of a hurry and is not yet fully adapted in the system tray.

from chatgpt.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.