ui: project wizzard design
* switched to QGridLayout for wizzard content layouting * distinguish scrollable windows based on content * content can define window size * removed QtApplicationSettingsScreen, now done via QtProjectWizzardWindow and QtProjectWizzardContentPreferences * added new project icon
This commit is contained in:
@@ -0,0 +1,65 @@
|
||||
#include "qt/window/project_wizzard/QtProjectWizzardContentPreferences.h"
|
||||
|
||||
#include <QSysInfo>
|
||||
|
||||
QtProjectWizzardContentPreferences::QtProjectWizzardContentPreferences(ProjectSettings* settings, QtProjectWizzardWindow* window)
|
||||
: QtProjectWizzardContent(settings, window)
|
||||
, m_headerSearch(nullptr)
|
||||
, m_frameworkSearch(nullptr)
|
||||
{
|
||||
m_headerSearch = new QtProjectWizzardContentPathsHeaderSearchGlobal(settings, window);
|
||||
|
||||
if (QSysInfo::macVersion() != QSysInfo::MV_None)
|
||||
{
|
||||
m_frameworkSearch = new QtProjectWizzardContentPathsFrameworkSearchGlobal(settings, window);
|
||||
}
|
||||
}
|
||||
|
||||
void QtProjectWizzardContentPreferences::populateWindow(QGridLayout* layout)
|
||||
{
|
||||
int row = 0;
|
||||
|
||||
layout->setRowMinimumHeight(row, 10);
|
||||
row++;
|
||||
|
||||
m_headerSearch->populateForm(layout, row);
|
||||
|
||||
if (m_frameworkSearch)
|
||||
{
|
||||
m_frameworkSearch->populateForm(layout, row);
|
||||
}
|
||||
|
||||
layout->setRowMinimumHeight(row, 10);
|
||||
}
|
||||
|
||||
void QtProjectWizzardContentPreferences::windowReady()
|
||||
{
|
||||
m_window->updateTitle("PREFERENCES");
|
||||
m_window->updateDoneButton("Save");
|
||||
m_window->hidePrevious();
|
||||
}
|
||||
|
||||
void QtProjectWizzardContentPreferences::load()
|
||||
{
|
||||
m_headerSearch->load();
|
||||
|
||||
if (m_frameworkSearch)
|
||||
{
|
||||
m_frameworkSearch->load();
|
||||
}
|
||||
}
|
||||
|
||||
void QtProjectWizzardContentPreferences::save()
|
||||
{
|
||||
m_headerSearch->save();
|
||||
|
||||
if (m_frameworkSearch)
|
||||
{
|
||||
m_frameworkSearch->save();
|
||||
}
|
||||
}
|
||||
|
||||
bool QtProjectWizzardContentPreferences::isScrollAble() const
|
||||
{
|
||||
return true;
|
||||
}
|
||||
Reference in New Issue
Block a user