FIRE-660 Zi Ree - resizable camera floater highlights properly

--HG--
branch : Firestorm_2.4.2
meow-7.2.2
Arrehn 2011-03-19 13:47:52 -04:00
parent 1791288fb0
commit 860066fc32
2 changed files with 11 additions and 46 deletions

View File

@ -527,7 +527,7 @@ void LLJoystickCameraRotate::draw()
{
LLGLSUIDefault gls_ui;
getImageUnselected()->draw( 0, 0 );
getImageUnselected()->draw( getLocalRect() );
LLPointer<LLUIImage> image = getImageSelected();
if( mInTop )
@ -579,17 +579,20 @@ void LLJoystickCameraRotate::drawRotatedImage( LLPointer<LLUIImage> image, S32 r
gGL.begin(LLRender::QUADS);
{
S32 scaledWidth = getLocalRect().getWidth();
S32 scaledHeight = getLocalRect().getHeight();
gGL.texCoord2fv( uv[ (rotations + 0) % 4]);
gGL.vertex2i(width, height );
gGL.vertex2i(scaledWidth, scaledHeight );
gGL.texCoord2fv( uv[ (rotations + 1) % 4]);
gGL.vertex2i(0, height );
gGL.vertex2i(0, scaledHeight );
gGL.texCoord2fv( uv[ (rotations + 2) % 4]);
gGL.vertex2i(0, 0);
gGL.texCoord2fv( uv[ (rotations + 3) % 4]);
gGL.vertex2i(width, 0);
gGL.vertex2i(scaledWidth, 0);
}
gGL.end();
}

View File

@ -237,30 +237,11 @@
height="78"
width="78">
<!-- Fake control icon to simulate the joystick widget -->
<icon
follows="all"
height="78"
image_name="Cam_Rotate_Out"
layout="topleft"
left="0"
name="icon_cam_rotate_stick"
scale_image="true"
sound_flags="3"
visible="true"
top="0"
width="78" />
<!--
image_selected="Cam_Rotate_In"
image_unselected="Cam_Rotate_Out"
//-->
<joystick_rotate
follows="all"
height="78"
image_selected="Blank"
image_unselected="Blank"
image_selected="Cam_Rotate_In"
image_unselected="Cam_Rotate_Out"
layout="topleft"
left="0"
mouse_opaque="false"
@ -338,30 +319,11 @@
height="78"
width="78">
<!-- Fake control icon to simulate the joystick widget -->
<icon
follows="all"
height="78"
image_name="Cam_Tracking_Out"
layout="topleft"
left="0"
name="icon_cam_track_stick"
scale_image="true"
sound_flags="3"
visible="true"
top="0"
width="78" />
<!--
image_selected="Cam_Tracking_In"
image_unselected="Cam_Tracking_Out"
//-->
<joystick_track
follows="all"
height="78"
image_selected="Blank"
image_unselected="Blank"
image_selected="Cam_Tracking_In"
image_unselected="Cam_Tracking_Out"
layout="topleft"
left="0"
name="cam_track_stick"