editor item and monster previews use dark background
This commit is contained in:
@@ -849,7 +849,11 @@ static bool edit_monst_type_event_filter(cDialog& me,std::string hit,cMonster& m
|
|||||||
put_monst_info_in_dlog(me,monst,which);
|
put_monst_info_in_dlog(me,monst,which);
|
||||||
}
|
}
|
||||||
} else if(hit == "preview") {
|
} else if(hit == "preview") {
|
||||||
|
// Use dark background that the game uses:
|
||||||
|
short defaultBackground = cDialog::defaultBackground;
|
||||||
|
cDialog::defaultBackground = cDialog::BG_DARK;
|
||||||
cDialog monstInfo(*ResMgr::dialogs.get("monster-info"), &me);
|
cDialog monstInfo(*ResMgr::dialogs.get("monster-info"), &me);
|
||||||
|
cDialog::defaultBackground = defaultBackground;
|
||||||
monstInfo["left"].hide();
|
monstInfo["left"].hide();
|
||||||
monstInfo["right"].hide();
|
monstInfo["right"].hide();
|
||||||
monstInfo.attachClickHandlers([](cDialog&,std::string,eKeyMod){return false;}, {"guard","mindless","invuln"});
|
monstInfo.attachClickHandlers([](cDialog&,std::string,eKeyMod){return false;}, {"guard","mindless","invuln"});
|
||||||
@@ -1707,7 +1711,13 @@ static bool edit_item_type_event_filter(cDialog& me, std::string hit, cItem& ite
|
|||||||
} else if(hit == "preview") {
|
} else if(hit == "preview") {
|
||||||
cItem temp_item = item;
|
cItem temp_item = item;
|
||||||
temp_item.ident = true;
|
temp_item.ident = true;
|
||||||
|
|
||||||
|
// Use dark background that the game uses:
|
||||||
|
short defaultBackground = cDialog::defaultBackground;
|
||||||
|
cDialog::defaultBackground = cDialog::BG_DARK;
|
||||||
cDialog itemInfo(*ResMgr::dialogs.get("item-info"), &me);
|
cDialog itemInfo(*ResMgr::dialogs.get("item-info"), &me);
|
||||||
|
cDialog::defaultBackground = defaultBackground;
|
||||||
|
|
||||||
itemInfo["left"].hide();
|
itemInfo["left"].hide();
|
||||||
itemInfo["right"].hide();
|
itemInfo["right"].hide();
|
||||||
itemInfo["done"].attachClickHandler(std::bind(&cDialog::toast, &itemInfo, false));
|
itemInfo["done"].attachClickHandler(std::bind(&cDialog::toast, &itemInfo, false));
|
||||||
|
@@ -853,6 +853,7 @@ static bool preview_spec_enc_dlog(cDialog& me, std::string item_hit, cSpecial& s
|
|||||||
|
|
||||||
if(str1.empty() && str2.empty()) break;
|
if(str1.empty() && str2.empty()) break;
|
||||||
|
|
||||||
|
// Use dark background that the game uses:
|
||||||
short defaultBackground = cDialog::defaultBackground;
|
short defaultBackground = cDialog::defaultBackground;
|
||||||
cDialog::defaultBackground = cDialog::BG_DARK;
|
cDialog::defaultBackground = cDialog::BG_DARK;
|
||||||
cStrDlog dlog(str1, str2, title, pic, pic_type, &me);
|
cStrDlog dlog(str1, str2, title, pic, pic_type, &me);
|
||||||
|
Reference in New Issue
Block a user