Skip to content
This repository has been archived by the owner on Sep 17, 2021. It is now read-only.

Option to highlight active app #45

Open
iamLoi opened this issue May 11, 2019 · 5 comments
Open

Option to highlight active app #45

iamLoi opened this issue May 11, 2019 · 5 comments

Comments

@iamLoi
Copy link

iamLoi commented May 11, 2019

Hi,

Thanks for creating this, amazing utility! I was wondering if a good feature would be an option to highlight active app in the dock. Currently one can add the active app widget, but that takes up space which can be used for other widgets. How about an option to highlight the currently active app on the dock icons itself (for example, with a gray background)?

Thanks

@billziss-gh
Copy link
Owner

@iamLoi that is a good idea! I am wondering if you would like to take a stab at it?

@iamLoi
Copy link
Author

iamLoi commented May 14, 2019

@iamLoi that is a good idea! I am wondering if you would like to take a stab at it?

I can try, although I have no previous experience with Objective-C. If I can have some pointers on which methods/classes which codes the icons on the dock and its status, I can tinker around but it may take a while.

@billziss-gh
Copy link
Owner

The code for the Dock widget is in DockWidget.m.

The code is unfortunately not straightforward, but perhaps the most important class for your task is DockWidgetItemView. You could perhaps add a new active property that visually modifies the widget by adding a border or other visual effect. The code already has an example of adding a shadow for "prominent" views, which are views that can accept dragged files (e.g. when you drag a file from your desktop into the touch bar).

@iamLoi
Copy link
Author

iamLoi commented May 15, 2019

Thanks for directing to the specific class! I will take look.

@iamLoi
Copy link
Author

iamLoi commented May 17, 2019

I've cloned the project into Xcode and made some minor changes, how do I run it in a simulator type environment where I can see the changes I've made live?

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

No branches or pull requests

2 participants