diff options
| author | Nat Goodspeed <nat@lindenlab.com> | 2009-09-26 18:08:24 -0400 |
|---|---|---|
| committer | Nat Goodspeed <nat@lindenlab.com> | 2009-09-26 18:08:24 -0400 |
| commit | bc4444cd78067cbf11d3ffb210375a31a33f96bd (patch) | |
| tree | d9b8e78db237869e630fec6c71335d1294cec101 /indra/llui/lluictrl.cpp | |
| parent | 8ddc0c0ac43e9d10bf0262cd1ab3c0e79808fc14 (diff) | |
| parent | 09bf3c1fec107e9e66514837d208ef62a6b67b91 (diff) | |
Merge into viewer/viewer-20 yesterday's lindenlab/svn-imports-viewer-20
Diffstat (limited to 'indra/llui/lluictrl.cpp')
| -rw-r--r-- | indra/llui/lluictrl.cpp | 50 |
1 files changed, 0 insertions, 50 deletions
diff --git a/indra/llui/lluictrl.cpp b/indra/llui/lluictrl.cpp index 28cdb1ac27..8807e26f6b 100644 --- a/indra/llui/lluictrl.cpp +++ b/indra/llui/lluictrl.cpp @@ -506,56 +506,6 @@ void LLUICtrl::setFocus(BOOL b) } } -void LLUICtrl::onFocusReceived() -{ - // trigger callbacks - LLFocusableElement::onFocusReceived(); - - // find first view in hierarchy above new focus that is a LLUICtrl - LLView* viewp = getParent(); - LLUICtrl* last_focus = dynamic_cast<LLUICtrl*>(gFocusMgr.getLastKeyboardFocus()); - - while (viewp && !viewp->isCtrl()) - { - viewp = viewp->getParent(); - } - - // and if it has newly gained focus, call onFocusReceived() - LLUICtrl* ctrlp = static_cast<LLUICtrl*>(viewp); - if (ctrlp && (!last_focus || !last_focus->hasAncestor(ctrlp))) - { - ctrlp->onFocusReceived(); - } -} - -void LLUICtrl::onFocusLost() -{ - // trigger callbacks - LLFocusableElement::onFocusLost(); - - // find first view in hierarchy above old focus that is a LLUICtrl - LLView* viewp = getParent(); - while (viewp && !viewp->isCtrl()) - { - viewp = viewp->getParent(); - } - - // and if it has just lost focus, call onFocusReceived() - LLUICtrl* ctrlp = static_cast<LLUICtrl*>(viewp); - // hasFocus() includes any descendants - if (ctrlp && !ctrlp->hasFocus()) - { - ctrlp->onFocusLost(); - } -} - -void LLUICtrl::onTopLost() -{ - // trigger callbacks - LLFocusableElement::onTopLost(); -} - - // virtual void LLUICtrl::setTabStop( BOOL b ) { |
