DEV-43439: Remove Back/Forward/Home buttons from Home side panel.
As per request from Yoz. They will add navigation buttons to the actual HTML content.master
parent
5df04533f6
commit
da2a0385ae
|
|
@ -69,48 +69,11 @@ BOOL LLPanelHome::postBuild()
|
|||
mBrowser->addObserver(this);
|
||||
mBrowser->setTrusted(true);
|
||||
mBrowser->setHomePageUrl(url);
|
||||
|
||||
childSetAction("back", onClickBack, this);
|
||||
childSetAction("forward", onClickForward, this);
|
||||
childSetAction("home", onClickHome, this);
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
//static
|
||||
void LLPanelHome::onClickBack(void* user_data)
|
||||
{
|
||||
LLPanelHome *self = (LLPanelHome*)user_data;
|
||||
if (self && self->mBrowser)
|
||||
{
|
||||
self->mBrowser->navigateBack();
|
||||
}
|
||||
}
|
||||
|
||||
//static
|
||||
void LLPanelHome::onClickForward(void* user_data)
|
||||
{
|
||||
LLPanelHome *self = (LLPanelHome*)user_data;
|
||||
if (self && self->mBrowser)
|
||||
{
|
||||
self->mBrowser->navigateForward();
|
||||
}
|
||||
}
|
||||
|
||||
//static
|
||||
void LLPanelHome::onClickHome(void* user_data)
|
||||
{
|
||||
LLPanelHome *self = (LLPanelHome*)user_data;
|
||||
if (self && self->mBrowser)
|
||||
{
|
||||
self->mBrowser->navigateHome();
|
||||
}
|
||||
}
|
||||
|
||||
void LLPanelHome::handleMediaEvent(LLPluginClassMedia *self, EMediaEvent event)
|
||||
{
|
||||
// update back/forward button state
|
||||
childSetEnabled("back", mBrowser->canNavigateBack());
|
||||
childSetEnabled("forward", mBrowser->canNavigateForward());
|
||||
}
|
||||
|
|
|
|||
|
|
@ -53,10 +53,6 @@ public:
|
|||
/*virtual*/ BOOL postBuild();
|
||||
/*virtual*/ void onOpen(const LLSD& key);
|
||||
|
||||
static void onClickBack(void* user_data);
|
||||
static void onClickForward(void* user_data);
|
||||
static void onClickHome(void* user_data);
|
||||
|
||||
private:
|
||||
// inherited from LLViewerMediaObserver
|
||||
/*virtual*/ void handleMediaEvent(LLPluginClassMedia *self, EMediaEvent event);
|
||||
|
|
|
|||
|
|
@ -20,58 +20,7 @@
|
|||
top_pad="10"
|
||||
width="313">
|
||||
<layout_panel
|
||||
auto_resize="false"
|
||||
height="20"
|
||||
layout="topleft"
|
||||
left="0"
|
||||
name="nav_controls"
|
||||
top="0"
|
||||
user_resize="false"
|
||||
width="313">
|
||||
<button
|
||||
follows="left|top"
|
||||
enabled="false"
|
||||
height="20"
|
||||
label="Back"
|
||||
layout="topleft"
|
||||
tab_stop="false"
|
||||
left="0"
|
||||
name="back"
|
||||
top="0"
|
||||
width="70">
|
||||
<button.commit_callback
|
||||
function="MediaBrowser.Back" />
|
||||
</button>
|
||||
<button
|
||||
follows="left|top"
|
||||
height="20"
|
||||
enabled="false"
|
||||
label="Forward"
|
||||
layout="topleft"
|
||||
tab_stop="false"
|
||||
left_pad="3"
|
||||
name="forward"
|
||||
top_delta="0"
|
||||
width="70">
|
||||
<button.commit_callback
|
||||
function="MediaBrowser.Forward" />
|
||||
</button>
|
||||
<button
|
||||
follows="left|top"
|
||||
height="20"
|
||||
label="Home"
|
||||
layout="topleft"
|
||||
tab_stop="false"
|
||||
left_pad="2"
|
||||
name="home"
|
||||
top_delta="0"
|
||||
width="70">
|
||||
<button.commit_callback
|
||||
function="MediaBrowser.Home" />
|
||||
</button>
|
||||
</layout_panel>
|
||||
<layout_panel
|
||||
height="530"
|
||||
height="550"
|
||||
layout="topleft"
|
||||
left_delta="0"
|
||||
name="browser_layout"
|
||||
|
|
@ -80,7 +29,7 @@
|
|||
<web_browser
|
||||
border_visible="false"
|
||||
follows="all"
|
||||
height="530"
|
||||
height="550"
|
||||
layout="topleft"
|
||||
left="0"
|
||||
name="browser"
|
||||
|
|
|
|||
Loading…
Reference in New Issue