ipsservices/nmipssettings/src/nmipssettingslabeledcombobox.cpp
changeset 27 9ba4404ef423
parent 23 2dc6caa42ec3
child 68 83cc6bae1de8
equal deleted inserted replaced
23:2dc6caa42ec3 27:9ba4404ef423
    54     layout->addItem(mLabel); // Takes ownership
    54     layout->addItem(mLabel); // Takes ownership
    55 
    55 
    56     // Connect signals and slots.
    56     // Connect signals and slots.
    57     connect(mComboBox, SIGNAL(currentIndexChanged(int)),
    57     connect(mComboBox, SIGNAL(currentIndexChanged(int)),
    58         this, SLOT(comboBoxIndexChanged(int)), Qt::UniqueConnection);
    58         this, SLOT(comboBoxIndexChanged(int)), Qt::UniqueConnection);
    59 
       
    60     connect(mComboBox, SIGNAL(currentIndexChanged(int)),
       
    61         this, SIGNAL(currentIndexChanged(int)), Qt::UniqueConnection);
       
    62 }
    59 }
    63 
    60 
    64 /*!
    61 /*!
    65     Destructor of NmIpsSettingsLabeledComboBox.
    62     Destructor of NmIpsSettingsLabeledComboBox.
    66 */
    63 */
   132 */
   129 */
   133 void NmIpsSettingsLabeledComboBox::comboBoxIndexChanged(int index)
   130 void NmIpsSettingsLabeledComboBox::comboBoxIndexChanged(int index)
   134 {
   131 {
   135     QString label(mLabelTexts.value(index));
   132     QString label(mLabelTexts.value(index));
   136     mLabel->setPlainText(label);
   133     mLabel->setPlainText(label);
       
   134     QMap<QString, QVariant> properties;
       
   135     properties.insert("currentIndex", index);
       
   136     emit propertyChanged(properties);
       
   137     emit currentIndexChanged(index);
   137 }
   138 }