summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
Diffstat (limited to 'indra')
-rw-r--r--indra/cmake/Copy3rdPartyLibs.cmake2
-rw-r--r--indra/llcommon/llsys.cpp129
-rw-r--r--indra/newview/CMakeLists.txt2
-rw-r--r--indra/newview/llappviewer.cpp9
-rw-r--r--indra/newview/llfloatertools.cpp19
-rwxr-xr-xindra/newview/llmediadataclient.cpp3
-rw-r--r--indra/newview/llpanelprimmediacontrols.cpp59
-rw-r--r--indra/newview/llpanelprimmediacontrols.h6
-rw-r--r--indra/newview/llviewermedia.cpp79
-rw-r--r--indra/newview/llviewermedia.h2
-rw-r--r--indra/newview/llviewerparcelmedia.cpp5
-rw-r--r--indra/newview/llvoiceclient.cpp2
-rw-r--r--indra/newview/llvovolume.cpp14
-rw-r--r--indra/newview/skins/default/xui/en/panel_preferences_privacy.xml11
-rw-r--r--indra/newview/skins/default/xui/en/panel_prim_media_controls.xml56
15 files changed, 311 insertions, 87 deletions
diff --git a/indra/cmake/Copy3rdPartyLibs.cmake b/indra/cmake/Copy3rdPartyLibs.cmake
index af407d52de..bbf31f9297 100644
--- a/indra/cmake/Copy3rdPartyLibs.cmake
+++ b/indra/cmake/Copy3rdPartyLibs.cmake
@@ -209,7 +209,7 @@ elseif(LINUX)
libapr-1.so.0
libaprutil-1.so.0
libatk-1.0.so
- libcrypto.so
+ libcrypto.so.0.9.7
libdb-4.2.so
libexpat.so
libgmock_main.so
diff --git a/indra/llcommon/llsys.cpp b/indra/llcommon/llsys.cpp
index 3652eeba72..cba8cf85b0 100644
--- a/indra/llcommon/llsys.cpp
+++ b/indra/llcommon/llsys.cpp
@@ -76,6 +76,75 @@ extern int errno;
static const S32 CPUINFO_BUFFER_SIZE = 16383;
LLCPUInfo gSysCPU;
+#if LL_WINDOWS
+#ifndef DLLVERSIONINFO
+typedef struct _DllVersionInfo
+{
+ DWORD cbSize;
+ DWORD dwMajorVersion;
+ DWORD dwMinorVersion;
+ DWORD dwBuildNumber;
+ DWORD dwPlatformID;
+}DLLVERSIONINFO;
+#endif
+
+#ifndef DLLGETVERSIONPROC
+typedef int (FAR WINAPI *DLLGETVERSIONPROC) (DLLVERSIONINFO *);
+#endif
+
+bool get_shell32_dll_version(DWORD& major, DWORD& minor, DWORD& build_number)
+{
+ bool result = false;
+ const U32 BUFF_SIZE = 32767;
+ WCHAR tempBuf[BUFF_SIZE];
+ if(GetSystemDirectory((LPWSTR)&tempBuf, BUFF_SIZE))
+ {
+
+ std::basic_string<WCHAR> shell32_path(tempBuf);
+
+ // Shell32.dll contains the DLLGetVersion function.
+ // according to msdn its not part of the API
+ // so you have to go in and get it.
+ // http://msdn.microsoft.com/en-us/library/bb776404(VS.85).aspx
+ shell32_path += TEXT("\\shell32.dll");
+
+ HMODULE hDllInst = LoadLibrary(shell32_path.c_str()); //load the DLL
+ if(hDllInst)
+ { // Could successfully load the DLL
+ DLLGETVERSIONPROC pDllGetVersion;
+ /*
+ You must get this function explicitly because earlier versions of the DLL
+ don't implement this function. That makes the lack of implementation of the
+ function a version marker in itself.
+ */
+ pDllGetVersion = (DLLGETVERSIONPROC) GetProcAddress(hDllInst,
+ "DllGetVersion");
+
+ if(pDllGetVersion)
+ {
+ // DLL supports version retrieval function
+ DLLVERSIONINFO dvi;
+
+ ZeroMemory(&dvi, sizeof(dvi));
+ dvi.cbSize = sizeof(dvi);
+ HRESULT hr = (*pDllGetVersion)(&dvi);
+
+ if(SUCCEEDED(hr))
+ { // Finally, the version is at our hands
+ major = dvi.dwMajorVersion;
+ minor = dvi.dwMinorVersion;
+ build_number = dvi.dwBuildNumber;
+ result = true;
+ }
+ }
+
+ FreeLibrary(hDllInst); // Release DLL
+ }
+ }
+ return result;
+}
+#endif // LL_WINDOWS
+
LLOSInfo::LLOSInfo() :
mMajorVer(0), mMinorVer(0), mBuild(0)
{
@@ -98,6 +167,11 @@ LLOSInfo::LLOSInfo() :
mMinorVer = osvi.dwMinorVersion;
mBuild = osvi.dwBuildNumber;
+ DWORD shell32_major, shell32_minor, shell32_build;
+ bool got_shell32_version = get_shell32_dll_version(shell32_major,
+ shell32_minor,
+ shell32_build);
+
switch(osvi.dwPlatformId)
{
case VER_PLATFORM_WIN32_NT:
@@ -122,8 +196,22 @@ LLOSInfo::LLOSInfo() :
else
mOSStringSimple = "Microsoft Windows Server 2003 ";
}
- else if(osvi.dwMajorVersion == 6 && osvi.dwMinorVersion == 0)
+ else if(osvi.dwMajorVersion == 6 && osvi.dwMinorVersion <= 1)
{
+ if(osvi.dwMinorVersion == 0)
+ {
+ mOSStringSimple = "Microsoft Windows Vista ";
+ }
+ else if(osvi.dwMinorVersion == 1)
+ {
+ mOSStringSimple = "Microsoft Windows 7 ";
+ }
+
+ if(osvi.wProductType != VER_NT_WORKSTATION)
+ {
+ mOSStringSimple += "Server ";
+ }
+
///get native system info if available..
typedef void (WINAPI *PGNSI)(LPSYSTEM_INFO); ///function pointer for loading GetNativeSystemInfo
SYSTEM_INFO si; //System Info object file contains architecture info
@@ -141,32 +229,13 @@ LLOSInfo::LLOSInfo() :
//of windows than this code does (in case it is needed for the future)
if ( si.wProcessorArchitecture==PROCESSOR_ARCHITECTURE_AMD64 ) //check for 64 bit
{
- if(osvi.wProductType == VER_NT_WORKSTATION)
- mOSStringSimple = "Microsoft Windows Vista 64-bit ";
- else
- mOSStringSimple = "Microsoft Windows Vista Server 64-bit ";
+ mOSStringSimple += "64-bit ";
}
else if (si.wProcessorArchitecture==PROCESSOR_ARCHITECTURE_INTEL )
{
- if(osvi.wProductType == VER_NT_WORKSTATION)
- mOSStringSimple = "Microsoft Windows Vista 32-bit ";
- else
- mOSStringSimple = "Microsoft Windows Vista Server 32-bit ";
- }
- else // PROCESSOR_ARCHITECTURE_IA64 || PROCESSOR_ARCHITECTURE_UNKNOWN not checked
- {
- if(osvi.wProductType == VER_NT_WORKSTATION)
- mOSStringSimple = "Microsoft Windows Vista ";
- else
- mOSStringSimple = "Microsoft Windows Vista Server ";
+ mOSStringSimple += "32-bit ";
}
}
- else if(osvi.dwMajorVersion == 6 && osvi.dwMinorVersion == 1)
- {
- if(osvi.wProductType == VER_NT_WORKSTATION)
- mOSStringSimple = "Microsoft Windows 7 ";
- else mOSStringSimple = "Microsoft Windows 7 Server ";
- }
else // Use the registry on early versions of Windows NT.
{
mOSStringSimple = "Microsoft Windows (unrecognized) ";
@@ -211,6 +280,7 @@ LLOSInfo::LLOSInfo() :
csdversion.c_str(),
(osvi.dwBuildNumber & 0xffff));
}
+
mOSString = mOSStringSimple + tmpstr;
}
break;
@@ -240,6 +310,21 @@ LLOSInfo::LLOSInfo() :
mOSString = mOSStringSimple;
break;
}
+
+ std::string compatibility_mode;
+ if(got_shell32_version)
+ {
+ if(osvi.dwMajorVersion != shell32_major
+ || osvi.dwMinorVersion != shell32_minor)
+ {
+ compatibility_mode = llformat(" compatibility mode. real ver: %d.%d (Build %d)",
+ shell32_major,
+ shell32_minor,
+ shell32_build);
+ }
+ }
+ mOSString += compatibility_mode;
+
#else
struct utsname un;
if(uname(&un) != -1)
diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt
index e7458529be..e8302ab5eb 100644
--- a/indra/newview/CMakeLists.txt
+++ b/indra/newview/CMakeLists.txt
@@ -1376,7 +1376,7 @@ if (WINDOWS)
# sets the 'working directory' for debugging from visual studio.
if (NOT UNATTENDED)
add_custom_command(
- TARGET ${VIEWER_BINARY_NAME} PRE_BUILD
+ TARGET ${VIEWER_BINARY_NAME} POST_BUILD
COMMAND ${CMAKE_SOURCE_DIR}/tools/vstool/vstool.exe
ARGS
--solution
diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp
index a5ca06ce30..4f2d3e9645 100644
--- a/indra/newview/llappviewer.cpp
+++ b/indra/newview/llappviewer.cpp
@@ -985,7 +985,8 @@ bool LLAppViewer::mainLoop()
#endif
//memory leaking simulation
- LLFloaterMemLeak* mem_leak_instance = LLFloaterReg::getTypedInstance<LLFloaterMemLeak>("mem_leaking");
+ LLFloaterMemLeak* mem_leak_instance =
+ LLFloaterReg::findTypedInstance<LLFloaterMemLeak>("mem_leaking");
if(mem_leak_instance)
{
mem_leak_instance->idle() ;
@@ -1171,7 +1172,8 @@ bool LLAppViewer::mainLoop()
catch(std::bad_alloc)
{
//stop memory leaking simulation
- LLFloaterMemLeak* mem_leak_instance = LLFloaterReg::getTypedInstance<LLFloaterMemLeak>("mem_leaking");
+ LLFloaterMemLeak* mem_leak_instance =
+ LLFloaterReg::findTypedInstance<LLFloaterMemLeak>("mem_leaking");
if(mem_leak_instance)
{
mem_leak_instance->stop() ;
@@ -1199,7 +1201,8 @@ bool LLAppViewer::mainLoop()
llwarns << "Bad memory allocation when saveFinalSnapshot() is called!" << llendl ;
//stop memory leaking simulation
- LLFloaterMemLeak* mem_leak_instance = LLFloaterReg::getTypedInstance<LLFloaterMemLeak>("mem_leaking");
+ LLFloaterMemLeak* mem_leak_instance =
+ LLFloaterReg::findTypedInstance<LLFloaterMemLeak>("mem_leaking");
if(mem_leak_instance)
{
mem_leak_instance->stop() ;
diff --git a/indra/newview/llfloatertools.cpp b/indra/newview/llfloatertools.cpp
index 9854d2594b..386fb7f909 100644
--- a/indra/newview/llfloatertools.cpp
+++ b/indra/newview/llfloatertools.cpp
@@ -43,6 +43,7 @@
#include "llcheckboxctrl.h"
#include "llcombobox.h"
#include "lldraghandle.h"
+#include "llerror.h"
#include "llfloaterbuildoptions.h"
#include "llfloatermediasettings.h"
#include "llfloateropenobject.h"
@@ -1122,11 +1123,27 @@ void LLFloaterTools::getMediaState()
LLVOVolume* object = dynamic_cast<LLVOVolume*>(node->getObject());
if (NULL != object)
{
- if (!object->permModify() || object->isMediaDataBeingFetched())
+ if (!object->permModify())
{
+ LL_INFOS("LLFloaterTools: media")
+ << "Selection not editable due to lack of modify permissions on object id "
+ << object->getID() << LL_ENDL;
+
editable = false;
break;
}
+ // XXX DISABLE this for now, because when the fetch finally
+ // does come in, the state of this floater doesn't properly
+ // update. This needs more thought.
+// if (object->isMediaDataBeingFetched())
+// {
+// LL_INFOS("LLFloaterTools: media")
+// << "Selection not editable due to media data being fetched for object id "
+// << object->getID() << LL_ENDL;
+//
+// editable = false;
+// break;
+// }
}
}
}
diff --git a/indra/newview/llmediadataclient.cpp b/indra/newview/llmediadataclient.cpp
index 6666a03ee4..badef4c7ae 100755
--- a/indra/newview/llmediadataclient.cpp
+++ b/indra/newview/llmediadataclient.cpp
@@ -637,6 +637,9 @@ void LLObjectMediaNavigateClient::navigate(LLMediaDataClientObject *object, U8 t
sd_payload[LLTextureEntry::OBJECT_ID_KEY] = object->getID();
sd_payload[LLMediaEntry::CURRENT_URL_KEY] = url;
sd_payload[LLTextureEntry::TEXTURE_INDEX_KEY] = (LLSD::Integer)texture_index;
+
+ LL_INFOS("LLMediaDataClient") << "navigate() initiated: " << ll_print_sd(sd_payload) << LL_ENDL;
+
request(object, sd_payload);
}
diff --git a/indra/newview/llpanelprimmediacontrols.cpp b/indra/newview/llpanelprimmediacontrols.cpp
index 12ad070efd..aca0e1d5c7 100644
--- a/indra/newview/llpanelprimmediacontrols.cpp
+++ b/indra/newview/llpanelprimmediacontrols.cpp
@@ -54,6 +54,7 @@
#include "llpanelprimmediacontrols.h"
#include "llpluginclassmedia.h"
#include "llprogressbar.h"
+#include "llstring.h"
#include "llviewercontrol.h"
#include "llviewerparcelmgr.h"
#include "llviewermedia.h"
@@ -92,6 +93,7 @@ LLPanelPrimMediaControls::LLPanelPrimMediaControls() :
mCommitCallbackRegistrar.add("MediaCtrl.Forward", boost::bind(&LLPanelPrimMediaControls::onClickForward, this));
mCommitCallbackRegistrar.add("MediaCtrl.Home", boost::bind(&LLPanelPrimMediaControls::onClickHome, this));
mCommitCallbackRegistrar.add("MediaCtrl.Stop", boost::bind(&LLPanelPrimMediaControls::onClickStop, this));
+ mCommitCallbackRegistrar.add("MediaCtrl.MediaStop", boost::bind(&LLPanelPrimMediaControls::onClickMediaStop, this));
mCommitCallbackRegistrar.add("MediaCtrl.Reload", boost::bind(&LLPanelPrimMediaControls::onClickReload, this));
mCommitCallbackRegistrar.add("MediaCtrl.Play", boost::bind(&LLPanelPrimMediaControls::onClickPlay, this));
mCommitCallbackRegistrar.add("MediaCtrl.Pause", boost::bind(&LLPanelPrimMediaControls::onClickPause, this));
@@ -102,6 +104,8 @@ LLPanelPrimMediaControls::LLPanelPrimMediaControls() :
mCommitCallbackRegistrar.add("MediaCtrl.CommitVolumeUp", boost::bind(&LLPanelPrimMediaControls::onCommitVolumeUp, this));
mCommitCallbackRegistrar.add("MediaCtrl.CommitVolumeDown", boost::bind(&LLPanelPrimMediaControls::onCommitVolumeDown, this));
mCommitCallbackRegistrar.add("MediaCtrl.ToggleMute", boost::bind(&LLPanelPrimMediaControls::onToggleMute, this));
+ mCommitCallbackRegistrar.add("MediaCtrl.SkipBack", boost::bind(&LLPanelPrimMediaControls::onClickSkipBack, this));
+ mCommitCallbackRegistrar.add("MediaCtrl.SkipForward", boost::bind(&LLPanelPrimMediaControls::onClickSkipForward, this));
LLUICtrlFactory::getInstance()->buildPanel(this, "panel_prim_media_controls.xml");
mInactivityTimer.reset();
@@ -135,6 +139,8 @@ BOOL LLPanelPrimMediaControls::postBuild()
mMediaAddress = getChild<LLUICtrl>("media_address_url");
mMediaPlaySliderPanel = getChild<LLUICtrl>("media_play_position");
mMediaPlaySliderCtrl = getChild<LLUICtrl>("media_play_slider");
+ mSkipFwdCtrl = getChild<LLUICtrl>("skip_forward");
+ mSkipBackCtrl = getChild<LLUICtrl>("skip_back");
mVolumeCtrl = getChild<LLUICtrl>("media_volume");
mVolumeBtn = getChild<LLButton>("media_volume_button");
mVolumeUpCtrl = getChild<LLUICtrl>("volume_up");
@@ -145,6 +151,7 @@ BOOL LLPanelPrimMediaControls::postBuild()
mLeftBookend = getChild<LLUICtrl>("left_bookend");
mRightBookend = getChild<LLUICtrl>("right_bookend");
mBackgroundImage = LLUI::getUIImage(getString("control_background_image_name"));
+ LLStringUtil::convertToF32(getString("skip_step"), mSkipStep);
// These are currently removed...but getChild creates a "dummy" widget.
// This class handles them missing.
@@ -329,12 +336,17 @@ void LLPanelPrimMediaControls::updateShape()
mReloadCtrl->setVisible(FALSE);
mMediaStopCtrl->setVisible(has_focus);
mHomeCtrl->setVisible(FALSE);
- mBackCtrl->setEnabled(has_focus);
- mFwdCtrl->setEnabled(has_focus);
+ // No nav controls
+ mBackCtrl->setVisible(FALSE);
+ mFwdCtrl->setEnabled(FALSE);
mMediaAddressCtrl->setVisible(false);
mMediaAddressCtrl->setEnabled(false);
mMediaPlaySliderPanel->setVisible(has_focus && !mini_controls);
mMediaPlaySliderPanel->setEnabled(has_focus && !mini_controls);
+ mSkipFwdCtrl->setVisible(has_focus && !mini_controls);
+ mSkipFwdCtrl->setEnabled(has_focus && !mini_controls);
+ mSkipBackCtrl->setVisible(has_focus && !mini_controls);
+ mSkipBackCtrl->setEnabled(has_focus && !mini_controls);
mVolumeCtrl->setVisible(has_focus);
mVolumeUpCtrl->setVisible(has_focus);
@@ -435,6 +447,10 @@ void LLPanelPrimMediaControls::updateShape()
mMediaAddressCtrl->setEnabled(has_focus && !mini_controls);
mMediaPlaySliderPanel->setVisible(FALSE);
mMediaPlaySliderPanel->setEnabled(FALSE);
+ mSkipFwdCtrl->setVisible(FALSE);
+ mSkipFwdCtrl->setEnabled(FALSE);
+ mSkipBackCtrl->setVisible(FALSE);
+ mSkipBackCtrl->setEnabled(FALSE);
mVolumeCtrl->setVisible(FALSE);
mVolumeUpCtrl->setVisible(FALSE);
@@ -789,7 +805,7 @@ void LLPanelPrimMediaControls::onClickForward()
focusOnTarget();
LLViewerMediaImpl* impl = getTargetMediaImpl();
-
+
if (impl)
{
impl->navigateForward();
@@ -862,16 +878,53 @@ void LLPanelPrimMediaControls::onClickStop()
if(impl)
{
+ impl->navigateStop();
+ }
+}
+
+void LLPanelPrimMediaControls::onClickMediaStop()
+{
+ focusOnTarget();
+
+ LLViewerMediaImpl* impl = getTargetMediaImpl();
+
+ if(impl)
+ {
impl->stop();
}
}
+void LLPanelPrimMediaControls::onClickSkipBack()
+{
+ focusOnTarget();
+
+ LLViewerMediaImpl* impl =getTargetMediaImpl();
+
+ if (impl)
+ {
+ impl->skipBack(mSkipStep);
+ }
+}
+
+void LLPanelPrimMediaControls::onClickSkipForward()
+{
+ focusOnTarget();
+
+ LLViewerMediaImpl* impl = getTargetMediaImpl();
+
+ if (impl)
+ {
+ impl->skipForward(mSkipStep);
+ }
+}
+
void LLPanelPrimMediaControls::onClickZoom()
{
focusOnTarget();
nextZoomLevel();
}
+
void LLPanelPrimMediaControls::nextZoomLevel()
{
int index = 0;
diff --git a/indra/newview/llpanelprimmediacontrols.h b/indra/newview/llpanelprimmediacontrols.h
index 124fa9cce4..54fc4e343f 100644
--- a/indra/newview/llpanelprimmediacontrols.h
+++ b/indra/newview/llpanelprimmediacontrols.h
@@ -95,6 +95,9 @@ private:
void onClickPause();
void onClickStop();
void onClickZoom();
+ void onClickSkipBack();
+ void onClickSkipForward();
+ void onClickMediaStop();
void onCommitURL();
void updateZoom();
@@ -137,6 +140,8 @@ private:
LLUICtrl *mHomeCtrl;
LLUICtrl *mUnzoomCtrl;
LLUICtrl *mOpenCtrl;
+ LLUICtrl *mSkipBackCtrl;
+ LLUICtrl *mSkipFwdCtrl;
LLUICtrl *mZoomCtrl;
LLPanel *mMediaProgressPanel;
LLProgressBar *mMediaProgressBar;
@@ -154,6 +159,7 @@ private:
LLUICtrl *mLeftBookend;
LLUICtrl *mRightBookend;
LLUIImage* mBackgroundImage;
+ F32 mSkipStep;
LLUICtrl *mMediaPanelScroll;
LLButton *mScrollUpCtrl;
diff --git a/indra/newview/llviewermedia.cpp b/indra/newview/llviewermedia.cpp
index 3a7c54479b..e55523c11e 100644
--- a/indra/newview/llviewermedia.cpp
+++ b/indra/newview/llviewermedia.cpp
@@ -278,7 +278,7 @@ viewer_media_t LLViewerMedia::newMediaImpl(
}
else
{
- media_impl->stop();
+ media_impl->unload();
media_impl->mTextureId = texture_id;
media_impl->mMediaWidth = media_width;
media_impl->mMediaHeight = media_height;
@@ -1092,15 +1092,7 @@ void LLViewerMediaImpl::stop()
{
if(mMediaSource)
{
- if(mMediaSource->pluginSupportsMediaBrowser())
- {
- mMediaSource->browse_stop();
- }
- else
- {
- mMediaSource->stop();
- }
-
+ mMediaSource->stop();
// destroyMediaSource();
}
}
@@ -1133,6 +1125,40 @@ void LLViewerMediaImpl::seek(F32 time)
}
//////////////////////////////////////////////////////////////////////////////////////////
+void LLViewerMediaImpl::skipBack(F32 step_scale)
+{
+ if(mMediaSource)
+ {
+ if(mMediaSource->pluginSupportsMediaTime())
+ {
+ F64 back_step = mMediaSource->getCurrentTime() - (mMediaSource->getDuration()*step_scale);
+ if(back_step < 0.0)
+ {
+ back_step = 0.0;
+ }
+ mMediaSource->seek(back_step);
+ }
+ }
+}
+
+//////////////////////////////////////////////////////////////////////////////////////////
+void LLViewerMediaImpl::skipForward(F32 step_scale)
+{
+ if(mMediaSource)
+ {
+ if(mMediaSource->pluginSupportsMediaTime())
+ {
+ F64 forward_step = mMediaSource->getCurrentTime() + (mMediaSource->getDuration()*step_scale);
+ if(forward_step > mMediaSource->getDuration())
+ {
+ forward_step = mMediaSource->getDuration();
+ }
+ mMediaSource->seek(forward_step);
+ }
+ }
+}
+
+//////////////////////////////////////////////////////////////////////////////////////////
void LLViewerMediaImpl::setVolume(F32 volume)
{
mRequestedVolume = volume;
@@ -1339,21 +1365,7 @@ void LLViewerMediaImpl::navigateBack()
{
if (mMediaSource)
{
- if(mMediaSource->pluginSupportsMediaTime())
- {
- F64 step_scale = 0.02; // temp , can be changed
- F64 back_step = mMediaSource->getCurrentTime() - (mMediaSource->getDuration()*step_scale);
- if(back_step < 0.0)
- {
- back_step = 0.0;
- }
- mMediaSource->seek(back_step);
- //mMediaSource->start(-2.0);
- }
- else
- {
- mMediaSource->browse_back();
- }
+ mMediaSource->browse_back();
}
}
@@ -1362,21 +1374,7 @@ void LLViewerMediaImpl::navigateForward()
{
if (mMediaSource)
{
- if(mMediaSource->pluginSupportsMediaTime())
- {
- F64 step_scale = 0.02; // temp , can be changed
- F64 forward_step = mMediaSource->getCurrentTime() + (mMediaSource->getDuration()*step_scale);
- if(forward_step > mMediaSource->getDuration())
- {
- forward_step = mMediaSource->getDuration();
- }
- mMediaSource->seek(forward_step);
- //mMediaSource->start(2.0);
- }
- else
- {
- mMediaSource->browse_forward();
- }
+ mMediaSource->browse_forward();
}
}
@@ -1525,7 +1523,6 @@ void LLViewerMediaImpl::navigateStop()
{
mMediaSource->browse_stop();
}
-
}
//////////////////////////////////////////////////////////////////////////////////////////
diff --git a/indra/newview/llviewermedia.h b/indra/newview/llviewermedia.h
index f4afce6c4c..ac12112ed4 100644
--- a/indra/newview/llviewermedia.h
+++ b/indra/newview/llviewermedia.h
@@ -149,6 +149,8 @@ public:
void pause();
void start();
void seek(F32 time);
+ void skipBack(F32 step_scale);
+ void skipForward(F32 step_scale);
void setVolume(F32 volume);
void updateVolume();
F32 getVolume();
diff --git a/indra/newview/llviewerparcelmedia.cpp b/indra/newview/llviewerparcelmedia.cpp
index 7559fd8e72..f61dbb1b39 100644
--- a/indra/newview/llviewerparcelmedia.cpp
+++ b/indra/newview/llviewerparcelmedia.cpp
@@ -218,7 +218,7 @@ void LLViewerParcelMedia::play(LLParcel* parcel)
LL_DEBUGS("Media") << "new media impl with mime type " << mime_type << ", url " << media_url << LL_ENDL;
// Delete the old one first so they don't fight over the texture.
- sMediaImpl->stop();
+ sMediaImpl = NULL;
sMediaImpl = LLViewerMedia::newMediaImpl(
placeholder_texture_id,
@@ -261,8 +261,7 @@ void LLViewerParcelMedia::stop()
// We need to remove the media HUD if it is up.
LLViewerMediaFocus::getInstance()->clearFocus();
- // This will kill the media instance.
- sMediaImpl->stop();
+ // This will unload & kill the media instance.
sMediaImpl = NULL;
}
diff --git a/indra/newview/llvoiceclient.cpp b/indra/newview/llvoiceclient.cpp
index 5fedfc943b..479cf5a04d 100644
--- a/indra/newview/llvoiceclient.cpp
+++ b/indra/newview/llvoiceclient.cpp
@@ -1867,7 +1867,7 @@ void LLVoiceClient::stateMachine()
}
else
{
- LL_WARNS("Voice") << "region doesn't have ProvisionVoiceAccountRequest capability!" << LL_ENDL;
+ LL_WARNS_ONCE("Voice") << "region doesn't have ProvisionVoiceAccountRequest capability!" << LL_ENDL;
}
}
}
diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp
index 5a67e64bbd..428af5380c 100644
--- a/indra/newview/llvovolume.cpp
+++ b/indra/newview/llvovolume.cpp
@@ -1734,9 +1734,9 @@ void LLVOVolume::syncMediaData(S32 texture_index, const LLSD &media_data, bool m
}
LLTextureEntry *te = getTE(texture_index);
- //llinfos << "BEFORE: texture_index = " << texture_index
- // << " hasMedia = " << te->hasMedia() << " : "
- // << ((NULL == te->getMediaData()) ? "NULL MEDIA DATA" : ll_pretty_print_sd(te->getMediaData()->asLLSD())) << llendl;
+ LL_DEBUGS("MediaOnAPrim") << "BEFORE: texture_index = " << texture_index
+ << " hasMedia = " << te->hasMedia() << " : "
+ << ((NULL == te->getMediaData()) ? "NULL MEDIA DATA" : ll_pretty_print_sd(te->getMediaData()->asLLSD())) << llendl;
std::string previous_url;
LLMediaEntry* mep = te->getMediaData();
@@ -1776,9 +1776,9 @@ void LLVOVolume::syncMediaData(S32 texture_index, const LLSD &media_data, bool m
removeMediaImpl(texture_index);
}
- //llinfos << "AFTER: texture_index = " << texture_index
- // << " hasMedia = " << te->hasMedia() << " : "
- // << ((NULL == te->getMediaData()) ? "NULL MEDIA DATA" : ll_pretty_print_sd(te->getMediaData()->asLLSD())) << llendl;
+ LL_DEBUGS("MediaOnAPrim") << "AFTER: texture_index = " << texture_index
+ << " hasMedia = " << te->hasMedia() << " : "
+ << ((NULL == te->getMediaData()) ? "NULL MEDIA DATA" : ll_pretty_print_sd(te->getMediaData()->asLLSD())) << llendl;
}
void LLVOVolume::mediaNavigateBounceBack(U8 texture_index)
@@ -1801,7 +1801,7 @@ void LLVOVolume::mediaNavigateBounceBack(U8 texture_index)
}
if (! url.empty())
{
- LL_INFOS("LLMediaDataClient") << "bouncing back to URL: " << url << LL_ENDL;
+ LL_INFOS("MediaOnAPrim") << "bouncing back to URL: " << url << LL_ENDL;
impl->navigateTo(url, "", false, true);
}
}
diff --git a/indra/newview/skins/default/xui/en/panel_preferences_privacy.xml b/indra/newview/skins/default/xui/en/panel_preferences_privacy.xml
index 1b9a99f90b..23832ba120 100644
--- a/indra/newview/skins/default/xui/en/panel_preferences_privacy.xml
+++ b/indra/newview/skins/default/xui/en/panel_preferences_privacy.xml
@@ -86,7 +86,16 @@
name="autoplay_enabled"
top_pad="10"
width="350" />
- <text
+ <check_box
+ control_name="ParcelMediaAutoPlayEnable"
+ height="16"
+ label="Automatically Play Parcel Media"
+ layout="topleft"
+ left="30"
+ name="parcel_autoplay_enabled"
+ top_pad="10"
+ width="350" />
+ <text
type="string"
length="1"
follows="left|top"
diff --git a/indra/newview/skins/default/xui/en/panel_prim_media_controls.xml b/indra/newview/skins/default/xui/en/panel_prim_media_controls.xml
index 98025e28db..88049fe7d1 100644
--- a/indra/newview/skins/default/xui/en/panel_prim_media_controls.xml
+++ b/indra/newview/skins/default/xui/en/panel_prim_media_controls.xml
@@ -8,6 +8,7 @@
mouse_opaque="false"
width="800">
<string name="control_background_image_name">Inspector_Background</string>
+ <string name="skip_step">0.2</string>
<panel
name="media_region"
bottom="125"
@@ -86,7 +87,7 @@
auto_resize="false"
height="22"
layout="topleft"
- tool_tip="Step back"
+ tool_tip="Navigate back"
width="22"
left="0"
top_delta="4">
@@ -111,7 +112,7 @@
hover_glow_amount="0.15"
height="22"
layout="topleft"
- tool_tip="Step forward"
+ tool_tip="Navigate forward"
top_delta="0"
min_width="22"
width="22">
@@ -165,7 +166,7 @@
min_width="22"
width="22">
<button.commit_callback
- function="MediaCtrl.Stop" />
+ function="MediaCtrl.MediaStop" />
</button>
</layout_panel>
<layout_panel
@@ -360,6 +361,55 @@ function="MediaCtrl.CommitURL" />
</slider_bar>
</layout_panel>
<layout_panel
+ name="skip_back"
+ auto_resize="false"
+ user_resize="false"
+ layout="topleft"
+ min_width="22"
+ width="22">
+ <button
+ image_overlay="SkipBackward_Off"
+ image_disabled="PushButton_Disabled"
+ image_disabled_selected="PushButton_Disabled"
+ image_selected="PushButton_Selected"
+ image_unselected="PushButton_Off"
+ hover_glow_amount="0.15"
+ auto_resize="false"
+ height="22"
+ layout="topleft"
+ tool_tip="Step back"
+ top="-14"
+ width="22"
+ left="0">
+ <button.commit_callback
+ function="MediaCtrl.SkipBack" />
+ </button>
+ </layout_panel>
+ <layout_panel
+ name="skip_forward"
+ auto_resize="false"
+ user_resize="false"
+ layout="topleft"
+ min_width="22"
+ width="22">
+ <button
+ image_overlay="SkipForward_Off"
+ image_disabled="PushButton_Disabled"
+ image_disabled_selected="PushButton_Disabled"
+ image_selected="PushButton_Selected"
+ image_unselected="PushButton_Off"
+ hover_glow_amount="0.15"
+ height="22"
+ layout="topleft"
+ tool_tip="Step forward"
+ top="-14"
+ min_width="22"
+ width="22">
+ <button.commit_callback
+ function="MediaCtrl.SkipForward" />
+ </button>
+ </layout_panel>
+ <layout_panel
name="media_volume"
auto_resize="false"
user_resize="false"