﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	severity	resolution	keywords	cc	mlocked
9537	MediaMonitor JumpTo plugin broken in commit ed4d961aed836fade236d006b2797f0c044970de	Lawrence Rust <lvr@…>	stuartm	"In commit ed4d961aed836fade236d006b2797f0c044970de the call to GetMythMainWindow()->JumpTo(""Main Menu"") was moved from MediaMonitor::JumpToMediaHandler into the plugins MythMusic, MythVideo & MythGallery.

However, JumpTo() doesn't complete synchronously, it calls QCoreApplication::postEvent to do the work.  When the plugin starts its event loop it finds the jump event and immediately exits without playing the inserted media.

It is necessary to execute the following code after calling JumpTo():
{{{
    GetMythMainWindow()->JumpTo(""Main Menu"");
    QTime t; t.start();
    while (GetMythMainWindow()->IsExitingToMain() && t.elapsed() < 2000)
        qApp->processEvents(); // Ensure jump is executed before calling handler

}}}

Because of this it may be preferable to keep the call to JumpTo() in MediaMonitor::JumpToMediaHandler and append the above code rather than replicate it in all plugins."	Bug Report - General	closed	minor	0.28	MythTV - General	Master Head	medium	Invalid			0
