diff options
Diffstat (limited to 'indra/newview/llprogressview.cpp')
-rw-r--r-- | indra/newview/llprogressview.cpp | 30 |
1 files changed, 19 insertions, 11 deletions
diff --git a/indra/newview/llprogressview.cpp b/indra/newview/llprogressview.cpp index 3add43a3c0..c77fc6dc84 100644 --- a/indra/newview/llprogressview.cpp +++ b/indra/newview/llprogressview.cpp @@ -85,6 +85,7 @@ bool LLProgressView::postBuild() mProgressText = getChild<LLTextBox>("progress_text"); mMessageText = getChild<LLTextBox>("message_text"); + mMessageTextRectInitial = mMessageText->getRect(); // auto resizes, save initial size // media control that is used to play intro video mMediaCtrl = getChild<LLMediaCtrl>("login_media_panel"); @@ -96,6 +97,12 @@ bool LLProgressView::postBuild() mCancelBtn = getChild<LLButton>("cancel_btn"); mCancelBtn->setClickedCallback( LLProgressView::onCancelButtonClicked, NULL ); + mLayoutPanel4 = getChild<LLView>("panel4"); + mLayoutPanel4RectInitial = mLayoutPanel4->getRect(); + + mLayoutMOTD = getChild<LLView>("panel_motd"); + mLayoutMOTDRectInitial = mLayoutMOTD->getRect(); + getChild<LLTextBox>("title_text")->setText(LLStringExplicit(LLAppViewer::instance()->getSecondLifeTitle())); getChild<LLTextBox>("message_text")->setClickedCallback(onClickMessage, this); @@ -341,6 +348,18 @@ void LLProgressView::setMessage(const std::string& msg) { mMessage = msg; mMessageText->setValue(mMessage); + S32 height = mMessageText->getTextPixelHeight(); + S32 delta = height - mMessageTextRectInitial.getHeight(); + if (delta > 0) + { + mLayoutPanel4->reshape(mLayoutPanel4RectInitial.getWidth(), mLayoutPanel4RectInitial.getHeight() + delta); + mLayoutMOTD->reshape(mLayoutMOTDRectInitial.getWidth(), mLayoutMOTDRectInitial.getHeight() + delta); + } + else + { + mLayoutPanel4->reshape(mLayoutPanel4RectInitial.getWidth(), mLayoutPanel4RectInitial.getHeight()); + mLayoutMOTD->reshape(mLayoutMOTDRectInitial.getWidth(), mLayoutMOTDRectInitial.getHeight()); + } } void LLProgressView::loadLogo(const std::string &path, @@ -433,17 +452,6 @@ void LLProgressView::initLogos() texture_start_x += icon_width + default_pad; #endif //LL_HAVOK - -/* - // 108x41 - icon_width = 74; - icon_height = default_height; - loadLogo(temp_str + "vivox_logo.png", - image_codec, - LLRect(texture_start_x, texture_start_y + icon_height, texture_start_x + icon_width, texture_start_y), - default_clip, - default_clip); -*/ } void LLProgressView::initStartTexture(S32 location_id, bool is_in_production) |