diff options
36 files changed, 486 insertions, 972 deletions
diff --git a/ChangeLog.txt b/ChangeLog.txt index 24a9082..d77522a 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt | |||
@@ -2,7 +2,108 @@ | |||
2 | =- 1.1.0 -= | 2 | =- 1.1.0 -= |
3 | =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- | 3 | =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- |
4 | 4 | ||
5 | 2009-01-20 Jacek Antonelli <jacek.antonelli@gmail.com> | 5 | 2009-01-24 McCabe Maxsted <hakushakukun@gmail.com> |
6 | |||
7 | * linden/indra/newview/llfloaterhtmlhelp.cpp: | ||
8 | Fixed 'open in external browser' button. | ||
9 | |||
10 | |||
11 | 2009-01-23 McCabe Maxsted <hakushakukun@gmail.com> | ||
12 | |||
13 | * linden/indra/llui/lltexteditor.cpp: | ||
14 | Backported Qarl's fix for VWR-8773: Closing parenthesis breaks urls. | ||
15 | |||
16 | * linden/indra/llcommon/llstring.h: | ||
17 | Backported fix for VWR-5529: group chat scrolls up when logging enabled. | ||
18 | * linden/indra/llui/lltexteditor.cpp: | ||
19 | Ditto. | ||
20 | * linden/indra/llui/lltexteditor.h: | ||
21 | Ditto. | ||
22 | * linden/indra/newview/skins/default/xui/en-us/floater_chat_history.xml: | ||
23 | Ditto. | ||
24 | * linden/indra/newview/skins/default/xui/en-us/floater_instant_message.xml: | ||
25 | Ditto. | ||
26 | * linden/indra/newview/skins/default/xui/en-us/floater_instant_message_ad_hoc.xml: | ||
27 | Ditto. | ||
28 | * linden/indra/newview/skins/default/xui/en-us/floater_instant_message_group.xml: | ||
29 | Ditto. | ||
30 | |||
31 | * linden/indra/llui/llkeywords.cpp: | ||
32 | Fixed single line comment highlighting. | ||
33 | |||
34 | |||
35 | 2009-01-22 McCabe Maxsted <hakushakukun@gmail.com> | ||
36 | |||
37 | * linden/indra/newview/llappviewer.cpp: | ||
38 | Windows version sets its own gstreamer environment variable. | ||
39 | * linden/indra/newview/llappviewer.h: | ||
40 | Ditto. | ||
41 | |||
42 | |||
43 | 2009-01-21 McCabe Maxsted <hakushakukun@gmail.com> | ||
44 | |||
45 | * linden/indra/newview/skins/default/xui/en-us/alerts.xml: | ||
46 | Added link to wiki tutorial and missing variables to build cheat sheet. | ||
47 | |||
48 | |||
49 | 2009-01-20 McCabe Maxsted <hakushakukun@gmail.com> | ||
50 | |||
51 | * linden/indra/newview/skins/default/xui/en-us/floater_media_browser.xml: | ||
52 | Fixed browser button layout. | ||
53 | |||
54 | * linden/indra/newview/app_settings/settings.xml: | ||
55 | Added new setting 'HelpSupportURL' for support homepage. | ||
56 | |||
57 | * linden/indra/newview/skins/default/xui/en-us/strings.xml: | ||
58 | Added translatable message for 'Set As Home' button. | ||
59 | |||
60 | * linden/indra/newview/llfloaterhtmlhelp.cpp: | ||
61 | Browser window now toggles from the menu, removed legacy F1 help code. | ||
62 | * linden/indra/newview/llfloaterhtmlhelp.h: | ||
63 | Ditto. | ||
64 | |||
65 | * linden/indra/newview/llfloaterhtml.cpp: | ||
66 | Deleted legacy browser window. | ||
67 | * linden/indra/newview/llfloaterhtml.h: | ||
68 | Ditto. | ||
69 | * linden/indra/newview/skins/default/xui/de/floater_html.xml: | ||
70 | Ditto. | ||
71 | * linden/indra/newview/skins/default/xui/en-us/floater_html.xml: | ||
72 | Ditto. | ||
73 | * linden/indra/newview/skins/default/xui/es/floater_html.xml: | ||
74 | Ditto. | ||
75 | * linden/indra/newview/skins/default/xui/fr/floater_html.xml: | ||
76 | Ditto. | ||
77 | * linden/indra/newview/skins/default/xui/ja/floater_html.xml: | ||
78 | Ditto. | ||
79 | * linden/indra/newview/skins/default/xui/ko/floater_html.xml: | ||
80 | Ditto. | ||
81 | * linden/indra/newview/skins/default/xui/pt/floater_html.xml: | ||
82 | Ditto. | ||
83 | * linden/indra/newview/skins/default/xui/zh/floater_html.xml: | ||
84 | Ditto. | ||
85 | * linden/indra/newview/CMakeLists.txt: | ||
86 | Ditto. | ||
87 | |||
88 | * linden/indra/newview/llfloaterchat.cpp: | ||
89 | Removed legacy include for llfloaterhtml.h | ||
90 | * linden/indra/newview/llwebbrowserctrl.cpp: | ||
91 | Ditto. | ||
92 | * linden/indra/newview/llimpanel.cpp: | ||
93 | Ditto. | ||
94 | * linden/indra/newview/llpanellogin.cpp: | ||
95 | Ditto. | ||
96 | * linden/indra/newview/llurldispatcher.cpp: | ||
97 | Ditto. | ||
98 | * linden/indra/newview/llviewermenu.cpp: | ||
99 | Ditto. | ||
100 | * linden/indra/newview/llviewerparcelmgr.cpp: | ||
101 | Ditto. | ||
102 | * linden/indra/newview/llviewerstats.cpp: | ||
103 | Ditto. | ||
104 | |||
105 | |||
106 | Jacek Antonelli <jacek.antonelli@gmail.com> | ||
6 | 107 | ||
7 | * linden/indra/newview/llfolderview.cpp: | 108 | * linden/indra/newview/llfolderview.cpp: |
8 | VWR-508/VWR-2199: Create "Worn Items" tab in Inventory | 109 | VWR-508/VWR-2199: Create "Worn Items" tab in Inventory |
diff --git a/linden/indra/llcommon/llstring.h b/linden/indra/llcommon/llstring.h index 7b08fd3..2d76eca 100644 --- a/linden/indra/llcommon/llstring.h +++ b/linden/indra/llcommon/llstring.h | |||
@@ -133,26 +133,32 @@ struct char_traits<U16> | |||
133 | class LLStringOps | 133 | class LLStringOps |
134 | { | 134 | { |
135 | public: | 135 | public: |
136 | static char toUpper(char elem) { return toupper(elem); } | 136 | static char toUpper(char elem) { return toupper((unsigned char)elem); } |
137 | static llwchar toUpper(llwchar elem) { return towupper(elem); } | 137 | static llwchar toUpper(llwchar elem) { return towupper(elem); } |
138 | 138 | ||
139 | static char toLower(char elem) { return tolower(elem); } | 139 | static char toLower(char elem) { return tolower((unsigned char)elem); } |
140 | static llwchar toLower(llwchar elem) { return towlower(elem); } | 140 | static llwchar toLower(llwchar elem) { return towlower(elem); } |
141 | 141 | ||
142 | static BOOL isSpace(char elem) { return isspace(elem) != 0; } | 142 | static bool isSpace(char elem) { return isspace((unsigned char)elem) != 0; } |
143 | static BOOL isSpace(llwchar elem) { return iswspace(elem) != 0; } | 143 | static bool isSpace(llwchar elem) { return iswspace(elem) != 0; } |
144 | 144 | ||
145 | static BOOL isUpper(char elem) { return isupper(elem) != 0; } | 145 | static bool isUpper(char elem) { return isupper((unsigned char)elem) != 0; } |
146 | static BOOL isUpper(llwchar elem) { return iswupper(elem) != 0; } | 146 | static bool isUpper(llwchar elem) { return iswupper(elem) != 0; } |
147 | 147 | ||
148 | static BOOL isLower(char elem) { return islower(elem) != 0; } | 148 | static bool isLower(char elem) { return islower((unsigned char)elem) != 0; } |
149 | static BOOL isLower(llwchar elem) { return iswlower(elem) != 0; } | 149 | static bool isLower(llwchar elem) { return iswlower(elem) != 0; } |
150 | |||
151 | static bool isDigit(char a) { return isdigit((unsigned char)a) != 0; } | ||
152 | static bool isDigit(llwchar a) { return iswdigit(a) != 0; } | ||
153 | |||
154 | static bool isPunct(char a) { return ispunct((unsigned char)a) != 0; } | ||
155 | static bool isPunct(llwchar a) { return iswpunct(a) != 0; } | ||
156 | |||
157 | static bool isAlnum(char a) { return isalnum((unsigned char)a) != 0; } | ||
158 | static bool isAlnum(llwchar a) { return iswalnum(a) != 0; } | ||
150 | 159 | ||
151 | static S32 collate(const char* a, const char* b) { return strcoll(a, b); } | 160 | static S32 collate(const char* a, const char* b) { return strcoll(a, b); } |
152 | static S32 collate(const llwchar* a, const llwchar* b); | 161 | static S32 collate(const llwchar* a, const llwchar* b); |
153 | |||
154 | static BOOL isDigit(char a) { return isdigit(a) != 0; } | ||
155 | static BOOL isDigit(llwchar a) { return iswdigit(a) != 0; } | ||
156 | }; | 162 | }; |
157 | 163 | ||
158 | /** | 164 | /** |
@@ -194,7 +200,7 @@ public: | |||
194 | typedef std::map<LLFormatMapString, LLFormatMapString> format_map_t; | 200 | typedef std::map<LLFormatMapString, LLFormatMapString> format_map_t; |
195 | static S32 format(std::basic_string<T>& s, const format_map_t& fmt_map); | 201 | static S32 format(std::basic_string<T>& s, const format_map_t& fmt_map); |
196 | 202 | ||
197 | static BOOL isValidIndex(const std::basic_string<T>& string, size_type i) | 203 | static bool isValidIndex(const std::basic_string<T>& string, size_type i) |
198 | { | 204 | { |
199 | return !string.empty() && (0 <= i) && (i <= string.size()); | 205 | return !string.empty() && (0 <= i) && (i <= string.size()); |
200 | } | 206 | } |
diff --git a/linden/indra/llui/llkeywords.cpp b/linden/indra/llui/llkeywords.cpp index 8cd33a2..cd58d70 100644 --- a/linden/indra/llui/llkeywords.cpp +++ b/linden/indra/llui/llkeywords.cpp | |||
@@ -412,6 +412,22 @@ void LLKeywords::findSegments(std::vector<LLTextSegment *>* seg_list, const LLWS | |||
412 | break; | 412 | break; |
413 | } | 413 | } |
414 | } | 414 | } |
415 | else if (cur_delimiter->isHead(cur)) | ||
416 | { | ||
417 | // Is there was an odd number of backslashes, then this delimiter | ||
418 | // does not end the sequence. | ||
419 | if (num_backslashes % 2 == 1) | ||
420 | { | ||
421 | between_delimiters++; | ||
422 | cur++; | ||
423 | } | ||
424 | else | ||
425 | { | ||
426 | // This is an end delimiter. | ||
427 | break; | ||
428 | } | ||
429 | } | ||
430 | |||
415 | } | 431 | } |
416 | else | 432 | else |
417 | { | 433 | { |
@@ -423,9 +439,25 @@ void LLKeywords::findSegments(std::vector<LLTextSegment *>* seg_list, const LLWS | |||
423 | if( *cur ) | 439 | if( *cur ) |
424 | { | 440 | { |
425 | cur += cur_delimiter->getLength(); | 441 | cur += cur_delimiter->getLength(); |
426 | seg_end = seg_start + between_delimiters | 442 | if (cur_delimiter->getType() == LLKeywordToken::TWO_SIDED_DELIMITER) |
427 | + cur_delimiter->getLength() | 443 | { |
428 | + cur_delimiter->getLength2(); | 444 | seg_end = seg_start + between_delimiters + 2 * cur_delimiter->getLength(); |
445 | } | ||
446 | else if (cur_delimiter->getType() == LLKeywordToken::ONE_SIDED_DELIMITER) | ||
447 | { | ||
448 | while( *cur && ('\n' != *cur) ) | ||
449 | { | ||
450 | between_delimiters++; | ||
451 | cur++; | ||
452 | } | ||
453 | seg_end = seg_start + between_delimiters + 2 + cur_delimiter->getLength(); | ||
454 | } | ||
455 | else | ||
456 | { | ||
457 | seg_end = seg_start + between_delimiters | ||
458 | + cur_delimiter->getLength() | ||
459 | + cur_delimiter->getLength2(); | ||
460 | } | ||
429 | } | 461 | } |
430 | else | 462 | else |
431 | { | 463 | { |
@@ -435,7 +467,6 @@ void LLKeywords::findSegments(std::vector<LLTextSegment *>* seg_list, const LLWS | |||
435 | } | 467 | } |
436 | else | 468 | else |
437 | { | 469 | { |
438 | llassert( cur_delimiter->getType() == LLKeywordToken::ONE_SIDED_DELIMITER ); | ||
439 | // Left side is the delimiter. Right side is eol or eof. | 470 | // Left side is the delimiter. Right side is eol or eof. |
440 | while( *cur && ('\n' != *cur) ) | 471 | while( *cur && ('\n' != *cur) ) |
441 | { | 472 | { |
@@ -445,7 +476,6 @@ void LLKeywords::findSegments(std::vector<LLTextSegment *>* seg_list, const LLWS | |||
445 | seg_end = seg_start + between_delimiters + cur_delimiter->getLength(); | 476 | seg_end = seg_start + between_delimiters + cur_delimiter->getLength(); |
446 | } | 477 | } |
447 | 478 | ||
448 | |||
449 | LLTextSegment* text_segment = new LLTextSegment( cur_delimiter->getColor(), seg_start, seg_end ); | 479 | LLTextSegment* text_segment = new LLTextSegment( cur_delimiter->getColor(), seg_start, seg_end ); |
450 | text_segment->setToken( cur_delimiter ); | 480 | text_segment->setToken( cur_delimiter ); |
451 | insertSegment( seg_list, text_segment, text_len, defaultColor); | 481 | insertSegment( seg_list, text_segment, text_len, defaultColor); |
diff --git a/linden/indra/llui/lltexteditor.cpp b/linden/indra/llui/lltexteditor.cpp index e56002f..72d8f17 100644 --- a/linden/indra/llui/lltexteditor.cpp +++ b/linden/indra/llui/lltexteditor.cpp | |||
@@ -260,7 +260,7 @@ LLTextEditor::LLTextEditor( | |||
260 | mIsSelecting( FALSE ), | 260 | mIsSelecting( FALSE ), |
261 | mSelectionStart( 0 ), | 261 | mSelectionStart( 0 ), |
262 | mSelectionEnd( 0 ), | 262 | mSelectionEnd( 0 ), |
263 | mScrolledToBottom( FALSE ), | 263 | mScrolledToBottom( TRUE ), |
264 | mOnScrollEndCallback( NULL ), | 264 | mOnScrollEndCallback( NULL ), |
265 | mOnScrollEndData( NULL ), | 265 | mOnScrollEndData( NULL ), |
266 | mCursorColor( LLUI::sColorsGroup->getColor( "TextCursorColor" ) ), | 266 | mCursorColor( LLUI::sColorsGroup->getColor( "TextCursorColor" ) ), |
@@ -277,14 +277,16 @@ LLTextEditor::LLTextEditor( | |||
277 | mCommitOnFocusLost( FALSE ), | 277 | mCommitOnFocusLost( FALSE ), |
278 | mHideScrollbarForShortDocs( FALSE ), | 278 | mHideScrollbarForShortDocs( FALSE ), |
279 | mTakesNonScrollClicks( TRUE ), | 279 | mTakesNonScrollClicks( TRUE ), |
280 | mTrackBottom( TRUE ), | 280 | mTrackBottom( FALSE ), |
281 | mAllowEmbeddedItems( allow_embedded_items ), | 281 | mAllowEmbeddedItems( allow_embedded_items ), |
282 | mAcceptCallingCardNames(FALSE), | 282 | mAcceptCallingCardNames(FALSE), |
283 | mHandleEditKeysDirectly( FALSE ), | 283 | mHandleEditKeysDirectly( FALSE ), |
284 | mMouseDownX(0), | 284 | mMouseDownX(0), |
285 | mMouseDownY(0), | 285 | mMouseDownY(0), |
286 | mLastSelectionX(-1), | 286 | mLastSelectionX(-1), |
287 | mLastSelectionY(-1) | 287 | mLastSelectionY(-1), |
288 | mReflowNeeded(FALSE), | ||
289 | mScrollNeeded(FALSE) | ||
288 | { | 290 | { |
289 | mSourceID.generate(); | 291 | mSourceID.generate(); |
290 | 292 | ||
@@ -468,6 +470,13 @@ void LLTextEditor::updateLineStartList(S32 startpos) | |||
468 | mScrollbar->setVisible(!short_doc); | 470 | mScrollbar->setVisible(!short_doc); |
469 | } | 471 | } |
470 | 472 | ||
473 | // if scrolled to bottom, stay at bottom | ||
474 | // unless user is editing text | ||
475 | // do this after updating page size | ||
476 | if (mScrolledToBottom && mTrackBottom && !hasFocus()) | ||
477 | { | ||
478 | endOfDoc(); | ||
479 | } | ||
471 | } | 480 | } |
472 | 481 | ||
473 | //////////////////////////////////////////////////////////// | 482 | //////////////////////////////////////////////////////////// |
@@ -511,8 +520,7 @@ void LLTextEditor::setText(const LLStringExplicit &utf8str) | |||
511 | setCursorPos(0); | 520 | setCursorPos(0); |
512 | deselect(); | 521 | deselect(); |
513 | 522 | ||
514 | updateLineStartList(); | 523 | needsReflow(); |
515 | updateScrollFromCursor(); | ||
516 | 524 | ||
517 | resetDirty(); | 525 | resetDirty(); |
518 | } | 526 | } |
@@ -529,8 +537,7 @@ void LLTextEditor::setWText(const LLWString &wtext) | |||
529 | setCursorPos(0); | 537 | setCursorPos(0); |
530 | deselect(); | 538 | deselect(); |
531 | 539 | ||
532 | updateLineStartList(); | 540 | needsReflow(); |
533 | updateScrollFromCursor(); | ||
534 | 541 | ||
535 | resetDirty(); | 542 | resetDirty(); |
536 | } | 543 | } |
@@ -568,8 +575,7 @@ void LLTextEditor::setWordWrap(BOOL b) | |||
568 | setCursorPos(0); | 575 | setCursorPos(0); |
569 | deselect(); | 576 | deselect(); |
570 | 577 | ||
571 | updateLineStartList(); | 578 | needsReflow(); |
572 | updateScrollFromCursor(); | ||
573 | } | 579 | } |
574 | 580 | ||
575 | 581 | ||
@@ -734,6 +740,7 @@ S32 LLTextEditor::getLineStart( S32 line ) const | |||
734 | { | 740 | { |
735 | return 0; | 741 | return 0; |
736 | } | 742 | } |
743 | |||
737 | line = llclamp(line, 0, num_lines-1); | 744 | line = llclamp(line, 0, num_lines-1); |
738 | S32 segidx = mLineStartList[line].mSegment; | 745 | S32 segidx = mLineStartList[line].mSegment; |
739 | S32 segoffset = mLineStartList[line].mOffset; | 746 | S32 segoffset = mLineStartList[line].mOffset; |
@@ -781,14 +788,14 @@ void LLTextEditor::getSegmentAndOffset( S32 startpos, S32* segidxp, S32* offsetp | |||
781 | *offsetp = startpos - (*seg_iter)->getStart(); | 788 | *offsetp = startpos - (*seg_iter)->getStart(); |
782 | } | 789 | } |
783 | 790 | ||
784 | const LLTextSegment* LLTextEditor::getPreviousSegment() | 791 | const LLTextSegment* LLTextEditor::getPreviousSegment() const |
785 | { | 792 | { |
786 | // find segment index at character to left of cursor (or rightmost edge of selection) | 793 | // find segment index at character to left of cursor (or rightmost edge of selection) |
787 | S32 idx = llmax(0, getSegmentIdxAtOffset(mCursorPos) - 1); | 794 | S32 idx = llmax(0, getSegmentIdxAtOffset(mCursorPos) - 1); |
788 | return idx >= 0 ? mSegments[idx] : NULL; | 795 | return idx >= 0 ? mSegments[idx] : NULL; |
789 | } | 796 | } |
790 | 797 | ||
791 | void LLTextEditor::getSelectedSegments(std::vector<const LLTextSegment*>& segments) | 798 | void LLTextEditor::getSelectedSegments(std::vector<const LLTextSegment*>& segments) const |
792 | { | 799 | { |
793 | S32 left = hasSelection() ? llmin(mSelectionStart, mSelectionEnd) : mCursorPos; | 800 | S32 left = hasSelection() ? llmin(mSelectionStart, mSelectionEnd) : mCursorPos; |
794 | S32 right = hasSelection() ? llmax(mSelectionStart, mSelectionEnd) : mCursorPos; | 801 | S32 right = hasSelection() ? llmax(mSelectionStart, mSelectionEnd) : mCursorPos; |
@@ -875,13 +882,12 @@ void LLTextEditor::setCursor(S32 row, S32 column) | |||
875 | } | 882 | } |
876 | doc += column; | 883 | doc += column; |
877 | setCursorPos(doc - mWText.c_str()); | 884 | setCursorPos(doc - mWText.c_str()); |
878 | updateScrollFromCursor(); | ||
879 | } | 885 | } |
880 | 886 | ||
881 | void LLTextEditor::setCursorPos(S32 offset) | 887 | void LLTextEditor::setCursorPos(S32 offset) |
882 | { | 888 | { |
883 | mCursorPos = llclamp(offset, 0, (S32)getLength()); | 889 | mCursorPos = llclamp(offset, 0, (S32)getLength()); |
884 | updateScrollFromCursor(); | 890 | needsScroll(); |
885 | // reset desired x cursor position | 891 | // reset desired x cursor position |
886 | mDesiredXPixel = -1; | 892 | mDesiredXPixel = -1; |
887 | } | 893 | } |
@@ -925,7 +931,7 @@ BOOL LLTextEditor::selectionContainsLineBreaks() | |||
925 | if (hasSelection()) | 931 | if (hasSelection()) |
926 | { | 932 | { |
927 | S32 left = llmin(mSelectionStart, mSelectionEnd); | 933 | S32 left = llmin(mSelectionStart, mSelectionEnd); |
928 | S32 right = left + abs(mSelectionStart - mSelectionEnd); | 934 | S32 right = left + llabs(mSelectionStart - mSelectionEnd); |
929 | 935 | ||
930 | const LLWString &wtext = mWText; | 936 | const LLWString &wtext = mWText; |
931 | for( S32 i = left; i < right; i++ ) | 937 | for( S32 i = left; i < right; i++ ) |
@@ -981,7 +987,7 @@ void LLTextEditor::indentSelectedLines( S32 spaces ) | |||
981 | { | 987 | { |
982 | const LLWString &text = mWText; | 988 | const LLWString &text = mWText; |
983 | S32 left = llmin( mSelectionStart, mSelectionEnd ); | 989 | S32 left = llmin( mSelectionStart, mSelectionEnd ); |
984 | S32 right = left + abs( mSelectionStart - mSelectionEnd ); | 990 | S32 right = left + llabs( mSelectionStart - mSelectionEnd ); |
985 | BOOL cursor_on_right = (mSelectionEnd > mSelectionStart); | 991 | BOOL cursor_on_right = (mSelectionEnd > mSelectionStart); |
986 | S32 cur = left; | 992 | S32 cur = left; |
987 | 993 | ||
@@ -1222,8 +1228,6 @@ BOOL LLTextEditor::handleHover(S32 x, S32 y, MASK mask) | |||
1222 | 1228 | ||
1223 | setCursorAtLocalPos( x, y, TRUE ); | 1229 | setCursorAtLocalPos( x, y, TRUE ); |
1224 | mSelectionEnd = mCursorPos; | 1230 | mSelectionEnd = mCursorPos; |
1225 | |||
1226 | updateScrollFromCursor(); | ||
1227 | } | 1231 | } |
1228 | 1232 | ||
1229 | lldebugst(LLERR_USER_INPUT) << "hover handled by " << getName() << " (active)" << llendl; | 1233 | lldebugst(LLERR_USER_INPUT) << "hover handled by " << getName() << " (active)" << llendl; |
@@ -1812,7 +1816,7 @@ void LLTextEditor::deleteSelection(BOOL group_with_next_op ) | |||
1812 | if( getEnabled() && hasSelection() ) | 1816 | if( getEnabled() && hasSelection() ) |
1813 | { | 1817 | { |
1814 | S32 pos = llmin( mSelectionStart, mSelectionEnd ); | 1818 | S32 pos = llmin( mSelectionStart, mSelectionEnd ); |
1815 | S32 length = abs( mSelectionStart - mSelectionEnd ); | 1819 | S32 length = llabs( mSelectionStart - mSelectionEnd ); |
1816 | 1820 | ||
1817 | remove( pos, length, group_with_next_op ); | 1821 | remove( pos, length, group_with_next_op ); |
1818 | 1822 | ||
@@ -1835,12 +1839,11 @@ void LLTextEditor::cut() | |||
1835 | return; | 1839 | return; |
1836 | } | 1840 | } |
1837 | S32 left_pos = llmin( mSelectionStart, mSelectionEnd ); | 1841 | S32 left_pos = llmin( mSelectionStart, mSelectionEnd ); |
1838 | S32 length = abs( mSelectionStart - mSelectionEnd ); | 1842 | S32 length = llabs( mSelectionStart - mSelectionEnd ); |
1839 | gClipboard.copyFromSubstring( mWText, left_pos, length, mSourceID ); | 1843 | gClipboard.copyFromSubstring( mWText, left_pos, length, mSourceID ); |
1840 | deleteSelection( FALSE ); | 1844 | deleteSelection( FALSE ); |
1841 | 1845 | ||
1842 | updateLineStartList(); | 1846 | needsReflow(); |
1843 | updateScrollFromCursor(); | ||
1844 | } | 1847 | } |
1845 | 1848 | ||
1846 | BOOL LLTextEditor::canCopy() const | 1849 | BOOL LLTextEditor::canCopy() const |
@@ -1856,7 +1859,7 @@ void LLTextEditor::copy() | |||
1856 | return; | 1859 | return; |
1857 | } | 1860 | } |
1858 | S32 left_pos = llmin( mSelectionStart, mSelectionEnd ); | 1861 | S32 left_pos = llmin( mSelectionStart, mSelectionEnd ); |
1859 | S32 length = abs( mSelectionStart - mSelectionEnd ); | 1862 | S32 length = llabs( mSelectionStart - mSelectionEnd ); |
1860 | gClipboard.copyFromSubstring(mWText, left_pos, length, mSourceID); | 1863 | gClipboard.copyFromSubstring(mWText, left_pos, length, mSourceID); |
1861 | } | 1864 | } |
1862 | 1865 | ||
@@ -1910,8 +1913,7 @@ void LLTextEditor::paste() | |||
1910 | setCursorPos(mCursorPos + insert(mCursorPos, clean_string, FALSE)); | 1913 | setCursorPos(mCursorPos + insert(mCursorPos, clean_string, FALSE)); |
1911 | deselect(); | 1914 | deselect(); |
1912 | 1915 | ||
1913 | updateLineStartList(); | 1916 | needsReflow(); |
1914 | updateScrollFromCursor(); | ||
1915 | } | 1917 | } |
1916 | 1918 | ||
1917 | 1919 | ||
@@ -2235,9 +2237,9 @@ BOOL LLTextEditor::handleKeyHere(KEY key, MASK mask ) | |||
2235 | 2237 | ||
2236 | if(text_may_have_changed) | 2238 | if(text_may_have_changed) |
2237 | { | 2239 | { |
2238 | updateLineStartList(); | 2240 | needsReflow(); |
2239 | } | 2241 | } |
2240 | updateScrollFromCursor(); | 2242 | needsScroll(); |
2241 | } | 2243 | } |
2242 | } | 2244 | } |
2243 | 2245 | ||
@@ -2280,8 +2282,7 @@ BOOL LLTextEditor::handleUnicodeCharHere(llwchar uni_char) | |||
2280 | // Most keystrokes will make the selection box go away, but not all will. | 2282 | // Most keystrokes will make the selection box go away, but not all will. |
2281 | deselect(); | 2283 | deselect(); |
2282 | 2284 | ||
2283 | updateLineStartList(); | 2285 | needsReflow(); |
2284 | updateScrollFromCursor(); | ||
2285 | } | 2286 | } |
2286 | } | 2287 | } |
2287 | 2288 | ||
@@ -2339,8 +2340,7 @@ void LLTextEditor::doDelete() | |||
2339 | } | 2340 | } |
2340 | } | 2341 | } |
2341 | 2342 | ||
2342 | updateLineStartList(); | 2343 | needsReflow(); |
2343 | updateScrollFromCursor(); | ||
2344 | } | 2344 | } |
2345 | 2345 | ||
2346 | //---------------------------------------------------------------------------- | 2346 | //---------------------------------------------------------------------------- |
@@ -2383,8 +2383,7 @@ void LLTextEditor::undo() | |||
2383 | 2383 | ||
2384 | setCursorPos(pos); | 2384 | setCursorPos(pos); |
2385 | 2385 | ||
2386 | updateLineStartList(); | 2386 | needsReflow(); |
2387 | updateScrollFromCursor(); | ||
2388 | } | 2387 | } |
2389 | 2388 | ||
2390 | BOOL LLTextEditor::canRedo() const | 2389 | BOOL LLTextEditor::canRedo() const |
@@ -2426,8 +2425,7 @@ void LLTextEditor::redo() | |||
2426 | 2425 | ||
2427 | setCursorPos(pos); | 2426 | setCursorPos(pos); |
2428 | 2427 | ||
2429 | updateLineStartList(); | 2428 | needsReflow(); |
2430 | updateScrollFromCursor(); | ||
2431 | } | 2429 | } |
2432 | 2430 | ||
2433 | void LLTextEditor::onFocusReceived() | 2431 | void LLTextEditor::onFocusReceived() |
@@ -3100,6 +3098,20 @@ void LLTextEditor::drawClippedSegment(const LLWString &text, S32 seg_start, S32 | |||
3100 | 3098 | ||
3101 | void LLTextEditor::draw() | 3099 | void LLTextEditor::draw() |
3102 | { | 3100 | { |
3101 | // do on-demand reflow | ||
3102 | if (mReflowNeeded) | ||
3103 | { | ||
3104 | updateLineStartList(); | ||
3105 | mReflowNeeded = FALSE; | ||
3106 | } | ||
3107 | |||
3108 | // then update scroll position, as cursor may have moved | ||
3109 | if (mScrollNeeded) | ||
3110 | { | ||
3111 | updateScrollFromCursor(); | ||
3112 | mScrollNeeded = FALSE; | ||
3113 | } | ||
3114 | |||
3103 | { | 3115 | { |
3104 | LLLocalClipRect clip(LLRect(0, getRect().getHeight(), getRect().getWidth() - (mScrollbar->getVisible() ? SCROLLBAR_SIZE : 0), 0)); | 3116 | LLLocalClipRect clip(LLRect(0, getRect().getHeight(), getRect().getWidth() - (mScrollbar->getVisible() ? SCROLLBAR_SIZE : 0), 0)); |
3105 | 3117 | ||
@@ -3118,10 +3130,10 @@ void LLTextEditor::draw() | |||
3118 | mBorder->setKeyboardFocusHighlight( gFocusMgr.getKeyboardFocus() == this);// && !mReadOnly); | 3130 | mBorder->setKeyboardFocusHighlight( gFocusMgr.getKeyboardFocus() == this);// && !mReadOnly); |
3119 | } | 3131 | } |
3120 | 3132 | ||
3133 | LLView::draw(); // Draw children (scrollbar and border) | ||
3134 | |||
3121 | // remember if we are supposed to be at the bottom of the buffer | 3135 | // remember if we are supposed to be at the bottom of the buffer |
3122 | mScrolledToBottom = isScrolledToBottom(); | 3136 | mScrolledToBottom = isScrolledToBottom(); |
3123 | |||
3124 | LLView::draw(); // Draw children (scrollbar and border) | ||
3125 | } | 3137 | } |
3126 | 3138 | ||
3127 | 3139 | ||
@@ -3311,7 +3323,7 @@ void LLTextEditor::setCursorAndScrollToEnd() | |||
3311 | { | 3323 | { |
3312 | deselect(); | 3324 | deselect(); |
3313 | endOfDoc(); | 3325 | endOfDoc(); |
3314 | updateScrollFromCursor(); | 3326 | needsScroll(); |
3315 | } | 3327 | } |
3316 | 3328 | ||
3317 | void LLTextEditor::getLineAndColumnForPosition( S32 position, S32* line, S32* col, BOOL include_wordwrap ) | 3329 | void LLTextEditor::getLineAndColumnForPosition( S32 position, S32* line, S32* col, BOOL include_wordwrap ) |
@@ -3374,7 +3386,9 @@ void LLTextEditor::endOfLine() | |||
3374 | 3386 | ||
3375 | void LLTextEditor::endOfDoc() | 3387 | void LLTextEditor::endOfDoc() |
3376 | { | 3388 | { |
3377 | mScrollbar->setDocPos( mScrollbar->getDocPosMax() ); | 3389 | mScrollbar->setDocPos(mScrollbar->getDocPosMax()); |
3390 | mScrolledToBottom = true; | ||
3391 | |||
3378 | S32 len = getLength(); | 3392 | S32 len = getLength(); |
3379 | if( len ) | 3393 | if( len ) |
3380 | { | 3394 | { |
@@ -3438,7 +3452,7 @@ void LLTextEditor::reshape(S32 width, S32 height, BOOL called_from_parent) | |||
3438 | // up-to-date mTextRect | 3452 | // up-to-date mTextRect |
3439 | updateTextRect(); | 3453 | updateTextRect(); |
3440 | 3454 | ||
3441 | updateLineStartList(); | 3455 | needsReflow(); |
3442 | 3456 | ||
3443 | // propagate shape information to scrollbar | 3457 | // propagate shape information to scrollbar |
3444 | mScrollbar->setDocSize( getLineCount() ); | 3458 | mScrollbar->setDocSize( getLineCount() ); |
@@ -3446,14 +3460,6 @@ void LLTextEditor::reshape(S32 width, S32 height, BOOL called_from_parent) | |||
3446 | S32 line_height = llround( mGLFont->getLineHeight() ); | 3460 | S32 line_height = llround( mGLFont->getLineHeight() ); |
3447 | S32 page_lines = mTextRect.getHeight() / line_height; | 3461 | S32 page_lines = mTextRect.getHeight() / line_height; |
3448 | mScrollbar->setPageSize( page_lines ); | 3462 | mScrollbar->setPageSize( page_lines ); |
3449 | |||
3450 | // if scrolled to bottom, stay at bottom | ||
3451 | // unless user is editing text | ||
3452 | // do this after updating page size | ||
3453 | if (mScrolledToBottom && mTrackBottom && !hasFocus()) | ||
3454 | { | ||
3455 | endOfDoc(); | ||
3456 | } | ||
3457 | } | 3463 | } |
3458 | 3464 | ||
3459 | void LLTextEditor::autoIndent() | 3465 | void LLTextEditor::autoIndent() |
@@ -3500,8 +3506,7 @@ void LLTextEditor::insertText(const std::string &new_text) | |||
3500 | 3506 | ||
3501 | setCursorPos(mCursorPos + insert( mCursorPos, utf8str_to_wstring(new_text), FALSE )); | 3507 | setCursorPos(mCursorPos + insert( mCursorPos, utf8str_to_wstring(new_text), FALSE )); |
3502 | 3508 | ||
3503 | updateLineStartList(); | 3509 | needsReflow(); |
3504 | updateScrollFromCursor(); | ||
3505 | 3510 | ||
3506 | setEnabled( enabled ); | 3511 | setEnabled( enabled ); |
3507 | } | 3512 | } |
@@ -3600,7 +3605,7 @@ void LLTextEditor::appendText(const std::string &new_text, bool allow_undo, bool | |||
3600 | mSegments.push_back(segment); | 3605 | mSegments.push_back(segment); |
3601 | } | 3606 | } |
3602 | 3607 | ||
3603 | updateLineStartList(old_length); | 3608 | needsReflow(); |
3604 | 3609 | ||
3605 | // Set the cursor and scroll position | 3610 | // Set the cursor and scroll position |
3606 | // Maintain the scroll position unless the scroll was at the end of the doc (in which | 3611 | // Maintain the scroll position unless the scroll was at the end of the doc (in which |
@@ -3639,14 +3644,6 @@ void LLTextEditor::appendText(const std::string &new_text, bool allow_undo, bool | |||
3639 | { | 3644 | { |
3640 | blockUndo(); | 3645 | blockUndo(); |
3641 | } | 3646 | } |
3642 | |||
3643 | // if scrolled to bottom, stay at bottom | ||
3644 | // unless user is editing text | ||
3645 | // do this after updating page size | ||
3646 | if (mScrolledToBottom && mTrackBottom && !hasFocus()) | ||
3647 | { | ||
3648 | endOfDoc(); | ||
3649 | } | ||
3650 | } | 3647 | } |
3651 | 3648 | ||
3652 | void LLTextEditor::removeTextFromEnd(S32 num_chars) | 3649 | void LLTextEditor::removeTextFromEnd(S32 num_chars) |
@@ -3661,7 +3658,10 @@ void LLTextEditor::removeTextFromEnd(S32 num_chars) | |||
3661 | mSelectionEnd = llclamp(mSelectionEnd, 0, len); | 3658 | mSelectionEnd = llclamp(mSelectionEnd, 0, len); |
3662 | 3659 | ||
3663 | pruneSegments(); | 3660 | pruneSegments(); |
3661 | |||
3662 | // pruneSegments will invalidate mLineStartList. | ||
3664 | updateLineStartList(); | 3663 | updateLineStartList(); |
3664 | needsScroll(); | ||
3665 | } | 3665 | } |
3666 | 3666 | ||
3667 | /////////////////////////////////////////////////////////////////// | 3667 | /////////////////////////////////////////////////////////////////// |
@@ -3759,8 +3759,7 @@ BOOL LLTextEditor::tryToRevertToPristineState() | |||
3759 | } | 3759 | } |
3760 | } | 3760 | } |
3761 | 3761 | ||
3762 | updateLineStartList(); | 3762 | needsReflow(); |
3763 | updateScrollFromCursor(); | ||
3764 | } | 3763 | } |
3765 | 3764 | ||
3766 | return isPristine(); // TRUE => success | 3765 | return isPristine(); // TRUE => success |
@@ -3808,6 +3807,7 @@ void LLTextEditor::updateSegments() | |||
3808 | { | 3807 | { |
3809 | findEmbeddedItemSegments(); | 3808 | findEmbeddedItemSegments(); |
3810 | } | 3809 | } |
3810 | |||
3811 | // Make sure we have at least one segment | 3811 | // Make sure we have at least one segment |
3812 | if (mSegments.size() == 1 && mSegments[0]->getIsDefault()) | 3812 | if (mSegments.size() == 1 && mSegments[0]->getIsDefault()) |
3813 | { | 3813 | { |
@@ -3824,6 +3824,7 @@ void LLTextEditor::updateSegments() | |||
3824 | } | 3824 | } |
3825 | 3825 | ||
3826 | // Only effective if text was removed from the end of the editor | 3826 | // Only effective if text was removed from the end of the editor |
3827 | // *NOTE: Using this will invalidate references to mSegments from mLineStartList. | ||
3827 | void LLTextEditor::pruneSegments() | 3828 | void LLTextEditor::pruneSegments() |
3828 | { | 3829 | { |
3829 | S32 len = mWText.length(); | 3830 | S32 len = mWText.length(); |
@@ -4066,9 +4067,7 @@ BOOL LLTextEditor::importBuffer(const char* buffer, S32 length ) | |||
4066 | setCursorPos(0); | 4067 | setCursorPos(0); |
4067 | deselect(); | 4068 | deselect(); |
4068 | 4069 | ||
4069 | updateLineStartList(); | 4070 | needsReflow(); |
4070 | updateScrollFromCursor(); | ||
4071 | |||
4072 | return success; | 4071 | return success; |
4073 | } | 4072 | } |
4074 | 4073 | ||
@@ -4260,35 +4259,55 @@ S32 LLTextEditor::findHTMLToken(const std::string &line, S32 pos, BOOL reverse) | |||
4260 | std::string openers=" \t\n('\"[{<>"; | 4259 | std::string openers=" \t\n('\"[{<>"; |
4261 | std::string closers=" \t\n)'\"]}><;"; | 4260 | std::string closers=" \t\n)'\"]}><;"; |
4262 | 4261 | ||
4263 | S32 m2 = 0; | 4262 | S32 index = 0; |
4264 | S32 retval = 0; | ||
4265 | 4263 | ||
4266 | if (reverse) | 4264 | if (reverse) |
4267 | { | 4265 | { |
4268 | 4266 | for (index=pos; index >= 0; index--) | |
4269 | for (retval=pos; retval >= 0; retval--) | ||
4270 | { | 4267 | { |
4271 | m2 = openers.find(line.substr(retval,1)); | 4268 | char c = line[index]; |
4269 | S32 m2 = openers.find(c); | ||
4272 | if (m2 >= 0) | 4270 | if (m2 >= 0) |
4273 | { | 4271 | { |
4274 | break; | 4272 | return index+1; |
4275 | } | 4273 | } |
4276 | } | 4274 | } |
4277 | return retval+1; | ||
4278 | } | 4275 | } |
4279 | else | 4276 | else |
4280 | { | 4277 | { |
4281 | 4278 | // adjust the search slightly, to allow matching parenthesis inside the URL | |
4282 | for (retval=pos; retval<(S32)line.length(); retval++) | 4279 | S32 paren_count = 0; |
4280 | for (index=pos; index<(S32)line.length(); index++) | ||
4283 | { | 4281 | { |
4284 | m2 = closers.find(line.substr(retval,1)); | 4282 | char c = line[index]; |
4285 | if (m2 >= 0) | 4283 | |
4284 | if (c == '(') | ||
4286 | { | 4285 | { |
4287 | break; | 4286 | paren_count++; |
4287 | } | ||
4288 | else if (c == ')') | ||
4289 | { | ||
4290 | if (paren_count <= 0) | ||
4291 | { | ||
4292 | return index; | ||
4293 | } | ||
4294 | else | ||
4295 | { | ||
4296 | paren_count--; | ||
4297 | } | ||
4298 | } | ||
4299 | else | ||
4300 | { | ||
4301 | S32 m2 = closers.find(c); | ||
4302 | if (m2 >= 0) | ||
4303 | { | ||
4304 | return index; | ||
4305 | } | ||
4288 | } | 4306 | } |
4289 | } | 4307 | } |
4290 | return retval; | 4308 | } |
4291 | } | 4309 | |
4310 | return index; | ||
4292 | } | 4311 | } |
4293 | 4312 | ||
4294 | BOOL LLTextEditor::findHTML(const std::string &line, S32 *begin, S32 *end) const | 4313 | BOOL LLTextEditor::findHTML(const std::string &line, S32 *begin, S32 *end) const |
@@ -4476,9 +4495,8 @@ void LLTextEditor::updatePreedit(const LLWString &preedit_string, | |||
4476 | 4495 | ||
4477 | mPreeditStandouts = preedit_standouts; | 4496 | mPreeditStandouts = preedit_standouts; |
4478 | 4497 | ||
4479 | updateLineStartList(); | 4498 | needsReflow(); |
4480 | setCursorPos(insert_preedit_at + caret_position); | 4499 | setCursorPos(insert_preedit_at + caret_position); |
4481 | // updateScrollFromCursor(); | ||
4482 | 4500 | ||
4483 | // Update of the preedit should be caused by some key strokes. | 4501 | // Update of the preedit should be caused by some key strokes. |
4484 | mKeystrokeTimer.reset(); | 4502 | mKeystrokeTimer.reset(); |
diff --git a/linden/indra/llui/lltexteditor.h b/linden/indra/llui/lltexteditor.h index 3cff91d..c76395c 100644 --- a/linden/indra/llui/lltexteditor.h +++ b/linden/indra/llui/lltexteditor.h | |||
@@ -110,6 +110,7 @@ public: | |||
110 | virtual BOOL canUndo() const; | 110 | virtual BOOL canUndo() const; |
111 | virtual void redo(); | 111 | virtual void redo(); |
112 | virtual BOOL canRedo() const; | 112 | virtual BOOL canRedo() const; |
113 | |||
113 | virtual void cut(); | 114 | virtual void cut(); |
114 | virtual BOOL canCut() const; | 115 | virtual BOOL canCut() const; |
115 | virtual void copy(); | 116 | virtual void copy(); |
@@ -245,9 +246,11 @@ public: | |||
245 | llwchar getWChar(S32 pos) const { return mWText[pos]; } | 246 | llwchar getWChar(S32 pos) const { return mWText[pos]; } |
246 | LLWString getWSubString(S32 pos, S32 len) const { return mWText.substr(pos, len); } | 247 | LLWString getWSubString(S32 pos, S32 len) const { return mWText.substr(pos, len); } |
247 | 248 | ||
248 | const LLTextSegment* getCurrentSegment() { return getSegmentAtOffset(mCursorPos); } | 249 | const LLTextSegment* getCurrentSegment() const { return getSegmentAtOffset(mCursorPos); } |
249 | const LLTextSegment* getPreviousSegment(); | 250 | const LLTextSegment* getPreviousSegment() const; |
250 | void getSelectedSegments(std::vector<const LLTextSegment*>& segments); | 251 | void getSelectedSegments(std::vector<const LLTextSegment*>& segments) const; |
252 | |||
253 | static bool isPartOfWord(llwchar c) { return (c == '_') || LLStringOps::isAlnum((char)c); } | ||
251 | 254 | ||
252 | protected: | 255 | protected: |
253 | // | 256 | // |
@@ -266,8 +269,6 @@ protected: | |||
266 | void assignEmbedded(const std::string &s); | 269 | void assignEmbedded(const std::string &s); |
267 | BOOL truncate(); // Returns true if truncation occurs | 270 | BOOL truncate(); // Returns true if truncation occurs |
268 | 271 | ||
269 | static BOOL isPartOfWord(llwchar c) { return (c == '_') || isalnum(c); } | ||
270 | |||
271 | void removeCharOrTab(); | 272 | void removeCharOrTab(); |
272 | void setCursorAtLocalPos(S32 x, S32 y, BOOL round); | 273 | void setCursorAtLocalPos(S32 x, S32 y, BOOL round); |
273 | S32 getCursorPosFromLocalCoord( S32 local_x, S32 local_y, BOOL round ) const; | 274 | S32 getCursorPosFromLocalCoord( S32 local_x, S32 local_y, BOOL round ) const; |
@@ -433,6 +434,14 @@ private: | |||
433 | void drawText(); | 434 | void drawText(); |
434 | void drawClippedSegment(const LLWString &wtext, S32 seg_start, S32 seg_end, F32 x, F32 y, S32 selection_left, S32 selection_right, const LLStyleSP& color, F32* right_x); | 435 | void drawClippedSegment(const LLWString &wtext, S32 seg_start, S32 seg_end, F32 x, F32 y, S32 selection_left, S32 selection_right, const LLStyleSP& color, F32* right_x); |
435 | 436 | ||
437 | void needsReflow() | ||
438 | { | ||
439 | mReflowNeeded = TRUE; | ||
440 | // cursor might have moved, need to scroll | ||
441 | mScrollNeeded = TRUE; | ||
442 | } | ||
443 | void needsScroll() { mScrollNeeded = TRUE; } | ||
444 | |||
436 | // | 445 | // |
437 | // Data | 446 | // Data |
438 | // | 447 | // |
@@ -489,6 +498,8 @@ private: | |||
489 | }; | 498 | }; |
490 | typedef std::vector<line_info> line_list_t; | 499 | typedef std::vector<line_info> line_list_t; |
491 | line_list_t mLineStartList; | 500 | line_list_t mLineStartList; |
501 | BOOL mReflowNeeded; | ||
502 | BOOL mScrollNeeded; | ||
492 | 503 | ||
493 | LLFrameTimer mKeystrokeTimer; | 504 | LLFrameTimer mKeystrokeTimer; |
494 | 505 | ||
diff --git a/linden/indra/newview/CMakeLists.txt b/linden/indra/newview/CMakeLists.txt index 0205ceb..4024fdd 100644 --- a/linden/indra/newview/CMakeLists.txt +++ b/linden/indra/newview/CMakeLists.txt | |||
@@ -150,7 +150,6 @@ set(viewer_SOURCE_FILES | |||
150 | llfloatergroupinvite.cpp | 150 | llfloatergroupinvite.cpp |
151 | llfloatergroups.cpp | 151 | llfloatergroups.cpp |
152 | llfloaterhardwaresettings.cpp | 152 | llfloaterhardwaresettings.cpp |
153 | llfloaterhtml.cpp | ||
154 | llfloaterhtmlhelp.cpp | 153 | llfloaterhtmlhelp.cpp |
155 | llfloaterhud.cpp | 154 | llfloaterhud.cpp |
156 | llfloaterimagepreview.cpp | 155 | llfloaterimagepreview.cpp |
@@ -544,7 +543,6 @@ set(viewer_HEADER_FILES | |||
544 | llfloatergroupinvite.h | 543 | llfloatergroupinvite.h |
545 | llfloatergroups.h | 544 | llfloatergroups.h |
546 | llfloaterhardwaresettings.h | 545 | llfloaterhardwaresettings.h |
547 | llfloaterhtml.h | ||
548 | llfloaterhtmlhelp.h | 546 | llfloaterhtmlhelp.h |
549 | llfloaterhud.h | 547 | llfloaterhud.h |
550 | llfloaterimagepreview.h | 548 | llfloaterimagepreview.h |
@@ -1047,7 +1045,6 @@ set(viewer_XUI_FILES | |||
1047 | skins/default/xui/en-us/floater_god_tools.xml | 1045 | skins/default/xui/en-us/floater_god_tools.xml |
1048 | skins/default/xui/en-us/floater_group_info.xml | 1046 | skins/default/xui/en-us/floater_group_info.xml |
1049 | skins/default/xui/en-us/floater_hardware_settings.xml | 1047 | skins/default/xui/en-us/floater_hardware_settings.xml |
1050 | skins/default/xui/en-us/floater_html.xml | ||
1051 | skins/default/xui/en-us/floater_hud.xml | 1048 | skins/default/xui/en-us/floater_hud.xml |
1052 | skins/default/xui/en-us/floater_image_preview.xml | 1049 | skins/default/xui/en-us/floater_image_preview.xml |
1053 | skins/default/xui/en-us/floater_import.xml | 1050 | skins/default/xui/en-us/floater_import.xml |
diff --git a/linden/indra/newview/app_settings/settings.xml b/linden/indra/newview/app_settings/settings.xml index 01f6add..e7e7303 100644 --- a/linden/indra/newview/app_settings/settings.xml +++ b/linden/indra/newview/app_settings/settings.xml | |||
@@ -2903,22 +2903,6 @@ | |||
2903 | <integer>0</integer> | 2903 | <integer>0</integer> |
2904 | </array> | 2904 | </array> |
2905 | </map> | 2905 | </map> |
2906 | <key>FloaterHtmlRect</key> | ||
2907 | <map> | ||
2908 | <key>Comment</key> | ||
2909 | <string>Rectangle for HTML window</string> | ||
2910 | <key>Persist</key> | ||
2911 | <integer>1</integer> | ||
2912 | <key>Type</key> | ||
2913 | <string>Rect</string> | ||
2914 | <key>Value</key> | ||
2915 | <array> | ||
2916 | <integer>100</integer> | ||
2917 | <integer>460</integer> | ||
2918 | <integer>370</integer> | ||
2919 | <integer>100</integer> | ||
2920 | </array> | ||
2921 | </map> | ||
2922 | <key>FloaterIMRect</key> | 2906 | <key>FloaterIMRect</key> |
2923 | <map> | 2907 | <map> |
2924 | <key>Comment</key> | 2908 | <key>Comment</key> |
@@ -3814,6 +3798,17 @@ | |||
3814 | <key>Value</key> | 3798 | <key>Value</key> |
3815 | <string>help/index.html</string> | 3799 | <string>help/index.html</string> |
3816 | </map> | 3800 | </map> |
3801 | <key>HelpSupportURL</key> | ||
3802 | <map> | ||
3803 | <key>Comment</key> | ||
3804 | <string>Main URL of support page</string> | ||
3805 | <key>Persist</key> | ||
3806 | <integer>1</integer> | ||
3807 | <key>Type</key> | ||
3808 | <string>String</string> | ||
3809 | <key>Value</key> | ||
3810 | <string>http://support.secondlife.com</string> | ||
3811 | </map> | ||
3817 | <key>HighResSnapshot</key> | 3812 | <key>HighResSnapshot</key> |
3818 | <map> | 3813 | <map> |
3819 | <key>Comment</key> | 3814 | <key>Comment</key> |
diff --git a/linden/indra/newview/llappviewer.cpp b/linden/indra/newview/llappviewer.cpp index 9e68078..4bb235e 100644 --- a/linden/indra/newview/llappviewer.cpp +++ b/linden/indra/newview/llappviewer.cpp | |||
@@ -75,6 +75,9 @@ | |||
75 | 75 | ||
76 | #if LL_WINDOWS | 76 | #if LL_WINDOWS |
77 | #include "llwindebug.h" | 77 | #include "llwindebug.h" |
78 | #include <direct.h> | ||
79 | #include <errno.h> | ||
80 | #include <stdlib.h> | ||
78 | #endif | 81 | #endif |
79 | 82 | ||
80 | #if LL_WINDOWS | 83 | #if LL_WINDOWS |
@@ -316,6 +319,34 @@ std::string gLoginPage; | |||
316 | std::vector<std::string> gLoginURIs; | 319 | std::vector<std::string> gLoginURIs; |
317 | static std::string gHelperURI; | 320 | static std::string gHelperURI; |
318 | 321 | ||
322 | |||
323 | void LLAppViewer::gst_plugin_path() | ||
324 | { | ||
325 | #ifdef LL_WINDOWS | ||
326 | char* buffer; | ||
327 | |||
328 | // Get the current working directory: | ||
329 | if((buffer = _getcwd(NULL,0)) == NULL) | ||
330 | { | ||
331 | LL_INFOS("InitInfo") << "_getcwd error" << LL_ENDL; | ||
332 | } | ||
333 | else | ||
334 | { | ||
335 | LL_INFOS("InitInfo") << "Imprudence is installed at " << buffer << LL_ENDL; | ||
336 | |||
337 | char plugin_path[255]; | ||
338 | strcpy (plugin_path,"GST_PLUGIN_PATH="); | ||
339 | strcat (plugin_path,buffer); | ||
340 | strcat (plugin_path,"\\lib"); | ||
341 | |||
342 | // Place GST_PLUGIN_PATH in the environment settings for imprudence.exe | ||
343 | putenv(plugin_path); | ||
344 | |||
345 | LL_INFOS("InitInfo") << "GST_PLUGIN_PATH set to " << getenv("GST_PLUGIN_PATH") << LL_ENDL; | ||
346 | } | ||
347 | #endif //LL_WINDOWS | ||
348 | } | ||
349 | |||
319 | void idle_afk_check() | 350 | void idle_afk_check() |
320 | { | 351 | { |
321 | // check idle timers | 352 | // check idle timers |
@@ -615,6 +646,8 @@ bool LLAppViewer::init() | |||
615 | LL_VERSION_PATCH, | 646 | LL_VERSION_PATCH, |
616 | LL_VERSION_BUILD ); | 647 | LL_VERSION_BUILD ); |
617 | 648 | ||
649 | gst_plugin_path(); | ||
650 | |||
618 | ////////////////////////////////////////////////////////////////////////////// | 651 | ////////////////////////////////////////////////////////////////////////////// |
619 | ////////////////////////////////////////////////////////////////////////////// | 652 | ////////////////////////////////////////////////////////////////////////////// |
620 | ////////////////////////////////////////////////////////////////////////////// | 653 | ////////////////////////////////////////////////////////////////////////////// |
diff --git a/linden/indra/newview/llappviewer.h b/linden/indra/newview/llappviewer.h index 801deb1..2083a93 100644 --- a/linden/indra/newview/llappviewer.h +++ b/linden/indra/newview/llappviewer.h | |||
@@ -137,6 +137,9 @@ public: | |||
137 | void pingMainloopTimeout(const std::string& state, F32 secs = -1.0f); | 137 | void pingMainloopTimeout(const std::string& state, F32 secs = -1.0f); |
138 | 138 | ||
139 | protected: | 139 | protected: |
140 | |||
141 | void gst_plugin_path(); // Sets GST_PLUGIN_PATH environment variable for GStreamer. | ||
142 | |||
140 | virtual bool initWindow(); // Initialize the viewer's window. | 143 | virtual bool initWindow(); // Initialize the viewer's window. |
141 | virtual bool initLogging(); // Initialize log files, logging system, return false on failure. | 144 | virtual bool initLogging(); // Initialize log files, logging system, return false on failure. |
142 | virtual void initConsole() {}; // Initialize OS level debugging console. | 145 | virtual void initConsole() {}; // Initialize OS level debugging console. |
@@ -147,7 +150,6 @@ protected: | |||
147 | 150 | ||
148 | virtual std::string generateSerialNumber() = 0; // Platforms specific classes generate this. | 151 | virtual std::string generateSerialNumber() = 0; // Platforms specific classes generate this. |
149 | 152 | ||
150 | |||
151 | private: | 153 | private: |
152 | 154 | ||
153 | bool initThreads(); // Initialize viewer threads, return false on failure. | 155 | bool initThreads(); // Initialize viewer threads, return false on failure. |
diff --git a/linden/indra/newview/llfloaterchat.cpp b/linden/indra/newview/llfloaterchat.cpp index 1f0c6ad..a626ad3 100644 --- a/linden/indra/newview/llfloaterchat.cpp +++ b/linden/indra/newview/llfloaterchat.cpp | |||
@@ -70,7 +70,6 @@ | |||
70 | #include "llchatbar.h" | 70 | #include "llchatbar.h" |
71 | #include "lllogchat.h" | 71 | #include "lllogchat.h" |
72 | #include "lltexteditor.h" | 72 | #include "lltexteditor.h" |
73 | #include "llfloaterhtml.h" | ||
74 | #include "llweb.h" | 73 | #include "llweb.h" |
75 | #include "llstylemap.h" | 74 | #include "llstylemap.h" |
76 | 75 | ||
diff --git a/linden/indra/newview/llfloaterhtml.cpp b/linden/indra/newview/llfloaterhtml.cpp deleted file mode 100644 index eb09754..0000000 --- a/linden/indra/newview/llfloaterhtml.cpp +++ /dev/null | |||
@@ -1,253 +0,0 @@ | |||
1 | /** | ||
2 | * @file llfloaterhtml.cpp | ||
3 | * @brief In-world HTML dialog | ||
4 | * | ||
5 | * $LicenseInfo:firstyear=2005&license=viewergpl$ | ||
6 | * | ||
7 | * Copyright (c) 2005-2008, Linden Research, Inc. | ||
8 | * | ||
9 | * Second Life Viewer Source Code | ||
10 | * The source code in this file ("Source Code") is provided by Linden Lab | ||
11 | * to you under the terms of the GNU General Public License, version 2.0 | ||
12 | * ("GPL"), unless you have obtained a separate licensing agreement | ||
13 | * ("Other License"), formally executed by you and Linden Lab. Terms of | ||
14 | * the GPL can be found in doc/GPL-license.txt in this distribution, or | ||
15 | * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2 | ||
16 | * | ||
17 | * There are special exceptions to the terms and conditions of the GPL as | ||
18 | * it is applied to this Source Code. View the full text of the exception | ||
19 | * in the file doc/FLOSS-exception.txt in this software distribution, or | ||
20 | * online at http://secondlifegrid.net/programs/open_source/licensing/flossexception | ||
21 | * | ||
22 | * By copying, modifying or distributing this software, you acknowledge | ||
23 | * that you have read and understood your obligations described above, | ||
24 | * and agree to abide by those obligations. | ||
25 | * | ||
26 | * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO | ||
27 | * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY, | ||
28 | * COMPLETENESS OR PERFORMANCE. | ||
29 | * $/LicenseInfo$ | ||
30 | */ | ||
31 | |||
32 | #include "llviewerprecompiledheaders.h" | ||
33 | |||
34 | #include "llfloaterhtml.h" | ||
35 | |||
36 | // viewer includes | ||
37 | #include "lluictrlfactory.h" | ||
38 | #include "llviewercontrol.h" | ||
39 | #include "lllineeditor.h" | ||
40 | #include "llviewerwindow.h" | ||
41 | #include "llweb.h" | ||
42 | |||
43 | #include "llwebbrowserctrl.h" | ||
44 | |||
45 | LLFloaterHtml* LLFloaterHtml::sInstance = 0; | ||
46 | |||
47 | //////////////////////////////////////////////////////////////////////////////// | ||
48 | // | ||
49 | LLFloaterHtml* LLFloaterHtml::getInstance() | ||
50 | { | ||
51 | if ( ! sInstance ) | ||
52 | sInstance = new LLFloaterHtml(); | ||
53 | |||
54 | return sInstance; | ||
55 | } | ||
56 | |||
57 | //////////////////////////////////////////////////////////////////////////////// | ||
58 | // | ||
59 | LLFloaterHtml::LLFloaterHtml() | ||
60 | : LLFloater( std::string("HTML Floater") ) | ||
61 | |||
62 | , | ||
63 | mWebBrowser( 0 ) | ||
64 | { | ||
65 | LLUICtrlFactory::getInstance()->buildFloater( this, "floater_html.xml" ); | ||
66 | |||
67 | childSetAction("back_btn", onClickBack, this); | ||
68 | childSetAction("home_btn", onClickHome, this); | ||
69 | childSetAction("forward_btn", onClickForward, this); | ||
70 | childSetAction("close_btn", onClickClose, this); | ||
71 | childSetCommitCallback("url_edit", onCommitUrlEdit, this ); | ||
72 | childSetAction("go_btn", onClickGo, this ); | ||
73 | |||
74 | // reposition floater from saved settings | ||
75 | LLRect rect = gSavedSettings.getRect( "FloaterHtmlRect" ); | ||
76 | reshape( rect.getWidth(), rect.getHeight(), FALSE ); | ||
77 | setRect( rect ); | ||
78 | |||
79 | mWebBrowser = getChild<LLWebBrowserCtrl>("html_floater_browser" ); | ||
80 | if ( mWebBrowser ) | ||
81 | { | ||
82 | // open links in internal browser | ||
83 | mWebBrowser->setOpenInExternalBrowser( false ); | ||
84 | } | ||
85 | } | ||
86 | |||
87 | //////////////////////////////////////////////////////////////////////////////// | ||
88 | // | ||
89 | LLFloaterHtml::~LLFloaterHtml() | ||
90 | { | ||
91 | // save position of floater | ||
92 | gSavedSettings.setRect( "FloaterHtmlRect", getRect() ); | ||
93 | |||
94 | sInstance = 0; | ||
95 | } | ||
96 | |||
97 | //////////////////////////////////////////////////////////////////////////////// | ||
98 | // virtual | ||
99 | void LLFloaterHtml::draw() | ||
100 | { | ||
101 | // enable/disable buttons depending on state | ||
102 | if ( mWebBrowser ) | ||
103 | { | ||
104 | bool enable_back = mWebBrowser->canNavigateBack(); | ||
105 | childSetEnabled( "back_btn", enable_back ); | ||
106 | |||
107 | bool enable_forward = mWebBrowser->canNavigateForward(); | ||
108 | childSetEnabled( "forward_btn", enable_forward ); | ||
109 | }; | ||
110 | |||
111 | LLFloater::draw(); | ||
112 | } | ||
113 | |||
114 | //////////////////////////////////////////////////////////////////////////////// | ||
115 | // | ||
116 | void LLFloaterHtml::show( std::string content_id, bool open_link_external, bool open_app_slurls ) | ||
117 | { | ||
118 | // calculate the XML labels we'll need (if only XML folders worked) | ||
119 | std::string title_str = content_id + "_title"; | ||
120 | std::string url_str = content_id + "_url"; | ||
121 | |||
122 | std::string title = getString( title_str ); | ||
123 | std::string url = getString( url_str ); | ||
124 | |||
125 | show( url, title, open_link_external, open_app_slurls ); | ||
126 | } | ||
127 | |||
128 | //////////////////////////////////////////////////////////////////////////////// | ||
129 | // | ||
130 | void LLFloaterHtml::show( std::string start_url, std::string title, bool open_link_external, bool open_app_slurls ) | ||
131 | { | ||
132 | // set the title | ||
133 | setTitle( title ); | ||
134 | |||
135 | // navigate to the URL | ||
136 | if ( mWebBrowser ) | ||
137 | { | ||
138 | mWebBrowser->setOpenAppSLURLs( open_app_slurls ); | ||
139 | mWebBrowser->setOpenInExternalBrowser( open_link_external ); | ||
140 | mWebBrowser->navigateTo( start_url ); | ||
141 | } | ||
142 | |||
143 | // make floater appear | ||
144 | setVisibleAndFrontmost(); | ||
145 | } | ||
146 | |||
147 | //////////////////////////////////////////////////////////////////////////////// | ||
148 | // | ||
149 | std::string LLFloaterHtml::getSupportUrl() | ||
150 | { | ||
151 | return getString("support_page_url"); | ||
152 | } | ||
153 | |||
154 | //////////////////////////////////////////////////////////////////////////////// | ||
155 | // | ||
156 | void LLFloaterHtml::onClose( bool app_quitting ) | ||
157 | { | ||
158 | setVisible( false ); | ||
159 | // HACK for fast XML iteration replace with: | ||
160 | // destroy(); | ||
161 | } | ||
162 | |||
163 | //////////////////////////////////////////////////////////////////////////////// | ||
164 | // | ||
165 | void LLFloaterHtml::onClickClose( void* data ) | ||
166 | { | ||
167 | LLFloaterHtml* self = ( LLFloaterHtml* )data; | ||
168 | self->close(); | ||
169 | } | ||
170 | |||
171 | //////////////////////////////////////////////////////////////////////////////// | ||
172 | // static | ||
173 | void LLFloaterHtml::onClickBack( void* data ) | ||
174 | { | ||
175 | LLFloaterHtml* self = ( LLFloaterHtml* )data; | ||
176 | if ( self ) | ||
177 | { | ||
178 | if ( self->mWebBrowser ) | ||
179 | { | ||
180 | self->mWebBrowser->navigateBack(); | ||
181 | }; | ||
182 | }; | ||
183 | } | ||
184 | |||
185 | //////////////////////////////////////////////////////////////////////////////// | ||
186 | // | ||
187 | void LLFloaterHtml::onClickHome( void* data ) | ||
188 | { | ||
189 | LLFloaterHtml* self = ( LLFloaterHtml* )data; | ||
190 | if ( self ) | ||
191 | { | ||
192 | if ( self->mWebBrowser ) | ||
193 | { | ||
194 | std::string home_url = self->getString("home_page_url"); | ||
195 | if ( home_url.length() > 4 ) | ||
196 | { | ||
197 | self->mWebBrowser->navigateTo( home_url ); | ||
198 | } | ||
199 | else | ||
200 | { | ||
201 | llwarns << "Invalid home page specified for HTML floater - navigating to default" << llendl; | ||
202 | self->mWebBrowser->navigateTo( "http://secondlife.com" ); | ||
203 | } | ||
204 | }; | ||
205 | }; | ||
206 | } | ||
207 | |||
208 | //////////////////////////////////////////////////////////////////////////////// | ||
209 | // static | ||
210 | void LLFloaterHtml::onClickForward( void* data ) | ||
211 | { | ||
212 | LLFloaterHtml* self = ( LLFloaterHtml* )data; | ||
213 | if ( self ) | ||
214 | { | ||
215 | if ( self->mWebBrowser ) | ||
216 | { | ||
217 | self->mWebBrowser->navigateForward(); | ||
218 | }; | ||
219 | }; | ||
220 | } | ||
221 | |||
222 | //////////////////////////////////////////////////////////////////////////////// | ||
223 | // static | ||
224 | void LLFloaterHtml::onCommitUrlEdit(LLUICtrl* ctrl, void* user_data) | ||
225 | { | ||
226 | LLFloaterHtml* self = (LLFloaterHtml*)user_data; | ||
227 | |||
228 | LLLineEditor* editor = (LLLineEditor*)ctrl; | ||
229 | std::string url = editor->getText(); | ||
230 | |||
231 | if ( self->mWebBrowser ) | ||
232 | { | ||
233 | self->mWebBrowser->navigateTo( url ); | ||
234 | }; | ||
235 | } | ||
236 | |||
237 | //////////////////////////////////////////////////////////////////////////////// | ||
238 | // static | ||
239 | void LLFloaterHtml::onClickGo( void* data ) | ||
240 | { | ||
241 | LLFloaterHtml* self = ( LLFloaterHtml* )data; | ||
242 | if ( self ) | ||
243 | { | ||
244 | std::string url = self->childGetValue( "url_edit" ).asString(); | ||
245 | if ( url.length() ) | ||
246 | { | ||
247 | if ( self->mWebBrowser ) | ||
248 | { | ||
249 | self->mWebBrowser->navigateTo( url ); | ||
250 | } | ||
251 | } | ||
252 | } | ||
253 | } | ||
diff --git a/linden/indra/newview/llfloaterhtml.h b/linden/indra/newview/llfloaterhtml.h deleted file mode 100644 index e236ffe..0000000 --- a/linden/indra/newview/llfloaterhtml.h +++ /dev/null | |||
@@ -1,76 +0,0 @@ | |||
1 | /** | ||
2 | * @file llfloaterhtml.h | ||
3 | * @author James Cook | ||
4 | * @brief In-world HTML dialog | ||
5 | * | ||
6 | * $LicenseInfo:firstyear=2005&license=viewergpl$ | ||
7 | * | ||
8 | * Copyright (c) 2005-2008, Linden Research, Inc. | ||
9 | * | ||
10 | * Second Life Viewer Source Code | ||
11 | * The source code in this file ("Source Code") is provided by Linden Lab | ||
12 | * to you under the terms of the GNU General Public License, version 2.0 | ||
13 | * ("GPL"), unless you have obtained a separate licensing agreement | ||
14 | * ("Other License"), formally executed by you and Linden Lab. Terms of | ||
15 | * the GPL can be found in doc/GPL-license.txt in this distribution, or | ||
16 | * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2 | ||
17 | * | ||
18 | * There are special exceptions to the terms and conditions of the GPL as | ||
19 | * it is applied to this Source Code. View the full text of the exception | ||
20 | * in the file doc/FLOSS-exception.txt in this software distribution, or | ||
21 | * online at http://secondlifegrid.net/programs/open_source/licensing/flossexception | ||
22 | * | ||
23 | * By copying, modifying or distributing this software, you acknowledge | ||
24 | * that you have read and understood your obligations described above, | ||
25 | * and agree to abide by those obligations. | ||
26 | * | ||
27 | * ALL LINDEN LAB SOURCE CODE IS PROVIDED "AS IS." LINDEN LAB MAKES NO | ||
28 | * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY, | ||
29 | * COMPLETENESS OR PERFORMANCE. | ||
30 | * $/LicenseInfo$ | ||
31 | */ | ||
32 | |||
33 | #ifndef LL_LLFLOATERHTML_H | ||
34 | #define LL_LLFLOATERHTML_H | ||
35 | |||
36 | #include "llfloater.h" | ||
37 | #include "llhtmlhelp.h" | ||
38 | |||
39 | class LLWebBrowserCtrl; | ||
40 | |||
41 | class LLFloaterHtml : | ||
42 | public LLFloater | ||
43 | { | ||
44 | public: | ||
45 | static LLFloaterHtml* getInstance(); | ||
46 | virtual ~LLFloaterHtml(); | ||
47 | |||
48 | virtual void draw(); | ||
49 | virtual void onClose( bool app_quitting ); | ||
50 | |||
51 | // Pass string like "in-world_help" or "additional help" | ||
52 | void show( std::string content_id, bool open_link_external, bool open_app_slurls ); | ||
53 | |||
54 | // Pass raw URL and window title | ||
55 | // Can be set to handle secondlife:///app/ URLs, but this should | ||
56 | // usually be false. | ||
57 | void show( std::string start_url, std::string title, bool open_link_external, bool open_app_slurls ); | ||
58 | |||
59 | std::string getSupportUrl(); | ||
60 | |||
61 | static void onClickClose( void* data ); | ||
62 | static void onClickBack( void* data ); | ||
63 | static void onClickHome( void* data ); | ||
64 | static void onClickForward( void* data ); | ||
65 | static void onCommitUrlEdit(LLUICtrl* ctrl, void* user_data); | ||
66 | static void onClickGo( void* data ); | ||
67 | |||
68 | private: | ||
69 | LLFloaterHtml(); | ||
70 | |||
71 | LLWebBrowserCtrl* mWebBrowser; | ||
72 | static LLFloaterHtml* sInstance; | ||
73 | LLButton* mCloseButton; | ||
74 | }; | ||
75 | |||
76 | #endif | ||
diff --git a/linden/indra/newview/llfloaterhtmlhelp.cpp b/linden/indra/newview/llfloaterhtmlhelp.cpp index 7fe4d59..85122c7 100644 --- a/linden/indra/newview/llfloaterhtmlhelp.cpp +++ b/linden/indra/newview/llfloaterhtmlhelp.cpp | |||
@@ -32,7 +32,6 @@ | |||
32 | #include "llviewerprecompiledheaders.h" | 32 | #include "llviewerprecompiledheaders.h" |
33 | 33 | ||
34 | #include "llfloaterhtmlhelp.h" | 34 | #include "llfloaterhtmlhelp.h" |
35 | #include "llfloaterhtml.h" | ||
36 | 35 | ||
37 | #include "llparcel.h" | 36 | #include "llparcel.h" |
38 | #include "lluictrlfactory.h" | 37 | #include "lluictrlfactory.h" |
@@ -50,6 +49,13 @@ | |||
50 | #include "llviewerparcelmedia.h" | 49 | #include "llviewerparcelmedia.h" |
51 | #include "llcombobox.h" | 50 | #include "llcombobox.h" |
52 | 51 | ||
52 | #include "llchat.h" | ||
53 | #include "lllineeditor.h" | ||
54 | #include "llfloaterchat.h" | ||
55 | #include "lltrans.h" | ||
56 | |||
57 | // static | ||
58 | LLFloaterMediaBrowser* LLFloaterMediaBrowser::sInstance = NULL; | ||
53 | 59 | ||
54 | LLFloaterMediaBrowser::LLFloaterMediaBrowser(const LLSD& media_data) | 60 | LLFloaterMediaBrowser::LLFloaterMediaBrowser(const LLSD& media_data) |
55 | { | 61 | { |
@@ -118,7 +124,7 @@ void LLFloaterMediaBrowser::buildURLHistory() | |||
118 | 124 | ||
119 | void LLFloaterMediaBrowser::onClose(bool app_quitting) | 125 | void LLFloaterMediaBrowser::onClose(bool app_quitting) |
120 | { | 126 | { |
121 | //setVisible(FALSE); | 127 | //setVisible(FALSE) |
122 | destroy(); | 128 | destroy(); |
123 | } | 129 | } |
124 | 130 | ||
@@ -155,20 +161,52 @@ void LLFloaterMediaBrowser::onLocationChange( const EventType& eventIn ) | |||
155 | 161 | ||
156 | LLFloaterMediaBrowser* LLFloaterMediaBrowser::showInstance(const LLSD& media_url) | 162 | LLFloaterMediaBrowser* LLFloaterMediaBrowser::showInstance(const LLSD& media_url) |
157 | { | 163 | { |
158 | LLFloaterMediaBrowser* floaterp = LLUISingleton<LLFloaterMediaBrowser, VisibilityPolicy<LLFloater> >::showInstance(media_url); | 164 | LLFloaterMediaBrowser* sInstance = LLUISingleton<LLFloaterMediaBrowser, VisibilityPolicy<LLFloater> >::showInstance(media_url); |
159 | 165 | ||
160 | floaterp->openMedia(media_url.asString()); | 166 | sInstance->openMedia(media_url.asString()); |
161 | return floaterp; | 167 | return sInstance; |
162 | } | 168 | } |
163 | 169 | ||
164 | void LLFloaterMediaBrowser::show() | 170 | //static |
171 | void LLFloaterMediaBrowser::toggle() | ||
172 | { | ||
173 | bool visible = LLFloaterMediaBrowser::instanceVisible(); | ||
174 | LLFloaterMediaBrowser* self = sInstance->getInstance(); | ||
175 | |||
176 | if(visible && self) | ||
177 | { | ||
178 | self->close(); | ||
179 | } | ||
180 | else | ||
181 | { | ||
182 | //Show home url if new session, last visited if not | ||
183 | std::string last_url = gSavedSettings.getString("BrowserLastVisited"); | ||
184 | if(last_url.empty()) | ||
185 | last_url = gSavedSettings.getString("BrowserHome"); | ||
186 | showInstance(last_url); | ||
187 | } | ||
188 | } | ||
189 | |||
190 | //static | ||
191 | void LLFloaterMediaBrowser::helpF1() | ||
192 | { | ||
193 | std::string url = gSavedSettings.getString("HelpSupportURL"); | ||
194 | std::string* url_copy = new std::string(url); | ||
195 | |||
196 | gViewerWindow->alertXml("ClickOpenF1Help", onClickF1HelpLoadURL, url_copy); | ||
197 | } | ||
198 | |||
199 | // static | ||
200 | void LLFloaterMediaBrowser::onClickF1HelpLoadURL(S32 option, void* userdata) | ||
165 | { | 201 | { |
166 | //Show home url if new session, last visited if not | 202 | std::string* urlp = (std::string*)userdata; |
167 | std::string last_url = gSavedSettings.getString("BrowserLastVisited"); | 203 | if (0 == option) |
168 | if(last_url.empty()) | 204 | { |
169 | last_url = gSavedSettings.getString("BrowserHome"); | 205 | showInstance(urlp->c_str()); |
170 | showInstance(last_url); | 206 | } |
207 | delete urlp; | ||
171 | } | 208 | } |
209 | |||
172 | //static | 210 | //static |
173 | void LLFloaterMediaBrowser::onEnterAddress(LLUICtrl* ctrl, void* user_data) | 211 | void LLFloaterMediaBrowser::onEnterAddress(LLUICtrl* ctrl, void* user_data) |
174 | { | 212 | { |
@@ -247,8 +285,6 @@ void LLFloaterMediaBrowser::onClickAssign(void* user_data) | |||
247 | LLViewerParcelMgr::getInstance()->sendParcelPropertiesUpdate( parcel, true ); | 285 | LLViewerParcelMgr::getInstance()->sendParcelPropertiesUpdate( parcel, true ); |
248 | // now check for video | 286 | // now check for video |
249 | LLViewerParcelMedia::update( parcel ); | 287 | LLViewerParcelMedia::update( parcel ); |
250 | |||
251 | |||
252 | } | 288 | } |
253 | 289 | ||
254 | void LLFloaterMediaBrowser::onClickHome(void* user_data) | 290 | void LLFloaterMediaBrowser::onClickHome(void* user_data) |
@@ -270,6 +306,11 @@ void LLFloaterMediaBrowser::onClickSetHome(void* user_data) | |||
270 | std::string url = self->mCurrentURL; | 306 | std::string url = self->mCurrentURL; |
271 | if(!url.empty()) | 307 | if(!url.empty()) |
272 | { | 308 | { |
309 | LLChat chat; | ||
310 | std::string log_message = LLTrans::getString("new_home_page") + " "; | ||
311 | log_message += url; | ||
312 | chat.mText = log_message; | ||
313 | LLFloaterChat::addChat(chat, FALSE, FALSE); | ||
273 | gSavedSettings.setString("BrowserHome", url); | 314 | gSavedSettings.setString("BrowserHome", url); |
274 | } | 315 | } |
275 | } | 316 | } |
@@ -279,257 +320,3 @@ void LLFloaterMediaBrowser::openMedia(const std::string& media_url) | |||
279 | mBrowser->setHomePageUrl(media_url); | 320 | mBrowser->setHomePageUrl(media_url); |
280 | mBrowser->navigateTo(media_url); | 321 | mBrowser->navigateTo(media_url); |
281 | } | 322 | } |
282 | |||
283 | LLViewerHtmlHelp gViewerHtmlHelp; | ||
284 | |||
285 | class LLFloaterHtmlHelp : | ||
286 | public LLFloater, | ||
287 | public LLWebBrowserCtrlObserver | ||
288 | { | ||
289 | public: | ||
290 | LLFloaterHtmlHelp(std::string start_url, std::string title); | ||
291 | virtual ~LLFloaterHtmlHelp(); | ||
292 | |||
293 | virtual void onClose( bool app_quitting ); | ||
294 | virtual void draw(); | ||
295 | |||
296 | static void show(std::string url, std::string title); | ||
297 | static void onClickBack( void* data ); | ||
298 | static void onClickHome( void* data ); | ||
299 | static void onClickForward( void* data ); | ||
300 | static void onClickClose( void* data ); | ||
301 | |||
302 | // browser observer impls | ||
303 | virtual void onStatusTextChange( const EventType& eventIn ); | ||
304 | virtual void onLocationChange( const EventType& eventIn ); | ||
305 | |||
306 | // used for some stats logging - will be removed at some point | ||
307 | static BOOL sFloaterOpened; | ||
308 | |||
309 | static void onClickF1HelpLoadURL(S32 option, void* userdata); | ||
310 | |||
311 | protected: | ||
312 | LLWebBrowserCtrl* mWebBrowser; | ||
313 | static LLFloaterHtmlHelp* sInstance; | ||
314 | LLButton* mBackButton; | ||
315 | LLButton* mForwardButton; | ||
316 | LLButton* mCloseButton; | ||
317 | LLTextBox* mStatusText; | ||
318 | std::string mStatusTextContents; | ||
319 | std::string mCurrentUrl; | ||
320 | std::string mSupportUrl; | ||
321 | }; | ||
322 | |||
323 | LLFloaterHtmlHelp* LLFloaterHtmlHelp::sInstance = 0; | ||
324 | |||
325 | BOOL LLFloaterHtmlHelp::sFloaterOpened = FALSE; | ||
326 | |||
327 | //////////////////////////////////////////////////////////////////////////////// | ||
328 | // | ||
329 | LLFloaterHtmlHelp::LLFloaterHtmlHelp(std::string start_url, std::string title) | ||
330 | : LLFloater( std::string("HTML Help") ), | ||
331 | mWebBrowser( 0 ), | ||
332 | mStatusTextContents( LLStringUtil::null ), | ||
333 | mCurrentUrl( LLStringUtil::null ) | ||
334 | { | ||
335 | sInstance = this; | ||
336 | |||
337 | // create floater from its XML definition | ||
338 | LLUICtrlFactory::getInstance()->buildFloater( this, "floater_html_help.xml" ); | ||
339 | |||
340 | childSetAction("back_btn", onClickBack, this); | ||
341 | childSetAction("home_btn", onClickHome, this); | ||
342 | childSetAction("forward_btn", onClickForward, this); | ||
343 | |||
344 | if (!title.empty()) | ||
345 | { | ||
346 | setTitle(title); | ||
347 | } | ||
348 | |||
349 | mWebBrowser = getChild<LLWebBrowserCtrl>("html_help_browser" ); | ||
350 | if ( mWebBrowser ) | ||
351 | { | ||
352 | // observe browser control events | ||
353 | mWebBrowser->addObserver( this ); | ||
354 | |||
355 | if (start_url != "") | ||
356 | { | ||
357 | mWebBrowser->navigateTo( start_url ); | ||
358 | } | ||
359 | else | ||
360 | { | ||
361 | // if the last page we were at before the client was closed is valid, go there and | ||
362 | // override what is in the XML file | ||
363 | // (not when the window was closed - it's only ever hidden - not closed) | ||
364 | std::string lastPageUrl = gSavedSettings.getString( "HtmlHelpLastPage" ); | ||
365 | if ( lastPageUrl != "" ) | ||
366 | { | ||
367 | mWebBrowser->navigateTo( lastPageUrl ); | ||
368 | }; | ||
369 | } | ||
370 | }; | ||
371 | } | ||
372 | |||
373 | //////////////////////////////////////////////////////////////////////////////// | ||
374 | // | ||
375 | LLFloaterHtmlHelp::~LLFloaterHtmlHelp() | ||
376 | { | ||
377 | // stop observing browser events | ||
378 | if ( mWebBrowser ) | ||
379 | { | ||
380 | mWebBrowser->remObserver( this ); | ||
381 | }; | ||
382 | |||
383 | // save position of floater | ||
384 | gSavedSettings.setRect( "HtmlHelpRect", getRect() ); | ||
385 | |||
386 | // save the location we were at when SL closed | ||
387 | gSavedSettings.setString( "HtmlHelpLastPage", mCurrentUrl ); | ||
388 | |||
389 | sInstance = 0; | ||
390 | } | ||
391 | |||
392 | //////////////////////////////////////////////////////////////////////////////// | ||
393 | // virtual | ||
394 | void LLFloaterHtmlHelp::draw() | ||
395 | { | ||
396 | // enable/disable buttons depending on state | ||
397 | if ( mWebBrowser ) | ||
398 | { | ||
399 | bool enable_back = mWebBrowser->canNavigateBack(); | ||
400 | childSetEnabled( "back_btn", enable_back ); | ||
401 | |||
402 | bool enable_forward = mWebBrowser->canNavigateForward(); | ||
403 | childSetEnabled( "forward_btn", enable_forward ); | ||
404 | }; | ||
405 | |||
406 | LLFloater::draw(); | ||
407 | } | ||
408 | |||
409 | //////////////////////////////////////////////////////////////////////////////// | ||
410 | // | ||
411 | void LLFloaterHtmlHelp::show(std::string url, std::string title) | ||
412 | { | ||
413 | LLFloaterHtml* floater_html = LLFloaterHtml::getInstance(); | ||
414 | floater_html->setVisible(FALSE); | ||
415 | |||
416 | if(url.empty()) | ||
417 | { | ||
418 | url = floater_html->getSupportUrl(); | ||
419 | } | ||
420 | std::string* url_copy = new std::string(url); | ||
421 | |||
422 | gViewerWindow->alertXml("ClickOpenF1Help", onClickF1HelpLoadURL, url_copy); | ||
423 | |||
424 | } | ||
425 | |||
426 | // static | ||
427 | void LLFloaterHtmlHelp::onClickF1HelpLoadURL(S32 option, void* userdata) | ||
428 | { | ||
429 | std::string* urlp = (std::string*)userdata; | ||
430 | if (0 == option) | ||
431 | { | ||
432 | LLWeb::loadURL(urlp->c_str()); | ||
433 | } | ||
434 | delete urlp; | ||
435 | } | ||
436 | |||
437 | //////////////////////////////////////////////////////////////////////////////// | ||
438 | // | ||
439 | void LLFloaterHtmlHelp::onClose( bool app_quitting ) | ||
440 | { | ||
441 | setVisible( false ); | ||
442 | } | ||
443 | |||
444 | //////////////////////////////////////////////////////////////////////////////// | ||
445 | // | ||
446 | void LLFloaterHtmlHelp::onClickClose( void* data ) | ||
447 | { | ||
448 | LLFloaterHtmlHelp* self = ( LLFloaterHtmlHelp* )data; | ||
449 | |||
450 | self->setVisible( false ); | ||
451 | } | ||
452 | |||
453 | //////////////////////////////////////////////////////////////////////////////// | ||
454 | // | ||
455 | void LLFloaterHtmlHelp::onClickBack( void* data ) | ||
456 | { | ||
457 | LLFloaterHtmlHelp* self = ( LLFloaterHtmlHelp* )data; | ||
458 | if ( self ) | ||
459 | { | ||
460 | if ( self->mWebBrowser ) | ||
461 | { | ||
462 | self->mWebBrowser->navigateBack(); | ||
463 | }; | ||
464 | }; | ||
465 | } | ||
466 | |||
467 | //////////////////////////////////////////////////////////////////////////////// | ||
468 | // | ||
469 | void LLFloaterHtmlHelp::onClickHome( void* data ) | ||
470 | { | ||
471 | LLFloaterHtmlHelp* self = ( LLFloaterHtmlHelp* )data; | ||
472 | if ( self ) | ||
473 | { | ||
474 | // get the home page URL (which can differ from the start URL) from XML and go there | ||
475 | LLWebBrowserCtrl* web_browser = self->getChild<LLWebBrowserCtrl>("html_help_browser" ); | ||
476 | if ( web_browser ) | ||
477 | { | ||
478 | web_browser->navigateHome(); | ||
479 | }; | ||
480 | }; | ||
481 | } | ||
482 | |||
483 | //////////////////////////////////////////////////////////////////////////////// | ||
484 | // | ||
485 | void LLFloaterHtmlHelp::onClickForward( void* data ) | ||
486 | { | ||
487 | LLFloaterHtmlHelp* self = ( LLFloaterHtmlHelp* )data; | ||
488 | if ( self ) | ||
489 | { | ||
490 | if ( self->mWebBrowser ) | ||
491 | { | ||
492 | self->mWebBrowser->navigateForward(); | ||
493 | }; | ||
494 | }; | ||
495 | } | ||
496 | |||
497 | //////////////////////////////////////////////////////////////////////////////// | ||
498 | // | ||
499 | void LLFloaterHtmlHelp::onStatusTextChange( const EventType& eventIn ) | ||
500 | { | ||
501 | mStatusTextContents = std::string( eventIn.getStringValue() ); | ||
502 | |||
503 | childSetText("status_text", mStatusTextContents); | ||
504 | } | ||
505 | |||
506 | //////////////////////////////////////////////////////////////////////////////// | ||
507 | // | ||
508 | void LLFloaterHtmlHelp::onLocationChange( const EventType& eventIn ) | ||
509 | { | ||
510 | llinfos << "MOZ> Location changed to " << eventIn.getStringValue() << llendl; | ||
511 | mCurrentUrl = std::string( eventIn.getStringValue() ); | ||
512 | } | ||
513 | |||
514 | //////////////////////////////////////////////////////////////////////////////// | ||
515 | // | ||
516 | LLViewerHtmlHelp::LLViewerHtmlHelp() | ||
517 | { | ||
518 | LLUI::setHtmlHelp(this); | ||
519 | } | ||
520 | |||
521 | LLViewerHtmlHelp::~LLViewerHtmlHelp() | ||
522 | { | ||
523 | LLUI::setHtmlHelp(NULL); | ||
524 | } | ||
525 | |||
526 | void LLViewerHtmlHelp::show() | ||
527 | { | ||
528 | LLFloaterHtmlHelp::show("", ""); | ||
529 | } | ||
530 | |||
531 | void LLViewerHtmlHelp::show(std::string url) | ||
532 | { | ||
533 | std::string title; // empty | ||
534 | LLFloaterHtmlHelp::show(url, title); | ||
535 | } | ||
diff --git a/linden/indra/newview/llfloaterhtmlhelp.h b/linden/indra/newview/llfloaterhtmlhelp.h index d726b77..d52d8d3 100644 --- a/linden/indra/newview/llfloaterhtmlhelp.h +++ b/linden/indra/newview/llfloaterhtmlhelp.h | |||
@@ -36,16 +36,6 @@ | |||
36 | #include "llfloater.h" | 36 | #include "llfloater.h" |
37 | #include "llwebbrowserctrl.h" | 37 | #include "llwebbrowserctrl.h" |
38 | 38 | ||
39 | class LLViewerHtmlHelp : public LLHtmlHelp | ||
40 | { | ||
41 | public: | ||
42 | LLViewerHtmlHelp(); | ||
43 | virtual ~LLViewerHtmlHelp(); | ||
44 | |||
45 | /*virtual*/ void show(); | ||
46 | /*virtual*/ void show(std::string start_url); | ||
47 | }; | ||
48 | |||
49 | class LLComboBox; | 39 | class LLComboBox; |
50 | class LLWebBrowserCtrl; | 40 | class LLWebBrowserCtrl; |
51 | 41 | ||
@@ -65,7 +55,9 @@ public: | |||
65 | void buildURLHistory(); | 55 | void buildURLHistory(); |
66 | 56 | ||
67 | static LLFloaterMediaBrowser* showInstance(const LLSD& id); | 57 | static LLFloaterMediaBrowser* showInstance(const LLSD& id); |
68 | static void show(); | 58 | |
59 | static void toggle(); | ||
60 | static void helpF1(); | ||
69 | static void onEnterAddress(LLUICtrl* ctrl, void* user_data); | 61 | static void onEnterAddress(LLUICtrl* ctrl, void* user_data); |
70 | static void onClickRefresh(void* user_data); | 62 | static void onClickRefresh(void* user_data); |
71 | static void onClickBack(void* user_data); | 63 | static void onClickBack(void* user_data); |
@@ -76,14 +68,15 @@ public: | |||
76 | static void onClickAssign(void* user_data); | 68 | static void onClickAssign(void* user_data); |
77 | static void onClickHome(void* user_data); | 69 | static void onClickHome(void* user_data); |
78 | static void onClickSetHome(void* user_data); | 70 | static void onClickSetHome(void* user_data); |
71 | static void onClickF1HelpLoadURL(S32 option, void* userdata); | ||
79 | 72 | ||
80 | private: | 73 | private: |
81 | LLWebBrowserCtrl* mBrowser; | 74 | LLWebBrowserCtrl* mBrowser; |
82 | LLComboBox* mAddressCombo; | 75 | LLComboBox* mAddressCombo; |
83 | std::string mCurrentURL; | 76 | std::string mCurrentURL; |
84 | }; | ||
85 | 77 | ||
86 | extern LLViewerHtmlHelp gViewerHtmlHelp; | 78 | static LLFloaterMediaBrowser* sInstance; |
79 | }; | ||
87 | 80 | ||
88 | #endif // LL_LLFLOATERHTMLHELP_H | 81 | #endif // LL_LLFLOATERHTMLHELP_H |
89 | 82 | ||
diff --git a/linden/indra/newview/llimpanel.cpp b/linden/indra/newview/llimpanel.cpp index 5e260ec..dede746 100644 --- a/linden/indra/newview/llimpanel.cpp +++ b/linden/indra/newview/llimpanel.cpp | |||
@@ -68,7 +68,6 @@ | |||
68 | #include "lluictrlfactory.h" | 68 | #include "lluictrlfactory.h" |
69 | #include "llviewerwindow.h" | 69 | #include "llviewerwindow.h" |
70 | #include "lllogchat.h" | 70 | #include "lllogchat.h" |
71 | #include "llfloaterhtml.h" | ||
72 | #include "llweb.h" | 71 | #include "llweb.h" |
73 | #include "llhttpclient.h" | 72 | #include "llhttpclient.h" |
74 | #include "llmutelist.h" | 73 | #include "llmutelist.h" |
diff --git a/linden/indra/newview/llpanellogin.cpp b/linden/indra/newview/llpanellogin.cpp index a495516..aeb3b2d 100644 --- a/linden/indra/newview/llpanellogin.cpp +++ b/linden/indra/newview/llpanellogin.cpp | |||
@@ -70,8 +70,6 @@ | |||
70 | #include "llweb.h" | 70 | #include "llweb.h" |
71 | #include "llwebbrowserctrl.h" | 71 | #include "llwebbrowserctrl.h" |
72 | 72 | ||
73 | #include "llfloaterhtml.h" | ||
74 | |||
75 | #include "llfloaterhtmlhelp.h" | 73 | #include "llfloaterhtmlhelp.h" |
76 | #include "llfloatertos.h" | 74 | #include "llfloatertos.h" |
77 | 75 | ||
@@ -559,7 +557,7 @@ BOOL LLPanelLogin::handleKeyHere(KEY key, MASK mask) | |||
559 | if ( KEY_F1 == key ) | 557 | if ( KEY_F1 == key ) |
560 | { | 558 | { |
561 | llinfos << "Spawning HTML help window" << llendl; | 559 | llinfos << "Spawning HTML help window" << llendl; |
562 | gViewerHtmlHelp.show(); | 560 | LLFloaterMediaBrowser::helpF1(); |
563 | return TRUE; | 561 | return TRUE; |
564 | } | 562 | } |
565 | 563 | ||
diff --git a/linden/indra/newview/llurldispatcher.cpp b/linden/indra/newview/llurldispatcher.cpp index 229314e..d574ea1 100644 --- a/linden/indra/newview/llurldispatcher.cpp +++ b/linden/indra/newview/llurldispatcher.cpp | |||
@@ -37,7 +37,6 @@ | |||
37 | #include "llcommandhandler.h" | 37 | #include "llcommandhandler.h" |
38 | #include "llfloaterurldisplay.h" | 38 | #include "llfloaterurldisplay.h" |
39 | #include "llfloaterdirectory.h" | 39 | #include "llfloaterdirectory.h" |
40 | #include "llfloaterhtml.h" | ||
41 | #include "llfloaterworldmap.h" | 40 | #include "llfloaterworldmap.h" |
42 | #include "llfloaterhtmlhelp.h" | 41 | #include "llfloaterhtmlhelp.h" |
43 | #include "llpanellogin.h" | 42 | #include "llpanellogin.h" |
diff --git a/linden/indra/newview/llviewermenu.cpp b/linden/indra/newview/llviewermenu.cpp index d607afe..4c6de79 100644 --- a/linden/indra/newview/llviewermenu.cpp +++ b/linden/indra/newview/llviewermenu.cpp | |||
@@ -105,7 +105,6 @@ | |||
105 | #include "llfloatergroupinfo.h" | 105 | #include "llfloatergroupinfo.h" |
106 | #include "llfloatergroupinvite.h" | 106 | #include "llfloatergroupinvite.h" |
107 | #include "llfloatergroups.h" | 107 | #include "llfloatergroups.h" |
108 | #include "llfloaterhtml.h" | ||
109 | #include "llfloaterhtmlhelp.h" | 108 | #include "llfloaterhtmlhelp.h" |
110 | #include "llfloaterhud.h" | 109 | #include "llfloaterhud.h" |
111 | #include "llfloaterinspect.h" | 110 | #include "llfloaterinspect.h" |
@@ -5146,7 +5145,7 @@ class LLShowFloater : public view_listener_t | |||
5146 | } | 5145 | } |
5147 | else if (floater_name == "help f1") | 5146 | else if (floater_name == "help f1") |
5148 | { | 5147 | { |
5149 | gViewerHtmlHelp.show(); | 5148 | LLFloaterMediaBrowser::helpF1(); |
5150 | } | 5149 | } |
5151 | else if (floater_name == "help tutorial") | 5150 | else if (floater_name == "help tutorial") |
5152 | { | 5151 | { |
@@ -5189,7 +5188,7 @@ class LLShowFloater : public view_listener_t | |||
5189 | } | 5188 | } |
5190 | else if (floater_name == "inworld browser") | 5189 | else if (floater_name == "inworld browser") |
5191 | { | 5190 | { |
5192 | LLFloaterMediaBrowser::show(); | 5191 | LLFloaterMediaBrowser::toggle(); |
5193 | } | 5192 | } |
5194 | return true; | 5193 | return true; |
5195 | } | 5194 | } |
@@ -6968,13 +6967,8 @@ void handle_load_from_xml(void*) | |||
6968 | 6967 | ||
6969 | void handle_slurl_test(void*) | 6968 | void handle_slurl_test(void*) |
6970 | { | 6969 | { |
6971 | const bool open_links_externally = false; | 6970 | std::string test_slurl = "http://secondlife.com/app/search/slurls.html"; |
6972 | const bool open_app_slurls = true; | 6971 | LLFloaterMediaBrowser::showInstance(test_slurl); |
6973 | LLFloaterHtml::getInstance()->show( | ||
6974 | "http://secondlife.com/app/search/slurls.html", | ||
6975 | "SLURL Test", | ||
6976 | open_links_externally, | ||
6977 | open_app_slurls); | ||
6978 | } | 6972 | } |
6979 | 6973 | ||
6980 | void handle_rebake_textures(void*) | 6974 | void handle_rebake_textures(void*) |
diff --git a/linden/indra/newview/llviewerparcelmgr.cpp b/linden/indra/newview/llviewerparcelmgr.cpp index a1311d3..5ef6f83 100644 --- a/linden/indra/newview/llviewerparcelmgr.cpp +++ b/linden/indra/newview/llviewerparcelmgr.cpp | |||
@@ -50,7 +50,6 @@ | |||
50 | #include "llfirstuse.h" | 50 | #include "llfirstuse.h" |
51 | #include "llfloaterbuyland.h" | 51 | #include "llfloaterbuyland.h" |
52 | #include "llfloatergroups.h" | 52 | #include "llfloatergroups.h" |
53 | //#include "llfloaterhtml.h" | ||
54 | #include "llfloatersellland.h" | 53 | #include "llfloatersellland.h" |
55 | #include "llfloatertools.h" | 54 | #include "llfloatertools.h" |
56 | #include "llnotify.h" | 55 | #include "llnotify.h" |
diff --git a/linden/indra/newview/llviewerstats.cpp b/linden/indra/newview/llviewerstats.cpp index 9034634..edefb57 100644 --- a/linden/indra/newview/llviewerstats.cpp +++ b/linden/indra/newview/llviewerstats.cpp | |||
@@ -53,7 +53,6 @@ | |||
53 | #include "llfasttimerview.h" | 53 | #include "llfasttimerview.h" |
54 | #include "llviewerregion.h" | 54 | #include "llviewerregion.h" |
55 | #include "llvoavatar.h" | 55 | #include "llvoavatar.h" |
56 | #include "llfloaterhtml.h" | ||
57 | #include "llviewerwindow.h" // *TODO: remove, only used for width/height | 56 | #include "llviewerwindow.h" // *TODO: remove, only used for width/height |
58 | #include "llworld.h" | 57 | #include "llworld.h" |
59 | #include "llfeaturemanager.h" | 58 | #include "llfeaturemanager.h" |
diff --git a/linden/indra/newview/llwebbrowserctrl.cpp b/linden/indra/newview/llwebbrowserctrl.cpp index e9a7132..c4a2b2b 100644 --- a/linden/indra/newview/llwebbrowserctrl.cpp +++ b/linden/indra/newview/llwebbrowserctrl.cpp | |||
@@ -35,7 +35,7 @@ | |||
35 | #include "llwebbrowserctrl.h" | 35 | #include "llwebbrowserctrl.h" |
36 | 36 | ||
37 | // viewer includes | 37 | // viewer includes |
38 | #include "llfloaterhtml.h" | 38 | #include "llfloaterhtmlhelp.h" |
39 | #include "llfloaterworldmap.h" | 39 | #include "llfloaterworldmap.h" |
40 | #include "lluictrlfactory.h" | 40 | #include "lluictrlfactory.h" |
41 | #include "llurldispatcher.h" | 41 | #include "llurldispatcher.h" |
@@ -750,15 +750,10 @@ void LLWebBrowserCtrl::onClickLinkHref( const EventType& eventIn ) | |||
750 | if ( LLStringUtil::compareInsensitive( eventIn.getStringValue().substr( 0, protocol1.length() ), protocol1 ) == 0 || | 750 | if ( LLStringUtil::compareInsensitive( eventIn.getStringValue().substr( 0, protocol1.length() ), protocol1 ) == 0 || |
751 | LLStringUtil::compareInsensitive( eventIn.getStringValue().substr( 0, protocol2.length() ), protocol2 ) == 0 ) | 751 | LLStringUtil::compareInsensitive( eventIn.getStringValue().substr( 0, protocol2.length() ), protocol2 ) == 0 ) |
752 | { | 752 | { |
753 | // If we spawn a new LLFloaterHTML, assume we want it to | 753 | // If we spawn a new LLFloaterMediaBrowser, assume we want it to |
754 | // follow this LLWebBrowserCtrl's setting for whether or | 754 | // follow this LLWebBrowserCtrl's setting for whether or |
755 | // not to open secondlife:///app/ links. JC. | 755 | // not to open secondlife:///app/ links. JC. |
756 | const bool open_links_externally = false; | 756 | LLFloaterMediaBrowser::showInstance(eventIn.getStringValue()); |
757 | LLFloaterHtml::getInstance()->show( | ||
758 | eventIn.getStringValue(), | ||
759 | "Second Life Browser", | ||
760 | open_links_externally, | ||
761 | mOpenAppSLURLs); | ||
762 | }; | 757 | }; |
763 | }; | 758 | }; |
764 | }; | 759 | }; |
diff --git a/linden/indra/newview/skins/default/xui/de/floater_html.xml b/linden/indra/newview/skins/default/xui/de/floater_html.xml deleted file mode 100644 index 5d5877e..0000000 --- a/linden/indra/newview/skins/default/xui/de/floater_html.xml +++ /dev/null | |||
@@ -1,14 +0,0 @@ | |||
1 | <?xml version="1.0" encoding="utf-8" standalone="yes" ?> | ||
2 | <floater name="htmlfloater" title=""> | ||
3 | <button label="Schließen" name="close_btn" /> | ||
4 | <button label="Zurück" name="back_btn" /> | ||
5 | <button label="Zuhause" name="home_btn" /> | ||
6 | <button label="Weiterleiten" name="forward_btn" /> | ||
7 | <button label="Los" name="go_btn" /> | ||
8 | <string name="home_page_url"> | ||
9 | http://de.secondlife.com | ||
10 | </string> | ||
11 | <string name="support_page_url"> | ||
12 | http://de.secondlife.com/support | ||
13 | </string> | ||
14 | </floater> | ||
diff --git a/linden/indra/newview/skins/default/xui/en-us/alerts.xml b/linden/indra/newview/skins/default/xui/en-us/alerts.xml index dc9b5ea..d3b15c5 100644 --- a/linden/indra/newview/skins/default/xui/en-us/alerts.xml +++ b/linden/indra/newview/skins/default/xui/en-us/alerts.xml | |||
@@ -404,6 +404,8 @@ Go to the Second Life web site for more information on partnering? | |||
404 | SKW -- Skew | 404 | SKW -- Skew |
405 | PB -- Slice/Dimple/Profile cut begin | 405 | PB -- Slice/Dimple/Profile cut begin |
406 | PE -- Slice/Dimple/Profile cut end | 406 | PE -- Slice/Dimple/Profile cut end |
407 | TB -- Twist begin | ||
408 | TE -- Twist end | ||
407 | XSH -- X-axis top shear | 409 | XSH -- X-axis top shear |
408 | YSH -- Y-axis top shear | 410 | YSH -- Y-axis top shear |
409 | XHL -- X-axis hole size | 411 | XHL -- X-axis hole size |
@@ -413,17 +415,21 @@ Go to the Second Life web site for more information on partnering? | |||
413 | ROF -- Radius offset | 415 | ROF -- Radius offset |
414 | REV -- Revolutions | 416 | REV -- Revolutions |
415 | 417 | ||
418 | PI -- pi | ||
419 | TWO_PI -- 2pi | ||
420 | PI_BY_TWO -- pi/2 | ||
421 | SQRT2 -- Square root of 2 | ||
422 | DEG_TO_RAD -- DEG_TO_RAD conversion (pi/180) | ||
423 | RAD_TO_DEG -- RAD_TO_DEG conversion (180/pi) | ||
424 | GRAVITY -- -9.8 | ||
425 | |||
416 | * -- Multiplication | 426 | * -- Multiplication |
417 | \ -- Division | 427 | \ -- Division |
418 | + -- Addition | 428 | + -- Addition |
419 | - -- Subtraction | 429 | - -- Subtraction |
420 | 430 | ||
421 | Examples: | 431 | For what these are and how to use them, read: |
422 | 432 | http://imprudenceviewer.org/wiki/Build_Math_Expressions | |
423 | * Enter 'ZP + 20' in the Z-axis position field | ||
424 | to move an object up 20 meters. | ||
425 | * Enter 'XS - YS' in the X-axis size field | ||
426 | to subtract the Y size from the X size. | ||
427 | </message> | 433 | </message> |
428 | </alert> | 434 | </alert> |
429 | <alert modal="true" name="ClickTextureConstants"> | 435 | <alert modal="true" name="ClickTextureConstants"> |
@@ -443,16 +449,11 @@ Go to the Second Life web site for more information on partnering? | |||
443 | + -- Addition | 449 | + -- Addition |
444 | - -- Subtraction | 450 | - -- Subtraction |
445 | 451 | ||
446 | Examples: | 452 | For what these are and how to use them, read: |
447 | 453 | http://imprudenceviewer.org/wiki/Build_Math_Expressions | |
448 | * Enter 'TSU * 4' in horizantal repeats field | ||
449 | to increase the amount of repeats by 4x. | ||
450 | * Enter 'TSV' in the horizontal repeats field | ||
451 | to make the horizontal and vertical | ||
452 | repeats match. | ||
453 | </message> | 454 | </message> |
454 | </alert> | 455 | </alert> |
455 | <alert modal="true" name="ClickWebProfileHelpAvatar"> | 456 | <alert modal="true" name="ClickWebProfileHelpAvatar"> |
456 | <message name="message"> | 457 | <message name="message"> |
457 | If this Resident has set a web profile URL then you can: | 458 | If this Resident has set a web profile URL then you can: |
458 | * Click 'Load' to see the page in this Web tab. | 459 | * Click 'Load' to see the page in this Web tab. |
diff --git a/linden/indra/newview/skins/default/xui/en-us/floater_chat_history.xml b/linden/indra/newview/skins/default/xui/en-us/floater_chat_history.xml index 6bd4424..a12cb2b 100644 --- a/linden/indra/newview/skins/default/xui/en-us/floater_chat_history.xml +++ b/linden/indra/newview/skins/default/xui/en-us/floater_chat_history.xml | |||
@@ -46,13 +46,15 @@ | |||
46 | bottom="28" embedded_items="false" enabled="false" | 46 | bottom="28" embedded_items="false" enabled="false" |
47 | follows="left|top|right|bottom" font="SansSerif" height="74" left="5" | 47 | follows="left|top|right|bottom" font="SansSerif" height="74" left="5" |
48 | max_length="2147483647" mouse_opaque="true" name="Chat History Editor" | 48 | max_length="2147483647" mouse_opaque="true" name="Chat History Editor" |
49 | track_bottom="true" | ||
49 | text_color="ChatHistoryTextColor" | 50 | text_color="ChatHistoryTextColor" |
50 | text_readonly_color="ChatHistoryTextColor" width="299" word_wrap="true" /> | 51 | text_readonly_color="ChatHistoryTextColor" width="299" word_wrap="true" /> |
51 | <text_editor type="string" length="1" bg_readonly_color="ChatHistoryBgColor" bg_writeable_color="ChatHistoryBgColor" | 52 | <text_editor type="string" length="1" bg_readonly_color="ChatHistoryBgColor" bg_writeable_color="ChatHistoryBgColor" |
52 | bottom="28" embedded_items="false" enabled="false" | 53 | bottom="28" embedded_items="false" enabled="false" |
53 | follows="left|top|right|bottom" font="SansSerif" height="74" left="5" | 54 | follows="left|top|right|bottom" font="SansSerif" height="74" left="5" |
54 | max_length="2147483647" mouse_opaque="true" | 55 | max_length="2147483647" mouse_opaque="true" |
55 | name="Chat History Editor with mute" text_color="ChatHistoryTextColor" | 56 | name="Chat History Editor with mute" text_color="ChatHistoryTextColor" |
57 | track_bottom="true" | ||
56 | text_readonly_color="ChatHistoryTextColor" width="300" word_wrap="true" /> | 58 | text_readonly_color="ChatHistoryTextColor" width="300" word_wrap="true" /> |
57 | <panel bottom="5" follows="left|right|bottom" left="5" name="chat_panel" right="-5" | 59 | <panel bottom="5" follows="left|right|bottom" left="5" name="chat_panel" right="-5" |
58 | tab_group="1" top="25"> | 60 | tab_group="1" top="25"> |
diff --git a/linden/indra/newview/skins/default/xui/en-us/floater_html.xml b/linden/indra/newview/skins/default/xui/en-us/floater_html.xml deleted file mode 100644 index d107454..0000000 --- a/linden/indra/newview/skins/default/xui/en-us/floater_html.xml +++ /dev/null | |||
@@ -1,25 +0,0 @@ | |||
1 | <?xml version="1.0" encoding="utf-8" standalone="yes" ?> | ||
2 | <floater can_close="true" can_drag_on_left="false" can_minimize="true" can_resize="true" | ||
3 | height="500" min_height="300" min_width="400" name="htmlfloater" title="" | ||
4 | width="700"> | ||
5 | <button bottom="10" follows="bottom|right" font="SansSerifSmall" height="20" | ||
6 | label="Close" name="close_btn" right="-10" width="80" /> | ||
7 | <web_browser bottom="40" follows="top|left|bottom|right" font="SansSerifSmall" left="15" | ||
8 | name="html_floater_browser" right="-15" top="-56" /> | ||
9 | <button bottom="-45" follows="top|left" font="SansSerifSmall" height="20" label="Back" | ||
10 | left="15" name="back_btn" width="70" /> | ||
11 | <button bottom_delta="0" follows="top|left" font="SansSerifSmall" height="20" | ||
12 | label="Forward" left_delta="73" name="forward_btn" width="70" /> | ||
13 | <line_editor bevel_style="in" border_style="line" border_thickness="1" bottom_delta="0" | ||
14 | follows="top|left|right" font="SansSerifSmall" height="20" left_delta="85" | ||
15 | max_length="256" mouse_opaque="true" name="url_edit" | ||
16 | select_all_on_focus_received="true" width="435" /> | ||
17 | <button bottom_delta="0" follows="top|right" font="SansSerifSmall" height="20" | ||
18 | label="Go" left_delta="440" name="go_btn" width="70" /> | ||
19 | <string name="home_page_url"> | ||
20 | http://www.secondlife.com | ||
21 | </string> | ||
22 | <string name="support_page_url"> | ||
23 | http://support.secondlife.com | ||
24 | </string> | ||
25 | </floater> | ||
diff --git a/linden/indra/newview/skins/default/xui/en-us/floater_instant_message.xml b/linden/indra/newview/skins/default/xui/en-us/floater_instant_message.xml index eb8e672..3b1c927 100644 --- a/linden/indra/newview/skins/default/xui/en-us/floater_instant_message.xml +++ b/linden/indra/newview/skins/default/xui/en-us/floater_instant_message.xml | |||
@@ -64,6 +64,7 @@ | |||
64 | follows="left|top|right|bottom" font="SansSerif" height="221" left="5" | 64 | follows="left|top|right|bottom" font="SansSerif" height="221" left="5" |
65 | max_length="2147483647" mouse_opaque="true" name="im_history" | 65 | max_length="2147483647" mouse_opaque="true" name="im_history" |
66 | text_color="ChatHistoryTextColor" | 66 | text_color="ChatHistoryTextColor" |
67 | track_bottom="true" | ||
67 | text_readonly_color="ChatHistoryTextColor" width="487" word_wrap="true" /> | 68 | text_readonly_color="ChatHistoryTextColor" width="487" word_wrap="true" /> |
68 | <line_editor bevel_style="in" border_style="line" border_thickness="1" bottom="7" | 69 | <line_editor bevel_style="in" border_style="line" border_thickness="1" bottom="7" |
69 | follows="left|right|bottom" font="SansSerif" height="20" | 70 | follows="left|right|bottom" font="SansSerif" height="20" |
diff --git a/linden/indra/newview/skins/default/xui/en-us/floater_instant_message_ad_hoc.xml b/linden/indra/newview/skins/default/xui/en-us/floater_instant_message_ad_hoc.xml index eea285c..ddf344d 100644 --- a/linden/indra/newview/skins/default/xui/en-us/floater_instant_message_ad_hoc.xml +++ b/linden/indra/newview/skins/default/xui/en-us/floater_instant_message_ad_hoc.xml | |||
@@ -1,73 +1,74 @@ | |||
1 | <?xml version="1.0" encoding="utf-8" standalone="yes" ?> | 1 | <?xml version="1.0" encoding="utf-8" standalone="yes" ?> |
2 | <floater border="true" bottom="-298" can_close="true" can_drag_on_left="false" | 2 | <floater border="true" bottom="-298" can_close="true" can_drag_on_left="false" |
3 | can_minimize="false" can_resize="true" default_tab_group="1" enabled="true" | 3 | can_minimize="false" can_resize="true" default_tab_group="1" enabled="true" |
4 | follows="left|top|right|bottom" height="297" label="(unknown)" left="1" | 4 | follows="left|top|right|bottom" height="297" label="(unknown)" left="1" |
5 | min_height="225" min_width="265" mouse_opaque="true" name="im_floater" | 5 | min_height="225" min_width="265" mouse_opaque="true" name="im_floater" |
6 | rect_control="" title="(unknown)" width="501"> | 6 | rect_control="" title="(unknown)" width="501"> |
7 | <string name="ringing"> | 7 | <string name="ringing"> |
8 | Joining Voice Chat... | 8 | Joining Voice Chat... |
9 | </string> | 9 | </string> |
10 | <string name="connected"> | 10 | <string name="connected"> |
11 | Connected, click End Call to hang up | 11 | Connected, click End Call to hang up |
12 | </string> | 12 | </string> |
13 | <string name="hang_up"> | 13 | <string name="hang_up"> |
14 | Left Voice Chat | 14 | Left Voice Chat |
15 | </string> | 15 | </string> |
16 | <string name="voice_icon"> | 16 | <string name="voice_icon"> |
17 | icn_voice-groupfocus.tga | 17 | icn_voice-groupfocus.tga |
18 | </string> | 18 | </string> |
19 | <string name="title_string"> | 19 | <string name="title_string"> |
20 | Instant Message with [NAME] | 20 | Instant Message with [NAME] |
21 | </string> | 21 | </string> |
22 | <string name="typing_start_string"> | 22 | <string name="typing_start_string"> |
23 | [NAME] is typing... | 23 | [NAME] is typing... |
24 | </string> | 24 | </string> |
25 | <string name="session_start_string"> | 25 | <string name="session_start_string"> |
26 | Starting session with [NAME] please wait. | 26 | Starting session with [NAME] please wait. |
27 | </string> | 27 | </string> |
28 | <string name="default_text_label"> | 28 | <string name="default_text_label"> |
29 | Click here to instant message. | 29 | Click here to instant message. |
30 | </string> | 30 | </string> |
31 | <layout_stack border="false" bottom="0" follows="left|top|right|bottom" height="277" left="2" | 31 | <layout_stack border="false" bottom="0" follows="left|top|right|bottom" height="277" left="2" |
32 | orientation="horizontal" tab_group="1" width="495" name="panels"> | 32 | orientation="horizontal" tab_group="1" width="495" name="panels"> |
33 | <layout_panel border="false" bottom="0" default_tab_group="1" follows="left|top|bottom|right" | 33 | <layout_panel border="false" bottom="0" default_tab_group="1" follows="left|top|bottom|right" |
34 | height="295" left="0" min_width="115" name="im_contents_panel" width="495"> | 34 | height="295" left="0" min_width="115" name="im_contents_panel" width="495"> |
35 | <button bottom="-20" enabled="false" follows="left|top" halign="center" height="20" | 35 | <button bottom="-20" enabled="false" follows="left|top" halign="center" height="20" |
36 | image_overlay="icn_voice-call-start.tga" image_overlay_alignment="left" | 36 | image_overlay="icn_voice-call-start.tga" image_overlay_alignment="left" |
37 | label="Call" left="5" name="start_call_btn" width="80" /> | 37 | label="Call" left="5" name="start_call_btn" width="80" /> |
38 | <button bottom_delta="0" follows="left|top" halign="center" height="20" | 38 | <button bottom_delta="0" follows="left|top" halign="center" height="20" |
39 | image_overlay="icn_voice-call-end.tga" image_overlay_alignment="left" | 39 | image_overlay="icn_voice-call-end.tga" image_overlay_alignment="left" |
40 | label="End Call" left_delta="0" name="end_call_btn" visible="false" | 40 | label="End Call" left_delta="0" name="end_call_btn" visible="false" |
41 | width="80" /> | 41 | width="80" /> |
42 | <button bottom_delta="0" follows="right|top" height="20" label="< <" | 42 | <button bottom_delta="0" follows="right|top" height="20" label="< <" |
43 | label_selected="> >" left="463" name="toggle_active_speakers_btn" | 43 | label_selected="> >" left="463" name="toggle_active_speakers_btn" |
44 | right="496" | 44 | right="496" |
45 | tool_tip="Click here to toggle a list of active participants in this IM session." | 45 | tool_tip="Click here to toggle a list of active participants in this IM session." |
46 | visible="true" width="80" /> | 46 | visible="true" width="80" /> |
47 | <text_editor type="string" length="1" bg_readonly_color="ChatHistoryBgColor" bg_writeable_color="ChatHistoryBgColor" | 47 | <text_editor type="string" length="1" bg_readonly_color="ChatHistoryBgColor" bg_writeable_color="ChatHistoryBgColor" |
48 | bottom="-265" embedded_items="false" enabled="false" | 48 | bottom="-265" embedded_items="false" enabled="false" |
49 | follows="left|top|right|bottom" font="SansSerif" height="239" left="5" | 49 | follows="left|top|right|bottom" font="SansSerif" height="239" left="5" |
50 | max_length="2147483647" mouse_opaque="true" name="im_history" | 50 | max_length="2147483647" mouse_opaque="true" name="im_history" |
51 | text_color="ChatHistoryTextColor" | 51 | track_bottom="true" |
52 | text_readonly_color="ChatHistoryTextColor" width="490" word_wrap="true" /> | 52 | text_color="ChatHistoryTextColor" |
53 | <line_editor bevel_style="in" border_style="line" border_thickness="1" bottom="7" | 53 | text_readonly_color="ChatHistoryTextColor" width="490" word_wrap="true" /> |
54 | enabled="true" follows="left|right|bottom" font="SansSerif" | 54 | <line_editor bevel_style="in" border_style="line" border_thickness="1" bottom="7" |
55 | handle_edit_keys_directly="false" height="20" | 55 | enabled="true" follows="left|right|bottom" font="SansSerif" |
56 | label="Click here to instant message" left="5" max_length="1022" | 56 | handle_edit_keys_directly="false" height="20" |
57 | mouse_opaque="true" name="chat_editor" select_all_on_focus_received="false" | 57 | label="Click here to instant message" left="5" max_length="1022" |
58 | select_on_focus="false" tab_group="1" width="426" /> | 58 | mouse_opaque="true" name="chat_editor" select_all_on_focus_received="false" |
59 | <button bottom_delta="0" enabled="true" follows="right|bottom" font="SansSerif" | 59 | select_on_focus="false" tab_group="1" width="426" /> |
60 | halign="center" height="20" label="Send" left="436" mouse_opaque="true" | 60 | <button bottom_delta="0" enabled="true" follows="right|bottom" font="SansSerif" |
61 | name="send_btn" scale_image="true" width="60" /> | 61 | halign="center" height="20" label="Send" left="436" mouse_opaque="true" |
62 | </layout_panel> | 62 | name="send_btn" scale_image="true" width="60" /> |
63 | <layout_panel auto_resize="false" bottom="0" can_resize="true" | 63 | </layout_panel> |
64 | filename="panel_speaker_controls.xml" height="120" left="0" min_width="140" | 64 | <layout_panel auto_resize="false" bottom="0" can_resize="true" |
65 | name="active_speakers_panel" top_delta="0" visible="false" width="140" /> | 65 | filename="panel_speaker_controls.xml" height="120" left="0" min_width="140" |
66 | </layout_stack> | 66 | name="active_speakers_panel" top_delta="0" visible="false" width="140" /> |
67 | <string name="live_help_dialog"> | 67 | </layout_stack> |
68 | *** Welcome to Help Request *** | 68 | <string name="live_help_dialog"> |
69 | Please first check our SL Help Pages by pressing F1, or by accessing the Knowledge Base http://secondlife.com/knowledgebase/ | 69 | *** Welcome to Help Request *** |
70 | If your answer is not there, please enter your question to begin, then allow a few moments for available helpers to respond. | 70 | Please first check our SL Help Pages by pressing F1, or by accessing the Knowledge Base http://secondlife.com/knowledgebase/ |
71 | -=-=- Response times will vary, especially during peak times -=-=- | 71 | If your answer is not there, please enter your question to begin, then allow a few moments for available helpers to respond. |
72 | </string> | 72 | -=-=- Response times will vary, especially during peak times -=-=- |
73 | </floater> | 73 | </string> |
74 | </floater> | ||
diff --git a/linden/indra/newview/skins/default/xui/en-us/floater_instant_message_group.xml b/linden/indra/newview/skins/default/xui/en-us/floater_instant_message_group.xml index 3a6e4ec..f59017e 100644 --- a/linden/indra/newview/skins/default/xui/en-us/floater_instant_message_group.xml +++ b/linden/indra/newview/skins/default/xui/en-us/floater_instant_message_group.xml | |||
@@ -64,6 +64,7 @@ | |||
64 | follows="left|top|right|bottom" font="SansSerif" left="4" | 64 | follows="left|top|right|bottom" font="SansSerif" left="4" |
65 | max_length="2147483647" mouse_opaque="true" name="im_history" | 65 | max_length="2147483647" mouse_opaque="true" name="im_history" |
66 | text_color="ChatHistoryTextColor" | 66 | text_color="ChatHistoryTextColor" |
67 | track_bottom="true" | ||
67 | text_readonly_color="ChatHistoryTextColor" top="104" width="170" | 68 | text_readonly_color="ChatHistoryTextColor" top="104" width="170" |
68 | word_wrap="true" /> | 69 | word_wrap="true" /> |
69 | <line_editor bevel_style="in" border_style="line" border_thickness="1" bottom="7" | 70 | <line_editor bevel_style="in" border_style="line" border_thickness="1" bottom="7" |
diff --git a/linden/indra/newview/skins/default/xui/en-us/floater_media_browser.xml b/linden/indra/newview/skins/default/xui/en-us/floater_media_browser.xml index 077ab23..318f46a 100644 --- a/linden/indra/newview/skins/default/xui/en-us/floater_media_browser.xml +++ b/linden/indra/newview/skins/default/xui/en-us/floater_media_browser.xml | |||
@@ -8,15 +8,15 @@ | |||
8 | <button bottom="0" follows="left|top" height="20" label="Back" left="0" name="back" | 8 | <button bottom="0" follows="left|top" height="20" label="Back" left="0" name="back" |
9 | width="55" /> | 9 | width="55" /> |
10 | <button bottom_delta="0" follows="left|top" height="20" label="Forward" left_delta="55" | 10 | <button bottom_delta="0" follows="left|top" height="20" label="Forward" left_delta="55" |
11 | name="forward" width="60" /> | 11 | name="forward" width="68" /> |
12 | <button bottom_delta="0" enabled="false" follows="left|top" height="20" label="Reload" | 12 | <button bottom_delta="0" enabled="false" follows="left|top" height="20" label="Reload" |
13 | left_delta="65" name="reload" width="70" /> | 13 | left_delta="70" name="reload" width="70" /> |
14 | <combo_box allow_text_entry="true" bottom_delta="0" follows="left|top|right" height="20" | 14 | <combo_box allow_text_entry="true" bottom_delta="0" follows="left|top|right" height="20" |
15 | left_delta="75" max_chars="235" name="address" width="225" /> | 15 | left_delta="75" max_chars="235" name="address" width="230" /> |
16 | <button bottom_delta="0" enabled="false" follows="right|top" height="20" label="Go" | 16 | <button bottom_delta="0" enabled="false" follows="right|top" height="20" label="Go" |
17 | left_delta="230" name="go" width="55" /> | 17 | left_delta="232" name="go" width="55" /> |
18 | <button bottom_delta="0" enabled="true" follows="right|top" height="20" label="Home" | 18 | <button bottom_delta="0" enabled="true" follows="right|top" height="20" label="Home" |
19 | left_delta="60" name="home" width="55" /> | 19 | left_delta="58" name="home" width="55" /> |
20 | </layout_panel> | 20 | </layout_panel> |
21 | <layout_panel auto_resize="false" bottom="0" height="20" left="0" | 21 | <layout_panel auto_resize="false" bottom="0" height="20" left="0" |
22 | name="parcel_owner_controls" user_resize="false" width="540"> | 22 | name="parcel_owner_controls" user_resize="false" width="540"> |
@@ -30,10 +30,10 @@ | |||
30 | <button bottom="5" follows="bottom|left" height="20" label="Open in My Web Browser" | 30 | <button bottom="5" follows="bottom|left" height="20" label="Open in My Web Browser" |
31 | left="0" name="open_browser" width="185" /> | 31 | left="0" name="open_browser" width="185" /> |
32 | <check_box bottom="5" control_name="UseExternalBrowser" follows="bottom|left" height="20" | 32 | <check_box bottom="5" control_name="UseExternalBrowser" follows="bottom|left" height="20" |
33 | label="Always open in my web browser" left_delta="190" name="open_always" | 33 | label="Always open in my web browser" left_delta="184" name="open_always" |
34 | width="200" /> | 34 | width="200" /> |
35 | <button bottom="5" enabled="false" follows="bottom|right" height="20" label="Set Home To Here" | 35 | <button bottom="5" enabled="false" follows="bottom|right" height="20" label="Set As Home" |
36 | left="-265" name="set_home" width="155" /> | 36 | left="-176" name="set_home" width="104" /> |
37 | <button bottom="5" follows="bottom|right" height="20" label="Close" left="-70" | 37 | <button bottom="5" follows="bottom|right" height="20" label="Close" left="-70" |
38 | name="close" width="70" /> | 38 | name="close" width="70" /> |
39 | </layout_panel> | 39 | </layout_panel> |
diff --git a/linden/indra/newview/skins/default/xui/en-us/strings.xml b/linden/indra/newview/skins/default/xui/en-us/strings.xml index ecacc78..5808e71 100644 --- a/linden/indra/newview/skins/default/xui/en-us/strings.xml +++ b/linden/indra/newview/skins/default/xui/en-us/strings.xml | |||
@@ -178,6 +178,7 @@ | |||
178 | 178 | ||
179 | <!-- System messages --> | 179 | <!-- System messages --> |
180 | <string name="landmark_created">You created a landmark at</string> | 180 | <string name="landmark_created">You created a landmark at</string> |
181 | <string name="new_home_page">Your new Home Page is</string> | ||
181 | 182 | ||
182 | </strings> | 183 | </strings> |
183 | 184 | ||
diff --git a/linden/indra/newview/skins/default/xui/es/floater_html.xml b/linden/indra/newview/skins/default/xui/es/floater_html.xml deleted file mode 100644 index 9985276..0000000 --- a/linden/indra/newview/skins/default/xui/es/floater_html.xml +++ /dev/null | |||
@@ -1,12 +0,0 @@ | |||
1 | <?xml version="1.0" encoding="utf-8" standalone="yes" ?> | ||
2 | <floater name="htmlfloater" title=""> | ||
3 | <button label="Volver" name="back_btn" /> | ||
4 | <button label="Avanzar" name="forward_btn" /> | ||
5 | <button label="Recargar" name="reload_btn" /> | ||
6 | <button label="Parar" name="stop_btn" /> | ||
7 | <button label="Casa" name="home_btn" /> | ||
8 | <button label="Ir" name="go_btn" /> | ||
9 | <string name="support_page_url"> | ||
10 | http://secondlife.com/app/support/index_es.html | ||
11 | </string> | ||
12 | </floater> | ||
diff --git a/linden/indra/newview/skins/default/xui/fr/floater_html.xml b/linden/indra/newview/skins/default/xui/fr/floater_html.xml deleted file mode 100644 index 9504040..0000000 --- a/linden/indra/newview/skins/default/xui/fr/floater_html.xml +++ /dev/null | |||
@@ -1,16 +0,0 @@ | |||
1 | <?xml version="1.0" encoding="utf-8" standalone="yes" ?> | ||
2 | <floater name="htmlfloater" title=""> | ||
3 | <button label="Fermer" name="close_btn" /> | ||
4 | <button label="Précédente" name="back_btn" /> | ||
5 | <button label="Suivante" name="forward_btn" /> | ||
6 | <button label="Recharger" name="reload_btn" /> | ||
7 | <button label="Arrêter" name="stop_btn" /> | ||
8 | <button label="Domicile" name="home_btn" /> | ||
9 | <button label="Aller" name="go_btn" /> | ||
10 | <string name="home_page_url"> | ||
11 | http://www.secondlife.com | ||
12 | </string> | ||
13 | <string name="support_page_url"> | ||
14 | http://support.secondlife.com | ||
15 | </string> | ||
16 | </floater> | ||
diff --git a/linden/indra/newview/skins/default/xui/ja/floater_html.xml b/linden/indra/newview/skins/default/xui/ja/floater_html.xml deleted file mode 100644 index da63fab..0000000 --- a/linden/indra/newview/skins/default/xui/ja/floater_html.xml +++ /dev/null | |||
@@ -1,14 +0,0 @@ | |||
1 | <?xml version="1.0" encoding="utf-8" standalone="yes" ?> | ||
2 | <floater name="htmlfloater" title=""> | ||
3 | <button label="閉じる" name="close_btn" /> | ||
4 | <button label="戻る" name="back_btn" /> | ||
5 | <button label="ホーム" name="home_btn" /> | ||
6 | <button label="進む" name="forward_btn" /> | ||
7 | <button label="移動" name="go_btn" /> | ||
8 | <string name="home_page_url"> | ||
9 | http://jp.secondlife.com | ||
10 | </string> | ||
11 | <string name="support_page_url"> | ||
12 | http://help.secondlife.com/jp | ||
13 | </string> | ||
14 | </floater> | ||
diff --git a/linden/indra/newview/skins/default/xui/ko/floater_html.xml b/linden/indra/newview/skins/default/xui/ko/floater_html.xml deleted file mode 100644 index c4c2055..0000000 --- a/linden/indra/newview/skins/default/xui/ko/floater_html.xml +++ /dev/null | |||
@@ -1,14 +0,0 @@ | |||
1 | <?xml version="1.0" encoding="utf-8" standalone="yes" ?> | ||
2 | <floater name="htmlfloater" title=""> | ||
3 | <button label="닫기" name="close_btn" /> | ||
4 | <button label="뒤로" name="back_btn" /> | ||
5 | <button label="홈" name="home_btn" /> | ||
6 | <button label="앞으로" name="forward_btn" /> | ||
7 | <button label="이동" name="go_btn" /> | ||
8 | <string name="home_page_url"> | ||
9 | http://kr.secondlife.com | ||
10 | </string> | ||
11 | <string name="support_page_url"> | ||
12 | http://help.secondlife.com/kr | ||
13 | </string> | ||
14 | </floater> | ||
diff --git a/linden/indra/newview/skins/default/xui/pt/floater_html.xml b/linden/indra/newview/skins/default/xui/pt/floater_html.xml deleted file mode 100644 index b64cb2d..0000000 --- a/linden/indra/newview/skins/default/xui/pt/floater_html.xml +++ /dev/null | |||
@@ -1,12 +0,0 @@ | |||
1 | <?xml version="1.0" encoding="utf-8" standalone="yes" ?> | ||
2 | <floater name="htmlfloater" title=""> | ||
3 | <text name="f1_help_title"> | ||
4 | Second Life Help | ||
5 | </text> | ||
6 | <text name="f1_help_url"> | ||
7 | http://secondlife.com/app/support/index_pt.html | ||
8 | </text> | ||
9 | <string name="support_page_url"> | ||
10 | http://secondlife.com/app/support/index_pt.html | ||
11 | </string> | ||
12 | </floater> | ||
diff --git a/linden/indra/newview/skins/default/xui/zh/floater_html.xml b/linden/indra/newview/skins/default/xui/zh/floater_html.xml deleted file mode 100644 index 8c75fa7..0000000 --- a/linden/indra/newview/skins/default/xui/zh/floater_html.xml +++ /dev/null | |||
@@ -1,12 +0,0 @@ | |||
1 | <?xml version="1.0" encoding="utf-8" standalone="yes" ?> | ||
2 | <floater name="htmlfloater" title=""> | ||
3 | <button label="返回" name="back_btn" /> | ||
4 | <button label="朝向" name="forward_btn" /> | ||
5 | <button label="重载入" name="reload_btn" /> | ||
6 | <button label="停止" name="stop_btn" /> | ||
7 | <button label="家" name="home_btn" /> | ||
8 | <button label="行动" name="go_btn" /> | ||
9 | <string name="support_page_url"> | ||
10 | http://secondlife.com/app/support/index_zh.html | ||
11 | </string> | ||
12 | </floater> | ||