Hi, I’m the creator of the Editor Console Pro replacement console extension. I have had numerous people ask me over the years if there was a way to capture the status bar click to open my console instead of the default Unity one, but I have always come up blank. I was wondering if anybody has any ideas on how to pull this off?
You can’t.
If you get ILSpy (or any other decompiler) you can look at the AppStatusBar class in UnityEditor namespace.
It is an internal class that handles everything, so you can’t access it. Even if you could, it is loaded from the C++ side, so you can’t replace it. Additionally, the click call is an extern call, going back to the C++ side, so again, can’t override or piggyback off of it.
They only way you might be able to do so, is to listen to the OS mouse clicks, and catch the ones that occur in the status bar. Not really a good robust way
Reviving this thread to say that I would like to know this too! The developer of Console Enhanced Pro says in the description that “ConsoleE is the only replacement console that can capture mouse clicks from Unity’s status bar.”. I haven’t confirmed it, as I don’t have the asset, but if true there’s at least one way.
UPDATE: I tested the free version and it works indeed.