From 55e52f363195ca7428a2b3773d8488d09e62b04d Mon Sep 17 00:00:00 2001
From: Sam Kolb <skolb@lindenlab.com>
Date: Tue, 11 Sep 2007 20:48:08 +0000
Subject: [PATCH] Merge sl-search-m0 back into release

---
 indra/newview/llfloaterland.cpp       |  3 ++-
 indra/newview/llfloaterland.h         |  2 +-
 indra/newview/llpanelgroupgeneral.cpp | 14 +++++++++--
 indra/newview/llpanelpermissions.cpp  | 35 ++++++++++++---------------
 indra/newview/llpanelpermissions.h    |  3 ---
 5 files changed, 30 insertions(+), 27 deletions(-)

diff --git a/indra/newview/llfloaterland.cpp b/indra/newview/llfloaterland.cpp
index aa9a06555cd..e0ceedf0f71 100644
--- a/indra/newview/llfloaterland.cpp
+++ b/indra/newview/llfloaterland.cpp
@@ -367,7 +367,8 @@ BOOL LLPanelLandGeneral::postBuild()
 	childSetUserData("Name", this);
 
 
-	mEditDesc = LLUICtrlFactory::getLineEditorByName(this, "Description");
+	mEditDesc = LLUICtrlFactory::getTextEditorByName(this, "Description");
+	mEditDesc->setCommitOnFocusLost(TRUE);
 	mEditDesc->setCommitCallback(onCommitAny);	
 	childSetPrevalidate("Description", LLLineEditor::prevalidatePrintableNotPipe);
 	childSetUserData("Description", this);
diff --git a/indra/newview/llfloaterland.h b/indra/newview/llfloaterland.h
index 6e8e525e0d0..ff9c10fab23 100644
--- a/indra/newview/llfloaterland.h
+++ b/indra/newview/llfloaterland.h
@@ -154,7 +154,7 @@ class LLPanelLandGeneral
 	LLTextBox*		mLabelName;
 	LLLineEditor*	mEditName;
 	LLTextBox*		mLabelDesc;
-	LLLineEditor*	mEditDesc;
+	LLTextEditor*	mEditDesc;
 
 	LLTextBox*		mTextSalePending;
 
diff --git a/indra/newview/llpanelgroupgeneral.cpp b/indra/newview/llpanelgroupgeneral.cpp
index ca62790147d..baeee12e7e5 100644
--- a/indra/newview/llpanelgroupgeneral.cpp
+++ b/indra/newview/llpanelgroupgeneral.cpp
@@ -480,7 +480,6 @@ bool LLPanelGroupGeneral::apply(LLString& mesg)
 		{
 			gGroupMgr->sendUpdateGroupInfo(mGroupID);
 		}
-		notifyObservers();
 	}
 
 	BOOL receive_notices = false;
@@ -491,7 +490,9 @@ bool LLPanelGroupGeneral::apply(LLString& mesg)
 		list_in_profile = mCtrlListGroup->get();
 
 	gAgent.setUserGroupFlags(mGroupID, receive_notices, list_in_profile);
+
 	mChanged = FALSE;
+	notifyObservers();
 
 	return true;
 }
@@ -660,7 +661,6 @@ void LLPanelGroupGeneral::update(LLGroupChange gc)
 		mCtrlReceiveNotices->setVisible(is_member);
 		if (is_member)
 		{
-			mCtrlReceiveNotices->set(agent_gdatap.mAcceptNotices);
 			mCtrlReceiveNotices->setEnabled(mAllowEdit);
 		}
 	}
@@ -804,6 +804,16 @@ void LLPanelGroupGeneral::updateChanged()
 		mChanged |= mInsignia->isDirty();
 	if ( mEditCharter )
 		mChanged |= mEditCharter->isDirty();
