fix issues with network task left running

stop the network activity when main window shows and on failed to
connect, disable media player pause if can't connect