aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/newview/floatergridmanager.cpp
diff options
context:
space:
mode:
authorMcCabe Maxsted2010-08-11 05:57:33 -0700
committerMcCabe Maxsted2010-08-26 11:19:26 -0700
commit54607d12837acac1b88cc3602e041362340796f8 (patch)
treeb814b112af2e7ab6b0333a8002b377fd31f11e31 /linden/indra/newview/floatergridmanager.cpp
parentApplied patch by Altair Memo for VWR-19947: Nvidia gpu_table.txt updated (diff)
downloadmeta-impy-54607d12837acac1b88cc3602e041362340796f8.zip
meta-impy-54607d12837acac1b88cc3602e041362340796f8.tar.gz
meta-impy-54607d12837acac1b88cc3602e041362340796f8.tar.bz2
meta-impy-54607d12837acac1b88cc3602e041362340796f8.tar.xz
Re-enabled search url fetching in the grid manager and fixed up web search to support them (fetched urls are equivalent to SearchURLDefault and searches follow the SL web search formatting)
Diffstat (limited to '')
-rw-r--r--linden/indra/newview/floatergridmanager.cpp81
1 files changed, 43 insertions, 38 deletions
diff --git a/linden/indra/newview/floatergridmanager.cpp b/linden/indra/newview/floatergridmanager.cpp
index 1ca7ae3..3d4b17f 100644
--- a/linden/indra/newview/floatergridmanager.cpp
+++ b/linden/indra/newview/floatergridmanager.cpp
@@ -94,7 +94,7 @@ void FloaterGridManager::clearInfo()
94 //getChild<LLLineEditor>("first_name")->clear(); 94 //getChild<LLLineEditor>("first_name")->clear();
95 //getChild<LLLineEditor>("last_name")->clear(); 95 //getChild<LLLineEditor>("last_name")->clear();
96 //getChild<LLLineEditor>("avatar_password")->clear(); 96 //getChild<LLLineEditor>("avatar_password")->clear();
97 //getChild<LLLineEditor>("search")->clear(); 97 getChild<LLLineEditor>("search")->clear();
98 //getChild<LLButton>("btn_delete"); 98 //getChild<LLButton>("btn_delete");
99 //getChild<LLButton>("btn_add") 99 //getChild<LLButton>("btn_add")
100 //getChild<LLButton>("btn_copy"); 100 //getChild<LLButton>("btn_copy");
@@ -129,7 +129,7 @@ void FloaterGridManager::refresh()
129 //getChild<LLLineEditor>("first_name")->setEnabled(can_edit); 129 //getChild<LLLineEditor>("first_name")->setEnabled(can_edit);
130 //getChild<LLLineEditor>("last_name")->setEnabled(can_edit); 130 //getChild<LLLineEditor>("last_name")->setEnabled(can_edit);
131 //getChild<LLLineEditor>("avatar_password")->setEnabled(can_edit); 131 //getChild<LLLineEditor>("avatar_password")->setEnabled(can_edit);
132 //getChild<LLLineEditor>("search")->setEnabled(can_edit); 132 getChild<LLLineEditor>("search")->setEnabled(can_edit);
133 getChild<LLButton>("btn_delete")->setEnabled(can_edit); 133 getChild<LLButton>("btn_delete")->setEnabled(can_edit);
134 //getChild<LLButton>("btn_add") 134 //getChild<LLButton>("btn_add")
135 //getChild<LLButton>("btn_copy")->setEnabled(can_edit); 135 //getChild<LLButton>("btn_copy")->setEnabled(can_edit);
@@ -234,52 +234,57 @@ void FloaterGridManager::refreshGrids()
234 // else if(gridInfo->getPasswordUrl().empty()) 234 // else if(gridInfo->getPasswordUrl().empty())
235 // FloaterGridManager::getInstance()->childSetText("avatar_password", std::string("")); 235 // FloaterGridManager::getInstance()->childSetText("avatar_password", std::string(""));
236 236
237 // if (gridInfo->getPlatform() == HippoGridInfo::PLATFORM_SECONDLIFE) { 237 if (gridInfo->getPlatform() == HippoGridInfo::PLATFORM_SECONDLIFE)
238 // //childSetEnabled("search", false); 238 {
239 // //childSetText("search", LLStringExplicit("")); 239 FloaterGridManager::getInstance()->childSetEnabled("search", false);
240 // childSetEnabled("render_compat", false); 240 FloaterGridManager::getInstance()->childSetText("search", LLStringUtil::null);
241 // childSetValue("render_compat", false); 241 //childSetEnabled("render_compat", false);
242 // } else { 242 //childSetValue("render_compat", false);
243 // //childSetEnabled("search", true); 243 }
244 // //childSetText("search", gridInfo->getSearchUrl()); 244 else
245 // childSetEnabled("render_compat", true); 245 {
246 // childSetValue("render_compat", gridInfo->isRenderCompat()); 246 FloaterGridManager::getInstance()->childSetEnabled("search", true);
247 // } 247 FloaterGridManager::getInstance()->childSetText("search", gridInfo->getSearchUrl());
248 //childSetEnabled("render_compat", true);
249 //childSetValue("render_compat", gridInfo->isRenderCompat());
250 }
248 251
249 } 252 }
250 else 253 else
251 { 254 {
252 std::string empty = ""; 255 FloaterGridManager::getInstance()->childSetText("gridnick", LLStringUtil::null);
253 FloaterGridManager::getInstance()->childSetText("gridnick", empty); 256 FloaterGridManager::getInstance()->childSetText("gridname", LLStringUtil::null);
254 FloaterGridManager::getInstance()->childSetText("gridname", empty); 257 FloaterGridManager::getInstance()->childSetText("loginuri", LLStringUtil::null);
255 FloaterGridManager::getInstance()->childSetText("loginuri", empty); 258 FloaterGridManager::getInstance()->childSetText("loginpage", LLStringUtil::null);
256 FloaterGridManager::getInstance()->childSetText("loginpage", empty); 259 FloaterGridManager::getInstance()->childSetText("helperuri", LLStringUtil::null);
257 FloaterGridManager::getInstance()->childSetText("helperuri", empty); 260 FloaterGridManager::getInstance()->childSetText("website", LLStringUtil::null);
258 FloaterGridManager::getInstance()->childSetText("website", empty); 261 FloaterGridManager::getInstance()->childSetText("support", LLStringUtil::null);
259 // FloaterGridManager::getInstance()->childSetText("first_name", empty); 262 FloaterGridManager::getInstance()->childSetText("register", LLStringUtil::null);
260 // FloaterGridManager::getInstance()->childSetText("last_name", empty); 263 FloaterGridManager::getInstance()->childSetText("password", LLStringUtil::null);
261 // FloaterGridManager::getInstance()->childSetText("avatar_password", empty); 264 // FloaterGridManager::getInstance()->childSetText("first_name", LLStringUtil::null);
265 // FloaterGridManager::getInstance()->childSetText("last_name", LLStringUtil::null);
266 // FloaterGridManager::getInstance()->childSetText("avatar_password", LLStringUtil::null);
267 FloaterGridManager::getInstance()->childSetText("search", LLStringUtil::null);
262 } 268 }
263 } 269 }
264 else if (FloaterGridManager::getInstance()->getState() == ADD_NEW) 270 else if (FloaterGridManager::getInstance()->getState() == ADD_NEW)
265 { 271 {
266 llinfos << "mState == ADD_NEW" << llendl; 272 llinfos << "mState == ADD_NEW" << llendl;
267 std::string required = "<required>"; 273 std::string required = "<required>";
268 std::string empty = "";
269 FloaterGridManager::getInstance()->childSetText("gridnick", required); 274 FloaterGridManager::getInstance()->childSetText("gridnick", required);
270 FloaterGridManager::getInstance()->childSetText("gridname", empty); 275 FloaterGridManager::getInstance()->childSetText("gridname", LLStringUtil::null);
271 FloaterGridManager::getInstance()->childSetText("loginuri", required); 276 FloaterGridManager::getInstance()->childSetText("loginuri", required);
272 FloaterGridManager::getInstance()->childSetText("loginpage", empty); 277 FloaterGridManager::getInstance()->childSetText("loginpage", LLStringUtil::null);
273 FloaterGridManager::getInstance()->childSetText("helperuri", empty); 278 FloaterGridManager::getInstance()->childSetText("helperuri", LLStringUtil::null);
274 FloaterGridManager::getInstance()->childSetText("website", empty); 279 FloaterGridManager::getInstance()->childSetText("website", LLStringUtil::null);
275 FloaterGridManager::getInstance()->childSetText("support", empty); 280 FloaterGridManager::getInstance()->childSetText("support", LLStringUtil::null);
276 FloaterGridManager::getInstance()->childSetText("register", empty); 281 FloaterGridManager::getInstance()->childSetText("register", LLStringUtil::null);
277 FloaterGridManager::getInstance()->childSetText("password", empty); 282 FloaterGridManager::getInstance()->childSetText("password", LLStringUtil::null);
278 // FloaterGridManager::getInstance()->childSetText("first_name", empty); 283 // FloaterGridManager::getInstance()->childSetText("first_name", LLStringUtil::null);
279 // FloaterGridManager::getInstance()->childSetText("last_name", empty); 284 // FloaterGridManager::getInstance()->childSetText("last_name", LLStringUtil::null);
280 // FloaterGridManager::getInstance()->childSetText("avatar_password", empty); 285 // FloaterGridManager::getInstance()->childSetText("avatar_password", LLStringUtil::null);
281 //childSetEnabled("search", true); 286 //childSetEnabled("search", true);
282 //childSetText("search", empty); 287 FloaterGridManager::getInstance()->childSetText("search", LLStringUtil::null);
283 } 288 }
284 else if (FloaterGridManager::getInstance()->getState() == ADD_COPY) 289 else if (FloaterGridManager::getInstance()->getState() == ADD_COPY)
285 { 290 {
@@ -316,7 +321,7 @@ void FloaterGridManager::applyChanges()
316 gridInfo->setSupportUrl(childGetValue("support")); 321 gridInfo->setSupportUrl(childGetValue("support"));
317 gridInfo->setRegisterUrl(childGetValue("register")); 322 gridInfo->setRegisterUrl(childGetValue("register"));
318 gridInfo->setPasswordUrl(childGetValue("password")); 323 gridInfo->setPasswordUrl(childGetValue("password"));
319 //gridInfo->setSearchUrl(childGetValue("search")); 324 gridInfo->setSearchUrl(childGetValue("search"));
320 gridInfo->setRenderCompat(childGetValue("render_compat")); 325 gridInfo->setRenderCompat(childGetValue("render_compat"));
321 326
322 // gridInfo->setFirstName(childGetValue("first_name")); 327 // gridInfo->setFirstName(childGetValue("first_name"));
@@ -387,7 +392,7 @@ bool FloaterGridManager::createNewGrid()
387 grid->setSupportUrl(childGetValue("support")); 392 grid->setSupportUrl(childGetValue("support"));
388 grid->setRegisterUrl(childGetValue("register")); 393 grid->setRegisterUrl(childGetValue("register"));
389 grid->setPasswordUrl(childGetValue("password")); 394 grid->setPasswordUrl(childGetValue("password"));
390 //grid->setSearchUrl(childGetValue("search")); 395 grid->setSearchUrl(childGetValue("search"));
391 grid->setRenderCompat(childGetValue("render_compat")); 396 grid->setRenderCompat(childGetValue("render_compat"));
392 gHippoGridManager->addGrid(grid); 397 gHippoGridManager->addGrid(grid);
393 398
@@ -450,7 +455,7 @@ void FloaterGridManager::retrieveGridInfo()
450 if (grid->getSupportUrl() != "") childSetText("support", grid->getSupportUrl()); 455 if (grid->getSupportUrl() != "") childSetText("support", grid->getSupportUrl());
451 if (grid->getRegisterUrl() != "") childSetText("register", grid->getRegisterUrl()); 456 if (grid->getRegisterUrl() != "") childSetText("register", grid->getRegisterUrl());
452 if (grid->getPasswordUrl() != "") childSetText("password", grid->getPasswordUrl()); 457 if (grid->getPasswordUrl() != "") childSetText("password", grid->getPasswordUrl());
453 //if (grid->getSearchUrl() != "") childSetText("search", grid->getSearchUrl()); 458 if (grid->getSearchUrl() != "") childSetText("search", grid->getSearchUrl());
454 } 459 }
455 else 460 else
456 { 461 {