Fix problem showing Index/Mask with other tabs on ColorPopup

We were able to click on Index (or Mask) and then Shift+click other
tab (like RGB) to show it. With this patch this is not possible anymore.
This commit is contained in:
David Capello 2017-06-22 18:56:05 -03:00
parent 0ced31a447
commit 5ac5b358f3

View File

@ -152,6 +152,10 @@ void ColorPopup::CustomButtonSet::onSelectItem(Item* item, bool focusItem, ui::M
if (getItem(i)->isSelected())
getItem(i)->setSelected(false);
}
else {
if (getItem(INDEX_MODE)->isSelected()) getItem(INDEX_MODE)->setSelected(false);
if (getItem(MASK_MODE)->isSelected()) getItem(MASK_MODE)->setSelected(false);
}
if (item) {
// Item already selected