diff options
author | James Cook <james@lindenlab.com> | 2007-01-02 08:33:20 +0000 |
---|---|---|
committer | James Cook <james@lindenlab.com> | 2007-01-02 08:33:20 +0000 |
commit | 420b91db29485df39fd6e724e782c449158811cb (patch) | |
tree | b471a94563af914d3ed3edd3e856d21cb1b69945 /indra/newview/llhudview.cpp |
Print done when done.
Diffstat (limited to 'indra/newview/llhudview.cpp')
-rw-r--r-- | indra/newview/llhudview.cpp | 78 |
1 files changed, 78 insertions, 0 deletions
diff --git a/indra/newview/llhudview.cpp b/indra/newview/llhudview.cpp new file mode 100644 index 0000000000..91cb5695ed --- /dev/null +++ b/indra/newview/llhudview.cpp @@ -0,0 +1,78 @@ +/** + * @file llhudview.cpp + * @brief 2D HUD overlay + * + * Copyright (c) 2003-$CurrentYear$, Linden Research, Inc. + * $License$ + */ + +#include "llviewerprecompiledheaders.h" + +#include "llhudview.h" + +// library includes +#include "v4color.h" +#include "llcoord.h" + +// viewer includes +#include "llagent.h" +#include "llcallingcard.h" +#include "llcolorscheme.h" +#include "llviewercontrol.h" +#include "llfloaterworldmap.h" +#include "llworldmapview.h" +#include "lltracker.h" +#include "llviewercamera.h" +#include "llui.h" + +LLHUDView *gHUDView = NULL; + +const S32 HUD_ARROW_SIZE = 32; + +LLHUDView::LLHUDView(const std::string& name, const LLRect& rect) +: LLView(name, rect, FALSE) +{ } + +LLHUDView::~LLHUDView() +{ } + +EWidgetType LLHUDView::getWidgetType() const +{ + return WIDGET_TYPE_HUD_VIEW; +} + +LLString LLHUDView::getWidgetTag() const +{ + return LL_HUD_VIEW_TAG; +} + +// virtual +void LLHUDView::draw() +{ + LLTracker::drawHUDArrow(); +} + + +// public +const LLColor4& LLHUDView::colorFromType(S32 type) +{ + switch (type) + { + case 0: + return LLColor4::green; + default: + return LLColor4::black; + } +} + + +/*virtual*/ +BOOL LLHUDView::handleMouseDown(S32 x, S32 y, MASK mask) +{ + if (LLTracker::handleMouseDown(x, y)) + { + return TRUE; + } + return LLView::handleMouseDown(x, y, mask); +} + |