summaryrefslogtreecommitdiff
path: root/indra/newview/lljoystickbutton.cpp
diff options
context:
space:
mode:
authorAndrew Dyukov <adyukov@productengine.com>2009-11-17 13:40:09 +0200
committerAndrew Dyukov <adyukov@productengine.com>2009-11-17 13:40:09 +0200
commite1aaaa34e45daca5a39a040865938cb3e2404f3e (patch)
tree8a8b8debd3f1db457ad3c0c90a5656c09757f9b2 /indra/newview/lljoystickbutton.cpp
parent93f8da6906dfd9c2bd34ffe82537e5f1b3c06f93 (diff)
Minor style changes for EXT-1014 (Unable to move undocked camera controls bar) fix.
--HG-- branch : product-engine
Diffstat (limited to 'indra/newview/lljoystickbutton.cpp')
-rw-r--r--indra/newview/lljoystickbutton.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/indra/newview/lljoystickbutton.cpp b/indra/newview/lljoystickbutton.cpp
index 0acc67ff5a..2cc5c8335d 100644
--- a/indra/newview/lljoystickbutton.cpp
+++ b/indra/newview/lljoystickbutton.cpp
@@ -136,13 +136,13 @@ void LLJoystick::updateSlop()
bool LLJoystick::pointInCircle(S32 x, S32 y) const
{
- if(this->getLocalRect().mTop!=this->getLocalRect().mRight)
+ if(this->getLocalRect().getHeight() != this->getLocalRect().getWidth())
{
llwarns << "Joystick shape is not square"<<llendl;
- return TRUE;
+ return true;
}
//center is x and y coordinates of center of joystick circle, and also its radius
- int center = this->getLocalRect().mTop/2;
+ int center = this->getLocalRect().getHeight()/2;
bool in_circle = (x - center) * (x - center) + (y - center) * (y - center) <= center * center;
return in_circle;
}