Initial support for a unified tabbed comm window with both nearby chat and IMs.
A bit hackish, and room for improvement, but it works and is a huge leap forward for many.meow-7.2.2
parent
5b4d3cda68
commit
b23f445060
|
|
@ -3,6 +3,7 @@ Please keep this updated with major user-facing features we add to firestorm bey
|
|||
FEATURE LICENSE
|
||||
|
||||
DePatronizedMenus LGPL
|
||||
AppalachianStarlight LGPL
|
||||
RLVa LGPL
|
||||
WornItems LGPL
|
||||
VerticalTabIms LGPL
|
||||
|
|
@ -13,4 +14,5 @@ ViewerTagBroadcast LGPL
|
|||
LargeProfile LGPL
|
||||
ImprovedPrefs LGPL
|
||||
WindlightExtraSettings LGPL
|
||||
WindlightServerProtocol LGPL
|
||||
WindlightParcelProtocol LGPL
|
||||
UnifiedCommWindow LGPL
|
||||
|
|
|
|||
|
|
@ -35,6 +35,9 @@
|
|||
#include "llagent.h"
|
||||
#include "lltransientfloatermgr.h"
|
||||
|
||||
#include "llnearbychat.h"
|
||||
#include "llfloater.h"
|
||||
|
||||
//
|
||||
// LLIMFloaterContainer
|
||||
//
|
||||
|
|
@ -60,7 +63,19 @@ BOOL LLIMFloaterContainer::postBuild()
|
|||
|
||||
void LLIMFloaterContainer::onOpen(const LLSD& key)
|
||||
{
|
||||
|
||||
LLMultiFloater::onOpen(key);
|
||||
|
||||
|
||||
// If we're using multitabs, and we open up for the first time
|
||||
// Add localchat by default if it's not already on the screen somewhere else. -AO
|
||||
LLFloater* floater = LLNearbyChat::getInstance();
|
||||
if (! LLFloater::isVisible(floater))
|
||||
{
|
||||
LLMultiFloater::showFloater(floater, LLTabContainer::START);
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
if (key.isDefined())
|
||||
{
|
||||
|
|
|
|||
|
|
@ -55,6 +55,12 @@
|
|||
#include "llfloaterreg.h"
|
||||
#include "lltrans.h"
|
||||
|
||||
// IM
|
||||
#include "llbutton.h"
|
||||
#include "lllayoutstack.h"
|
||||
|
||||
#include "llimfloatercontainer.h"
|
||||
|
||||
static const S32 RESIZE_BAR_THICKNESS = 3;
|
||||
|
||||
LLNearbyChat::LLNearbyChat(const LLSD& key)
|
||||
|
|
@ -68,6 +74,7 @@ LLNearbyChat::~LLNearbyChat()
|
|||
{
|
||||
}
|
||||
|
||||
|
||||
BOOL LLNearbyChat::postBuild()
|
||||
{
|
||||
//menu
|
||||
|
|
@ -84,8 +91,19 @@ BOOL LLNearbyChat::postBuild()
|
|||
|
||||
gSavedSettings.declareS32("nearbychat_showicons_and_names",2,"NearByChat header settings",true);
|
||||
|
||||
/* Imish things */
|
||||
|
||||
LLButton* slide_left = getChild<LLButton>("slide_left_btn");
|
||||
slide_left->setVisible(false);
|
||||
LLButton* slide_right = getChild<LLButton>("slide_right_btn");
|
||||
slide_right->setVisible(false);
|
||||
|
||||
/****************/
|
||||
|
||||
mChatHistory = getChild<LLChatHistory>("chat_history");
|
||||
|
||||
return LLFloater::postBuild();
|
||||
|
||||
/*
|
||||
if(!LLDockableFloater::postBuild())
|
||||
return false;
|
||||
|
||||
|
|
@ -104,6 +122,7 @@ BOOL LLNearbyChat::postBuild()
|
|||
mDragHandle->setTitleVisible(TRUE);
|
||||
|
||||
return true;
|
||||
*/
|
||||
}
|
||||
|
||||
|
||||
|
|
@ -218,6 +237,18 @@ bool LLNearbyChat::onNearbyChatCheckContextMenuItem(const LLSD& userdata)
|
|||
return false;
|
||||
}
|
||||
|
||||
void LLNearbyChat::openFloater(const LLSD& key)
|
||||
{
|
||||
// We override this to put nearbychat in the IM floater. -AO
|
||||
LLIMFloaterContainer* floater_container = LLIMFloaterContainer::getInstance();
|
||||
if (floater_container)
|
||||
{
|
||||
floater_container->showFloater(this, LLTabContainer::START);
|
||||
}
|
||||
|
||||
LLFloater::openFloater(key);
|
||||
}
|
||||
|
||||
void LLNearbyChat::setVisible(BOOL visible)
|
||||
{
|
||||
if(visible)
|
||||
|
|
@ -228,15 +259,17 @@ void LLNearbyChat::setVisible(BOOL visible)
|
|||
chat_channel->removeToastsFromChannel();
|
||||
}
|
||||
}
|
||||
|
||||
LLDockableFloater::setVisible(visible);
|
||||
}
|
||||
|
||||
void LLNearbyChat::onOpen(const LLSD& key )
|
||||
{
|
||||
llinfos << "onOPEN called..." << llendl;
|
||||
LLDockableFloater::onOpen(key);
|
||||
}
|
||||
|
||||
|
||||
|
||||
void LLNearbyChat::setRect (const LLRect &rect)
|
||||
{
|
||||
LLDockableFloater::setRect(rect);
|
||||
|
|
|
|||
|
|
@ -56,6 +56,7 @@ public:
|
|||
/*virtual*/ void onOpen (const LLSD& key);
|
||||
|
||||
/*virtual*/ void setVisible(BOOL visible);
|
||||
void openFloater(const LLSD& key);
|
||||
|
||||
virtual void setRect (const LLRect &rect);
|
||||
|
||||
|
|
|
|||
|
|
@ -1,12 +1,11 @@
|
|||
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
|
||||
<multi_floater
|
||||
can_close="false"
|
||||
can_minimize="true"
|
||||
can_close="true"
|
||||
can_minimize="false"
|
||||
can_resize="true"
|
||||
height="390"
|
||||
layout="topleft"
|
||||
name="floater_im_box"
|
||||
help_topic="floater_im_box"
|
||||
save_rect="true"
|
||||
save_visibility="true"
|
||||
single_instance="true"
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
name="panel_im"
|
||||
top="0"
|
||||
can_dock="false"
|
||||
can_minimize="true"
|
||||
can_minimize="false"
|
||||
can_close="true"
|
||||
visible="false"
|
||||
width="394"
|
||||
|
|
|
|||
|
|
@ -1,53 +1,73 @@
|
|||
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
|
||||
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
|
||||
<floater
|
||||
border_visible="false"
|
||||
border="false"
|
||||
bg_opaque_image="Window_Foreground"
|
||||
bg_alpha_image="Window_Background"
|
||||
bg_alpha_image_overlay="DkGray_66"
|
||||
legacy_header_height="18"
|
||||
can_minimize="true"
|
||||
can_tear_off="false"
|
||||
can_resize="true"
|
||||
can_drag_on_left="false"
|
||||
can_close="false"
|
||||
can_dock="true"
|
||||
bevel_style="in"
|
||||
height="300"
|
||||
min_width="235"
|
||||
background_visible="true"
|
||||
default_tab_group="1"
|
||||
follows="all"
|
||||
height="350"
|
||||
layout="topleft"
|
||||
left="0"
|
||||
name="nearby_chat"
|
||||
help_topic="nearby_chat"
|
||||
save_rect="true"
|
||||
title="NEARBY CHAT"
|
||||
save_dock_state="true"
|
||||
save_visibility="true"
|
||||
top="0"
|
||||
can_close="true"
|
||||
can_minimize="false"
|
||||
single_instance="true"
|
||||
width="320">
|
||||
<check_box
|
||||
bottom_delta="36"
|
||||
control_name="TranslateChat"
|
||||
enabled="true"
|
||||
height="16"
|
||||
label="Translate chat (powered by Google)"
|
||||
layout="topleft"
|
||||
left="5"
|
||||
name="translate_chat_checkbox"
|
||||
width="230" />
|
||||
<chat_history
|
||||
parse_urls="true"
|
||||
bg_readonly_color="ChatHistoryBgColor"
|
||||
bg_writeable_color="ChatHistoryBgColor"
|
||||
follows="all"
|
||||
left="5"
|
||||
top_delta="17"
|
||||
layout="topleft"
|
||||
height="260"
|
||||
name="chat_history"
|
||||
parse_highlights="true"
|
||||
text_color="ChatHistoryTextColor"
|
||||
text_readonly_color="ChatHistoryTextColor"
|
||||
right_widget_pad="5"
|
||||
left_widget_pad="0"
|
||||
width="315" />
|
||||
visible="false"
|
||||
width="394"
|
||||
can_resize="true"
|
||||
min_width="250"
|
||||
min_height="190">
|
||||
<layout_stack
|
||||
animate="false"
|
||||
default_tab_group="2"
|
||||
follows="all"
|
||||
height="320"
|
||||
width="394"
|
||||
layout="topleft"
|
||||
orientation="horizontal"
|
||||
name="im_panels"
|
||||
tab_group="1"
|
||||
top="20"
|
||||
left="0">
|
||||
|
||||
<layout_panel
|
||||
default_tab_group="3"
|
||||
left="0"
|
||||
tab_group="2"
|
||||
top="0"
|
||||
height="200"
|
||||
width="254"
|
||||
user_resize="true">
|
||||
<button
|
||||
height="20"
|
||||
follows="left|top"
|
||||
top="0"
|
||||
left="2"
|
||||
image_overlay="TabIcon_Open_Off"
|
||||
layout="topleft"
|
||||
width="25"
|
||||
name="slide_left_btn" />
|
||||
<button
|
||||
height="20"
|
||||
follows="left|top"
|
||||
top="0"
|
||||
left="2"
|
||||
image_overlay="TabIcon_Close_Off"
|
||||
width="25"
|
||||
name="slide_right_btn" />
|
||||
<chat_history
|
||||
font="SansSerifSmall"
|
||||
follows="left|right|top|bottom"
|
||||
height="170"
|
||||
name="chat_history"
|
||||
parse_highlights="true"
|
||||
parse_urls="true"
|
||||
left="1"
|
||||
width="249"
|
||||
value="test1">
|
||||
</chat_history>
|
||||
</layout_panel>
|
||||
</layout_stack>
|
||||
|
||||
</floater>
|
||||
|
|
|
|||
|
|
@ -52,7 +52,7 @@
|
|||
name="show_nearby_chat"
|
||||
tool_tip="Shows/hides nearby chat log">
|
||||
<button.init_callback
|
||||
function="Button.SetDockableFloaterToggle"
|
||||
function="Button.SetFloaterToggle"
|
||||
parameter="nearby_chat" />
|
||||
</button>
|
||||
</panel>
|
||||
|
|
|
|||
Loading…
Reference in New Issue