aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/llui/llmodaldialog.cpp
diff options
context:
space:
mode:
authorJacek Antonelli2008-08-15 23:44:54 -0500
committerJacek Antonelli2008-08-15 23:44:54 -0500
commitb2afb8800bb033a04bb3ecdf0363068d56648ef1 (patch)
tree3568129b5bbddb47cd39d622b4137a8fbff4abaf /linden/indra/llui/llmodaldialog.cpp
parentSecond Life viewer sources 1.14.0.1 (diff)
downloadmeta-impy-b2afb8800bb033a04bb3ecdf0363068d56648ef1.zip
meta-impy-b2afb8800bb033a04bb3ecdf0363068d56648ef1.tar.gz
meta-impy-b2afb8800bb033a04bb3ecdf0363068d56648ef1.tar.bz2
meta-impy-b2afb8800bb033a04bb3ecdf0363068d56648ef1.tar.xz
Second Life viewer sources 1.15.0.2
Diffstat (limited to 'linden/indra/llui/llmodaldialog.cpp')
-rw-r--r--linden/indra/llui/llmodaldialog.cpp21
1 files changed, 11 insertions, 10 deletions
diff --git a/linden/indra/llui/llmodaldialog.cpp b/linden/indra/llui/llmodaldialog.cpp
index c875e7c..788dead 100644
--- a/linden/indra/llui/llmodaldialog.cpp
+++ b/linden/indra/llui/llmodaldialog.cpp
@@ -4,6 +4,7 @@
4 * 4 *
5 * Copyright (c) 2002-2007, Linden Research, Inc. 5 * Copyright (c) 2002-2007, Linden Research, Inc.
6 * 6 *
7 * Second Life Viewer Source Code
7 * The source code in this file ("Source Code") is provided by Linden Lab 8 * The source code in this file ("Source Code") is provided by Linden Lab
8 * to you under the terms of the GNU General Public License, version 2.0 9 * to you under the terms of the GNU General Public License, version 2.0
9 * ("GPL"), unless you have obtained a separate licensing agreement 10 * ("GPL"), unless you have obtained a separate licensing agreement
@@ -84,8 +85,8 @@ void LLModalDialog::startModal()
84 } 85 }
85 86
86 // This is a modal dialog. It sucks up all mouse and keyboard operations. 87 // This is a modal dialog. It sucks up all mouse and keyboard operations.
87 gFocusMgr.setMouseCapture( this, NULL ); 88 gFocusMgr.setMouseCapture( this );
88 gFocusMgr.setTopView( this, NULL ); 89 gFocusMgr.setTopCtrl( this );
89 setFocus(TRUE); 90 setFocus(TRUE);
90 91
91 sModalStack.push_front( this ); 92 sModalStack.push_front( this );
@@ -126,10 +127,10 @@ void LLModalDialog::setVisible( BOOL visible )
126 if( visible ) 127 if( visible )
127 { 128 {
128 // This is a modal dialog. It sucks up all mouse and keyboard operations. 129 // This is a modal dialog. It sucks up all mouse and keyboard operations.
129 gFocusMgr.setMouseCapture( this, NULL ); 130 gFocusMgr.setMouseCapture( this );
130 131
131 // The dialog view is a root view 132 // The dialog view is a root view
132 gFocusMgr.setTopView( this, NULL ); 133 gFocusMgr.setTopCtrl( this );
133 setFocus( TRUE ); 134 setFocus( TRUE );
134 } 135 }
135 else 136 else
@@ -241,9 +242,9 @@ void LLModalDialog::draw()
241 if (mModal) 242 if (mModal)
242 { 243 {
243 // If we've lost focus to a non-child, get it back ASAP. 244 // If we've lost focus to a non-child, get it back ASAP.
244 if( gFocusMgr.getTopView() != this ) 245 if( gFocusMgr.getTopCtrl() != this )
245 { 246 {
246 gFocusMgr.setTopView( this, NULL); 247 gFocusMgr.setTopCtrl( this );
247 } 248 }
248 249
249 if( !gFocusMgr.childHasKeyboardFocus( this ) ) 250 if( !gFocusMgr.childHasKeyboardFocus( this ) )
@@ -253,7 +254,7 @@ void LLModalDialog::draw()
253 254
254 if( !gFocusMgr.childHasMouseCapture( this ) ) 255 if( !gFocusMgr.childHasMouseCapture( this ) )
255 { 256 {
256 gFocusMgr.setMouseCapture( this, NULL ); 257 gFocusMgr.setMouseCapture( this );
257 } 258 }
258 } 259 }
259 } 260 }
@@ -278,7 +279,7 @@ void LLModalDialog::onAppFocusLost()
278 LLModalDialog* instance = LLModalDialog::sModalStack.front(); 279 LLModalDialog* instance = LLModalDialog::sModalStack.front();
279 if( gFocusMgr.childHasMouseCapture( instance ) ) 280 if( gFocusMgr.childHasMouseCapture( instance ) )
280 { 281 {
281 gFocusMgr.setMouseCapture( NULL, NULL ); 282 gFocusMgr.setMouseCapture( NULL );
282 } 283 }
283 284
284 if( gFocusMgr.childHasKeyboardFocus( instance ) ) 285 if( gFocusMgr.childHasKeyboardFocus( instance ) )
@@ -296,9 +297,9 @@ void LLModalDialog::onAppFocusGained()
296 LLModalDialog* instance = LLModalDialog::sModalStack.front(); 297 LLModalDialog* instance = LLModalDialog::sModalStack.front();
297 298
298 // This is a modal dialog. It sucks up all mouse and keyboard operations. 299 // This is a modal dialog. It sucks up all mouse and keyboard operations.
299 gFocusMgr.setMouseCapture( instance, NULL ); 300 gFocusMgr.setMouseCapture( instance );
300 instance->setFocus(TRUE); 301 instance->setFocus(TRUE);
301 gFocusMgr.setTopView( instance, NULL ); 302 gFocusMgr.setTopCtrl( instance );
302 303
303 instance->centerOnScreen(); 304 instance->centerOnScreen();
304 } 305 }