ACME-251 Create AvatarFolderItemView: Changed classes name from LLPersonFolder* to LLPersonTab*
parent
74f0d33dc1
commit
f8ce67f0e0
|
|
@ -453,7 +453,7 @@ set(viewer_SOURCE_FILES
|
|||
llpathfindingpathtool.cpp
|
||||
llpersistentnotificationstorage.cpp
|
||||
llpersonmodelcommon.cpp
|
||||
llpersonfolderview.cpp
|
||||
llpersontabview.cpp
|
||||
llphysicsmotion.cpp
|
||||
llphysicsshapebuilderutil.cpp
|
||||
llplacesinventorybridge.cpp
|
||||
|
|
@ -1032,7 +1032,7 @@ set(viewer_HEADER_FILES
|
|||
llpathfindingpathtool.h
|
||||
llpersistentnotificationstorage.h
|
||||
llpersonmodelcommon.h
|
||||
llpersonfolderview.h
|
||||
llpersontabview.h
|
||||
llphysicsmotion.h
|
||||
llphysicsshapebuilderutil.h
|
||||
llplacesinventorybridge.h
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@
|
|||
#include "llpanelpeoplemenus.h"
|
||||
#include "llparticipantlist.h"
|
||||
#include "llpersonmodelcommon.h"
|
||||
#include "llpersonfolderview.h"
|
||||
#include "llpersontabview.h"
|
||||
#include "llsidetraypanelcontainer.h"
|
||||
#include "llrecentpeople.h"
|
||||
#include "llviewercontrol.h" // for gSavedSettings
|
||||
|
|
@ -725,13 +725,13 @@ BOOL LLPanelPeople::postBuild()
|
|||
|
||||
//Create a session
|
||||
//LLSpeakerMgr* speaker_manager = (LLSpeakerMgr*)LLLocalSpeakerMgr::getInstance();
|
||||
LLPersonFolderModel* item = new LLPersonFolderModel("Facebook Friends", mConversationViewModel);
|
||||
LLPersonFolderView::Params params;
|
||||
LLPersonTabModel* item = new LLPersonTabModel("Facebook Friends", mConversationViewModel);
|
||||
LLPersonTabView::Params params;
|
||||
params.name = item->getDisplayName();
|
||||
params.root = mConversationsRoot;
|
||||
params.listener = item;
|
||||
params.tool_tip = params.name;
|
||||
LLPersonFolderView * widget = LLUICtrlFactory::create<LLPersonFolderView>(params);
|
||||
LLPersonTabView * widget = LLUICtrlFactory::create<LLPersonTabView>(params);
|
||||
widget->addToFolder(mConversationsRoot);
|
||||
|
||||
mPersonFolderModelMap[item->getID()] = item;
|
||||
|
|
@ -1661,8 +1661,8 @@ bool LLPanelPeople::onConversationModelEvent(const LLSD& event)
|
|||
|
||||
if(type == "add_participant")
|
||||
{
|
||||
LLPersonFolderModel * person_folder_model = dynamic_cast<LLPersonFolderModel *>(mPersonFolderModelMap[folder_id]);
|
||||
LLPersonFolderView * person_folder_view = dynamic_cast<LLPersonFolderView *>(mPersonFolderViewMap[person_id]);
|
||||
LLPersonTabModel * person_folder_model = dynamic_cast<LLPersonTabModel *>(mPersonFolderModelMap[folder_id]);
|
||||
LLPersonTabView * person_folder_view = dynamic_cast<LLPersonTabView *>(mPersonFolderViewMap[person_id]);
|
||||
|
||||
if(person_folder_model)
|
||||
{
|
||||
|
|
@ -1733,12 +1733,12 @@ void LLPanelPeople::addTestParticipant()
|
|||
{
|
||||
for(int i = 0; i < 300; ++i)
|
||||
{
|
||||
LLPersonFolderModel * person_folder_model = dynamic_cast<LLPersonFolderModel *>(mPersonFolderModelMap.begin()->second);
|
||||
LLPersonTabModel * person_folder_model = dynamic_cast<LLPersonTabModel *>(mPersonFolderModelMap.begin()->second);
|
||||
addParticipantToModel(person_folder_model, LLUUID().generateNewID(), "EastBayGuy");
|
||||
}
|
||||
}
|
||||
|
||||
void LLPanelPeople::addParticipantToModel(LLPersonFolderModel * person_folder_model, const LLUUID& agent_id, const std::string& name)
|
||||
void LLPanelPeople::addParticipantToModel(LLPersonTabModel * person_folder_model, const LLUUID& agent_id, const std::string& name)
|
||||
{
|
||||
LLPersonModel* person_model = NULL;
|
||||
|
||||
|
|
|
|||
|
|
@ -45,13 +45,13 @@ class LLMenuButton;
|
|||
class LLTabContainer;
|
||||
class LLFolderView;
|
||||
|
||||
class LLPersonFolderModel;
|
||||
class LLPersonFolderView;
|
||||
class LLPersonTabModel;
|
||||
class LLPersonTabView;
|
||||
class LLPersonView;
|
||||
class LLPersonModel;
|
||||
|
||||
typedef std::map<LLUUID, LLPersonFolderModel *> person_folder_model_map;
|
||||
typedef std::map<LLUUID, LLPersonFolderView *> person_folder_view_map;
|
||||
typedef std::map<LLUUID, LLPersonTabModel *> person_folder_model_map;
|
||||
typedef std::map<LLUUID, LLPersonTabView *> person_folder_view_map;
|
||||
|
||||
class LLPanelPeople
|
||||
: public LLPanel
|
||||
|
|
@ -74,7 +74,7 @@ public:
|
|||
void openFacebookWeb(LLFloaterWebContent::Params& p);
|
||||
void showFacebookFriends(const LLSD& friends);
|
||||
void addTestParticipant();
|
||||
void addParticipantToModel(LLPersonFolderModel * session_model, const LLUUID& agent_id, const std::string& name);
|
||||
void addParticipantToModel(LLPersonTabModel * session_model, const LLUUID& agent_id, const std::string& name);
|
||||
void hideFacebookFriends();
|
||||
void loadFacebookFriends();
|
||||
void tryToReconnectToFacebook();
|
||||
|
|
|
|||
|
|
@ -54,7 +54,7 @@ LLPersonModelCommon::~LLPersonModelCommon()
|
|||
|
||||
}
|
||||
|
||||
void LLPersonModelCommon::postEvent(const std::string& event_type, LLPersonFolderModel* folder, LLPersonModel* person)
|
||||
void LLPersonModelCommon::postEvent(const std::string& event_type, LLPersonTabModel* folder, LLPersonModel* person)
|
||||
{
|
||||
LLUUID folder_id = folder->getID();
|
||||
LLUUID person_id = person->getID();
|
||||
|
|
@ -84,34 +84,34 @@ void LLPersonModelCommon::showProperties(void)
|
|||
}
|
||||
|
||||
//
|
||||
// LLPersonFolderModel
|
||||
// LLPersonTabModel
|
||||
//
|
||||
|
||||
LLPersonFolderModel::LLPersonFolderModel(std::string display_name, LLFolderViewModelInterface& root_view_model) :
|
||||
LLPersonTabModel::LLPersonTabModel(std::string display_name, LLFolderViewModelInterface& root_view_model) :
|
||||
LLPersonModelCommon(display_name,root_view_model)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
LLPersonFolderModel::LLPersonFolderModel(LLFolderViewModelInterface& root_view_model) :
|
||||
LLPersonTabModel::LLPersonTabModel(LLFolderViewModelInterface& root_view_model) :
|
||||
LLPersonModelCommon(root_view_model)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void LLPersonFolderModel::addParticipant(LLPersonModel* participant)
|
||||
void LLPersonTabModel::addParticipant(LLPersonModel* participant)
|
||||
{
|
||||
addChild(participant);
|
||||
postEvent("add_participant", this, participant);
|
||||
}
|
||||
|
||||
void LLPersonFolderModel::removeParticipant(LLPersonModel* participant)
|
||||
void LLPersonTabModel::removeParticipant(LLPersonModel* participant)
|
||||
{
|
||||
removeChild(participant);
|
||||
postEvent("remove_participant", this, participant);
|
||||
}
|
||||
|
||||
void LLPersonFolderModel::removeParticipant(const LLUUID& participant_id)
|
||||
void LLPersonTabModel::removeParticipant(const LLUUID& participant_id)
|
||||
{
|
||||
LLPersonModel* participant = findParticipant(participant_id);
|
||||
if (participant)
|
||||
|
|
@ -120,12 +120,12 @@ void LLPersonFolderModel::removeParticipant(const LLUUID& participant_id)
|
|||
}
|
||||
}
|
||||
|
||||
void LLPersonFolderModel::clearParticipants()
|
||||
void LLPersonTabModel::clearParticipants()
|
||||
{
|
||||
clearChildren();
|
||||
}
|
||||
|
||||
LLPersonModel* LLPersonFolderModel::findParticipant(const LLUUID& person_id)
|
||||
LLPersonModel* LLPersonTabModel::findParticipant(const LLUUID& person_id)
|
||||
{
|
||||
LLPersonModel * person_model = NULL;
|
||||
child_list_t::iterator iter;
|
||||
|
|
@ -144,7 +144,7 @@ LLPersonModel* LLPersonFolderModel::findParticipant(const LLUUID& person_id)
|
|||
}
|
||||
|
||||
//
|
||||
// LLConversationItemParticipant
|
||||
// LLPersonModel
|
||||
//
|
||||
|
||||
LLPersonModel::LLPersonModel(std::string display_name, LLFolderViewModelInterface& root_view_model) :
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@
|
|||
#include "../llui/llfolderviewitem.h"
|
||||
#include "../llui/llfolderviewmodel.h"
|
||||
|
||||
class LLPersonFolderModel;
|
||||
class LLPersonTabModel;
|
||||
class LLPersonModel;
|
||||
|
||||
// Conversation items: we hold a list of those and create an LLFolderViewItem widget for each
|
||||
|
|
@ -93,7 +93,7 @@ public:
|
|||
std::string& tooltip_msg) { return FALSE; }
|
||||
|
||||
const LLUUID& getID() {return mID;}
|
||||
void postEvent(const std::string& event_type, LLPersonFolderModel* session, LLPersonModel* participant);
|
||||
void postEvent(const std::string& event_type, LLPersonTabModel* session, LLPersonModel* participant);
|
||||
|
||||
protected:
|
||||
|
||||
|
|
@ -101,11 +101,11 @@ protected:
|
|||
LLUUID mID;
|
||||
};
|
||||
|
||||
class LLPersonFolderModel : public LLPersonModelCommon
|
||||
class LLPersonTabModel : public LLPersonModelCommon
|
||||
{
|
||||
public:
|
||||
LLPersonFolderModel(std::string display_name, LLFolderViewModelInterface& root_view_model);
|
||||
LLPersonFolderModel(LLFolderViewModelInterface& root_view_model);
|
||||
LLPersonTabModel(std::string display_name, LLFolderViewModelInterface& root_view_model);
|
||||
LLPersonTabModel(LLFolderViewModelInterface& root_view_model);
|
||||
|
||||
LLPointer<LLUIImage> getIcon() const { return NULL; }
|
||||
void addParticipant(LLPersonModel* participant);
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
/**
|
||||
* @file llpersonfolderview.cpp
|
||||
* @brief Implementation of llpersonfolderview
|
||||
* @file llpersontabview.cpp
|
||||
* @brief Implementation of llpersontabview
|
||||
* @author Gilbert@lindenlab.com
|
||||
*
|
||||
* $LicenseInfo:firstyear=2013&license=viewerlgpl$
|
||||
|
|
@ -27,35 +27,35 @@
|
|||
|
||||
#include "llviewerprecompiledheaders.h"
|
||||
|
||||
#include "llpersonfolderview.h"
|
||||
#include "llpersontabview.h"
|
||||
|
||||
static LLDefaultChildRegistry::Register<LLPersonFolderView> r_person_folder_view("person_folder_view");
|
||||
static LLDefaultChildRegistry::Register<LLPersonTabView> r_person_folder_view("person_folder_view");
|
||||
|
||||
const LLColor4U DEFAULT_WHITE(255, 255, 255);
|
||||
|
||||
LLPersonFolderView::Params::Params()
|
||||
LLPersonTabView::Params::Params()
|
||||
{}
|
||||
|
||||
LLPersonFolderView::LLPersonFolderView(const LLPersonFolderView::Params& p) :
|
||||
LLPersonTabView::LLPersonTabView(const LLPersonTabView::Params& p) :
|
||||
LLFolderViewFolder(p)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
S32 LLPersonFolderView::getLabelXPos()
|
||||
S32 LLPersonTabView::getLabelXPos()
|
||||
{
|
||||
return getIndentation() + mArrowSize + 15;//Should be a .xml variable but causes crash;
|
||||
}
|
||||
|
||||
LLPersonFolderView::~LLPersonFolderView()
|
||||
LLPersonTabView::~LLPersonTabView()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
void LLPersonFolderView::draw()
|
||||
void LLPersonTabView::draw()
|
||||
{
|
||||
static LLUIColor sFgColor = LLUIColorTable::instance().getColor("MenuItemEnabledColor", DEFAULT_WHITE);
|
||||
static const LLFolderViewItem::Params& default_params = LLUICtrlFactory::getDefaultParams<LLPersonFolderView>();
|
||||
static const LLFolderViewItem::Params& default_params = LLUICtrlFactory::getDefaultParams<LLPersonTabView>();
|
||||
|
||||
static LLUIColor sHighlightBgColor = LLUIColorTable::instance().getColor("MenuItemHighlightBgColor", DEFAULT_WHITE);
|
||||
static LLUIColor sFlashBgColor = LLUIColorTable::instance().getColor("MenuItemFlashBgColor", DEFAULT_WHITE);
|
||||
|
|
@ -79,7 +79,7 @@ void LLPersonFolderView::draw()
|
|||
}
|
||||
|
||||
//
|
||||
// LLPersonFolderModel
|
||||
// LLPersonView
|
||||
//
|
||||
|
||||
|
||||
|
|
@ -1,6 +1,6 @@
|
|||
/**
|
||||
* @file llpersonfolderview.h
|
||||
* @brief Header file for llpersonfolderview
|
||||
* @file llpersontabview.h
|
||||
* @brief Header file for llpersontabview
|
||||
* @author Gilbert@lindenlab.com
|
||||
*
|
||||
* $LicenseInfo:firstyear=2013&license=viewerlgpl$
|
||||
|
|
@ -24,13 +24,13 @@
|
|||
* Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
|
||||
* $/LicenseInfo$
|
||||
*/
|
||||
#ifndef LL_LLPERSONFOLDERVIEW_H
|
||||
#define LL_LLPERSONFOLDERVIEW_H
|
||||
#ifndef LL_LLPERSONTABVIEW_H
|
||||
#define LL_LLPERSONTABVIEW_H
|
||||
|
||||
#include "llavatariconctrl.h"
|
||||
#include "llfolderviewitem.h"
|
||||
|
||||
class LLPersonFolderView : public LLFolderViewFolder
|
||||
class LLPersonTabView : public LLFolderViewFolder
|
||||
{
|
||||
|
||||
public:
|
||||
|
|
@ -40,8 +40,8 @@ public:
|
|||
Params();
|
||||
};
|
||||
|
||||
LLPersonFolderView(const LLPersonFolderView::Params& p);
|
||||
virtual ~LLPersonFolderView();
|
||||
LLPersonTabView(const LLPersonTabView::Params& p);
|
||||
virtual ~LLPersonTabView();
|
||||
|
||||
S32 getLabelXPos();
|
||||
|
||||
|
|
@ -89,5 +89,5 @@ private:
|
|||
//LLView* getItemChildView(EAvatarListItemChildIndex child_view_index);
|
||||
};
|
||||
|
||||
#endif // LL_LLPERSONFOLDERVIEW_H
|
||||
#endif // LL_LLPERSONTABVIEW_H
|
||||
|
||||
Loading…
Reference in New Issue