diff options
author | Bryan O'Sullivan <bos@lindenlab.com> | 2009-06-22 15:02:19 -0700 |
---|---|---|
committer | Bryan O'Sullivan <bos@lindenlab.com> | 2009-06-22 15:02:19 -0700 |
commit | baa73fddd9287ddafd2d31551cb253b355ed910a (patch) | |
tree | e3f0986617fe6c0ee0a14df6aac13c6bb6f92507 /indra/newview/lltexturectrl.cpp | |
parent | dc3833f31b8a20220ddb1775e1625c016c397435 (diff) | |
parent | fcaa1ad46fd1df4cfec9dee12caf6e7b5bf32136 (diff) |
Merge with viewer-2.0.0-3 branch
Diffstat (limited to 'indra/newview/lltexturectrl.cpp')
-rw-r--r-- | indra/newview/lltexturectrl.cpp | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/indra/newview/lltexturectrl.cpp b/indra/newview/lltexturectrl.cpp index 7a06f0df9e..3c9290acea 100644 --- a/indra/newview/lltexturectrl.cpp +++ b/indra/newview/lltexturectrl.cpp @@ -351,7 +351,7 @@ BOOL LLFloaterTexturePicker::handleKeyHere(KEY key, MASK mask) root_folder->scrollToShowSelection(); // move focus to inventory proper - root_folder->setFocus(TRUE); + mInventoryPanel->setFocus(TRUE); // treat this as a user selection of the first filtered result commitIfImmediateSet(); @@ -359,7 +359,7 @@ BOOL LLFloaterTexturePicker::handleKeyHere(KEY key, MASK mask) return TRUE; } - if (root_folder->hasFocus() && key == KEY_UP) + if (mInventoryPanel->hasFocus() && key == KEY_UP) { mSearchEdit->focusFirstItem(TRUE); } @@ -858,7 +858,7 @@ void LLFloaterTexturePicker::onTextureSelect( const LLTextureEntry& te ) /////////////////////////////////////////////////////////////////////// // LLTextureCtrl -static LLRegisterWidget<LLTextureCtrl> r("texture_picker"); +static LLDefaultWidgetRegistry::Register<LLTextureCtrl> r("texture_picker"); LLTextureCtrl::LLTextureCtrl(const LLTextureCtrl::Params& p) : LLUICtrl(p), @@ -1001,6 +1001,9 @@ void LLTextureCtrl::setLabel(const std::string& label) void LLTextureCtrl::showPicker(BOOL take_focus) { + // show hourglass cursor when loading inventory window + // because inventory construction is slooow + getWindow()->setCursor(UI_CURSOR_WAIT); LLFloater* floaterp = mFloaterHandle.get(); // Show the dialog @@ -1020,7 +1023,9 @@ void LLTextureCtrl::showPicker(BOOL take_focus) mFloaterHandle = floaterp->getHandle(); - gFloaterView->getParentFloater(this)->addDependentFloater(floaterp); + LLFloater* root_floater = gFloaterView->getParentFloater(this); + if (root_floater) + root_floater->addDependentFloater(floaterp); floaterp->openFloater(); } |