| 73 | } |
| 74 | |
| 75 | void GradientDialog::Private::insertItem() |
| 76 | { |
| 77 | QGradientStop newStop; |
| 78 | newStop.first = 0.5; |
| 79 | newStop.second = Qt::white; |
| 80 | const int index = ui->stopSelector->currentIndex() + 1; |
| 81 | ui->stopSelector->setCurrentIndex(-1); |
| 82 | m_gradient.insert(index, newStop); |
| 83 | |
| 84 | QStringList newItems; |
| 85 | newItems << tr("stop %1").arg(m_currStopNr); |
| 86 | ui->stopSelector->insertItems(index, newItems); |
| 87 | |
| 88 | ui->stopSelector->setCurrentIndex(index); |
| 89 | |
| 90 | updateGradientDisplay(); |
| 91 | } |
| 92 | |
| 93 | void GradientDialog::Private::deleteItem() |
| 94 | { |
nothing calls this directly
no test coverage detected