diff options
author | Jacek Antonelli | 2008-09-06 18:24:57 -0500 |
---|---|---|
committer | Jacek Antonelli | 2008-09-06 18:25:07 -0500 |
commit | 798d367d54a6c6379ad355bd8345fa40e31e7fe9 (patch) | |
tree | 1921f1708cd0240648c97bc02df2c2ab5f2fc41e /linden/indra/newview/lltoolview.cpp | |
parent | Second Life viewer sources 1.20.15 (diff) | |
download | meta-impy-798d367d54a6c6379ad355bd8345fa40e31e7fe9.zip meta-impy-798d367d54a6c6379ad355bd8345fa40e31e7fe9.tar.gz meta-impy-798d367d54a6c6379ad355bd8345fa40e31e7fe9.tar.bz2 meta-impy-798d367d54a6c6379ad355bd8345fa40e31e7fe9.tar.xz |
Second Life viewer sources 1.21.0-RC
Diffstat (limited to '')
-rw-r--r-- | linden/indra/newview/lltoolview.cpp | 88 |
1 files changed, 44 insertions, 44 deletions
diff --git a/linden/indra/newview/lltoolview.cpp b/linden/indra/newview/lltoolview.cpp index 13b6e2a..561147b 100644 --- a/linden/indra/newview/lltoolview.cpp +++ b/linden/indra/newview/lltoolview.cpp | |||
@@ -77,50 +77,50 @@ LLToolView::~LLToolView() | |||
77 | } | 77 | } |
78 | 78 | ||
79 | //*TODO:translate? | 79 | //*TODO:translate? |
80 | void LLToolView::addTool(const LLString& icon_off, const LLString& icon_on, LLPanel* panel, LLTool* tool, LLView* hoverView, const char* label) | 80 | // void LLToolView::addTool(const std::string& icon_off, const std::string& icon_on, LLPanel* panel, LLTool* tool, LLView* hoverView, const char* label) |
81 | { | 81 | // { |
82 | llassert(tool); | 82 | // llassert(tool); |
83 | 83 | ||
84 | LLToolContainer* contain = new LLToolContainer(this); | 84 | // LLToolContainer* contain = new LLToolContainer(this); |
85 | 85 | ||
86 | LLRect btn_rect = getButtonRect(mButtonCount); | 86 | // LLRect btn_rect = getButtonRect(mButtonCount); |
87 | 87 | ||
88 | contain->mButton = new LLButton("ToolBtn", | 88 | // contain->mButton = new LLButton("ToolBtn", |
89 | btn_rect, | 89 | // btn_rect, |
90 | icon_off, | 90 | // icon_off, |
91 | icon_on, | 91 | // icon_on, |
92 | "", | 92 | // "", |
93 | &LLToolView::onClickToolButton, | 93 | // &LLToolView::onClickToolButton, |
94 | contain, | 94 | // contain, |
95 | LLFontGL::sSansSerif); | 95 | // LLFontGL::sSansSerif); |
96 | 96 | ||
97 | contain->mPanel = panel; | 97 | // contain->mPanel = panel; |
98 | contain->mTool = tool; | 98 | // contain->mTool = tool; |
99 | 99 | ||
100 | addChild(contain->mButton); | 100 | // addChild(contain->mButton); |
101 | mButtonCount++; | 101 | // mButtonCount++; |
102 | 102 | ||
103 | const S32 LABEL_TOP_SPACING = 0; | 103 | // const S32 LABEL_TOP_SPACING = 0; |
104 | const LLFontGL* font = LLResMgr::getInstance()->getRes( LLFONT_SANSSERIF_SMALL ); | 104 | // const LLFontGL* font = LLResMgr::getInstance()->getRes( LLFONT_SANSSERIF_SMALL ); |
105 | S32 label_width = font->getWidth( label ); | 105 | // S32 label_width = font->getWidth( label ); |
106 | LLRect label_rect; | 106 | // LLRect label_rect; |
107 | label_rect.setLeftTopAndSize( | 107 | // label_rect.setLeftTopAndSize( |
108 | btn_rect.mLeft + btn_rect.getWidth() / 2 - label_width / 2, | 108 | // btn_rect.mLeft + btn_rect.getWidth() / 2 - label_width / 2, |
109 | btn_rect.mBottom - LABEL_TOP_SPACING, | 109 | // btn_rect.mBottom - LABEL_TOP_SPACING, |
110 | label_width, | 110 | // label_width, |
111 | llfloor(font->getLineHeight())); | 111 | // llfloor(font->getLineHeight())); |
112 | addChild( new LLTextBox( "tool label", label_rect, label, font ) ); | 112 | // addChild( new LLTextBox( "tool label", label_rect, label, font ) ); |
113 | 113 | ||
114 | // Can optionally ignore panel | 114 | // // Can optionally ignore panel |
115 | if (contain->mPanel) | 115 | // if (contain->mPanel) |
116 | { | 116 | // { |
117 | contain->mPanel->setBackgroundVisible( FALSE ); | 117 | // contain->mPanel->setBackgroundVisible( FALSE ); |
118 | contain->mPanel->setBorderVisible( FALSE ); | 118 | // contain->mPanel->setBorderVisible( FALSE ); |
119 | addChild(contain->mPanel); | 119 | // addChild(contain->mPanel); |
120 | } | 120 | // } |
121 | 121 | ||
122 | mContainList.push_back(contain); | 122 | // mContainList.push_back(contain); |
123 | } | 123 | // } |
124 | 124 | ||
125 | 125 | ||
126 | LLRect LLToolView::getButtonRect(S32 button_index) | 126 | LLRect LLToolView::getButtonRect(S32 button_index) |