forked from qt-creator/qt-creator
Maemo: Fix logic in device configurations dialog.
Don't do anything when the "emulator" or "hardware" buttons are clicked and are already checked.
This commit is contained in:
@@ -274,12 +274,14 @@ void MaemoDeviceConfigurationsSettingsWidget::configNameEditingFinished()
|
|||||||
|
|
||||||
void MaemoDeviceConfigurationsSettingsWidget::deviceTypeChanged()
|
void MaemoDeviceConfigurationsSettingsWidget::deviceTypeChanged()
|
||||||
{
|
{
|
||||||
const QString name = currentConfig().name;
|
|
||||||
const MaemoDeviceConfig::DeviceType devType =
|
const MaemoDeviceConfig::DeviceType devType =
|
||||||
m_ui->deviceButton->isChecked()
|
m_ui->deviceButton->isChecked()
|
||||||
? MaemoDeviceConfig::Physical
|
? MaemoDeviceConfig::Physical
|
||||||
: MaemoDeviceConfig::Simulator;
|
: MaemoDeviceConfig::Simulator;
|
||||||
|
if (currentConfig().type == devType)
|
||||||
|
return;
|
||||||
|
|
||||||
|
const QString name = currentConfig().name;
|
||||||
if (devType == MaemoDeviceConfig::Simulator) {
|
if (devType == MaemoDeviceConfig::Simulator) {
|
||||||
m_lastConfigHW = currentConfig();
|
m_lastConfigHW = currentConfig();
|
||||||
currentConfig() = m_lastConfigSim;
|
currentConfig() = m_lastConfigSim;
|
||||||
|
|||||||
Reference in New Issue
Block a user