diff --git a/Telegram/SourceFiles/calls/calls_call.cpp b/Telegram/SourceFiles/calls/calls_call.cpp
index f17f378da..a421e4299 100644
--- a/Telegram/SourceFiles/calls/calls_call.cpp
+++ b/Telegram/SourceFiles/calls/calls_call.cpp
@@ -523,6 +523,14 @@ void Call::setState(State state) {
 			&& _state != State::Ringing) {
 			_waitingTrack.reset();
 		}
+		if (false
+			|| _state == State::Ended
+			|| _state == State::Failed
+			|| _state == State::Busy) {
+			// Destroy controller before destroying Call Panel,
+			// so that the panel hide animation is smooth.
+			destroyController();
+		}
 		switch (_state) {
 		case State::Established:
 			_startTime = getms(true);
@@ -539,7 +547,6 @@ void Call::setState(State state) {
 			_delegate->callFailed(this);
 			break;
 		case State::Busy:
-			destroyController();
 			_delegate->playSound(Delegate::Sound::Busy);
 			break;
 		}
diff --git a/Telegram/SourceFiles/calls/calls_panel.cpp b/Telegram/SourceFiles/calls/calls_panel.cpp
index 86cbedbd8..b46f320b9 100644
--- a/Telegram/SourceFiles/calls/calls_panel.cpp
+++ b/Telegram/SourceFiles/calls/calls_panel.cpp
@@ -671,10 +671,13 @@ void Panel::stateChanged(State state) {
 		}
 	}
 
-	if ((state == State::Starting) || (state == State::WaitingIncoming)) {
-		Platform::ReInitOnTopPanel(this);
-	} else {
-		Platform::DeInitOnTopPanel(this);
+	if (windowHandle()) {
+		// First stateChanged() is called before the first Platform::InitOnTopPanel(this).
+		if ((state == State::Starting) || (state == State::WaitingIncoming)) {
+			Platform::ReInitOnTopPanel(this);
+		} else {
+			Platform::DeInitOnTopPanel(this);
+		}
 	}
 	if (state == State::Established) {
 		if (!isActiveWindow()) {