1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-01-21 06:53:53 +00:00

Added transparency to 'owned' tooltip

This commit is contained in:
Andrei Kortunov 2017-08-08 22:57:39 +04:00
parent 8c1c80ab91
commit 56f5a5dee3
3 changed files with 21 additions and 3 deletions

View file

@ -378,9 +378,8 @@ namespace MWGui
{ {
mDynamicToolTipBox->setVisible(true); mDynamicToolTipBox->setVisible(true);
// TODO: apply alpha to "owned" background
if((mShowOwned == 1 || mShowOwned == 3) && isFocusObject && checkOwned()) if((mShowOwned == 1 || mShowOwned == 3) && isFocusObject && checkOwned())
mDynamicToolTipBox->changeWidgetSkin("HUD_Box_NoTransp_Owned"); mDynamicToolTipBox->changeWidgetSkin(MWBase::Environment::get().getWindowManager()->isGuiMode() ? "HUD_Box_NoTransp_Owned" : "HUD_Box_Owned");
else else
mDynamicToolTipBox->changeWidgetSkin(MWBase::Environment::get().getWindowManager()->isGuiMode() ? "HUD_Box_NoTransp" : "HUD_Box"); mDynamicToolTipBox->changeWidgetSkin(MWBase::Environment::get().getWindowManager()->isGuiMode() ? "HUD_Box_NoTransp" : "HUD_Box");

View file

@ -36,6 +36,18 @@
<!-- The interior of the box --> <!-- The interior of the box -->
<Child type="Widget" skin="DialogBG_NoTransp_Owned" offset="0 0 40 40" align="Stretch" name="Client"/>
<!-- Borders -->
<Child type="Widget" skin="MW_Box" offset="0 0 40 40" align="Left Stretch" name="Client"/>
</Resource>
<Resource type="ResourceSkin" name="HUD_Box_Owned" size="40 40">
<!-- The interior of the box -->
<Child type="Widget" skin="DialogBG_Owned" offset="0 0 40 40" align="Stretch" name="Client"/> <Child type="Widget" skin="DialogBG_Owned" offset="0 0 40 40" align="Stretch" name="Client"/>
<!-- Borders --> <!-- Borders -->

View file

@ -158,7 +158,14 @@
</Resource> </Resource>
<!-- Defines a owned background --> <!-- Defines a owned background -->
<Resource type="ResourceSkin" name="DialogBG_Owned" size="8 8" texture="white"> <Resource type="ResourceSkin" name="DialogBG_NoTransp_Owned" size="8 8" texture="white">
<Property key="Colour" value="#{setting=GUI,color background owned}"/>
<BasisSkin type="MainSkin" offset="0 0 8 8">
<State name="normal" offset="0 0 8 8"/>
</BasisSkin>
</Resource>
<Resource type="ResourceSkin" name="DialogBG_Owned" size="8 8" texture="transparent">
<Property key="Colour" value="#{setting=GUI,color background owned}"/> <Property key="Colour" value="#{setting=GUI,color background owned}"/>
<BasisSkin type="MainSkin" offset="0 0 8 8"> <BasisSkin type="MainSkin" offset="0 0 8 8">
<State name="normal" offset="0 0 8 8"/> <State name="normal" offset="0 0 8 8"/>