fixed issue with ribbons when not using mouse + improved looks of input config screen
git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/branches/irrlicht@3538 178a84e3-b1eb-0310-8ba1-8eac791a3b58
This commit is contained in:
parent
cc2c62e024
commit
1f362f88b0
@ -17,7 +17,8 @@
|
|||||||
<div width="85%" proportion="1" layout="horizontal-row" align="center">
|
<div width="85%" proportion="1" layout="horizontal-row" align="center">
|
||||||
<label proportion="2" height="100%" text="Accelerate" text_align="right"/>
|
<label proportion="2" height="100%" text="Accelerate" text_align="right"/>
|
||||||
<spacer proportion="1" height="100%" />
|
<spacer proportion="1" height="100%" />
|
||||||
<button id="binding_up" proportion="2" height="100%" text="[none]"/>
|
<button id="binding_up" proportion="3" height="100%" text="[none]"/>
|
||||||
|
<spacer proportion="1" height="100%" />
|
||||||
</div>
|
</div>
|
||||||
<spacer height="5" width="10"/>
|
<spacer height="5" width="10"/>
|
||||||
|
|
||||||
@ -25,56 +26,64 @@
|
|||||||
<div width="85%" proportion="1" layout="horizontal-row" align="center">
|
<div width="85%" proportion="1" layout="horizontal-row" align="center">
|
||||||
<label proportion="2" height="100%" text="Brake" text_align="right"/>
|
<label proportion="2" height="100%" text="Brake" text_align="right"/>
|
||||||
<spacer proportion="1" height="100%" />
|
<spacer proportion="1" height="100%" />
|
||||||
<button id="binding_down" proportion="2" height="100%" text="[none]"/>
|
<button id="binding_down" proportion="3" height="100%" text="[none]"/>
|
||||||
|
<spacer proportion="1" height="100%" />
|
||||||
</div>
|
</div>
|
||||||
<spacer height="5" width="10"/>
|
<spacer height="5" width="10"/>
|
||||||
|
|
||||||
<div width="85%" proportion="1" layout="horizontal-row" align="center">
|
<div width="85%" proportion="1" layout="horizontal-row" align="center">
|
||||||
<label proportion="2" height="100%" text="Left" text_align="right"/>
|
<label proportion="2" height="100%" text="Left" text_align="right"/>
|
||||||
<spacer proportion="1" height="100%" />
|
<spacer proportion="1" height="100%" />
|
||||||
<button id="binding_left" proportion="2" height="100%" text="[none]"/>
|
<button id="binding_left" proportion="3" height="100%" text="[none]"/>
|
||||||
|
<spacer proportion="1" height="100%" />
|
||||||
</div>
|
</div>
|
||||||
<spacer height="5" width="10"/>
|
<spacer height="5" width="10"/>
|
||||||
|
|
||||||
<div width="85%" proportion="1" layout="horizontal-row" align="center">
|
<div width="85%" proportion="1" layout="horizontal-row" align="center">
|
||||||
<label proportion="2" height="100%" text="Right" text_align="right"/>
|
<label proportion="2" height="100%" text="Right" text_align="right"/>
|
||||||
<spacer proportion="1" height="100%" />
|
<spacer proportion="1" height="100%" />
|
||||||
<button id="binding_right" proportion="2" height="100%" text="[none]"/>
|
<button id="binding_right" proportion="3" height="100%" text="[none]"/>
|
||||||
|
<spacer proportion="1" height="100%" />
|
||||||
</div>
|
</div>
|
||||||
<spacer height="5" width="10"/>
|
<spacer height="5" width="10"/>
|
||||||
|
|
||||||
<div width="85%" proportion="1" layout="horizontal-row" align="center">
|
<div width="85%" proportion="1" layout="horizontal-row" align="center">
|
||||||
<label proportion="2" height="100%" text="Fire" text_align="right"/>
|
<label proportion="2" height="100%" text="Fire" text_align="right"/>
|
||||||
<spacer proportion="1" height="100%" />
|
<spacer proportion="1" height="100%" />
|
||||||
<button id="binding_fire" proportion="2" height="100%" text="[none]"/>
|
<button id="binding_fire" proportion="3" height="100%" text="[none]"/>
|
||||||
|
<spacer proportion="1" height="100%" />
|
||||||
</div>
|
</div>
|
||||||
<spacer height="5" width="10"/>
|
<spacer height="5" width="10"/>
|
||||||
|
|
||||||
<div width="85%" proportion="1" layout="horizontal-row" align="center" >
|
<div width="85%" proportion="1" layout="horizontal-row" align="center" >
|
||||||
<label proportion="2" height="100%" text="Nitro" text_align="right"/>
|
<label proportion="2" height="100%" text="Nitro" text_align="right"/>
|
||||||
<spacer proportion="1" height="100%" />
|
<spacer proportion="1" height="100%" />
|
||||||
<button id="binding_nitro" proportion="2" height="100%" text="[none]"/>
|
<button id="binding_nitro" proportion="3" height="100%" text="[none]"/>
|
||||||
|
<spacer proportion="1" height="100%" />
|
||||||
</div>
|
</div>
|
||||||
<spacer height="5" width="10"/>
|
<spacer height="5" width="10"/>
|
||||||
|
|
||||||
<div width="85%" proportion="1" layout="horizontal-row" align="center">
|
<div width="85%" proportion="1" layout="horizontal-row" align="center">
|
||||||
<label proportion="2" height="100%" text="Sharp Turn" text_align="right"/>
|
<label proportion="2" height="100%" text="Sharp Turn" text_align="right"/>
|
||||||
<spacer proportion="1" height="100%" />
|
<spacer proportion="1" height="100%" />
|
||||||
<button id="binding_drift" proportion="2" height="100%" text="[none]"/>
|
<button id="binding_drift" proportion="3" height="100%" text="[none]"/>
|
||||||
|
<spacer proportion="1" height="100%" />
|
||||||
</div>
|
</div>
|
||||||
<spacer height="5" width="10"/>
|
<spacer height="5" width="10"/>
|
||||||
|
|
||||||
<div width="85%" proportion="1" layout="horizontal-row" align="center">
|
<div width="85%" proportion="1" layout="horizontal-row" align="center">
|
||||||
<label proportion="2" height="100%" text="Rescue" text_align="right"/>
|
<label proportion="2" height="100%" text="Rescue" text_align="right"/>
|
||||||
<spacer proportion="1" height="100%" />
|
<spacer proportion="1" height="100%" />
|
||||||
<button id="binding_rescue" proportion="2" height="100%" text="[none]"/>
|
<button id="binding_rescue" proportion="3" height="100%" text="[none]"/>
|
||||||
|
<spacer proportion="1" height="100%" />
|
||||||
</div>
|
</div>
|
||||||
<spacer height="5" width="10"/>
|
<spacer height="5" width="10"/>
|
||||||
|
|
||||||
<div width="85%" proportion="1" layout="horizontal-row" align="center">
|
<div width="85%" proportion="1" layout="horizontal-row" align="center">
|
||||||
<label proportion="2" height="100%" text="Look Back" text_align="right"/>
|
<label proportion="2" height="100%" text="Look Back" text_align="right"/>
|
||||||
<spacer proportion="1" height="100%" />
|
<spacer proportion="1" height="100%" />
|
||||||
<button id="binding_look_back" proportion="2" height="100%" text="[none]"/>
|
<button id="binding_look_back" proportion="3" height="100%" text="[none]"/>
|
||||||
|
<spacer proportion="1" height="100%" />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<spacer width="50" height="10" />
|
<spacer width="50" height="10" />
|
||||||
|
@ -274,7 +274,8 @@ namespace StateManager
|
|||||||
{
|
{
|
||||||
if(name == "devices")
|
if(name == "devices")
|
||||||
{
|
{
|
||||||
RibbonGridWidget* devices = dynamic_cast<RibbonGridWidget*>(widget);
|
RibbonGridWidget* devices = getCurrentScreen()->getWidget<RibbonGridWidget>("devices");
|
||||||
|
assert(devices != NULL);
|
||||||
|
|
||||||
const std::string& selection = devices->getSelectionName();
|
const std::string& selection = devices->getSelectionName();
|
||||||
if( selection.find("gamepad") != std::string::npos )
|
if( selection.find("gamepad") != std::string::npos )
|
||||||
|
@ -969,7 +969,7 @@ bool RibbonGridWidget::rightPressed()
|
|||||||
updateLabel();
|
updateLabel();
|
||||||
propagateSelection();
|
propagateSelection();
|
||||||
}
|
}
|
||||||
return false;
|
return true;
|
||||||
}
|
}
|
||||||
// -----------------------------------------------------------------------------
|
// -----------------------------------------------------------------------------
|
||||||
bool RibbonGridWidget::leftPressed()
|
bool RibbonGridWidget::leftPressed()
|
||||||
@ -982,7 +982,7 @@ bool RibbonGridWidget::leftPressed()
|
|||||||
updateLabel();
|
updateLabel();
|
||||||
propagateSelection();
|
propagateSelection();
|
||||||
}
|
}
|
||||||
return false;
|
return true;
|
||||||
}
|
}
|
||||||
// -----------------------------------------------------------------------------
|
// -----------------------------------------------------------------------------
|
||||||
bool RibbonGridWidget::transmitEvent(Widget* w, std::string& originator)
|
bool RibbonGridWidget::transmitEvent(Widget* w, std::string& originator)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user