Implement button navigation rules for gamepads. Fix mouse click / gamepad transition key conflicting. Fix how a pointer is generated for components via the Component<> reference template. Since we sometimes want to dynamic cast it, it loses all its typing data if we make a new shared pointer instead.
if(!GetSelection().expired()){//If we are on controller/gamepad it's possible we haven't highlighted a button yet, so don't click this button right away.
SetMouseNavigation(game->GetMouse(Mouse::LEFT).bPressed||game->GetMouse(Mouse::RIGHT).bPressed||game->GetMouse(Mouse::MIDDLE).bPressed);//If a click occurs we use mouse controls.
SetMouseNavigation(game->GetMouse(Mouse::LEFT).bReleased||game->GetMouse(Mouse::RIGHT).bReleased||game->GetMouse(Mouse::MIDDLE).bReleased);//If a click occurs we use mouse controls.
boolignoreInputs=false;//We set this to true because on the next button release, we don't want buttons to cause menu navigation. This is for when the player needs to activate the cursor via keyboard/gamepad and nothing is highlighted. It gets reset to false once a button has been released.
staticboolMOUSE_NAVIGATION;
boolcover;//A black cover for when a menu pops up to fade out the stuff behind it.