Unity Editor breaks after some time

I’m using Unity 5 and I’m experiencing annoying bug. I think it happens after compiling scripts or importing assets.

So basically my Inspector window locks down to the object that was selected when the bug occured. After that I cannot select any other GameObjects: they will get highlighted in Hierarchy but Inspector shows the initial GameObject. If I change scene at this point, hierarchy changes but nothing else happens. Scene, game and inspector views show the initial scene and GameObject.

In order to fight this bug I have to restart Unity like once an hour. It gets very annoying.

Are you locking the window? There’s a small padlock at the top of many windows that can be used to lock the contents so that you can select something else and drag it in, for instance.