changed the way to create qml pages, now the page is created when you go to it
- added PageSetupWizardConfigSource, PageSetupWizardInstalling, PageSetupWizardProtocolSettings, PageSetupWizardTextKey
This commit is contained in:
parent
68b27451f2
commit
4f36349630
25 changed files with 503 additions and 158 deletions
|
@ -56,4 +56,14 @@ void ContainersModel::setSelectedServerIndex(int index)
|
|||
endResetModel();
|
||||
}
|
||||
|
||||
void ContainersModel::setCurrentlyInstalledContainerIndex(int index)
|
||||
{
|
||||
// beginResetModel();
|
||||
m_currentlyInstalledContainerIndex = createIndex(index, 0);
|
||||
// endResetModel();
|
||||
}
|
||||
|
||||
QString ContainersModel::getCurrentlyInstalledContainerName()
|
||||
{
|
||||
return data(m_currentlyInstalledContainerIndex, NameRole).toString();
|
||||
}
|
||||
|
|
|
@ -27,12 +27,16 @@ public:
|
|||
|
||||
QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const override;
|
||||
Q_INVOKABLE void setSelectedServerIndex(int index);
|
||||
Q_INVOKABLE void setCurrentlyInstalledContainerIndex(int index);
|
||||
|
||||
Q_INVOKABLE QString getCurrentlyInstalledContainerName();
|
||||
|
||||
protected:
|
||||
QHash<int, QByteArray> roleNames() const override;
|
||||
|
||||
private:
|
||||
int m_selectedServerIndex;
|
||||
QModelIndex m_currentlyInstalledContainerIndex;
|
||||
std::shared_ptr<Settings> m_settings;
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue