diff options
Diffstat (limited to 'indra/newview')
-rw-r--r-- | indra/newview/app_settings/settings.xml | 33 | ||||
-rw-r--r-- | indra/newview/app_settings/settings_per_account.xml | 11 | ||||
-rw-r--r-- | indra/newview/llbottomtray.cpp | 11 | ||||
-rw-r--r-- | indra/newview/llfloatersounddevices.cpp | 2 | ||||
-rw-r--r-- | indra/newview/llpanellogin.cpp | 5 | ||||
-rw-r--r-- | indra/newview/llpanelvoicedevicesettings.cpp | 36 | ||||
-rw-r--r-- | indra/newview/llviewermessage.cpp | 6 | ||||
-rw-r--r-- | indra/newview/llviewertexturelist.cpp | 31 | ||||
-rw-r--r-- | indra/newview/llvoicechannel.cpp | 8 | ||||
-rw-r--r-- | indra/newview/skins/default/xui/en/floater_postcard.xml | 1 | ||||
-rw-r--r-- | indra/newview/skins/default/xui/en/floater_script_debug_panel.xml | 1 | ||||
-rw-r--r-- | indra/newview/skins/default/xui/en/floater_sound_devices.xml | 21 | ||||
-rw-r--r-- | indra/newview/skins/default/xui/en/panel_sound_devices.xml | 8 | ||||
-rw-r--r-- | indra/newview/skins/minimal/xui/en/panel_bottomtray.xml | 2 |
14 files changed, 124 insertions, 52 deletions
diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index ac52cff49a..33c5e533be 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -4284,6 +4284,39 @@ <key>Value</key> <real>0.25</real> </map> + <key>Jpeg2000AdvancedCompression</key> + <map> + <key>Comment</key> + <string>Use advanced Jpeg2000 compression options (precincts, blocks, ordering, markers)</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> + <key>Jpeg2000PrecinctsSize</key> + <map> + <key>Comment</key> + <string>Size of image precincts. Assumed square and same for all levels. Must be power of 2.</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>S32</string> + <key>Value</key> + <integer>256</integer> + </map> + <key>Jpeg2000BlocksSize</key> + <map> + <key>Comment</key> + <string>Size of encoding blocks. Assumed square and same for all levels. Must be power of 2. Max 64, Min 4.</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>S32</string> + <key>Value</key> + <integer>64</integer> + </map> <key>KeepAspectForSnapshot</key> <map> <key>Comment</key> diff --git a/indra/newview/app_settings/settings_per_account.xml b/indra/newview/app_settings/settings_per_account.xml index 8efec1cff0..ff24efaf2c 100644 --- a/indra/newview/app_settings/settings_per_account.xml +++ b/indra/newview/app_settings/settings_per_account.xml @@ -44,6 +44,17 @@ <key>Value</key> <integer>0</integer> </map> + <key>LastPostcardRecipient</key> + <map> + <key>Comment</key> + <string>Last recipient of postcard</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>String</string> + <key>Value</key> + <string /> + </map> <key>LogNearbyChat</key> <map> <key>Comment</key> diff --git a/indra/newview/llbottomtray.cpp b/indra/newview/llbottomtray.cpp index c72cdfd1dc..f51552aae5 100644 --- a/indra/newview/llbottomtray.cpp +++ b/indra/newview/llbottomtray.cpp @@ -559,7 +559,7 @@ BOOL LLBottomTray::postBuild() else { LLTransientFloaterMgr::getInstance()->addControlView(getChild<LLButton>("speak_btn")); - LLTransientFloaterMgr::getInstance()->addControlView(getChild<LLButton>("speak_flyout_btn")); + LLTransientFloaterMgr::getInstance()->addControlView(getChild<LLButton>("flyout_btn")); } @@ -1591,7 +1591,7 @@ void LLBottomTray::initResizeStateContainers() // because it resets chatbar's width according to resize logic. void LLBottomTray::initButtonsVisibility() { - setVisibleAndFitWidths(RS_BUTTON_SPEAK, gSavedSettings.getBOOL("EnableVoiceChat")); + setVisibleAndFitWidths(RS_BUTTON_SPEAK, gSavedSettings.getBOOL("EnableVoiceChat") || !mSpeakBtn ); setVisibleAndFitWidths(RS_BUTTON_GESTURES, gSavedSettings.getBOOL("ShowGestureButton")); setVisibleAndFitWidths(RS_BUTTON_MOVEMENT, gSavedSettings.getBOOL("ShowMoveButton")); setVisibleAndFitWidths(RS_BUTTON_CAMERA, gSavedSettings.getBOOL("ShowCameraButton")); @@ -1605,7 +1605,12 @@ void LLBottomTray::initButtonsVisibility() void LLBottomTray::setButtonsControlsAndListeners() { - gSavedSettings.getControl("EnableVoiceChat")->getSignal()->connect(boost::bind(&LLBottomTray::toggleShowButton, RS_BUTTON_SPEAK, _2)); + // always show the speak panel if using the basic skin + if (mSpeakBtn) + { + gSavedSettings.getControl("EnableVoiceChat")->getSignal()->connect(boost::bind(&LLBottomTray::toggleShowButton, RS_BUTTON_SPEAK, _2)); + } + gSavedSettings.getControl("ShowGestureButton")->getSignal()->connect(boost::bind(&LLBottomTray::toggleShowButton, RS_BUTTON_GESTURES, _2)); gSavedSettings.getControl("ShowMoveButton")->getSignal()->connect(boost::bind(&LLBottomTray::toggleShowButton, RS_BUTTON_MOVEMENT, _2)); gSavedSettings.getControl("ShowCameraButton")->getSignal()->connect(boost::bind(&LLBottomTray::toggleShowButton, RS_BUTTON_CAMERA, _2)); diff --git a/indra/newview/llfloatersounddevices.cpp b/indra/newview/llfloatersounddevices.cpp index 3903b9b015..9fe7c7f9dd 100644 --- a/indra/newview/llfloatersounddevices.cpp +++ b/indra/newview/llfloatersounddevices.cpp @@ -56,7 +56,7 @@ BOOL LLFloaterSoundDevices::postBuild() { LLTransientDockableFloater::postBuild(); - LLView *anchor_panel = LLBottomTray::getInstance()->getChild<LLView>("speak_flyout_btn"); + LLView *anchor_panel = LLBottomTray::getInstance()->getChild<LLView>("flyout_btn"); setDockControl(new LLDockControl(anchor_panel, this, getDockTongue(), LLDockControl::TOP)); setIsChrome(TRUE); diff --git a/indra/newview/llpanellogin.cpp b/indra/newview/llpanellogin.cpp index 4ac3a248d3..27f341b4f6 100644 --- a/indra/newview/llpanellogin.cpp +++ b/indra/newview/llpanellogin.cpp @@ -769,7 +769,10 @@ void LLPanelLogin::loadLoginPage() gViewerWindow->setMenuBackgroundColor(false, !LLGridManager::getInstance()->isInProductionGrid()); LLMediaCtrl* web_browser = sInstance->getChild<LLMediaCtrl>("login_html"); - web_browser->navigateTo( oStr.str(), "text/html" ); + if (web_browser->getCurrentNavUrl() != oStr.str()) + { + web_browser->navigateTo( oStr.str(), "text/html" ); + } } void LLPanelLogin::handleMediaEvent(LLPluginClassMedia* /*self*/, EMediaEvent event) diff --git a/indra/newview/llpanelvoicedevicesettings.cpp b/indra/newview/llpanelvoicedevicesettings.cpp index 71bb4a5584..dc87bd0077 100644 --- a/indra/newview/llpanelvoicedevicesettings.cpp +++ b/indra/newview/llpanelvoicedevicesettings.cpp @@ -221,23 +221,7 @@ void LLPanelVoiceDeviceSettings::refresh() iter != LLVoiceClient::getInstance()->getCaptureDevices().end(); iter++) { - // Lets try to localize some system device names. EXT-8375 - std::string device_name = *iter; - LLStringUtil::toLower(device_name); //compare in low case - if ("default system device" == device_name) - { - device_name = getString(device_name); - } - else if ("no device" == device_name) - { - device_name = getString(device_name); - } - else - { - // restore original value - device_name = *iter; - } - mCtrlInputDevices->add(device_name, ADD_BOTTOM ); + mCtrlInputDevices->add( *iter, ADD_BOTTOM ); } if(!mCtrlInputDevices->setSimple(mInputDevice)) @@ -254,23 +238,7 @@ void LLPanelVoiceDeviceSettings::refresh() for(iter= LLVoiceClient::getInstance()->getRenderDevices().begin(); iter != LLVoiceClient::getInstance()->getRenderDevices().end(); iter++) { - // Lets try to localize some system device names. EXT-8375 - std::string device_name = *iter; - LLStringUtil::toLower(device_name); //compare in low case - if ("default system device" == device_name) - { - device_name = getString(device_name); - } - else if ("no device" == device_name) - { - device_name = getString(device_name); - } - else - { - // restore original value - device_name = *iter; - } - mCtrlOutputDevices->add(device_name, ADD_BOTTOM ); + mCtrlOutputDevices->add( *iter, ADD_BOTTOM ); } if(!mCtrlOutputDevices->setSimple(mOutputDevice)) diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp index fea5345f9c..298e789f65 100644 --- a/indra/newview/llviewermessage.cpp +++ b/indra/newview/llviewermessage.cpp @@ -5373,6 +5373,12 @@ bool attempt_standard_notification(LLMessageSystem* msgsystem) { // notification was specified using the new mechanism, so we can just handle it here std::string notificationID; + msgsystem->getStringFast(_PREHASH_AlertInfo, _PREHASH_Message, notificationID);
+ if (!LLNotifications::getInstance()->templateExists(notificationID))
+ {
+ return false;
+ } + std::string llsdRaw; LLSD llsdBlock; msgsystem->getStringFast(_PREHASH_AlertInfo, _PREHASH_Message, notificationID); diff --git a/indra/newview/llviewertexturelist.cpp b/indra/newview/llviewertexturelist.cpp index d331779e1f..33e7328cd7 100644 --- a/indra/newview/llviewertexturelist.cpp +++ b/indra/newview/llviewertexturelist.cpp @@ -946,16 +946,19 @@ BOOL LLViewerTextureList::createUploadFile(const std::string& filename, LLPointer<LLImageFormatted> image = LLImageFormatted::createFromType(codec); if (image.isNull()) { + image->setLastError("Couldn't open the image to be uploaded."); return FALSE; } if (!image->load(filename)) { + image->setLastError("Couldn't load the image to be uploaded."); return FALSE; } // Decompress or expand it in a raw image structure LLPointer<LLImageRaw> raw_image = new LLImageRaw; if (!image->decode(raw_image, 0.0f)) { + image->setLastError("Couldn't decode the image to be uploaded."); return FALSE; } // Check the image constraints @@ -966,8 +969,15 @@ BOOL LLViewerTextureList::createUploadFile(const std::string& filename, } // Convert to j2c (JPEG2000) and save the file locally LLPointer<LLImageJ2C> compressedImage = convertToUploadFile(raw_image); + if (compressedImage.isNull()) + { + image->setLastError("Couldn't convert the image to jpeg2000."); + llinfos << "Couldn't convert to j2c, file : " << filename << llendl; + return FALSE; + } if (!compressedImage->save(out_filename)) { + image->setLastError("Couldn't create the jpeg2000 image for upload."); llinfos << "Couldn't create output file : " << out_filename << llendl; return FALSE; } @@ -975,6 +985,7 @@ BOOL LLViewerTextureList::createUploadFile(const std::string& filename, LLPointer<LLImageJ2C> integrity_test = new LLImageJ2C; if (!integrity_test->loadAndValidate( out_filename )) { + image->setLastError("The created jpeg2000 image is corrupt."); llinfos << "Image file : " << out_filename << " is corrupt" << llendl; return FALSE; } @@ -992,7 +1003,25 @@ LLPointer<LLImageJ2C> LLViewerTextureList::convertToUploadFile(LLPointer<LLImage (raw_image->getWidth() * raw_image->getHeight() <= LL_IMAGE_REZ_LOSSLESS_CUTOFF * LL_IMAGE_REZ_LOSSLESS_CUTOFF)) compressedImage->setReversible(TRUE); - compressedImage->encode(raw_image, 0.0f); + + if (gSavedSettings.getBOOL("Jpeg2000AdvancedCompression")) + { + // This test option will create jpeg2000 images with precincts for each level, RPCL ordering + // and PLT markers. The block size is also optionally modifiable. + // Note: the images hence created are compatible with older versions of the viewer. + // Read the blocks and precincts size settings + S32 block_size = gSavedSettings.getS32("Jpeg2000BlocksSize"); + S32 precinct_size = gSavedSettings.getS32("Jpeg2000PrecinctsSize"); + llinfos << "Advanced JPEG2000 Compression: precinct = " << precinct_size << ", block = " << block_size << llendl; + compressedImage->initEncode(*raw_image, block_size, precinct_size, 0); + } + + if (!compressedImage->encode(raw_image, 0.0f)) + { + llinfos << "convertToUploadFile : encode returns with error!!" << llendl; + // Clear up the pointer so we don't leak that one + compressedImage = NULL; + } return compressedImage; } diff --git a/indra/newview/llvoicechannel.cpp b/indra/newview/llvoicechannel.cpp index a71539266d..b921b7a481 100644 --- a/indra/newview/llvoicechannel.cpp +++ b/indra/newview/llvoicechannel.cpp @@ -412,6 +412,7 @@ void LLVoiceChannel::doSetState(const EState& new_state) { EState old_state = mState; mState = new_state; + if (!mStateChangedCallback.empty()) mStateChangedCallback(old_state, mState, mCallDirection, mCallEndedByAgent); } @@ -846,8 +847,11 @@ void LLVoiceChannelP2P::activate() // otherwise answering the call else { - LLVoiceClient::getInstance()->answerInvite(mSessionHandle); - + if (!LLVoiceClient::getInstance()->answerInvite(mSessionHandle)) + { + handleError(ERROR_UNKNOWN); + return; + } // using the session handle invalidates it. Clear it out here so we can't reuse it by accident. mSessionHandle.clear(); } diff --git a/indra/newview/skins/default/xui/en/floater_postcard.xml b/indra/newview/skins/default/xui/en/floater_postcard.xml index b4ecedd981..8da35e9d7f 100644 --- a/indra/newview/skins/default/xui/en/floater_postcard.xml +++ b/indra/newview/skins/default/xui/en/floater_postcard.xml @@ -36,6 +36,7 @@ Recipient's Email: </text> <line_editor + control_name="LastPostcardRecipient" follows="left|top" height="20" layout="topleft" diff --git a/indra/newview/skins/default/xui/en/floater_script_debug_panel.xml b/indra/newview/skins/default/xui/en/floater_script_debug_panel.xml index d1db5c17ba..ce96ea232e 100644 --- a/indra/newview/skins/default/xui/en/floater_script_debug_panel.xml +++ b/indra/newview/skins/default/xui/en/floater_script_debug_panel.xml @@ -20,5 +20,6 @@ parse_highlights="true" read_only="true" width="420" + track_bottom="true" word_wrap="true" /> </floater> diff --git a/indra/newview/skins/default/xui/en/floater_sound_devices.xml b/indra/newview/skins/default/xui/en/floater_sound_devices.xml index c7c7a05af2..304987c3d5 100644 --- a/indra/newview/skins/default/xui/en/floater_sound_devices.xml +++ b/indra/newview/skins/default/xui/en/floater_sound_devices.xml @@ -11,7 +11,7 @@ save_rect="true" single_instance="true" bevel_style="in" - height="140" + height="164" layout="topleft" name="floater_sound_devices" title="Sound Devices" @@ -25,4 +25,23 @@ left="2" top="26" class="panel_voice_device_settings"/> + <text + name="voice_label" + top="136" + left="12" + height="14" + width="80" + layout="topleft" + >Voice Chat</text> + <check_box + layout="topleft" + control_name="EnableVoiceChat" + follows="bottom|left" + top="138" + left="80" + name="enable_voice" + width="100" + height="14" + label="Enabled" + /> </floater> diff --git a/indra/newview/skins/default/xui/en/panel_sound_devices.xml b/indra/newview/skins/default/xui/en/panel_sound_devices.xml index 9812281323..ccae7c5350 100644 --- a/indra/newview/skins/default/xui/en/panel_sound_devices.xml +++ b/indra/newview/skins/default/xui/en/panel_sound_devices.xml @@ -11,14 +11,6 @@ name="default_text"> Default </panel.string> - <panel.string - name="default system device"> - Default system device - </panel.string> - <panel.string - name="no device"> - No device - </panel.string> <icon height="18" image_name="Microphone_On" diff --git a/indra/newview/skins/minimal/xui/en/panel_bottomtray.xml b/indra/newview/skins/minimal/xui/en/panel_bottomtray.xml index 237af61717..d722c54081 100644 --- a/indra/newview/skins/minimal/xui/en/panel_bottomtray.xml +++ b/indra/newview/skins/minimal/xui/en/panel_bottomtray.xml @@ -115,7 +115,7 @@ top="5" left="0" height="23" - name="speak_flyout_btn" + name="flyout_btn" label="" tab_stop="false" tool_tip="Change your sound preferences" |