move abr import to main menu, add progress bar

This commit is contained in:
2019-02-23 00:45:14 +01:00
parent edc2bacc90
commit e1f82373c6
11 changed files with 163 additions and 98 deletions

View File

@@ -148,8 +148,9 @@ std::vector<std::shared_ptr<Brush>> ABR::compute_brushes(const std::string& path
{
auto patt_uid = wstr2str(patt->value<String>("Idnt"));
b->m_pattern_path = path + "/patterns/" + patt_uid + ".png";
//b->m_brush_thumb_path = path + "/patterns/thumbs/" + patt_uid + ".png";
b->m_pattern_thumb_path = path + "/patterns/thumbs/" + patt_uid + ".png";
b->m_pattern_depth = p->value<UnitFloat>("textureDepth") * 0.01f;
b->m_pattern_enabled = true;
}
ret.push_back(b);
}
@@ -305,8 +306,8 @@ std::shared_ptr<ABR::Double> ABR::parse_doub()
std::shared_ptr<ABR::Enum> ABR::parse_enum()
{
auto ret = std::make_shared<Enum>();
auto t = rkey_or_string();
auto e = rkey_or_string();
ret->type = rkey_or_string();
ret->value = rkey_or_string();
//printf("enum: %s %s\n", t.c_str(), e.c_str());
return ret;
}