From 3b7c0d52d92f3e1acde70de525abb2781e2006ee Mon Sep 17 00:00:00 2001 From: Kitty Barnett Date: Fri, 17 Jun 2011 00:31:57 +0200 Subject: [PATCH] - changed : removed the custom LLTabContainer drag-and-hold code in LLPanelMainInventory -> note: this code will change the auto-scroll rectangle for the active inventory panel as a side-effect --- indra/llui/lltabcontainer.h | 2 +- indra/newview/llpanelmaininventory.cpp | 23 +++++++++++++++-------- 2 files changed, 16 insertions(+), 9 deletions(-) diff --git a/indra/llui/lltabcontainer.h b/indra/llui/lltabcontainer.h index 6bd2e19bfc..9d3e39d041 100644 --- a/indra/llui/lltabcontainer.h +++ b/indra/llui/lltabcontainer.h @@ -208,7 +208,7 @@ public: S32 getMinTabWidth() const { return mMinTabWidth; } S32 getMaxTabWidth() const { return mMaxTabWidth; } - void startDragAndDropDelayTimer() { mDragAndDropDelayTimer.start(); } +// void startDragAndDropDelayTimer() { mDragAndDropDelayTimer.start(); } void onTabBtn( const LLSD& data, LLPanel* panel ); void onNextBtn(const LLSD& data); diff --git a/indra/newview/llpanelmaininventory.cpp b/indra/newview/llpanelmaininventory.cpp index 8938448217..f5ec22e185 100644 --- a/indra/newview/llpanelmaininventory.cpp +++ b/indra/newview/llpanelmaininventory.cpp @@ -543,16 +543,23 @@ BOOL LLPanelMainInventory::handleDragAndDrop(S32 x, S32 y, MASK mask, BOOL drop, std::string& tooltip_msg) { // Check to see if we are auto scrolling from the last frame - LLInventoryPanel* panel = (LLInventoryPanel*)this->getActivePanel(); - BOOL needsToScroll = panel->getScrollableContainer()->autoScroll(x, y); - if(mFilterTabs) +// LLInventoryPanel* panel = (LLInventoryPanel*)this->getActivePanel(); +// BOOL needsToScroll = panel->getScrollableContainer()->autoScroll(x, y); +// if(mFilterTabs) +// { +// if(needsToScroll) +// { +// mFilterTabs->startDragAndDropDelayTimer(); +// } +// } +// [SL:KB] - Checked: UI-TabDndButtonCommit | Checked: 2011-06-16 (Catznip-2.6.0c) | Added: Catznip-2.6.0c + LLInventoryPanel* pInvPanel = getActivePanel(); + if ( (pInvPanel) && (pInvPanel->pointInView(x - pInvPanel->getRect().mLeft, y - pInvPanel->getRect().mBottom)) ) { - if(needsToScroll) - { - mFilterTabs->startDragAndDropDelayTimer(); - } + pInvPanel->getScrollableContainer()->autoScroll(x, y); } - +// [/SL:KB] + BOOL handled = LLPanel::handleDragAndDrop(x, y, mask, drop, cargo_type, cargo_data, accept, tooltip_msg); return handled;