mirror of
https://github.com/parchlinux/calamares.git
synced 2025-06-28 09:55:37 -04:00
[libcalamaresui] Load QML on startup
This commit is contained in:
parent
5973dbf74c
commit
ff03235e33
2 changed files with 9 additions and 2 deletions
|
@ -69,6 +69,7 @@ ExecutionViewStep::ExecutionViewStep( QObject* parent )
|
|||
innerLayout->addWidget( m_label );
|
||||
|
||||
cDebug() << "QML import paths:" << Logger::DebugList( m_qmlShow->engine()->importPathList() );
|
||||
loadQml();
|
||||
|
||||
connect( JobQueue::instance(), &JobQueue::progress, this, &ExecutionViewStep::updateFromJobQueue );
|
||||
|
||||
|
@ -134,15 +135,20 @@ ExecutionViewStep::isAtEnd() const
|
|||
return true;
|
||||
}
|
||||
|
||||
|
||||
void
|
||||
ExecutionViewStep::onActivate()
|
||||
ExecutionViewStep::loadQml()
|
||||
{
|
||||
if ( !m_qmlShowLoaded && !Calamares::Branding::instance()->slideshowPath().isEmpty() )
|
||||
{
|
||||
m_qmlShow->setSource( QUrl::fromLocalFile( Calamares::Branding::instance()->slideshowPath() ) );
|
||||
m_qmlShowLoaded = true;
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
ExecutionViewStep::onActivate()
|
||||
{
|
||||
loadQml();
|
||||
|
||||
JobQueue* queue = JobQueue::instance();
|
||||
foreach ( const QString& instanceKey, m_jobInstanceKeys )
|
||||
|
|
|
@ -65,6 +65,7 @@ private:
|
|||
|
||||
QStringList m_jobInstanceKeys;
|
||||
|
||||
void loadQml(); //< Loads the slideshow QML (from branding)
|
||||
void updateFromJobQueue( qreal percent, const QString& message );
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue