summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitry Zaporozhan <dzaporozhan@productengine.com>2010-03-04 16:55:00 +0200
committerDmitry Zaporozhan <dzaporozhan@productengine.com>2010-03-04 16:55:00 +0200
commita9b829f371183de408745d27c3fbabf9d4624ea2 (patch)
treedaa9b80628dbaae2f4fb150c72c8c3a6513f1a72
parent997e91f08e9b6afd5bb3335da235e6ea9e9c0761 (diff)
Fixed low bug EXT-5998 - Classified is scrolled if previos classified was scrolled.
--HG-- branch : product-engine
-rw-r--r--indra/newview/llpanelclassified.cpp10
-rw-r--r--indra/newview/llpanelclassified.h2
2 files changed, 12 insertions, 0 deletions
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<LLUICtrl>("snapshot_panel")->getLocalRect();
}
+void LLPanelClassifiedInfo::scrollToTop()
+{
+ LLScrollContainer* scrollContainer = findChild<LLScrollContainer>("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();