diff options
author | McCabe Maxsted | 2011-05-03 18:09:28 -0700 |
---|---|---|
committer | McCabe Maxsted | 2011-05-04 15:21:09 -0700 |
commit | cc8e7060dfb54900f1600965a78c6f6f9fc564c4 (patch) | |
tree | 9b23e53ace5696db2c78867582308f38cba19d71 /linden/indra/newview/llprefscolors.cpp | |
parent | Backported crash fix in llhudeffectlookat from gpl'd viewer 2 (diff) | |
download | meta-impy-cc8e7060dfb54900f1600965a78c6f6f9fc564c4.zip meta-impy-cc8e7060dfb54900f1600965a78c6f6f9fc564c4.tar.gz meta-impy-cc8e7060dfb54900f1600965a78c6f6f9fc564c4.tar.bz2 meta-impy-cc8e7060dfb54900f1600965a78c6f6f9fc564c4.tar.xz |
Besides the numerous label and organizational changes, here are the main points
* Moved numerous options out of the Advanced panel
* Moved numerous options out of the General panel
* Combined the Network and Web Browser panels
* Combined IM, Chat, and Spell checking preferences
* Combined 'Show timestamps in IMs' and 'Show timestamps in Local Chat' to one ShowTimestamps setting
* Removed UI for 'hide my own group title'. This can still be set in the debug settings
* Renamed Popups > Notifications
* Renamed Chat Colors > Colors
* Renamed 'IMs and Logging' to 'Logging and Privacy'
* Moved Colors next to Skins
* Added style guide to the top of every preferences panel xui
Diffstat (limited to 'linden/indra/newview/llprefscolors.cpp')
-rw-r--r-- | linden/indra/newview/llprefscolors.cpp | 30 |
1 files changed, 27 insertions, 3 deletions
diff --git a/linden/indra/newview/llprefscolors.cpp b/linden/indra/newview/llprefscolors.cpp index b0bc345..0b4caf5 100644 --- a/linden/indra/newview/llprefscolors.cpp +++ b/linden/indra/newview/llprefscolors.cpp | |||
@@ -80,6 +80,12 @@ BOOL LLPrefsColors::postBuild() | |||
80 | childSetCommitCallback("HighlightOwnNameInChat", onCommitCheckSelfName, this); | 80 | childSetCommitCallback("HighlightOwnNameInChat", onCommitCheckSelfName, this); |
81 | childSetCommitCallback("HighlightFriendsChat", onCommitCheckFriends, this); | 81 | childSetCommitCallback("HighlightFriendsChat", onCommitCheckFriends, this); |
82 | 82 | ||
83 | getChild<LLColorSwatchCtrl>("effect_color_swatch")->set(gSavedSettings.getColor4("EffectColor")); | ||
84 | |||
85 | getChild<LLColorSwatchCtrl>("client_tag_color")->set(gSavedSettings.getColor4("ImprudenceTagColor")); | ||
86 | static BOOL* sShowClientColor = rebind_llcontrol<BOOL>("ShowClientColor", &gSavedSettings, true); | ||
87 | childSetValue("client_name_color_check", (*sShowClientColor)); | ||
88 | |||
83 | return TRUE; | 89 | return TRUE; |
84 | } | 90 | } |
85 | 91 | ||
@@ -96,6 +102,8 @@ void LLPrefsColors::refreshColors() | |||
96 | mHTMLLinkColor = gSavedSettings.getColor4("HTMLLinkColor"); | 102 | mHTMLLinkColor = gSavedSettings.getColor4("HTMLLinkColor"); |
97 | mFriendsChatColor = gSavedSettings.getColor4("FriendsChatColor"); | 103 | mFriendsChatColor = gSavedSettings.getColor4("FriendsChatColor"); |
98 | mOwnNameChatColor = gSavedSettings.getColor4("OwnNameChatColor"); | 104 | mOwnNameChatColor = gSavedSettings.getColor4("OwnNameChatColor"); |
105 | mEffectColor = gSavedSettings.getColor4("EffectColor"); | ||
106 | mClientTagColor = gSavedSettings.getColor4("ImprudenceTagColor"); | ||
99 | } | 107 | } |
100 | 108 | ||
101 | // static | 109 | // static |
@@ -113,9 +121,6 @@ void LLPrefsColors::updateSelfCheck() | |||
113 | childSetEnabled("nick01", highlight_names_enabled); | 121 | childSetEnabled("nick01", highlight_names_enabled); |
114 | childSetEnabled("nick02", highlight_names_enabled); | 122 | childSetEnabled("nick02", highlight_names_enabled); |
115 | childSetEnabled("nick03", highlight_names_enabled); | 123 | childSetEnabled("nick03", highlight_names_enabled); |
116 | childSetEnabled("nick01_text", highlight_names_enabled); | ||
117 | childSetEnabled("nick02_text", highlight_names_enabled); | ||
118 | childSetEnabled("nick03_text", highlight_names_enabled); | ||
119 | } | 124 | } |
120 | 125 | ||
121 | // static | 126 | // static |
@@ -130,6 +135,18 @@ void LLPrefsColors::updateFriendsCheck() | |||
130 | getChild<LLColorSwatchCtrl>("FriendsChatColor")->setEnabled(childGetValue("HighlightFriendsChat")); | 135 | getChild<LLColorSwatchCtrl>("FriendsChatColor")->setEnabled(childGetValue("HighlightFriendsChat")); |
131 | } | 136 | } |
132 | 137 | ||
138 | // static | ||
139 | void LLPrefsColors::onCommitCheckClient(LLUICtrl* ctrl, void* userdata) | ||
140 | { | ||
141 | LLPrefsColors* self = (LLPrefsColors*)userdata; | ||
142 | self->updateClientCheck(); | ||
143 | } | ||
144 | |||
145 | void LLPrefsColors::updateClientCheck() | ||
146 | { | ||
147 | getChild<LLColorSwatchCtrl>("client_tag_color")->setEnabled(childGetValue("client_name_color_checkt")); | ||
148 | } | ||
149 | |||
133 | void LLPrefsColors::cancel() | 150 | void LLPrefsColors::cancel() |
134 | { | 151 | { |
135 | gSavedSettings.setColor4("SystemChatColor", mSystemChatColor); | 152 | gSavedSettings.setColor4("SystemChatColor", mSystemChatColor); |
@@ -143,6 +160,8 @@ void LLPrefsColors::cancel() | |||
143 | gSavedSettings.setColor4("HTMLLinkColor", mHTMLLinkColor); | 160 | gSavedSettings.setColor4("HTMLLinkColor", mHTMLLinkColor); |
144 | gSavedSettings.setColor4("FriendsChatColor", mFriendsChatColor); | 161 | gSavedSettings.setColor4("FriendsChatColor", mFriendsChatColor); |
145 | gSavedSettings.setColor4("OwnNameChatColor", mOwnNameChatColor); | 162 | gSavedSettings.setColor4("OwnNameChatColor", mOwnNameChatColor); |
163 | gSavedSettings.setColor4("EffectColor", mEffectColor); | ||
164 | gSavedSettings.setColor4("ImprudenceTagColor", mClientTagColor); | ||
146 | } | 165 | } |
147 | 166 | ||
148 | void LLPrefsColors::apply() | 167 | void LLPrefsColors::apply() |
@@ -177,5 +196,10 @@ void LLPrefsColors::apply() | |||
177 | boost::trim(nick03); | 196 | boost::trim(nick03); |
178 | gSavedSettings.setString("HighlightNickname03", nick03); | 197 | gSavedSettings.setString("HighlightNickname03", nick03); |
179 | 198 | ||
199 | gSavedSettings.setColor4("EffectColor", childGetValue("effect_color_swatch")); | ||
200 | |||
201 | gSavedSettings.setBOOL("ShowClientColor", childGetValue("client_name_color_check")); | ||
202 | gSavedSettings.setColor4("ImprudenceTagColor", getChild<LLColorSwatchCtrl>("client_tag_color")->get()); | ||
203 | |||
180 | refreshColors(); // member values become the official values and cancel becomes a no-op. | 204 | refreshColors(); // member values become the official values and cancel becomes a no-op. |
181 | } | 205 | } |