def METHOD_NAME(
		isNowActive: bool,
		speechViewerFrame: Optional[SpeechViewerFrame] = None
) -> None:
	global _guiFrame, isActive
	isActive = isNowActive
	_guiFrame = speechViewerFrame
	if gui and gui.mainFrame:
		gui.mainFrame.onSpeechViewerEnabled(isNowActive)