Can't Edit Files in Android Studio
This appears to be that the Code view loses focus to the Project view. That's why I can't edit the code and the search box appears: because The focus is with the Project view, permanently.
I couldn't find a permanent solution. However, by accident, I found a workaround that is less annoying than restarting Android Studio:
When you lose focus to the Project view, click on the far right of the Code View, where the scrollbar exist.
I tried to figure out what causes the Project View to steal the focus permanently but I couldn't. Until someone do, this will be the accepted answer.
click on vertical scroll bar area to get focus in project view
I have faced same problem and tried some of the solutions above. None of worked for me. After File
-> Invalidate Caches/Restart
the problem have been solved.