+	if ( mCtrlShowInGroupList)
+		mChanged |= mCtrlShowInGroupList->isDirty();
+	if ( mCtrlMature)
+		mChanged |= mCtrlMature->isDirty();
+	if ( mCtrlOpenEnrollment)
+		mChanged |= mCtrlOpenEnrollment->isDirty();
+	if ( mCtrlEnrollmentFee)
+		mChanged |= mCtrlEnrollmentFee->isDirty();
+	if ( mSpinEnrollmentFee)
+		mChanged |= mSpinEnrollmentFee->isDirty();
 //	if ( mCtrlReceiveNotices )			// "Receive group notices" is different, see onReceiveNotices()
 //		mChanged |= mCtrlReceiveNotices->isDirty();
 }
diff --git a/indra/newview/llpanelpermissions.cpp b/indra/newview/llpanelpermissions.cpp
index 133173b02d8..e2e283f516b 100644
--- a/indra/newview/llpanelpermissions.cpp
+++ b/indra/newview/llpanelpermissions.cpp
@@ -1,18 +1,13 @@
 /** 
  * @file llpanelpermissions.cpp
  * @brief LLPanelPermissions class implementation
+ * This class represents the panel in the build view for
+ * viewing/editing object names, owners, permissions, etc.
  *
  * Copyright (c) 2002-$CurrentYear$, Linden Research, Inc.
  * $License$
  */
 
-//*****************************************************************************
-//
-// This class represents the panel in the build view for
-// viewing/editing object names, owners, permissions, etc.
-//
-//*****************************************************************************
-
 #include "llviewerprecompiledheaders.h"
 
 #include "llpanelpermissions.h"
@@ -51,8 +46,13 @@
 ///----------------------------------------------------------------------------
 
 // Default constructor
+LLPanelPermissions::LLPanelPermissions(const std::string& title) :
+	LLPanel(title)
+{
+	setMouseOpaque(FALSE);
+}
 
-BOOL	LLPanelPermissions::postBuild()
+BOOL LLPanelPermissions::postBuild()
 {
 	this->childSetCommitCallback("Object Name",LLPanelPermissions::onCommitName,this);
 	this->childSetPrevalidate("Object Name",LLLineEditor::prevalidatePrintableNotPipe);
@@ -86,25 +86,21 @@ BOOL	LLPanelPermissions::postBuild()
 	this->childSetCommitCallback("clickaction",LLPanelPermissions::onCommitClickAction,this);
 	this->childSetCommitCallback("search_check",LLPanelPermissions::onCommitIncludeInSearch,this);
 	
-
-	LLTextBox*	LabelGroupNameRectProxy = gUICtrlFactory->getTextBoxByName(this,"Group Name Proxy");
-	if(LabelGroupNameRectProxy )
+	LLTextBox* group_rect_proxy = gUICtrlFactory->getTextBoxByName(this,"Group Name Proxy");
+	if(group_rect_proxy )
 	{
-		mLabelGroupName = new LLNameBox("Group Name",LabelGroupNameRectProxy->getRect());
+		mLabelGroupName = new LLNameBox("Group Name", group_rect_proxy->getRect());
 		addChild(mLabelGroupName);
-	}else
+	}
+	else
+	{
 		mLabelGroupName = NULL;
+	}
 
 	return TRUE;
 }
 
-LLPanelPermissions::LLPanelPermissions(const std::string& title) :
-	LLPanel(title)
-{
-	setMouseOpaque(FALSE);
-}
 
-// Destroys the object
 LLPanelPermissions::~LLPanelPermissions()
 {
 	// base class will take care of everything
@@ -113,7 +109,6 @@ LLPanelPermissions::~LLPanelPermissions()
 
 void LLPanelPermissions::refresh()
 {
-	
 	LLButton*	BtnDeedToGroup = gUICtrlFactory->getButtonByName(this,"button deed");
 	if(BtnDeedToGroup)
 	{	
diff --git a/indra/newview/llpanelpermissions.h b/indra/newview/llpanelpermissions.h
index 48c52b56b9f..4cc276ff063 100644
--- a/indra/newview/llpanelpermissions.h
+++ b/indra/newview/llpanelpermissions.h
@@ -9,10 +9,7 @@
 #ifndef LL_LLPANELPERMISSIONS_H
 #define LL_LLPANELPERMISSIONS_H
 
-#ifndef LL_LLPANEL_H
 #include "llpanel.h"
-#endif
-
 #include "lluuid.h"
 
 //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
-- 
GitLab