Pārlūkot izejas kodu

UI: Do not show tray icon if not active

Because the virtual camera stops immediately when you call
obs_output_stop() rather than with a delay like other outputs, it
exposed a bug where the tray icon would show OBS as active when stopping
the source, regardless of the fact that it was stopped.  The bug was
that the expression used to activate the tray icon did not check to make
sure that the output was actually active, so add that to the expression.
jp9000 5 gadi atpakaļ
vecāks
revīzija
4869167f5c
1 mainītis faili ar 2 papildinājumiem un 1 dzēšanām
  1. 2 1
      UI/window-basic-main.cpp

+ 2 - 1
UI/window-basic-main.cpp

@@ -5589,7 +5589,8 @@ inline void OBSBasic::OnDeactivate()
 		if (trayIcon && trayIcon->isVisible())
 			trayIcon->setIcon(QIcon::fromTheme(
 				"obs-tray", QIcon(":/res/images/obs.png")));
-	} else if (trayIcon && trayIcon->isVisible()) {
+	} else if (outputHandler->Active() && trayIcon &&
+		   trayIcon->isVisible()) {
 		if (os_atomic_load_bool(&recording_paused))
 			trayIcon->setIcon(QIcon(":/res/images/obs_paused.png"));
 		else