crissNb / Dynamic-Island-Sketchybar

Dynamic Island on iPhone 14 Pro implementation on Mac using Sketchybar
MIT License
427 stars 22 forks source link

Specify which monitor to use for dynamic island #40

Closed priyanshuppal closed 1 year ago

priyanshuppal commented 1 year ago

Hey. I have started building a new setup where i am using my macbook as my secondary display. is there a way to only keep sketchbar on the macbook even if the primary display is the monitor.

crissNb commented 1 year ago

I thought this would be an easy implementation I could do by changing display property of SketchyBar. Although this technically positions the Dynamic Island to the correct display, it seems like the animation only plays whenever the monitor is in the focus. I believe this is happening because I'm using a "popup" item for the islands. I always thought of not using "popup" item in hindsight, it seems like now is the right time to actually make the change.

I believe making this change also has a potential in resolving #39 as well as better config.

priyanshuppal commented 1 year ago

even if it doesn't work while its unfocused, i just want to keep it on the macbook because it looks weird on the monitor lol would be nice if it could work while it was unfocused. could it be the --default updates=when_shown property in the config.sh file?

crissNb commented 1 year ago

As of right now, this feature cannot be used with the current configuration file. I don't plan on specifically implementing this feature and making changes to the configuration file at the moment, mostly because I'll be making major configuration changes anyway (with the changes that will fix the animations completely).

If you'd like to have the island shown on your second screen right now, you'll need to modify the source code directly. You can do this in item.sh. Under sketchy_bar, add the following

display=2

Where 2 is the id of your display (so in this case it would be using your secondary display).

You may also need to remove the line where associated_display for the island is set (same item.sh file).

crissNb commented 1 year ago

This has now been implemented properly with the latest config changes. This, however requires you to update the configuration file entirely. A clean reinstallation is recommended.