forked from qt-creator/qt-creator
Mobile wizards: Don't show orientation options for Harmattan & Meego.
This commit is contained in:
@@ -31,7 +31,9 @@ public:
|
|||||||
void loadFile(const QString &fileName);
|
void loadFile(const QString &fileName);
|
||||||
void loadUrl(const QUrl &url);
|
void loadUrl(const QUrl &url);
|
||||||
|
|
||||||
|
// Note that this will only have an effect on Symbian and Fremantle.
|
||||||
void setOrientation(ScreenOrientation orientation);
|
void setOrientation(ScreenOrientation orientation);
|
||||||
|
|
||||||
void showExpanded();
|
void showExpanded();
|
||||||
|
|
||||||
QGraphicsWebView *webView() const;
|
QGraphicsWebView *webView() const;
|
||||||
|
@@ -20,7 +20,9 @@ public:
|
|||||||
explicit MainWindow(QWidget *parent = 0);
|
explicit MainWindow(QWidget *parent = 0);
|
||||||
virtual ~MainWindow();
|
virtual ~MainWindow();
|
||||||
|
|
||||||
|
// Note that this will only have an effect on Symbian and Fremantle.
|
||||||
void setOrientation(ScreenOrientation orientation);
|
void setOrientation(ScreenOrientation orientation);
|
||||||
|
|
||||||
void showExpanded();
|
void showExpanded();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
@@ -28,7 +28,10 @@ public:
|
|||||||
|
|
||||||
void setMainQmlFile(const QString &file);
|
void setMainQmlFile(const QString &file);
|
||||||
void addImportPath(const QString &path);
|
void addImportPath(const QString &path);
|
||||||
|
|
||||||
|
// Note that this will only have an effect on Symbian and Fremantle.
|
||||||
void setOrientation(ScreenOrientation orientation);
|
void setOrientation(ScreenOrientation orientation);
|
||||||
|
|
||||||
void showExpanded();
|
void showExpanded();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
@@ -94,14 +94,17 @@ int AbstractMobileAppWizardDialog::nextId() const
|
|||||||
const bool symbianTargetSelected =
|
const bool symbianTargetSelected =
|
||||||
m_targetsPage->isTargetSelected(QLatin1String(Constants::S60_EMULATOR_TARGET_ID))
|
m_targetsPage->isTargetSelected(QLatin1String(Constants::S60_EMULATOR_TARGET_ID))
|
||||||
|| m_targetsPage->isTargetSelected(QLatin1String(Constants::S60_DEVICE_TARGET_ID));
|
|| m_targetsPage->isTargetSelected(QLatin1String(Constants::S60_DEVICE_TARGET_ID));
|
||||||
const bool maemoTargetSelected =
|
const bool fremantleTargetSelected
|
||||||
m_targetsPage->isTargetSelected(QLatin1String(Constants::MAEMO5_DEVICE_TARGET_ID))
|
= m_targetsPage->isTargetSelected(QLatin1String(Constants::MAEMO5_DEVICE_TARGET_ID));
|
||||||
|
const bool maemoTargetSelected = fremantleTargetSelected
|
||||||
|| m_targetsPage->isTargetSelected(QLatin1String(Constants::HARMATTAN_DEVICE_TARGET_ID))
|
|| m_targetsPage->isTargetSelected(QLatin1String(Constants::HARMATTAN_DEVICE_TARGET_ID))
|
||||||
|| m_targetsPage->isTargetSelected(QLatin1String(Constants::MEEGO_DEVICE_TARGET_ID));
|
|| m_targetsPage->isTargetSelected(QLatin1String(Constants::MEEGO_DEVICE_TARGET_ID));
|
||||||
|
|
||||||
if (currentPage() == m_targetsPage) {
|
if (currentPage() == m_targetsPage) {
|
||||||
if (symbianTargetSelected || maemoTargetSelected)
|
if (symbianTargetSelected || fremantleTargetSelected)
|
||||||
return m_genericOptionsPageId;
|
return m_genericOptionsPageId;
|
||||||
|
else if (maemoTargetSelected)
|
||||||
|
return m_maemoOptionsPageId;
|
||||||
else
|
else
|
||||||
return idOfNextGenericPage();
|
return idOfNextGenericPage();
|
||||||
} else if (currentPage() == m_genericOptionsPage) {
|
} else if (currentPage() == m_genericOptionsPage) {
|
||||||
@@ -122,7 +125,7 @@ int AbstractMobileAppWizardDialog::nextId() const
|
|||||||
void AbstractMobileAppWizardDialog::initializePage(int id)
|
void AbstractMobileAppWizardDialog::initializePage(int id)
|
||||||
{
|
{
|
||||||
if (id == startId()) {
|
if (id == startId()) {
|
||||||
m_targetItem->setNextItems(QList<Utils::WizardProgressItem *>() << m_genericItem << itemOfNextGenericPage());
|
m_targetItem->setNextItems(QList<Utils::WizardProgressItem *>() << m_genericItem << m_maemoItem << itemOfNextGenericPage());
|
||||||
m_genericItem->setNextItems(QList<Utils::WizardProgressItem *>() << m_symbianItem << m_maemoItem);
|
m_genericItem->setNextItems(QList<Utils::WizardProgressItem *>() << m_symbianItem << m_maemoItem);
|
||||||
m_symbianItem->setNextItems(QList<Utils::WizardProgressItem *>() << m_maemoItem << itemOfNextGenericPage());
|
m_symbianItem->setNextItems(QList<Utils::WizardProgressItem *>() << m_maemoItem << itemOfNextGenericPage());
|
||||||
} else if (id == m_genericOptionsPageId) {
|
} else if (id == m_genericOptionsPageId) {
|
||||||
|
Reference in New Issue
Block a user