本文整理汇总了C++中MythMainWindow::installEventFilter方法的典型用法代码示例。如果您正苦于以下问题:C++ MythMainWindow::installEventFilter方法的具体用法?C++ MythMainWindow::installEventFilter怎么用?C++ MythMainWindow::installEventFilter使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类MythMainWindow
的用法示例。
在下文中一共展示了MythMainWindow::installEventFilter方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: main
//.........这里部分代码省略.........
WriteDefaults();
// Refresh Global/Main Menu keys after DB update in case there was no DB
// when they were written originally
mainWindow->ResetKeys();
InitJumpPoints();
internal_media_init();
CleanupMyOldInUsePrograms();
pmanager = new MythPluginManager();
gContext->SetPluginManager(pmanager);
if (pluginname.size())
{
if (pmanager->run_plugin(pluginname) ||
pmanager->run_plugin("myth" + pluginname))
{
qApp->exec();
return GENERIC_EXIT_OK;
}
else
return GENERIC_EXIT_INVALID_CMDLINE;
}
MediaMonitor *mon = MediaMonitor::GetMediaMonitor();
if (mon)
{
mon->StartMonitoring();
mainWindow->installEventFilter(mon);
}
NetworkControl *networkControl = NULL;
if (gCoreContext->GetNumSetting("NetworkControlEnabled", 0))
{
int networkPort = gCoreContext->GetNumSetting("NetworkControlPort", 6545);
networkControl = new NetworkControl();
if (!networkControl->listen(QHostAddress::Any,networkPort))
VERBOSE(VB_IMPORTANT,
QString("NetworkControl failed to bind to port %1.")
.arg(networkPort));
}
#ifdef __linux__
#ifdef CONFIG_BINDINGS_PYTHON
HardwareProfile *profile = new HardwareProfile();
if (profile && profile->NeedsUpdate())
profile->SubmitProfile();
delete profile;
#endif
#endif
if (!RunMenu(themedir, themename) && !resetTheme(themedir, themename))
{
return GENERIC_EXIT_NO_THEME;
}
#ifndef _MSC_VER
// Setup handler for USR1 signals to reload theme
signal(SIGUSR1, &signal_USR1_handler);
// Setup handler for USR2 signals to restart LIRC
signal(SIGUSR2, &signal_USR2_handler);