summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--indra/newview/app_settings/settings.xml15
-rw-r--r--indra/newview/llavataractions.cpp4
-rw-r--r--indra/newview/llfloaterwebcontent.cpp18
-rw-r--r--indra/newview/llfloaterwebcontent.h2
-rw-r--r--indra/newview/skins/default/xui/en/floater_media_browser.xml2
-rw-r--r--indra/newview/skins/default/xui/en/floater_web_content.xml9
-rw-r--r--indra/newview/skins/minimal/xui/en/floater_web_content.xml9
7 files changed, 50 insertions, 9 deletions
diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml
index 34a179f95b..9d46cd442b 100644
--- a/indra/newview/app_settings/settings.xml
+++ b/indra/newview/app_settings/settings.xml
@@ -13405,5 +13405,20 @@
<key>Value</key>
<integer>1</integer>
</map>
+ <key>WebProfileRect</key>
+ <map>
+ <key>Comment</key>
+ <string>Web profile dimensions</string>
+ <key>Persist</key>
+ <integer>1</integer>
+ <key>Type</key>
+ <string>Rect</string>
+ <key>Value</key>
+ <array>
+ <integer>0</integer>
+ <integer>650</integer>
+ <integer>475</integer>
+ <integer>0</integer>
+ </array> </map>
</map>
</llsd>
diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp
index eeb4ec8458..b2d97a796a 100644
--- a/indra/newview/llavataractions.cpp
+++ b/indra/newview/llavataractions.cpp
@@ -313,7 +313,9 @@ static void on_avatar_name_show_profile(const LLUUID& agent_id, const LLAvatarNa
std::string url = getProfileURL(username);
// PROFILES: open in webkit window
- LLWeb::loadWebURLInternal(url, "", agent_id.asString());
+ const bool show_chrome = false;
+ static LLCachedControl<LLRect> profile_rect(gSavedSettings, "WebProfileRect");
+ LLFloaterWebContent::create(url, "", agent_id.asString(), show_chrome, profile_rect);
}
// static
diff --git a/indra/newview/llfloaterwebcontent.cpp b/indra/newview/llfloaterwebcontent.cpp
index 058567492b..43eecbf048 100644
--- a/indra/newview/llfloaterwebcontent.cpp
+++ b/indra/newview/llfloaterwebcontent.cpp
@@ -99,7 +99,7 @@ void LLFloaterWebContent::initializeURLHistory()
}
//static
-void LLFloaterWebContent::create( const std::string &url, const std::string& target, const std::string& uuid )
+void LLFloaterWebContent::create( const std::string &url, const std::string& target, const std::string& uuid, bool show_chrome, const LLRect& preferred_media_size)
{
lldebugs << "url = " << url << ", target = " << target << ", uuid = " << uuid << llendl;
@@ -155,6 +155,20 @@ void LLFloaterWebContent::create( const std::string &url, const std::string& tar
// tell the browser instance to load the specified URL
browser->open_media(url, target);
LLViewerMedia::proxyWindowOpened(target, uuid);
+
+ browser->getChild<LLLayoutPanel>("status_bar")->setVisible(show_chrome);
+ browser->getChild<LLLayoutPanel>("nav_controls")->setVisible(show_chrome);
+
+ if (!show_chrome)
+ {
+ browser->setResizeLimits(100, 100);
+ }
+
+ if (!preferred_media_size.isEmpty())
+ {
+ //ignore x, y for now
+ browser->geometryChanged(browser->getRect().mLeft, browser->getRect().mBottom, preferred_media_size.getWidth(), preferred_media_size.getHeight());
+ }
}
}
@@ -210,7 +224,7 @@ void LLFloaterWebContent::geometryChanged(S32 x, S32 y, S32 width, S32 height)
lldebugs << "geometry change: " << geom << llendl;
- handleReshape(geom,false);
+ setShape(geom);
}
void LLFloaterWebContent::open_media(const std::string& web_url, const std::string& target)
diff --git a/indra/newview/llfloaterwebcontent.h b/indra/newview/llfloaterwebcontent.h
index ecc7e970d8..56b6ef12c8 100644
--- a/indra/newview/llfloaterwebcontent.h
+++ b/indra/newview/llfloaterwebcontent.h
@@ -46,7 +46,7 @@ public:
void initializeURLHistory();
- static void create(const std::string &url, const std::string& target, const std::string& uuid = LLStringUtil::null);
+ static void create(const std::string &url, const std::string& target, const std::string& uuid = LLStringUtil::null, bool show_chrome = true, const LLRect& preferred_media_size = LLRect() );
static void closeRequest(const std::string &uuid);
static void geometryChanged(const std::string &uuid, S32 x, S32 y, S32 width, S32 height);
diff --git a/indra/newview/skins/default/xui/en/floater_media_browser.xml b/indra/newview/skins/default/xui/en/floater_media_browser.xml
index 43729d7c9f..5a1f920398 100644
--- a/indra/newview/skins/default/xui/en/floater_media_browser.xml
+++ b/indra/newview/skins/default/xui/en/floater_media_browser.xml
@@ -5,7 +5,7 @@
height="440"
layout="topleft"
min_height="140"
- min_width="467"
+ min_width="0"
name="floater_about"
help_topic="floater_about"
save_rect="true"
diff --git a/indra/newview/skins/default/xui/en/floater_web_content.xml b/indra/newview/skins/default/xui/en/floater_web_content.xml
index e04a72cbc0..a62ff21589 100644
--- a/indra/newview/skins/default/xui/en/floater_web_content.xml
+++ b/indra/newview/skins/default/xui/en/floater_web_content.xml
@@ -18,6 +18,7 @@
follows="left|right|top|bottom"
layout="topleft"
left="5"
+ animate="false"
name="stack1"
orientation="vertical"
top="20"
@@ -156,14 +157,18 @@
name="external_controls"
top_delta="0"
user_resize="false"
+ auto_resize="true"
width="585">
<web_browser
- bottom="-22"
+ bottom="-2"
follows="all"
layout="topleft"
left="0"
name="webbrowser"
top="0"/>
+ </layout_panel>
+ <layout_panel name="status_bar"
+ height="23">
<text
type="string"
length="200"
@@ -174,7 +179,7 @@
name="statusbartext"
parse_urls="false"
text_color="0.4 0.4 0.4 1"
- top_pad="5"
+ top_pad="3"
width="495"/>
<progress_bar
color_bar="0.3 1.0 0.3 1"
diff --git a/indra/newview/skins/minimal/xui/en/floater_web_content.xml b/indra/newview/skins/minimal/xui/en/floater_web_content.xml
index 50cb5b14ce..fd45ef2f62 100644
--- a/indra/newview/skins/minimal/xui/en/floater_web_content.xml
+++ b/indra/newview/skins/minimal/xui/en/floater_web_content.xml
@@ -17,6 +17,7 @@
follows="left|right|top|bottom"
layout="topleft"
left="5"
+ animate="false"
name="stack1"
orientation="vertical"
top="20"
@@ -155,14 +156,18 @@
name="external_controls"
top_delta="0"
user_resize="false"
+ auto_resize="true"
width="585">
<web_browser
- bottom="-22"
+ bottom="-2"
follows="all"
layout="topleft"
left="0"
name="webbrowser"
top="0"/>
+ </layout_panel>
+ <layout_panel name="status_bar"
+ height="23">
<text
type="string"
length="200"
@@ -173,7 +178,7 @@
name="statusbartext"
parse_urls="false"
text_color="0.4 0.4 0.4 1"
- top_pad="5"
+ top_pad="3"
width="495"/>
<progress_bar
color_bar="0.3 1.0 0.3 1"