if (selected == "true")
fselected = true;
- std::wstring wlabel = narrow_to_wide(label.c_str());
+ std::wstring wlabel = narrow_to_wide(label);
core::rect<s32> rect = core::rect<s32>(
pos.X, pos.Y + ((imgsize.Y/2) - m_btn_height),
pos.Y + ((imgsize.Y/2) + m_btn_height));
FieldSpec spec(
- narrow_to_wide(name.c_str()),
+ narrow_to_wide(name),
wlabel, //Needed for displaying text on MSVC
wlabel,
258+m_fields.size()
core::rect<s32>(pos.X, pos.Y, pos.X + dim.X, pos.Y + dim.Y);
FieldSpec spec(
- narrow_to_wide(name.c_str()),
+ narrow_to_wide(name),
L"",
L"",
258+m_fields.size()
label = unescape_string(label);
- std::wstring wlabel = narrow_to_wide(label.c_str());
+ std::wstring wlabel = narrow_to_wide(label);
FieldSpec spec(
- narrow_to_wide(name.c_str()),
+ narrow_to_wide(name),
wlabel,
L"",
258+m_fields.size()
core::rect<s32> rect = core::rect<s32>(pos.X, pos.Y, pos.X+geom.X, pos.Y+geom.Y);
- std::wstring fname_w = narrow_to_wide(name.c_str());
+ std::wstring fname_w = narrow_to_wide(name);
FieldSpec spec(
fname_w,
core::rect<s32> rect = core::rect<s32>(pos.X, pos.Y, pos.X+geom.X, pos.Y+geom.Y);
- std::wstring fname_w = narrow_to_wide(name.c_str());
+ std::wstring fname_w = narrow_to_wide(name);
FieldSpec spec(
fname_w,
core::rect<s32> rect = core::rect<s32>(pos.X, pos.Y,
pos.X + width, pos.Y + (m_btn_height * 2));
- std::wstring fname_w = narrow_to_wide(name.c_str());
+ std::wstring fname_w = narrow_to_wide(name);
FieldSpec spec(
fname_w,
label = unescape_string(label);
- std::wstring wlabel = narrow_to_wide(label.c_str());
+ std::wstring wlabel = narrow_to_wide(label);
FieldSpec spec(
- narrow_to_wide(name.c_str()),
+ narrow_to_wide(name),
wlabel,
L"",
258+m_fields.size()
default_val = unescape_string(default_val);
label = unescape_string(label);
- std::wstring wlabel = narrow_to_wide(label.c_str());
+ std::wstring wlabel = narrow_to_wide(label);
FieldSpec spec(
- narrow_to_wide(name.c_str()),
+ narrow_to_wide(name),
wlabel,
- narrow_to_wide(default_val.c_str()),
+ narrow_to_wide(default_val),
258+m_fields.size()
);
default_val = unescape_string(default_val);
label = unescape_string(label);
- std::wstring wlabel = narrow_to_wide(label.c_str());
+ std::wstring wlabel = narrow_to_wide(label);
FieldSpec spec(
- narrow_to_wide(name.c_str()),
+ narrow_to_wide(name),
wlabel,
- narrow_to_wide(default_val.c_str()),
+ narrow_to_wide(default_val),
258+m_fields.size()
);
// in the integer cases: 0.4 is not exactly
// representable in binary floating point.
s32 posy = pos.Y + ((float)i) * spacing.Y * 2.0 / 5.0;
- std::wstring wlabel = narrow_to_wide(lines[i].c_str());
+ std::wstring wlabel = narrow_to_wide(lines[i]);
core::rect<s32> rect = core::rect<s32>(
pos.X, posy - m_btn_height,
pos.X + m_font->getDimension(wlabel.c_str()).Width,
pressed_image_name = unescape_string(pressed_image_name);
label = unescape_string(label);
- std::wstring wlabel = narrow_to_wide(label.c_str());
+ std::wstring wlabel = narrow_to_wide(label);
FieldSpec spec(
- narrow_to_wide(name.c_str()),
+ narrow_to_wide(name),
wlabel,
- narrow_to_wide(image_name.c_str()),
+ narrow_to_wide(image_name),
258+m_fields.size()
);
spec.ftype = f_Button;
}
FieldSpec spec(
- narrow_to_wide(name.c_str()),
+ narrow_to_wide(name),
L"",
L"",
258+m_fields.size()
item.deSerialize(item_name, idef);
video::ITexture *texture = idef->getInventoryTexture(item.getDefinition(idef).name, m_gamedef);
- m_tooltips[narrow_to_wide(name.c_str())] =
+ m_tooltips[narrow_to_wide(name)] =
TooltipSpec (item.getDefinition(idef).description,
m_default_tooltip_bgcolor,
m_default_tooltip_color);
label = unescape_string(label);
FieldSpec spec(
- narrow_to_wide(name.c_str()),
- narrow_to_wide(label.c_str()),
- narrow_to_wide(item_name.c_str()),
+ narrow_to_wide(name),
+ narrow_to_wide(label),
+ narrow_to_wide(item_name),
258+m_fields.size()
);
std::vector<std::string> parts = split(element,';');
if (parts.size() == 2) {
std::string name = parts[0];
- m_tooltips[narrow_to_wide(name.c_str())] = TooltipSpec (parts[1], m_default_tooltip_bgcolor, m_default_tooltip_color);
+ m_tooltips[narrow_to_wide(name)] = TooltipSpec (parts[1], m_default_tooltip_bgcolor, m_default_tooltip_color);
return;
} else if (parts.size() == 4) {
std::string name = parts[0];
video::SColor tmp_color1, tmp_color2;
if ( parseColorString(parts[2], tmp_color1, false) && parseColorString(parts[3], tmp_color2, false) ) {
- m_tooltips[narrow_to_wide(name.c_str())] = TooltipSpec (parts[1], tmp_color1, tmp_color2);
+ m_tooltips[narrow_to_wide(name)] = TooltipSpec (parts[1], tmp_color1, tmp_color2);
return;
}
}