diff --git a/indra/newview/llnotify.cpp b/indra/newview/llnotify.cpp index 20145004f..c942aee44 100644 --- a/indra/newview/llnotify.cpp +++ b/indra/newview/llnotify.cpp @@ -242,6 +242,30 @@ LLNotifyBox::LLNotifyBox(LLNotificationPtr notification, // it appears below the caution textbox y = y - caution_height; } + else if (mIsCaution && mIsTip) + { + + const S32 BTN_TOP = BOTTOM_PAD + (((mNumOptions-1+2)/3)) * (BTN_HEIGHT+VPAD); + + // Tokenization on \n is handled by LLTextBox + + const S32 MAX_LENGTH = 512 + 20 + DB_FIRST_NAME_BUF_SIZE + DB_LAST_NAME_BUF_SIZE + DB_INV_ITEM_NAME_BUF_SIZE; // For script dialogs: add space for title. + + text = new LLTextEditor(std::string("box"), LLRect(x, y, getRect().getWidth()-2, mIsTip ? BOTTOM : BTN_TOP+16), MAX_LENGTH, mMessage, sFont, FALSE); + text->setWordWrap(TRUE); + text->setTabStop(FALSE); + text->setMouseOpaque(FALSE); + text->setBorderVisible(FALSE); + text->setTakesNonScrollClicks(FALSE); + text->setHideScrollbarForShortDocs(TRUE); + text->setReadOnlyBgColor ( LLColor4::transparent ); // the background color of the box is manually + // rendered under the text box, therefore we want + // the actual text box to be transparent + text->setReadOnlyFgColor ( gColors.getColor("NotifyCautionWarnColor") ); //sets caution text color for tip notifications + text->setEnabled(FALSE); // makes it read-only + text->setTabStop(FALSE); // can't tab to it (may be a problem for scrolling via keyboard) + addChild(text); + } else {