Let’s replace the Apple’s default Touch Bar

As mentioned (http://www.martinpham.com/tunesbar-control-itunes-with-menu-bar-and-touch-bar/), I’m so happy with new Touch Bar right now.  Now I can rate songs, see song’s name, control iTunes, and also change volume, brightness right on my Touch Bar, just 1 step, no-submenu-no-shit.

But soon I realized, I don’t have an Esc button!

Well, it’s a bit stupid when you don’t have Esc button. Although you can still call it with Fn button

But non ha senso! 

I decided to do some more reverse engineerings into Apple’s stuffs, and nothing about Display the Esc button on Touch Bar, instead of the sick-(x)-button.

But .. Hey, since the default Touch Bar layout sucks. Totally useless buttons on the left side (App Control), and limited buttons on the right side (Control Strip), I swear you will never bother with App Control buttons. So Why not redesign ALL the Touchbar layout?

I quickly found an interesting API
+ (void)presentSystemModalFunctionBar: (id)arg1 placement: (long long)arg2 systemTrayItemIdentifier: (id)arg3;

With placement = 0, your Touch Bar will live along with others. But with placement = 1, guess? Your Touch Bar replace everything and become the only view! Like only you on this planet 😉

Eccola!

My Esc button came back!! ♥️♥️♥️

But of course, I don’t want to miss the Touch Bar of other apps (TouchBar Piano is one of my favorite). Well, I’m gonna add app filter, so my new awesome Touch Bar only shows on whitelisted apps.

Updated 2017/07/24: Changed the ugly slider button

TunesBar

5 Replies to “Let’s replace the Apple’s default Touch Bar”

  1. Hi Martin, I was wondering if I could interview you for a story on your Touch Bar post. It is very interesting and I disagree when you say “Just another boring website.” My email is david@cultofmac.com. What is the best way to connect with you? Thanks so much.
    Sincerely,
    David Pierini
    Cult of Mac

    1. Hi Matt, I’m gonna update it soon with the installer (to install additional helper, like brightness control, screenshot,..). Keep in touch 🙂

  2. Is any of your code available as open source? Love the idea of messing around with the touchbar, would love to see some idea of how it works.

Leave a Reply

Your email address will not be published. Required fields are marked *