MainWindow: Fix menu entry for log dock widget

Simplify the log window handling a little bit.

Fix a bug that caused the log window to disappear when the window was
minimised.