/*------------------------------------------------------------------------------
|    OpenMAXILPlayerControl::onItemSceneChanged
+-----------------------------------------------------------------------------*/
void OpenMAXILPlayerControl::onItemSceneChanged()
{
   QQuickWindow* window = m_quickItem->window();
   if (!window)
      return;

   connect(window, SIGNAL(sceneGraphInitialized()),
           this, SLOT(onSceneGraphInitialized()), Qt::DirectConnection);
   connect(window, SIGNAL(afterRendering()),
           this, SLOT(onAfterRendering()), Qt::DirectConnection);

   window->update();
}
/*------------------------------------------------------------------------------
|    OpenMAXILPlayerControl::onItemSceneChanged
+-----------------------------------------------------------------------------*/
void OpenMAXILPlayerControl::onItemSceneChanged()
{
   LOG_DEBUG(LOG_TAG, "Getting window...");
   QQuickWindow* window = m_quickItem->window();
   if (!window) {
      LOG_ERROR(LOG_TAG, "Failed to get QQuickWindow.");
      return;
   }

   connect(window, SIGNAL(sceneGraphInitialized()),
           this, SLOT(onSceneGraphInitialized()), Qt::DirectConnection);
   connect(window, SIGNAL(afterRendering()),
           this, SLOT(onAfterRendering()), Qt::DirectConnection);
   window->update();
}