Hide purple icon in window recording
Did latest versions of Sonoma break this?
let frontAppId = frontOnly ? NSWorkspace.shared.frontmostApplication?.processIdentifier : nil
// in sonoma, there is a new new purple thing overlaying the traffic lights, I don't really want this to show up.
// its title is simply "Window", but its bundle id is the same as the parent, so this seems like a strange bodge..
return availableContent!.windows.filter {
guard let app = $0.owningApplication,
let title = $0.title, !title.isEmpty else {
return false
}
return !excludedWindows.contains(app.bundleIdentifier)
&& !title.contains("Item-0")
&& title != "Window"
&& (!frontOnly
|| frontAppId == nil // include all if none is frontmost
|| (frontAppId == app.processID))
}
Just curious, what did you use to inspect and find the title of this icon? It's annoying Apple stick this on the window title bar, it's already in the MenuBar!
Quartz Debug has a nice window list hidden inside of it
Hi! I don't think this has changed in any recent update. The comment should probably be clearer, though. What this does is remove the purple overlays from the list of windows by filtering away its title, "Window" (very generic..). The "Window" "window" would otherwise show up in the list of available windows for an app if you're already recording it with another application - fairly certain that is where I found the mention of it. Then by temporarily changing the display title from the window's title to its owningApplication's bundle identifier I could get that info.
The window itself has a grey version of the overlay which I think is actually a part of the window (the traffic lights are replaced as far as I can tell?), so I don't think you can get rid of it unfortunately
Ah, I understand. Such a pain Apple adds this icon (I kind of get why they want it clear to the ussr ), it is already in the menubar.
Im using your app as a base to create something we can use to consistantly record a window at a fixed size for some demo videos we are making. Your app is a great starting point, so thanks! We will put in some PR's at some point. I have also tidied up the settings window.
Please let us know if you ever figure out a way of getting rid of the purple icon thing!
Cheers! Will do