currently on Big Sur beta 9, wanted to know if there is a way to set a trackpad gesture or touchbar button to open apples new control center without having to constantly clicking it on the top bar?
you can use the "run apple script" action to do that with a script like this:
tell application "System Events" to click menu bar item "Control Centre" of menu bar 1 of application process "ControlCenter"
I'll soon add a predefined action to open the Control Center at the current mouse location.
You solved so many scripting issues I had here by telling me how to script that part of the menu bar, you made my evening WAY better
The best trick to find that kind of stuff:
- Open Automator App
- Create a new workflow
- Click the record button
- Perform the action you want to do with Apple Script
- Stop the recording
- Automator will show a list of events, you can select them and press cmd+c, it will copy real Apple Script to your clipboard (the scripts might look weird, but they help a lot with understanding things)
And after saving the evening, the man saves the day! Never knew this could be done!!! (Transforming Automator Actions into Apple Script)
Just stumbled upon this thread- looking for the same answer. Being in the US, I had to change the script "Control Centre" to 'Control Center", then it worked. The predefined action 'show control center' never worked, which is what lead me here. I wonder if for the same reason.
doesn't seem to be working when in full screen mode or on another desktop space. also not woking as a named trigger or keyboard shortcut