Commit eb0fde8b authored by Matthias Möller's avatar Matthias Möller

doc

removed unused commands

refs #1148

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@15729 383ad7c9-94d9-4d36-a494-682f7c89f535
parent 7455073e
......@@ -123,7 +123,6 @@ void MaterialPicker::initializePlugin() {
stream >> materialInfo.reflectance;
stream.str("");
stream.clear();
savedString.push_back(QString::number(Qt::Key_unknown));
stream << savedString[8].toStdString();
stream >> materialInfo.key;
......@@ -201,8 +200,9 @@ void MaterialPicker::clearList() {
materialListWidget_->clear();
materialList_.clear();
materialStrings_.clear();
OpenFlipperSettings().setValue(propName_, materialStrings_);
fillMaterialButton_->setEnabled(false);
//setting value empty instead of removing will cause an error at start up
OpenFlipperSettings().remove(propName_);
}
......@@ -212,6 +212,7 @@ void MaterialPicker::slotRemoveCurrentItem()
{
if (!materialListWidget_->count())
return;
QMessageBox msgBox;
QListWidgetItem* item = materialListWidget_->currentItem();
msgBox.setText(tr("Remove ")+plainName(item->text(),materialListWidget_->currentRow())+tr("?"));
......@@ -357,6 +358,7 @@ QString MaterialPicker::plainName(const QString &string, int index)
{
if (materialList_[index].key == Qt::Key_unknown)
return string;
QString str(string);
return str.remove(0,4);
}
......
......@@ -127,8 +127,12 @@ private:
bool fillMaterial_;
private:
/// returns the item name with hotkey hint
QString itemName(const QString &_name, int _key);
/// returns the plain name of the material without hotkey hint
QString plainName(const QString &string, int index);
private slots:
void initializePlugin();
......@@ -150,9 +154,6 @@ private slots:
void saveNewName ( QWidget * _editor, QAbstractItemDelegate::EndEditHint _hint );
void saveNewName (QListWidgetItem* _item);
/// returns the plain name of the material without hotkey hint
QString plainName(const QString &string, int index);
/// returns a formatted string for saving
QString materialString(const MaterialInfo& _mat, const QString &_name);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment