Disable buttons opening the modal forms on page unload

If button which opens a modal form is clicked after page started
reloading, form will disappear once reload is finished. To avoid this
glitch make user unable to press such buttons until reload finishes.

Change-Id: Id81a5e108644f99ee939296b54835f4f4ac2aaa7
Closes-Bug: #1357331
Merge "Disable buttons opening the modal forms on page unload"