summaryrefslogtreecommitdiff
path: root/indra/newview/llviewerwindow.cpp
diff options
context:
space:
mode:
authorRoxie Linden <roxie@lindenlab.com>2010-04-02 02:03:21 -0700
committerRoxie Linden <roxie@lindenlab.com>2010-04-02 02:03:21 -0700
commit9523c70f9dd3b2db21f6578bbb2b1da6873004ea (patch)
treefe3f862878af5793aeec797d63c1d7c114d3c68d /indra/newview/llviewerwindow.cpp
parent18d9efff12ef8b59c648a801fe2c5c7e0bc8fde4 (diff)
parentaa0a129b6798f8be554d1d9d41cbd217a0040daf (diff)
DEV-45809 - Merge Second Life Enterprise changes into viewer 2.x trunk
Includes: DEV-45800, DEV-45803 - Grid Manager DEV-45804 - SLURL refactor DEV-45801 - Single username field (for Identity Evolution and SLE Ldap) Also, Includes Certificate Management code allowing the viewer to connect to grids not signed by a well know key (just like any web browser). Also contains secure storage for things like passwords. The security/certificate code is modular with the intention of adding modules to directly use the operating system facilities for crypto if available. (that's much more secure than we'll ever be) Also, refactor of voice to modularize it, and add a diamondware voice module. CR: Aimee, James, Lynx, Mani, Karina and a list of thousands
Diffstat (limited to 'indra/newview/llviewerwindow.cpp')
-rw-r--r--indra/newview/llviewerwindow.cpp33
1 files changed, 13 insertions, 20 deletions
diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp
index ae3f680cbf..4c6a02db87 100644
--- a/indra/newview/llviewerwindow.cpp
+++ b/indra/newview/llviewerwindow.cpp
@@ -85,7 +85,6 @@
#include "lltooltip.h"
#include "llmediaentry.h"
#include "llurldispatcher.h"
-#include "llurlsimstring.h"
// newview includes
#include "llagent.h"
@@ -799,7 +798,7 @@ BOOL LLViewerWindow::handleRightMouseUp(LLWindow *window, LLCoordGL pos, MASK m
BOOL LLViewerWindow::handleMiddleMouseDown(LLWindow *window, LLCoordGL pos, MASK mask)
{
BOOL down = TRUE;
- gVoiceClient->middleMouseState(true);
+ LLVoiceClient::getInstance()->middleMouseState(true);
handleAnyMouseClick(window,pos,mask,LLMouseHandler::CLICK_MIDDLE,down);
// Always handled as far as the OS is concerned.
@@ -826,20 +825,15 @@ LLWindowCallbacks::DragNDropResult LLViewerWindow::handleDragNDrop( LLWindow *wi
if (slurl_dnd_enabled)
{
-
- // special case SLURLs
- // isValidSLURL() call was added here to make sure that dragged SLURL is valid (EXT-4964)
- if ( LLSLURL::isSLURL( data ) && LLSLURL::isValidSLURL( data ) )
+ LLSLURL dropped_slurl(data);
+ if(dropped_slurl.isSpatial())
{
if (drop)
{
- LLURLDispatcher::dispatch( data, NULL, true );
- LLURLSimString::setStringRaw( LLSLURL::stripProtocol( data ) );
- LLPanelLogin::refreshLocation( true );
- LLPanelLogin::updateLocationUI();
+ LLURLDispatcher::dispatch( dropped_slurl.getSLURLString(), NULL, true );
+ return LLWindowCallbacks::DND_MOVE;
}
- return LLWindowCallbacks::DND_MOVE;
- };
+ }
}
if (prim_media_dnd_enabled)
@@ -957,7 +951,7 @@ LLWindowCallbacks::DragNDropResult LLViewerWindow::handleDragNDrop( LLWindow *wi
BOOL LLViewerWindow::handleMiddleMouseUp(LLWindow *window, LLCoordGL pos, MASK mask)
{
BOOL down = FALSE;
- gVoiceClient->middleMouseState(false);
+ LLVoiceClient::getInstance()->middleMouseState(false);
handleAnyMouseClick(window,pos,mask,LLMouseHandler::CLICK_MIDDLE,down);
// Always handled as far as the OS is concerned.
@@ -1074,7 +1068,7 @@ void LLViewerWindow::handleFocusLost(LLWindow *window)
BOOL LLViewerWindow::handleTranslatedKeyDown(KEY key, MASK mask, BOOL repeated)
{
// Let the voice chat code check for its PTT key. Note that this never affects event processing.
- gVoiceClient->keyDown(key, mask);
+ LLVoiceClient::getInstance()->keyDown(key, mask);
if (gAwayTimer.getElapsedTimeF32() > MIN_AFK_TIME)
{
@@ -1096,7 +1090,7 @@ BOOL LLViewerWindow::handleTranslatedKeyDown(KEY key, MASK mask, BOOL repeated)
BOOL LLViewerWindow::handleTranslatedKeyUp(KEY key, MASK mask)
{
// Let the voice chat code check for its PTT key. Note that this never affects event processing.
- gVoiceClient->keyUp(key, mask);
+ LLVoiceClient::getInstance()->keyUp(key, mask);
return FALSE;
}
@@ -1955,7 +1949,7 @@ void LLViewerWindow::setNormalControlsVisible( BOOL visible )
// ...and set the menu color appropriately.
setMenuBackgroundColor(gAgent.getGodLevel() > GOD_NOT,
- LLViewerLogin::getInstance()->isInProductionGrid());
+ LLGridManager::getInstance()->isInProductionGrid());
}
if ( gStatusBar )
@@ -1976,15 +1970,15 @@ void LLViewerWindow::setMenuBackgroundColor(bool god_mode, bool dev_grid)
LLSD args;
LLColor4 new_bg_color;
- if(god_mode && LLViewerLogin::getInstance()->isInProductionGrid())
+ if(god_mode && LLGridManager::getInstance()->isInProductionGrid())
{
new_bg_color = LLUIColorTable::instance().getColor( "MenuBarGodBgColor" );
}
- else if(god_mode && !LLViewerLogin::getInstance()->isInProductionGrid())
+ else if(god_mode && !LLGridManager::getInstance()->isInProductionGrid())
{
new_bg_color = LLUIColorTable::instance().getColor( "MenuNonProductionGodBgColor" );
}
- else if(!god_mode && !LLViewerLogin::getInstance()->isInProductionGrid())
+ else if(!god_mode && !LLGridManager::getInstance()->isInProductionGrid())
{
new_bg_color = LLUIColorTable::instance().getColor( "MenuNonProductionBgColor" );
}
@@ -2200,7 +2194,6 @@ BOOL LLViewerWindow::handleKey(KEY key, MASK mask)
}
return TRUE;
}
-
// hidden edit menu for cut/copy/paste
if (gEditMenu && gEditMenu->handleAcceleratorKey(key, mask))
{