forked from teamnwah/openmw-tes3coop
Fix an issue with items that have no UI icon
This commit is contained in:
parent
81ec8c2f55
commit
b6bad969a0
1 changed files with 3 additions and 2 deletions
|
@ -61,7 +61,8 @@ namespace MWGui
|
||||||
mDraggedWidget = baseWidget;
|
mDraggedWidget = baseWidget;
|
||||||
MyGUI::ImageBox* image = baseWidget->createWidget<MyGUI::ImageBox>("ImageBox",
|
MyGUI::ImageBox* image = baseWidget->createWidget<MyGUI::ImageBox>("ImageBox",
|
||||||
MyGUI::IntCoord(5, 5, 32, 32), MyGUI::Align::Default);
|
MyGUI::IntCoord(5, 5, 32, 32), MyGUI::Align::Default);
|
||||||
int pos = path.rfind(".");
|
size_t pos = path.rfind(".");
|
||||||
|
if (pos != std::string::npos)
|
||||||
path.erase(pos);
|
path.erase(pos);
|
||||||
path.append(".dds");
|
path.append(".dds");
|
||||||
image->setImageTexture(path);
|
image->setImageTexture(path);
|
||||||
|
|
Loading…
Reference in a new issue