From a9b829f371183de408745d27c3fbabf9d4624ea2 Mon Sep 17 00:00:00 2001 From: Dmitry Zaporozhan Date: Thu, 4 Mar 2010 16:55:00 +0200 Subject: Fixed low bug EXT-5998 - Classified is scrolled if previos classified was scrolled. --HG-- branch : product-engine --- indra/newview/llpanelclassified.cpp | 10 ++++++++++ indra/newview/llpanelclassified.h | 2 ++ 2 files changed, 12 insertions(+) (limited to 'indra/newview') diff --git a/indra/newview/llpanelclassified.cpp b/indra/newview/llpanelclassified.cpp index 0bbd850eda..d59a7d752e 100644 --- a/indra/newview/llpanelclassified.cpp +++ b/indra/newview/llpanelclassified.cpp @@ -1252,6 +1252,7 @@ void LLPanelClassifiedInfo::onOpen(const LLSD& key) resetData(); resetControls(); + scrollToTop(); setClassifiedId(key["classified_id"]); setClassifiedName(key["name"]); @@ -1517,6 +1518,13 @@ LLRect LLPanelClassifiedInfo::getDefaultSnapshotRect() return getChild("snapshot_panel")->getLocalRect(); } +void LLPanelClassifiedInfo::scrollToTop() +{ + LLScrollContainer* scrollContainer = findChild("profile_scroll"); + if (scrollContainer) + scrollContainer->goToTop(); +} + void LLPanelClassifiedInfo::onMapClick() { LLFloaterWorldMap::getInstance()->trackLocation(getPosGlobal()); @@ -1612,6 +1620,8 @@ void LLPanelClassifiedEdit::onOpen(const LLSD& key) mIsNew = classified_id.isNull(); + scrollToTop(); + if(mIsNew) { setAvatarId(gAgent.getID()); diff --git a/indra/newview/llpanelclassified.h b/indra/newview/llpanelclassified.h index 1b5b5e54d8..78f095a9bb 100644 --- a/indra/newview/llpanelclassified.h +++ b/indra/newview/llpanelclassified.h @@ -299,6 +299,8 @@ protected: LLRect getDefaultSnapshotRect(); + void scrollToTop(); + void onMapClick(); void onTeleportClick(); void onExit(); -- cgit v1.2.3