mirror of
https://github.com/The-Powder-Toy/The-Powder-Toy.git
synced 2025-08-13 20:04:01 +02:00
fix compile warnings, fix tooltips fading in too slowly
This commit is contained in:
@@ -27,12 +27,13 @@ ElementSearchActivity::ElementSearchActivity(GameController * gameController, st
|
|||||||
firstResult(NULL),
|
firstResult(NULL),
|
||||||
gameController(gameController),
|
gameController(gameController),
|
||||||
tools(tools),
|
tools(tools),
|
||||||
|
toolTip(""),
|
||||||
|
toolTipPresence(0),
|
||||||
shiftPressed(false),
|
shiftPressed(false),
|
||||||
ctrlPressed(false),
|
ctrlPressed(false),
|
||||||
altPressed(false),
|
altPressed(false),
|
||||||
exit(false),
|
isToolTipFadingIn(false),
|
||||||
toolTip(""),
|
exit(false)
|
||||||
isToolTipFadingIn(false)
|
|
||||||
{
|
{
|
||||||
ui::Label * title = new ui::Label(ui::Point(4, 5), ui::Point(Size.X-8, 15), "Element Search");
|
ui::Label * title = new ui::Label(ui::Point(4, 5), ui::Point(Size.X-8, 15), "Element Search");
|
||||||
title->SetTextColour(style::Colour::InformationTitle);
|
title->SetTextColour(style::Colour::InformationTitle);
|
||||||
@@ -211,7 +212,7 @@ void ElementSearchActivity::OnTick(float dt)
|
|||||||
if (toolTipPresence < 120)
|
if (toolTipPresence < 120)
|
||||||
toolTipPresence += int(dt*2)>1?int(dt*2):2;
|
toolTipPresence += int(dt*2)>1?int(dt*2):2;
|
||||||
}
|
}
|
||||||
if (toolTipPresence>0)
|
else if (toolTipPresence>0)
|
||||||
{
|
{
|
||||||
toolTipPresence -= int(dt)>0?int(dt):1;
|
toolTipPresence -= int(dt)>0?int(dt):1;
|
||||||
if (toolTipPresence<0)
|
if (toolTipPresence<0)
|
||||||
|
Reference in New Issue
Block a user