diff options
50 files changed, 404 insertions, 493 deletions
diff --git a/indra/llcharacter/llcharacter.cpp b/indra/llcharacter/llcharacter.cpp index 528a7bb4a5..40a9752268 100644 --- a/indra/llcharacter/llcharacter.cpp +++ b/indra/llcharacter/llcharacter.cpp @@ -181,16 +181,18 @@ void LLCharacter::requestStopMotion( LLMotion* motion) // updateMotions() //----------------------------------------------------------------------------- static LLFastTimer::DeclareTimer FTM_UPDATE_ANIMATION("Update Animation"); +static LLFastTimer::DeclareTimer FTM_UPDATE_HIDDEN_ANIMATION("Update Hidden Anim"); void LLCharacter::updateMotions(e_update_t update_type) { - LLFastTimer t(FTM_UPDATE_ANIMATION); if (update_type == HIDDEN_UPDATE) { + LLFastTimer t(FTM_UPDATE_HIDDEN_ANIMATION); mMotionController.updateMotionsMinimal(); } else { + LLFastTimer t(FTM_UPDATE_ANIMATION); // unpause if the number of outstanding pause requests has dropped to the initial one if (mMotionController.isPaused() && mPauseRequest->getNumRefs() == 1) { diff --git a/indra/llui/llconsole.cpp b/indra/llui/llconsole.cpp index 0237c80efa..a4f69e7ac1 100644 --- a/indra/llui/llconsole.cpp +++ b/indra/llui/llconsole.cpp @@ -244,23 +244,6 @@ void LLConsole::draw() } } -void LLConsole::addLine(const std::string& utf8line) -{ - LLWString wline = utf8str_to_wstring(utf8line); - addLine(wline, 0.f, LLColor4(1.f, 1.f, 1.f, 1.f)); -} - -void LLConsole::addLine(const LLWString& wline) -{ - addLine(wline, 0.f, LLColor4(1.f, 1.f, 1.f, 1.f)); -} - -void LLConsole::addLine(const std::string& utf8line, F32 size, const LLColor4 &color) -{ - LLWString wline = utf8str_to_wstring(utf8line); - addLine(wline, size, color); -} - //Generate highlight color segments for this paragraph. Pass in default color of paragraph. void LLConsole::Paragraph::makeParagraphColorSegments (const LLColor4 &color) { @@ -383,21 +366,45 @@ void LLConsole::Paragraph::updateLines(F32 screen_width, const LLFontGL* font, b //Pass in the string and the default color for this block of text. LLConsole::Paragraph::Paragraph (LLWString str, const LLColor4 &color, F32 add_time, const LLFontGL* font, F32 screen_width) - : mParagraphText(str), mAddTime(add_time), mMaxWidth(-1) +: mParagraphText(str), mAddTime(add_time), mMaxWidth(-1) { makeParagraphColorSegments(color); updateLines( screen_width, font ); } -void LLConsole::addLine(const LLWString& wline, F32 size, const LLColor4 &color) +// called once per frame regardless of console visibility +// static +void LLConsole::updateClass() { - Paragraph paragraph(wline, color, mTimer.getElapsedTimeF32(), mFont, (F32)getRect().getWidth() ); - - mParagraphs.push_back ( paragraph ); + LLInstanceTrackerScopedGuard guard; + + for (instance_iter it = guard.beginInstances(); it != guard.endInstances(); ++it) + { + it->update(); + } +} + +void LLConsole::update() +{ + { + LLMutexLock lock(&mMutex); + + while (!mLines.empty()) + { + mParagraphs.push_back( + Paragraph( mLines.front(), + LLColor4::white, + mTimer.getElapsedTimeF32(), + mFont, + (F32)getRect().getWidth())); + mLines.pop_front(); + } + } // remove old paragraphs which can't possibly be visible any more. ::draw() will do something similar but more conservative - we do this here because ::draw() isn't guaranteed to ever be called! (i.e. the console isn't visible) - while ((S32)mParagraphs.size() > llmax((S32)0, (S32)(mMaxLines))) - { - mParagraphs.pop_front(); - } + while ((S32)mParagraphs.size() > llmax((S32)0, (S32)(mMaxLines))) + { + mParagraphs.pop_front(); + } } + diff --git a/indra/llui/llconsole.h b/indra/llui/llconsole.h index 4719950f28..f38e2bc9c2 100644 --- a/indra/llui/llconsole.h +++ b/indra/llui/llconsole.h @@ -40,7 +40,7 @@ class LLSD; -class LLConsole : public LLFixedBuffer, public LLUICtrl +class LLConsole : public LLFixedBuffer, public LLUICtrl, public LLInstanceTracker<LLConsole> { public: typedef enum e_font_size @@ -68,6 +68,9 @@ protected: friend class LLUICtrlFactory; public: + // call once per frame to pull data out of LLFixedBuffer + static void updateClass(); + //A paragraph color segment defines the color of text in a line //of text that was received for console display. It has no //notion of line wraps, screen position, or the text it contains. @@ -139,14 +142,12 @@ public: // -1 = monospace, 0 means small, font size = 1 means big void setFontSize(S32 size_index); - void addLine(const std::string& utf8line, F32 size, const LLColor4 &color); - void addLine(const LLWString& wline, F32 size, const LLColor4 &color); // Overrides /*virtual*/ void draw(); - /*virtual*/ void addLine(const std::string& utf8line); - /*virtual*/ void addLine(const LLWString& line); private: + void update(); + F32 mLinePersistTime; // Age at which to stop drawing. F32 mFadeTime; // Age at which to start fading const LLFontGL* mFont; diff --git a/indra/llui/llmultisliderctrl.cpp b/indra/llui/llmultisliderctrl.cpp index cb81c39103..50942e55ca 100644 --- a/indra/llui/llmultisliderctrl.cpp +++ b/indra/llui/llmultisliderctrl.cpp @@ -331,6 +331,10 @@ void LLMultiSliderCtrl::updateText() void LLMultiSliderCtrl::onEditorCommit( LLUICtrl* ctrl, const LLSD& userdata) { LLMultiSliderCtrl* self = dynamic_cast<LLMultiSliderCtrl*>(ctrl->getParent()); + llassert(self); + if (!self) // cast failed - wrong type! :O + return; + if (!ctrl) return; diff --git a/indra/llui/lltabcontainer.cpp b/indra/llui/lltabcontainer.cpp index fe699cfa01..13340e7ded 100644 --- a/indra/llui/lltabcontainer.cpp +++ b/indra/llui/lltabcontainer.cpp @@ -1631,14 +1631,9 @@ void LLTabContainer::setTabImage(LLPanel* child, LLIconCtrl* icon) void LLTabContainer::reshapeTuple(LLTabTuple* tuple) { static LLUICachedControl<S32> tab_padding ("UITabPadding", 0); - static LLUICachedControl<S32> image_top_padding ("UIButtonImageTopPadding", 2); - static LLUICachedControl<S32> image_bottom_padding ("UIButtonImageBottomPadding", 2); if (!mIsVertical) { - tuple->mButton->setImageOverlayTopPad(image_top_padding); - tuple->mButton->setImageOverlayBottomPad(image_bottom_padding); - // remove current width from total tab strip width mTotalTabWidth -= tuple->mButton->getRect().getWidth(); diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index db4e0b5afd..d0c2f3cb34 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -8456,6 +8456,17 @@ <key>Value</key> <integer>0</integer> </map> + <key>ShowVoiceVisualizersInCalls</key> + <map> + <key>Comment</key> + <string>Enables in-world voice visualizers, voice gestures and lip-sync while in group or P2P calls.</string> + <key>Persist</key> + <integer>1</integer> + <key>Type</key> + <string>Boolean</string> + <key>Value</key> + <integer>0</integer> + </map> <key>ShowVolumeSettingsPopup</key> <map> <key>Comment</key> @@ -9949,28 +9960,6 @@ <key>Value</key> <integer>15</integer> </map> - <key>UIButtonImageTopPadding</key> - <map> - <key>Comment</key> - <string>Button Overlay Image Top Padding</string> - <key>Persist</key> - <integer>1</integer> - <key>Type</key> - <string>S32</string> - <key>Value</key> - <integer>2</integer> - </map> - <key>UIButtonImageBottomPadding</key> - <map> - <key>Comment</key> - <string>Button Overlay Image Bottom Padding</string> - <key>Persist</key> - <integer>1</integer> - <key>Type</key> - <string>S32</string> - <key>Value</key> - <integer>2</integer> - </map> <key>UploadBakedTexOld</key> <map> <key>Comment</key> diff --git a/indra/newview/llagentui.cpp b/indra/newview/llagentui.cpp index 7404fe5bc4..72ab9235cf 100644 --- a/indra/newview/llagentui.cpp +++ b/indra/newview/llagentui.cpp @@ -150,11 +150,17 @@ BOOL LLAgentUI::buildLocationString(std::string& str, ELocationFormat fmt,const sim_access_string.c_str()); break; case LOCATION_FORMAT_NO_MATURITY: - case LOCATION_FORMAT_FULL: buffer = llformat("%s (%d, %d, %d)", region_name.c_str(), pos_x, pos_y, pos_z); break; + case LOCATION_FORMAT_FULL: + buffer = llformat("%s (%d, %d, %d)%s%s", + region_name.c_str(), + pos_x, pos_y, pos_z, + sim_access_string.empty() ? "" : " - ", + sim_access_string.c_str()); + break; } } else diff --git a/indra/newview/llagentwearables.cpp b/indra/newview/llagentwearables.cpp index 6620780b27..6078620e87 100644 --- a/indra/newview/llagentwearables.cpp +++ b/indra/newview/llagentwearables.cpp @@ -1290,25 +1290,29 @@ void LLAgentWearables::makeNewOutfit(const std::string& new_folder_name, j, new_wearable, todo); - if (isWearableCopyable((EWearableType)type, j)) + llassert(item); + if (item) { - copy_inventory_item( - gAgent.getID(), - item->getPermissions().getOwner(), - item->getUUID(), - folder_id, - new_name, - cb); - } - else - { - move_inventory_item( - gAgent.getID(), - gAgent.getSessionID(), - item->getUUID(), - folder_id, - new_name, - cb); + if (isWearableCopyable((EWearableType)type, j)) + { + copy_inventory_item( + gAgent.getID(), + item->getPermissions().getOwner(), + item->getUUID(), + folder_id, + new_name, + cb); + } + else + { + move_inventory_item( + gAgent.getID(), + gAgent.getSessionID(), + item->getUUID(), + folder_id, + new_name, + cb); + } } } } diff --git a/indra/newview/llchathistory.cpp b/indra/newview/llchathistory.cpp index 13a5df353d..7a5d8be84a 100644 --- a/indra/newview/llchathistory.cpp +++ b/indra/newview/llchathistory.cpp @@ -66,6 +66,8 @@ static LLDefaultChildRegistry::Register<LLChatHistory> r("chat_history"); const static std::string NEW_LINE(rawstr_to_utf8("\n")); +const static U32 LENGTH_OF_TIME_STR = std::string("12:00").length(); + // support for secondlife:///app/objectim/{UUID}/ SLapps class LLObjectIMHandler : public LLCommandHandler { @@ -544,6 +546,7 @@ void LLChatHistory::clear() void LLChatHistory::appendMessage(const LLChat& chat, const LLSD &args, const LLStyle::Params& input_append_params) { bool use_plain_text_chat_history = args["use_plain_text_chat_history"].asBoolean(); + if (!mEditor->scrolledToEnd() && chat.mFromID != gAgent.getID() && !chat.mFromName.empty()) { mUnreadChatSources.insert(chat.mFromName); @@ -609,6 +612,14 @@ void LLChatHistory::appendMessage(const LLChat& chat, const LLSD &args, const LL style_params.font.style = "ITALIC"; } + //*HACK we graying out chat history by graying out messages that contains full date in a time string + bool message_from_log = chat.mTimeStr.length() > LENGTH_OF_TIME_STR; + if (message_from_log) + { + style_params.color(LLColor4::grey); + style_params.readonly_color(LLColor4::grey); + } + if (use_plain_text_chat_history) { mEditor->appendText("[" + chat.mTimeStr + "] ", mEditor->getText().size() != 0, style_params); @@ -644,10 +655,10 @@ void LLChatHistory::appendMessage(const LLChat& chat, const LLSD &args, const LL mEditor->appendText("<nolink>" + chat.mFromName + "</nolink>" + delimiter, false, link_params); } - else if ( chat.mFromName != SYSTEM_FROM && chat.mFromID.notNull() ) + else if ( chat.mFromName != SYSTEM_FROM && chat.mFromID.notNull() && !message_from_log) { LLStyle::Params link_params(style_params); - link_params.fillFrom(LLStyleMap::instance().lookupAgent(chat.mFromID)); + link_params.overwriteFrom(LLStyleMap::instance().lookupAgent(chat.mFromID)); // Convert the name to a hotlink and add to message. mEditor->appendText(chat.mFromName + delimiter, false, link_params); } diff --git a/indra/newview/lldrawpoolalpha.cpp b/indra/newview/lldrawpoolalpha.cpp index 6d77361414..7be6e82251 100644 --- a/indra/newview/lldrawpoolalpha.cpp +++ b/indra/newview/lldrawpoolalpha.cpp @@ -180,6 +180,7 @@ void LLDrawPoolAlpha::render(S32 pass) if (LLPipeline::sFastAlpha && !deferred_render) { + LLGLDisable blend_disable(GL_BLEND); gGL.setAlphaRejectSettings(LLRender::CF_GREATER, 0.33f); if (mVertexShaderLevel > 0) { diff --git a/indra/newview/llface.cpp b/indra/newview/llface.cpp index d12fd48ffb..c0a3eb1316 100644 --- a/indra/newview/llface.cpp +++ b/indra/newview/llface.cpp @@ -1327,6 +1327,21 @@ BOOL LLFace::getGeometryVolume(const LLVolume& volume, return TRUE; } +//check if the face has a media +BOOL LLFace::hasMedia() const +{ + if(mHasMedia) + { + return TRUE ; + } + if(mTexture.notNull()) + { + return mTexture->hasParcelMedia() ; //if has a parcel media + } + + return FALSE ; //no media. +} + const F32 LEAST_IMPORTANCE = 0.05f ; const F32 LEAST_IMPORTANCE_FOR_LARGE_IMAGE = 0.3f ; @@ -1336,7 +1351,7 @@ F32 LLFace::getTextureVirtualSize() F32 cos_angle_to_view_dir; mPixelArea = calcPixelArea(cos_angle_to_view_dir, radius); - if (mPixelArea <= 0) + if (mPixelArea < 0.0001f) { return 0.f; } @@ -1381,14 +1396,38 @@ F32 LLFace::calcPixelArea(F32& cos_angle_to_view_dir, F32& radius) { //get area of circle around face LLVector3 center = getPositionAgent(); - LLVector3 size = (mExtents[1] - mExtents[0]) * 0.5f; - + LLVector3 size = (mExtents[1] - mExtents[0]) * 0.5f; LLViewerCamera* camera = LLViewerCamera::getInstance(); + + //if has media, check if the face is out of the view frustum. + BOOL has_media = hasMedia() ; + if(has_media && !camera->AABBInFrustum(center, size)) + { + mImportanceToCamera = 0.f ; + return 0.f ; + } + + F32 size_squared = size.lengthSquared() ; LLVector3 lookAt = center - camera->getOrigin(); F32 dist = lookAt.normVec() ; + cos_angle_to_view_dir = lookAt * camera->getXAxis() ; + if(has_media) + { + if(cos_angle_to_view_dir > camera->getCosHalfFov()) //the center is within the view frustum + { + cos_angle_to_view_dir = 1.0f ; + } + else + { + if(dist * dist * (lookAt - camera->getXAxis()).lengthSquared() < size_squared) + { + cos_angle_to_view_dir = 1.0f ; + } + } + } //get area of circle around node - F32 app_angle = atanf(size.length()/dist); + F32 app_angle = atanf(fsqrtf(size_squared) / dist); radius = app_angle*LLDrawable::sCurPixelAngle; F32 face_area = radius*radius * 3.14159f; @@ -1398,8 +1437,7 @@ F32 LLFace::calcPixelArea(F32& cos_angle_to_view_dir, F32& radius) mImportanceToCamera = 1.0f ; } else - { - cos_angle_to_view_dir = lookAt * camera->getXAxis() ; + { mImportanceToCamera = LLFace::calcImportanceToCamera(cos_angle_to_view_dir, dist) ; } diff --git a/indra/newview/llface.h b/indra/newview/llface.h index e12b64a2f2..bf658dc00c 100644 --- a/indra/newview/llface.h +++ b/indra/newview/llface.h @@ -194,6 +194,9 @@ public: F32 getTextureVirtualSize() ; F32 getImportanceToCamera()const {return mImportanceToCamera ;} + void setHasMedia(bool has_media) { mHasMedia = has_media ;} + BOOL hasMedia() const ; + //for atlas LLTextureAtlasSlot* getAtlasInfo() ; void setAtlasInUse(BOOL flag); @@ -262,7 +265,7 @@ private: //based on the distance from the face to the view point and the angle from the face center to the view direction. F32 mImportanceToCamera ; F32 mBoundingSphereRadius ; - + bool mHasMedia ; //atlas LLPointer<LLTextureAtlasSlot> mAtlasInfop ; diff --git a/indra/newview/llfavoritesbar.cpp b/indra/newview/llfavoritesbar.cpp index 1e8a739d78..bf7c735488 100644 --- a/indra/newview/llfavoritesbar.cpp +++ b/indra/newview/llfavoritesbar.cpp @@ -1264,8 +1264,11 @@ LLInventoryModel::item_array_t::iterator LLFavoritesBarCtrl::findItemByUUID(LLIn void LLFavoritesBarCtrl::insertBeforeItem(LLInventoryModel::item_array_t& items, const LLUUID& beforeItemId, LLViewerInventoryItem* insertedItem) { LLViewerInventoryItem* beforeItem = gInventory.getItem(beforeItemId); - - items.insert(findItemByUUID(items, beforeItem->getUUID()), insertedItem); + llassert(beforeItem); + if (beforeItem) + { + items.insert(findItemByUUID(items, beforeItem->getUUID()), insertedItem); + } } // EOF diff --git a/indra/newview/llfeaturemanager.cpp b/indra/newview/llfeaturemanager.cpp index fb724f30e0..fbb90c69f3 100644 --- a/indra/newview/llfeaturemanager.cpp +++ b/indra/newview/llfeaturemanager.cpp @@ -287,6 +287,7 @@ BOOL LLFeatureManager::loadFeatureTables() if (!flp) { LL_ERRS("RenderInit") << "Specified parameter before <list> keyword!" << LL_ENDL; + return FALSE; } S32 available; F32 recommended; diff --git a/indra/newview/llfloatergesture.cpp b/indra/newview/llfloatergesture.cpp index b684e1f985..90617a337a 100644 --- a/indra/newview/llfloatergesture.cpp +++ b/indra/newview/llfloatergesture.cpp @@ -427,8 +427,13 @@ void LLFloaterGesture::onClickPlay() BOOL inform_server = TRUE; BOOL deactivate_similar = FALSE; LLGestureManager::instance().setGestureLoadedCallback(item_id, boost::bind(&LLFloaterGesture::playGesture, this, item_id)); - LLGestureManager::instance().activateGestureWithAsset(item_id, gInventory.getItem(item_id)->getAssetUUID(), inform_server, deactivate_similar); - LL_DEBUGS("Gesture")<< "Activating gesture with inventory ID: " << item_id <<LL_ENDL; + LLViewerInventoryItem *item = gInventory.getItem(item_id); + llassert(item); + if (item) + { + LLGestureManager::instance().activateGestureWithAsset(item_id, item->getAssetUUID(), inform_server, deactivate_similar); + LL_DEBUGS("Gesture")<< "Activating gesture with inventory ID: " << item_id <<LL_ENDL; + } } else { @@ -510,15 +515,16 @@ void LLFloaterGesture::onCopyPasteAction(const LLSD& command) if(ids.empty() || !gInventory.isCategoryComplete(mGestureFolderID)) return; LLInventoryCategory* gesture_dir = gInventory.getCategory(mGestureFolderID); + llassert(gesture_dir); LLPointer<GestureCopiedCallback> cb = new GestureCopiedCallback(this); for(LLDynamicArray<LLUUID>::iterator it = ids.begin(); it != ids.end(); it++) { LLInventoryItem* item = gInventory.getItem(*it); - LLStringUtil::format_map_t string_args; - string_args["[COPY_NAME]"] = item->getName(); - if(item && item->getInventoryType() == LLInventoryType::IT_GESTURE) + if(gesture_dir && item && item->getInventoryType() == LLInventoryType::IT_GESTURE) { + LLStringUtil::format_map_t string_args; + string_args["[COPY_NAME]"] = item->getName(); LL_DEBUGS("Gesture")<< "Copying gesture " << item->getName() << " "<< item->getUUID() << " into " << gesture_dir->getName() << " "<< gesture_dir->getUUID() << LL_ENDL; copy_inventory_item(gAgent.getID(), item->getPermissions().getOwner(), item->getUUID(), diff --git a/indra/newview/llfloaternotificationsconsole.cpp b/indra/newview/llfloaternotificationsconsole.cpp index 90db8988b2..94b5ebba00 100644 --- a/indra/newview/llfloaternotificationsconsole.cpp +++ b/indra/newview/llfloaternotificationsconsole.cpp @@ -112,10 +112,15 @@ void LLNotificationChannelPanel::onClickNotification(void* user_data) { LLNotificationChannelPanel* self = (LLNotificationChannelPanel*)user_data; if (!self) return; - void* data = self->getChild<LLScrollListCtrl>("notifications_list")->getFirstSelected()->getUserdata(); - if (data) + LLScrollListItem* firstselected = self->getChild<LLScrollListCtrl>("notifications_list")->getFirstSelected(); + llassert(firstselected); + if (firstselected) { - gFloaterView->getParentFloater(self)->addDependentFloater(new LLFloaterNotification((LLNotification*)data), TRUE); + void* data = firstselected->getUserdata(); + if (data) + { + gFloaterView->getParentFloater(self)->addDependentFloater(new LLFloaterNotification((LLNotification*)data), TRUE); + } } } @@ -124,10 +129,15 @@ void LLNotificationChannelPanel::onClickNotificationReject(void* user_data) { LLNotificationChannelPanel* self = (LLNotificationChannelPanel*)user_data; if (!self) return; - void* data = self->getChild<LLScrollListCtrl>("notification_rejects_list")->getFirstSelected()->getUserdata(); - if (data) + LLScrollListItem* firstselected = self->getChild<LLScrollListCtrl>("notification_rejects_list")->getFirstSelected(); + llassert(firstselected); + if (firstselected) { - gFloaterView->getParentFloater(self)->addDependentFloater(new LLFloaterNotification((LLNotification*)data), TRUE); + void* data = firstselected->getUserdata(); + if (data) + { + gFloaterView->getParentFloater(self)->addDependentFloater(new LLFloaterNotification((LLNotification*)data), TRUE); + } } } diff --git a/indra/newview/llfloaterpreference.cpp b/indra/newview/llfloaterpreference.cpp index 3c9f7492a2..43111d76f7 100644 --- a/indra/newview/llfloaterpreference.cpp +++ b/indra/newview/llfloaterpreference.cpp @@ -110,8 +110,6 @@ const F32 MAX_USER_FAR_CLIP = 512.f; const F32 MIN_USER_FAR_CLIP = 64.f; -const S32 ASPECT_RATIO_STR_LEN = 100; - class LLVoiceSetKeyDialog : public LLModalDialog { public: @@ -283,7 +281,6 @@ void fractionFromDecimal(F32 decimal_val, S32& numerator, S32& denominator) } // static std::string LLFloaterPreference::sSkin = ""; -F32 LLFloaterPreference::sAspectRatio = 0.0; ////////////////////////////////////////////// // LLFloaterPreference @@ -324,11 +321,9 @@ LLFloaterPreference::LLFloaterPreference(const LLSD& key) mCommitCallbackRegistrar.add("Pref.VertexShaderEnable", boost::bind(&LLFloaterPreference::onVertexShaderEnable, this)); mCommitCallbackRegistrar.add("Pref.WindowedMod", boost::bind(&LLFloaterPreference::onCommitWindowedMode, this)); mCommitCallbackRegistrar.add("Pref.UpdateSliderText", boost::bind(&LLFloaterPreference::onUpdateSliderText,this, _1,_2)); - mCommitCallbackRegistrar.add("Pref.AutoDetectAspect", boost::bind(&LLFloaterPreference::onCommitAutoDetectAspect, this)); mCommitCallbackRegistrar.add("Pref.ParcelMediaAutoPlayEnable", boost::bind(&LLFloaterPreference::onCommitParcelMediaAutoPlayEnable, this)); mCommitCallbackRegistrar.add("Pref.MediaEnabled", boost::bind(&LLFloaterPreference::onCommitMediaEnabled, this)); mCommitCallbackRegistrar.add("Pref.MusicEnabled", boost::bind(&LLFloaterPreference::onCommitMusicEnabled, this)); - mCommitCallbackRegistrar.add("Pref.onSelectAspectRatio", boost::bind(&LLFloaterPreference::onKeystrokeAspectRatio, this)); mCommitCallbackRegistrar.add("Pref.QualityPerformance", boost::bind(&LLFloaterPreference::onChangeQuality, this, _2)); mCommitCallbackRegistrar.add("Pref.applyUIColor", boost::bind(&LLFloaterPreference::applyUIColor, this ,_1, _2)); mCommitCallbackRegistrar.add("Pref.getUIColor", boost::bind(&LLFloaterPreference::getUIColor, this ,_1, _2)); @@ -359,12 +354,7 @@ BOOL LLFloaterPreference::postBuild() LLFloaterPreference::~LLFloaterPreference() { // clean up user data - LLComboBox* ctrl_aspect_ratio = getChild<LLComboBox>( "aspect_ratio"); LLComboBox* ctrl_window_size = getChild<LLComboBox>("windowsize combo"); - for (S32 i = 0; i < ctrl_aspect_ratio->getItemCount(); i++) - { - ctrl_aspect_ratio->setCurrentByIndex(i); - } for (S32 i = 0; i < ctrl_window_size->getItemCount(); i++) { ctrl_window_size->setCurrentByIndex(i); @@ -514,8 +504,6 @@ void LLFloaterPreference::cancel() LLFloaterReg::hideInstance("pref_voicedevicesettings"); - gSavedSettings.setF32("FullScreenAspectRatio", sAspectRatio); - } void LLFloaterPreference::onOpen(const LLSD& key) @@ -968,37 +956,6 @@ void LLFloaterPreference::disableUnavailableSettings() } } -void LLFloaterPreference::onCommitAutoDetectAspect() -{ - BOOL auto_detect = getChild<LLCheckBoxCtrl>("aspect_auto_detect")->get(); - F32 ratio; - - if (auto_detect) - { - S32 numerator = 0; - S32 denominator = 0; - - // clear any aspect ratio override - gViewerWindow->mWindow->setNativeAspectRatio(0.f); - fractionFromDecimal(gViewerWindow->mWindow->getNativeAspectRatio(), numerator, denominator); - - std::string aspect; - if (numerator != 0) - { - aspect = llformat("%d:%d", numerator, denominator); - } - else - { - aspect = llformat("%.3f", gViewerWindow->mWindow->getNativeAspectRatio()); - } - - getChild<LLComboBox>( "aspect_ratio")->setLabel(aspect); - - ratio = gViewerWindow->mWindow->getNativeAspectRatio(); - gSavedSettings.setF32("FullScreenAspectRatio", ratio); - } -} - void LLFloaterPreference::onCommitParcelMediaAutoPlayEnable() { BOOL autoplay = getChild<LLCheckBoxCtrl>("autoplay_enabled")->get(); @@ -1266,56 +1223,9 @@ void LLFloaterPreference::updateSliderText(LLSliderCtrl* ctrl, LLTextBox* text_b } } -void LLFloaterPreference::onKeystrokeAspectRatio() -{ - getChild<LLCheckBoxCtrl>("aspect_auto_detect")->set(FALSE); -} - void LLFloaterPreference::applyResolution() { - LLComboBox* ctrl_aspect_ratio = getChild<LLComboBox>( "aspect_ratio"); gGL.flush(); - char aspect_ratio_text[ASPECT_RATIO_STR_LEN]; /*Flawfinder: ignore*/ - if (ctrl_aspect_ratio->getCurrentIndex() == -1) - { - // *Can't pass const char* from c_str() into strtok - strncpy(aspect_ratio_text, ctrl_aspect_ratio->getSimple().c_str(), sizeof(aspect_ratio_text) -1); /*Flawfinder: ignore*/ - aspect_ratio_text[sizeof(aspect_ratio_text) -1] = '\0'; - char *element = strtok(aspect_ratio_text, ":/\\"); - if (!element) - { - sAspectRatio = 0.f; // will be clamped later - } - else - { - LLLocale locale(LLLocale::USER_LOCALE); - sAspectRatio = (F32)atof(element); - } - - // look for denominator - element = strtok(NULL, ":/\\"); - if (element) - { - LLLocale locale(LLLocale::USER_LOCALE); - - F32 denominator = (F32)atof(element); - if (denominator != 0.f) - { - sAspectRatio /= denominator; - } - } - } - else - { - sAspectRatio = (F32)ctrl_aspect_ratio->getValue().asReal(); - } - - // presumably, user entered a non-numeric value if aspect_ratio == 0.f - if (sAspectRatio != 0.f) - { - sAspectRatio = llclamp(sAspectRatio, 0.2f, 5.f); - gSavedSettings.setF32("FullScreenAspectRatio", sAspectRatio); - } // Screen resolution S32 num_resolutions; @@ -1393,48 +1303,6 @@ BOOL LLPanelPreference::postBuild() childSetText("email_address",getString("log_in_to_change") ); // childSetText("busy_response", getString("log_in_to_change")); } - - - if(hasChild("aspect_ratio")) - { - // We used to set up fullscreen resolution and window size - // controls here, see LLFloaterWindowSize::initWindowSizeControls() - - if (gSavedSettings.getBOOL("FullScreenAutoDetectAspectRatio")) - { - LLFloaterPreference::sAspectRatio = gViewerWindow->getDisplayAspectRatio(); - } - else - { - LLFloaterPreference::sAspectRatio = gSavedSettings.getF32("FullScreenAspectRatio"); - } - - getChild<LLComboBox>("aspect_ratio")->setTextEntryCallback(boost::bind(&LLPanelPreference::setControlFalse, this, LLSD("FullScreenAutoDetectAspectRatio") )); - - - S32 numerator = 0; - S32 denominator = 0; - fractionFromDecimal(LLFloaterPreference::sAspectRatio, numerator, denominator); - - LLUIString aspect_ratio_text = getString("aspect_ratio_text"); - if (numerator != 0) - { - aspect_ratio_text.setArg("[NUM]", llformat("%d", numerator)); - aspect_ratio_text.setArg("[DEN]", llformat("%d", denominator)); - } - else - { - aspect_ratio_text = llformat("%.3f", LLFloaterPreference::sAspectRatio); - } - - LLComboBox* ctrl_aspect_ratio = getChild<LLComboBox>( "aspect_ratio"); - //mCtrlAspectRatio->setCommitCallback(onSelectAspectRatio, this); - // add default aspect ratios - ctrl_aspect_ratio->add(aspect_ratio_text, &LLFloaterPreference::sAspectRatio, ADD_TOP); - ctrl_aspect_ratio->setCurrentByIndex(0); - - refresh(); - } //////////////////////PanelPrivacy /////////////////// if (hasChild("media_enabled")) diff --git a/indra/newview/llfloaterpreference.h b/indra/newview/llfloaterpreference.h index 0827c7c2b2..93b39d72bc 100644 --- a/indra/newview/llfloaterpreference.h +++ b/indra/newview/llfloaterpreference.h @@ -128,10 +128,8 @@ public: void updateSliderText(LLSliderCtrl* ctrl, LLTextBox* text_box); void onUpdateSliderText(LLUICtrl* ctrl, const LLSD& name); - void onKeystrokeAspectRatio(); // void fractionFromDecimal(F32 decimal_val, S32& numerator, S32& denominator); - void onCommitAutoDetectAspect(); void onCommitParcelMediaAutoPlayEnable(); void onCommitMediaEnabled(); void onCommitMusicEnabled(); @@ -142,7 +140,6 @@ public: void buildPopupLists(); static void refreshSkin(void* data); static void cleanupBadSetting(); - static F32 sAspectRatio; private: static std::string sSkin; bool mGotPersonalInfo; diff --git a/indra/newview/llfloaterproperties.cpp b/indra/newview/llfloaterproperties.cpp index bde86a4034..5c0593ad29 100644 --- a/indra/newview/llfloaterproperties.cpp +++ b/indra/newview/llfloaterproperties.cpp @@ -880,7 +880,11 @@ void LLFloaterProperties::dirtyAll() iter != inst_list.end(); ++iter) { LLFloaterProperties* floater = dynamic_cast<LLFloaterProperties*>(*iter); - floater->dirty(); + llassert(floater); // else cast failed - wrong type D: + if (floater) + { + floater->dirty(); + } } } diff --git a/indra/newview/llfloatertools.cpp b/indra/newview/llfloatertools.cpp index 4edd09b02c..e2b083a29b 100644 --- a/indra/newview/llfloatertools.cpp +++ b/indra/newview/llfloatertools.cpp @@ -666,8 +666,8 @@ void LLFloaterTools::updatePopup(LLCoordGL center, MASK mask) if (mCheckCopyCenters) mCheckCopyCenters ->setVisible( create_visible ); if (mCheckCopyRotates) mCheckCopyRotates ->setVisible( create_visible ); - if (mCheckCopyCenters) mCheckCopyCenters->setEnabled( mCheckCopySelection->get() ); - if (mCheckCopyRotates) mCheckCopyRotates->setEnabled( mCheckCopySelection->get() ); + if (mCheckCopyCenters && mCheckCopySelection) mCheckCopyCenters->setEnabled( mCheckCopySelection->get() ); + if (mCheckCopyRotates && mCheckCopySelection) mCheckCopyRotates->setEnabled( mCheckCopySelection->get() ); // Land buttons BOOL land_visible = (tool == LLToolBrushLand::getInstance() || tool == LLToolSelectLand::getInstance() ); diff --git a/indra/newview/llfloateruipreview.cpp b/indra/newview/llfloateruipreview.cpp index 3e804bef9d..f61c86db14 100644 --- a/indra/newview/llfloateruipreview.cpp +++ b/indra/newview/llfloateruipreview.cpp @@ -362,8 +362,7 @@ BOOL LLFadeEventTimer::tick() if(NULL == mParent) // no more need to tick, so suicide { - delete this; - return FALSE; + return TRUE; } // Set up colors diff --git a/indra/newview/llgroupmgr.cpp b/indra/newview/llgroupmgr.cpp index 4c1019a882..4db75bbd8a 100644 --- a/indra/newview/llgroupmgr.cpp +++ b/indra/newview/llgroupmgr.cpp @@ -677,9 +677,12 @@ void LLGroupMgrGroupData::sendRoleChanges() break; } case RC_UPDATE_ALL: + // fall through case RC_UPDATE_POWERS: need_power_recalc = true; + // fall through case RC_UPDATE_DATA: + // fall through default: { LLGroupRoleData* group_role_data = (*role_it).second; @@ -762,7 +765,7 @@ void LLGroupMgr::addObserver(LLGroupMgrObserver* observer) mObservers.insert(std::pair<LLUUID, LLGroupMgrObserver*>(observer->getID(), observer)); } -void LLGroupMgr::addObserver(const LLUUID& group_id, LLParticularGroupMgrObserver* observer) +void LLGroupMgr::addObserver(const LLUUID& group_id, LLParticularGroupObserver* observer) { if(group_id.notNull() && observer) { @@ -792,7 +795,7 @@ void LLGroupMgr::removeObserver(LLGroupMgrObserver* observer) } } -void LLGroupMgr::removeObserver(const LLUUID& group_id, LLParticularGroupMgrObserver* observer) +void LLGroupMgr::removeObserver(const LLUUID& group_id, LLParticularGroupObserver* observer) { if(group_id.isNull() || !observer) { @@ -1364,7 +1367,7 @@ void LLGroupMgr::notifyObservers(LLGroupChange gc) gi->second->mChanged = FALSE; - // notify LLParticularGroupMgrObserver + // notify LLParticularGroupObserver observer_map_t::iterator obs_it = mParticularObservers.find(group_id); if(obs_it == mParticularObservers.end()) return; diff --git a/indra/newview/llgroupmgr.h b/indra/newview/llgroupmgr.h index 588b4a9034..2c86de8b97 100644 --- a/indra/newview/llgroupmgr.h +++ b/indra/newview/llgroupmgr.h @@ -53,10 +53,10 @@ protected: LLUUID mID; }; -class LLParticularGroupMgrObserver +class LLParticularGroupObserver { public: - virtual ~LLParticularGroupMgrObserver(){} + virtual ~LLParticularGroupObserver(){} virtual void changed(const LLUUID& group_id, LLGroupChange gc) = 0; }; @@ -313,9 +313,9 @@ public: ~LLGroupMgr(); void addObserver(LLGroupMgrObserver* observer); - void addObserver(const LLUUID& group_id, LLParticularGroupMgrObserver* observer); + void addObserver(const LLUUID& group_id, LLParticularGroupObserver* observer); void removeObserver(LLGroupMgrObserver* observer); - void removeObserver(const LLUUID& group_id, LLParticularGroupMgrObserver* observer); + void removeObserver(const LLUUID& group_id, LLParticularGroupObserver* observer); LLGroupMgrGroupData* getGroupData(const LLUUID& id); void sendGroupPropertiesRequest(const LLUUID& group_id); @@ -374,7 +374,7 @@ private: typedef std::map<LLUUID, LLGroupMgrGroupData*> group_map_t; group_map_t mGroups; - typedef std::set<LLParticularGroupMgrObserver*> observer_set_t; + typedef std::set<LLParticularGroupObserver*> observer_set_t; typedef std::map<LLUUID,observer_set_t> observer_map_t; observer_map_t mParticularObservers; }; diff --git a/indra/newview/llimfloatercontainer.cpp b/indra/newview/llimfloatercontainer.cpp index ba034609e9..7162386d08 100644 --- a/indra/newview/llimfloatercontainer.cpp +++ b/indra/newview/llimfloatercontainer.cpp @@ -121,36 +121,6 @@ void LLIMFloaterContainer::onCloseFloater(LLUUID& id) mSessions.erase(id); } -void LLIMFloaterContainer::processProperties(void* data, enum EAvatarProcessorType type) -{ - if (APT_PROPERTIES == type) - { - LLAvatarData* avatar_data = static_cast<LLAvatarData*>(data); - if (avatar_data) - { - LLUUID avatar_id = avatar_data->avatar_id; - LLUUID* cached_avatarId = LLAvatarIconIDCache::getInstance()->get(avatar_id); - if(cached_avatarId && cached_avatarId->notNull() && avatar_data->image_id != *cached_avatarId) - { - LLAvatarIconIDCache::getInstance()->add(avatar_id,avatar_data->image_id); - mTabContainer->setTabImage(get_ptr_in_map(mSessions, avatar_id), avatar_data->image_id); - } - } - } -} - -void LLIMFloaterContainer::changed(const LLUUID& group_id, LLGroupChange gc) -{ - if (GC_PROPERTIES == gc) - { - LLGroupMgrGroupData* group_data = LLGroupMgr::getInstance()->getGroupData(group_id); - if (group_data && group_data->mInsigniaID.notNull()) - { - mTabContainer->setTabImage(get_ptr_in_map(mSessions, group_id), group_data->mInsigniaID); - } - } -} - void LLIMFloaterContainer::onNewMessageReceived(const LLSD& data) { LLUUID session_id = data["from_id"].asUUID(); diff --git a/indra/newview/llimfloatercontainer.h b/indra/newview/llimfloatercontainer.h index b07ef2d71d..46c0617c01 100644 --- a/indra/newview/llimfloatercontainer.h +++ b/indra/newview/llimfloatercontainer.h @@ -43,7 +43,7 @@ class LLTabContainer; -class LLIMFloaterContainer : public LLMultiFloater, public LLAvatarPropertiesObserver, public LLParticularGroupMgrObserver +class LLIMFloaterContainer : public LLMultiFloater { public: LLIMFloaterContainer(const LLSD& seed); @@ -57,9 +57,6 @@ public: BOOL select_added_floater, LLTabContainer::eInsertionPoint insertion_point = LLTabContainer::END); - void processProperties(void* data, EAvatarProcessorType type); - void changed(const LLUUID& group_id, LLGroupChange gc); - static LLFloater* getCurrentVoiceFloater(); static LLIMFloaterContainer* findInstance(); diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp index 32482a065c..5a6c6ebbee 100644 --- a/indra/newview/llimview.cpp +++ b/indra/newview/llimview.cpp @@ -77,6 +77,9 @@ const static std::string IM_FROM_ID("from_id"); const static std::string NO_SESSION("(IM Session Doesn't Exist)"); const static std::string ADHOC_NAME_SUFFIX(" Conference"); +const static std::string NEARBY_P2P_BY_OTHER("nearby_P2P_by_other"); +const static std::string NEARBY_P2P_BY_AGENT("nearby_P2P_by_agent"); + std::string LLCallDialogManager::sPreviousSessionlName = ""; LLIMModel::LLIMSession::SType LLCallDialogManager::sPreviousSessionType = LLIMModel::LLIMSession::P2P_SESSION; std::string LLCallDialogManager::sCurrentSessionlName = ""; @@ -1372,7 +1375,7 @@ void LLCallDialogManager::onVoiceChannelChanged(const LLUUID &session_id) } sSession = session; - sSession->mVoiceChannel->setStateChangedCallback(boost::bind(LLCallDialogManager::onVoiceChannelStateChanged, _1, _2, _3)); + sSession->mVoiceChannel->setStateChangedCallback(boost::bind(LLCallDialogManager::onVoiceChannelStateChanged, _1, _2, _3, _4)); if(sCurrentSessionlName != session->mName) { sPreviousSessionlName = sCurrentSessionlName; @@ -1403,7 +1406,7 @@ void LLCallDialogManager::onVoiceChannelChanged(const LLUUID &session_id) } -void LLCallDialogManager::onVoiceChannelStateChanged(const LLVoiceChannel::EState& old_state, const LLVoiceChannel::EState& new_state, const LLVoiceChannel::EDirection& direction) +void LLCallDialogManager::onVoiceChannelStateChanged(const LLVoiceChannel::EState& old_state, const LLVoiceChannel::EState& new_state, const LLVoiceChannel::EDirection& direction, bool ended_by_agent) { LLSD mCallDialogPayload; LLOutgoingCallDialog* ocd = NULL; @@ -1423,6 +1426,7 @@ void LLCallDialogManager::onVoiceChannelStateChanged(const LLVoiceChannel::EStat mCallDialogPayload["state"] = new_state; mCallDialogPayload["disconnected_channel_name"] = sSession->mName; mCallDialogPayload["session_type"] = sSession->mSessionType; + mCallDialogPayload["ended_by_agent"] = ended_by_agent; switch(new_state) { @@ -1618,14 +1622,16 @@ void LLOutgoingCallDialog::show(const LLSD& key) channel_name = LLTextUtil::formatPhoneNumber(channel_name); } childSetTextArg("nearby", "[VOICE_CHANNEL_NAME]", channel_name); - childSetTextArg("nearby_P2P", "[VOICE_CHANNEL_NAME]", mPayload["disconnected_channel_name"].asString()); + childSetTextArg("nearby_P2P_by_other", "[VOICE_CHANNEL_NAME]", mPayload["disconnected_channel_name"].asString()); // skipping "You will now be reconnected to nearby" in notification when call is ended by disabling voice, // so no reconnection to nearby chat happens (EXT-4397) bool voice_works = LLVoiceClient::voiceEnabled() && gVoiceClient->voiceWorking(); std::string reconnect_nearby = voice_works ? LLTrans::getString("reconnect_nearby") : std::string(); childSetTextArg("nearby", "[RECONNECT_NEARBY]", reconnect_nearby); - childSetTextArg("nearby_P2P", "[RECONNECT_NEARBY]", reconnect_nearby); + + const std::string& nearby_str = mPayload["ended_by_agent"] ? NEARBY_P2P_BY_AGENT : NEARBY_P2P_BY_OTHER; + childSetTextArg(nearby_str, "[RECONNECT_NEARBY]", reconnect_nearby); } std::string callee_name = mPayload["session_name"].asString(); @@ -1659,6 +1665,7 @@ void LLOutgoingCallDialog::show(const LLSD& key) { case LLVoiceChannel::STATE_CALL_STARTED : getChild<LLTextBox>("calling")->setVisible(true); + getChild<LLButton>("Cancel")->setVisible(true); if(show_oldchannel) { getChild<LLTextBox>("leaving")->setVisible(true); @@ -1680,7 +1687,8 @@ void LLOutgoingCallDialog::show(const LLSD& key) case LLVoiceChannel::STATE_HUNG_UP : if (mPayload["session_type"].asInteger() == LLIMModel::LLIMSession::P2P_SESSION) { - getChild<LLTextBox>("nearby_P2P")->setVisible(true); + const std::string& nearby_str = mPayload["ended_by_agent"] ? NEARBY_P2P_BY_AGENT : NEARBY_P2P_BY_OTHER; + getChild<LLTextBox>(nearby_str)->setVisible(true); } else { @@ -1699,7 +1707,8 @@ void LLOutgoingCallDialog::hideAllText() getChild<LLTextBox>("calling")->setVisible(false); getChild<LLTextBox>("leaving")->setVisible(false); getChild<LLTextBox>("connecting")->setVisible(false); - getChild<LLTextBox>("nearby_P2P")->setVisible(false); + getChild<LLTextBox>("nearby_P2P_by_other")->setVisible(false); + getChild<LLTextBox>("nearby_P2P_by_agent")->setVisible(false); getChild<LLTextBox>("nearby")->setVisible(false); getChild<LLTextBox>("noanswer")->setVisible(false); } diff --git a/indra/newview/llimview.h b/indra/newview/llimview.h index 21c7626109..ad6cede727 100644 --- a/indra/newview/llimview.h +++ b/indra/newview/llimview.h @@ -452,7 +452,7 @@ public: static void initClass(); static void onVoiceChannelChanged(const LLUUID &session_id); - static void onVoiceChannelStateChanged(const LLVoiceChannel::EState& old_state, const LLVoiceChannel::EState& new_state, const LLVoiceChannel::EDirection& direction); + static void onVoiceChannelStateChanged(const LLVoiceChannel::EState& old_state, const LLVoiceChannel::EState& new_state, const LLVoiceChannel::EDirection& direction, bool ended_by_agent); protected: static std::string sPreviousSessionlName; diff --git a/indra/newview/llpanelimcontrolpanel.cpp b/indra/newview/llpanelimcontrolpanel.cpp index cbd6f64a48..8e305a5674 100644 --- a/indra/newview/llpanelimcontrolpanel.cpp +++ b/indra/newview/llpanelimcontrolpanel.cpp @@ -224,14 +224,6 @@ void LLPanelIMControlPanel::setSessionId(const LLUUID& session_id) childSetEnabled("share_btn", FALSE); childSetEnabled("teleport_btn", FALSE); childSetEnabled("pay_btn", FALSE); - - getChild<LLTextBox>("avatar_name")->setValue(im_session->mName); - getChild<LLTextBox>("avatar_name")->setToolTip(im_session->mName); - } - else - { - // If the participant is an avatar, fetch the currect name - gCacheName->get(mAvatarID, FALSE, boost::bind(&LLPanelIMControlPanel::nameUpdatedCallback, this, _1, _2, _3, _4)); } } @@ -247,19 +239,6 @@ void LLPanelIMControlPanel::changed(U32 mask) } } -void LLPanelIMControlPanel::nameUpdatedCallback(const LLUUID& id, const std::string& first, const std::string& last, BOOL is_group) -{ - if ( id == mAvatarID ) - { - std::string avatar_name; - avatar_name.assign(first); - avatar_name.append(" "); - avatar_name.append(last); - getChild<LLTextBox>("avatar_name")->setValue(avatar_name); - getChild<LLTextBox>("avatar_name")->setToolTip(avatar_name); - } -} - LLPanelGroupControlPanel::LLPanelGroupControlPanel(const LLUUID& session_id): mParticipantList(NULL) { diff --git a/indra/newview/llpanelimcontrolpanel.h b/indra/newview/llpanelimcontrolpanel.h index 3ab505a084..ce8fc58e56 100644 --- a/indra/newview/llpanelimcontrolpanel.h +++ b/indra/newview/llpanelimcontrolpanel.h @@ -89,9 +89,6 @@ public: // LLFriendObserver trigger virtual void changed(U32 mask); -protected: - void nameUpdatedCallback(const LLUUID& id, const std::string& first, const std::string& last, BOOL is_group); - private: void onViewProfileButtonClicked(); void onAddFriendButtonClicked(); diff --git a/indra/newview/llpanellandmarkinfo.cpp b/indra/newview/llpanellandmarkinfo.cpp index 36a542cfa0..cd6c727b5c 100644 --- a/indra/newview/llpanellandmarkinfo.cpp +++ b/indra/newview/llpanellandmarkinfo.cpp @@ -406,21 +406,24 @@ void LLPanelLandmarkInfo::populateFoldersList() // Put the "Landmarks" folder first in list. LLUUID landmarks_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_LANDMARK); - const LLViewerInventoryCategory* cat = gInventory.getCategory(landmarks_id); - if (!cat) + const LLViewerInventoryCategory* lmcat = gInventory.getCategory(landmarks_id); + if (!lmcat) { llwarns << "Cannot find the landmarks folder" << llendl; } - std::string cat_full_name = getFullFolderName(cat); - mFolderCombo->add(cat_full_name, cat->getUUID()); + else + { + std::string cat_full_name = getFullFolderName(lmcat); + mFolderCombo->add(cat_full_name, lmcat->getUUID()); + } typedef std::vector<folder_pair_t> folder_vec_t; folder_vec_t folders; // Sort the folders by their full name. for (S32 i = 0; i < cats.count(); i++) { - cat = cats.get(i); - cat_full_name = getFullFolderName(cat); + const LLViewerInventoryCategory* cat = cats.get(i); + std::string cat_full_name = getFullFolderName(cat); folders.push_back(folder_pair_t(cat->getUUID(), cat_full_name)); } sort(folders.begin(), folders.end(), cmp_folders); diff --git a/indra/newview/llpanelpicks.cpp b/indra/newview/llpanelpicks.cpp index ada65c98a4..8eb0b69491 100644 --- a/indra/newview/llpanelpicks.cpp +++ b/indra/newview/llpanelpicks.cpp @@ -843,10 +843,13 @@ void LLPanelPicks::onPanelClassifiedClose(LLPanelClassifiedInfo* panel) { LLClassifiedItem* c_item = dynamic_cast<LLClassifiedItem*>( mClassifiedsList->getItemByValue(values[n])); - - c_item->setClassifiedName(panel->getClassifiedName()); - c_item->setDescription(panel->getDescription()); - c_item->setSnapshotId(panel->getSnapshotId()); + llassert(c_item); + if (c_item) + { + c_item->setClassifiedName(panel->getClassifiedName()); + c_item->setDescription(panel->getDescription()); + c_item->setSnapshotId(panel->getSnapshotId()); + } } } } diff --git a/indra/newview/llpanelplaces.cpp b/indra/newview/llpanelplaces.cpp index 17a970cfcf..26b57c003b 100644 --- a/indra/newview/llpanelplaces.cpp +++ b/indra/newview/llpanelplaces.cpp @@ -1048,14 +1048,13 @@ void LLPanelPlaces::updateVerbs() mTeleportBtn->setVisible(!is_create_landmark_visible && !isLandmarkEditModeOn); mShowOnMapBtn->setVisible(!is_create_landmark_visible && !isLandmarkEditModeOn); - mOverflowBtn->setVisible(!is_create_landmark_visible && !isLandmarkEditModeOn); + mOverflowBtn->setVisible(is_place_info_visible && !is_create_landmark_visible && !isLandmarkEditModeOn); mEditBtn->setVisible(mPlaceInfoType == LANDMARK_INFO_TYPE && !isLandmarkEditModeOn); mSaveBtn->setVisible(isLandmarkEditModeOn); mCancelBtn->setVisible(isLandmarkEditModeOn); mCloseBtn->setVisible(is_create_landmark_visible && !isLandmarkEditModeOn); mShowOnMapBtn->setEnabled(!is_create_landmark_visible && !isLandmarkEditModeOn && have_3d_pos); - mOverflowBtn->setEnabled(is_place_info_visible && !is_create_landmark_visible); if (is_place_info_visible) { diff --git a/indra/newview/llpreviewscript.cpp b/indra/newview/llpreviewscript.cpp index a8feaf690d..3221745fa3 100644 --- a/indra/newview/llpreviewscript.cpp +++ b/indra/newview/llpreviewscript.cpp @@ -661,7 +661,9 @@ void LLScriptEdCore::onBtnDynamicHelp() live_help_floater = new LLFloater(LLSD()); LLUICtrlFactory::getInstance()->buildFloater(live_help_floater, "floater_lsl_guide.xml", NULL); LLFloater* parent = dynamic_cast<LLFloater*>(getParent()); - parent->addDependentFloater(live_help_floater, TRUE); + llassert(parent); + if (parent) + parent->addDependentFloater(live_help_floater, TRUE); live_help_floater->childSetCommitCallback("lock_check", onCheckLock, this); live_help_floater->childSetValue("lock_check", gSavedSettings.getBOOL("ScriptHelpFollowsCursor")); live_help_floater->childSetCommitCallback("history_combo", onHelpComboCommit, this); diff --git a/indra/newview/llsidepaneliteminfo.cpp b/indra/newview/llsidepaneliteminfo.cpp index 44348ba429..0275736f6d 100644 --- a/indra/newview/llsidepaneliteminfo.cpp +++ b/indra/newview/llsidepaneliteminfo.cpp @@ -231,20 +231,23 @@ void LLSidepanelItemInfo::refreshFromItem(LLViewerInventoryItem* item) // PERMISSIONS LOOKUP // //////////////////////// + llassert(item); + if (!item) return; + // do not enable the UI for incomplete items. BOOL is_complete = item->isComplete(); const BOOL cannot_restrict_permissions = LLInventoryType::cannotRestrictPermissions(item->getInventoryType()); const BOOL is_calling_card = (item->getInventoryType() == LLInventoryType::IT_CALLINGCARD); const LLPermissions& perm = item->getPermissions(); const BOOL can_agent_manipulate = gAgent.allowOperation(PERM_OWNER, perm, - GP_OBJECT_MANIPULATE); + GP_OBJECT_MANIPULATE); const BOOL can_agent_sell = gAgent.allowOperation(PERM_OWNER, perm, - GP_OBJECT_SET_SALE) && + GP_OBJECT_SET_SALE) && !cannot_restrict_permissions; const BOOL is_link = item->getIsLinkType(); const LLUUID trash_id = gInventory.findCategoryUUIDForType(LLFolderType::FT_TRASH); - bool not_in_trash = item && (item->getUUID() != trash_id) && !gInventory.isObjectDescendentOf(item->getUUID(), trash_id); + bool not_in_trash = (item->getUUID() != trash_id) && !gInventory.isObjectDescendentOf(item->getUUID(), trash_id); // You need permission to modify the object to modify an inventory // item in it. diff --git a/indra/newview/llstylemap.cpp b/indra/newview/llstylemap.cpp index 2485563cbc..61705c4eb3 100644 --- a/indra/newview/llstylemap.cpp +++ b/indra/newview/llstylemap.cpp @@ -49,6 +49,7 @@ const LLStyle::Params &LLStyleMap::lookupAgent(const LLUUID &source) if (source != LLUUID::null && source != gAgent.getID() ) { style_params.color.control = "HTMLLinkColor"; + style_params.readonly_color.control = "HTMLLinkColor"; style_params.link_href = LLSLURL::buildCommand("agent", source, "inspect"); } @@ -56,6 +57,7 @@ const LLStyle::Params &LLStyleMap::lookupAgent(const LLUUID &source) { // Make the resident's own name white and don't make the name clickable. style_params.color = LLColor4::white; + style_params.readonly_color = LLColor4::white; } mMap[source] = style_params; @@ -75,11 +77,13 @@ const LLStyle::Params &LLStyleMap::lookup(const LLUUID& id, const std::string& l if (id != LLUUID::null && !link.empty()) { style_params.color.control = "HTMLLinkColor"; + style_params.readonly_color.control = "HTMLLinkColor"; style_params.link_href = link; } else { style_params.color = LLColor4::white; + style_params.readonly_color = LLColor4::white; } mMap[id] = style_params; } diff --git a/indra/newview/lltoastimpanel.cpp b/indra/newview/lltoastimpanel.cpp index 7ae2404203..cb43beb819 100644 --- a/indra/newview/lltoastimpanel.cpp +++ b/indra/newview/lltoastimpanel.cpp @@ -141,32 +141,6 @@ BOOL LLToastIMPanel::handleToolTip(S32 x, S32 y, MASK mask) return LLToastPanel::handleToolTip(x, y, mask); } -void LLToastIMPanel::showInspector() -{ - LLIMModel::LLIMSession* im_session = LLIMModel::getInstance()->findIMSession(mSessionID); - if(!im_session) - { - llwarns << "Invalid IM session" << llendl; - return; - } - - switch(im_session->mSessionType) - { - case LLIMModel::LLIMSession::P2P_SESSION: - LLFloaterReg::showInstance("inspect_avatar", LLSD().with("avatar_id", mAvatarID)); - break; - case LLIMModel::LLIMSession::GROUP_SESSION: - LLFloaterReg::showInstance("inspect_group", LLSD().with("group_id", mSessionID)); - break; - case LLIMModel::LLIMSession::ADHOC_SESSION: - LLFloaterReg::showInstance("inspect_avatar", LLSD().with("avatar_id", im_session->mOtherParticipantID)); - break; - default: - llwarns << "Unknown IM session type" << llendl; - break; - } -} - void LLToastIMPanel::spawnNameToolTip() { // Spawn at right side of the name textbox. @@ -176,7 +150,7 @@ void LLToastIMPanel::spawnNameToolTip() LLToolTip::Params params; params.background_visible(false); - params.click_callback(boost::bind(&LLToastIMPanel::showInspector, this)); + params.click_callback(boost::bind(&LLFloaterReg::showInstance, "inspect_avatar", LLSD().with("avatar_id", mAvatarID), FALSE)); params.delay_time(0.0f); // spawn instantly on hover params.image(LLUI::getUIImage("Info_Small")); params.message(""); @@ -201,7 +175,7 @@ void LLToastIMPanel::spawnGroupIconToolTip() LLInspector::Params params; params.fillFrom(LLUICtrlFactory::instance().getDefaultParams<LLInspector>()); - params.click_callback(boost::bind(&LLToastIMPanel::showInspector, this)); + params.click_callback(boost::bind(&LLFloaterReg::showInstance, "inspect_group", LLSD().with("group_id", mSessionID), FALSE)); params.delay_time(0.100f); params.image(LLUI::getUIImage("Info_Small")); params.message(g_data.mName); @@ -214,16 +188,15 @@ void LLToastIMPanel::spawnGroupIconToolTip() void LLToastIMPanel::initIcon() { - LLIconCtrl* sys_msg_icon = getChild<LLIconCtrl>("sys_msg_icon"); - mAvatarIcon->setVisible(FALSE); mGroupIcon->setVisible(FALSE); - sys_msg_icon->setVisible(FALSE); mAdhocIcon->setVisible(FALSE); if(mAvatarName->getValue().asString() == SYSTEM_FROM) { - sys_msg_icon->setVisible(TRUE); + // "sys_msg_icon" was disabled by Erica in the changeset: 5109 (85181bc92cbe) + // and "dummy widget" warnings appeared in log. + // It does not make sense to have such image with empty name. Removed for EXT-5057. } else { diff --git a/indra/newview/lltoolpie.cpp b/indra/newview/lltoolpie.cpp index bf1e307d71..fdf9e1df2e 100644 --- a/indra/newview/lltoolpie.cpp +++ b/indra/newview/lltoolpie.cpp @@ -1485,6 +1485,12 @@ BOOL LLToolPie::pickRightMouseDownCallback() while( object && object->isAttachment()) { object = (LLViewerObject*)object->getParent(); + llassert(object); + } + + if (!object) + { + return TRUE; // unexpected, but escape } // Object is an avatar, so check for mute by id. diff --git a/indra/newview/llviewermenufile.cpp b/indra/newview/llviewermenufile.cpp index 6bad8843fd..84b270f8cc 100644 --- a/indra/newview/llviewermenufile.cpp +++ b/indra/newview/llviewermenufile.cpp @@ -796,84 +796,88 @@ void upload_done_callback(const LLUUID& uuid, void* user_data, S32 result, LLExt //LLAssetType::EType pref_loc = data->mPreferredLocation; BOOL is_balance_sufficient = TRUE; - if(result >= 0) + if(data) { - LLFolderType::EType dest_loc = (data->mPreferredLocation == LLFolderType::FT_NONE) ? LLFolderType::assetTypeToFolderType(data->mAssetInfo.mType) : data->mPreferredLocation; - - if (LLAssetType::AT_SOUND == data->mAssetInfo.mType || - LLAssetType::AT_TEXTURE == data->mAssetInfo.mType || - LLAssetType::AT_ANIMATION == data->mAssetInfo.mType) + if (result >= 0) { - // Charge the user for the upload. - LLViewerRegion* region = gAgent.getRegion(); - - if(!(can_afford_transaction(expected_upload_cost))) - { - LLFloaterBuyCurrency::buyCurrency( - llformat(LLTrans::getString("UploadingCosts").c_str(), - data->mAssetInfo.getName().c_str()), - expected_upload_cost); - is_balance_sufficient = FALSE; - } - else if(region) + LLFolderType::EType dest_loc = (data->mPreferredLocation == LLFolderType::FT_NONE) ? LLFolderType::assetTypeToFolderType(data->mAssetInfo.mType) : data->mPreferredLocation; + + if (LLAssetType::AT_SOUND == data->mAssetInfo.mType || + LLAssetType::AT_TEXTURE == data->mAssetInfo.mType || + LLAssetType::AT_ANIMATION == data->mAssetInfo.mType) { - // Charge user for upload - gStatusBar->debitBalance(expected_upload_cost); + // Charge the user for the upload. + LLViewerRegion* region = gAgent.getRegion(); - LLMessageSystem* msg = gMessageSystem; - msg->newMessageFast(_PREHASH_MoneyTransferRequest); - msg->nextBlockFast(_PREHASH_AgentData); - msg->addUUIDFast(_PREHASH_AgentID, gAgent.getID()); - msg->addUUIDFast(_PREHASH_SessionID, gAgent.getSessionID()); - msg->nextBlockFast(_PREHASH_MoneyData); - msg->addUUIDFast(_PREHASH_SourceID, gAgent.getID()); - msg->addUUIDFast(_PREHASH_DestID, LLUUID::null); - msg->addU8("Flags", 0); - // we tell the sim how much we were expecting to pay so it - // can respond to any discrepancy - msg->addS32Fast(_PREHASH_Amount, expected_upload_cost); - msg->addU8Fast(_PREHASH_AggregatePermNextOwner, (U8)LLAggregatePermissions::AP_EMPTY); - msg->addU8Fast(_PREHASH_AggregatePermInventory, (U8)LLAggregatePermissions::AP_EMPTY); - msg->addS32Fast(_PREHASH_TransactionType, TRANS_UPLOAD_CHARGE); - msg->addStringFast(_PREHASH_Description, NULL); - msg->sendReliable(region->getHost()); + if(!(can_afford_transaction(expected_upload_cost))) + { + LLFloaterBuyCurrency::buyCurrency( + llformat(LLTrans::getString("UploadingCosts").c_str(), + data->mAssetInfo.getName().c_str()), + expected_upload_cost); + is_balance_sufficient = FALSE; + } + else if(region) + { + // Charge user for upload + gStatusBar->debitBalance(expected_upload_cost); + + LLMessageSystem* msg = gMessageSystem; + msg->newMessageFast(_PREHASH_MoneyTransferRequest); + msg->nextBlockFast(_PREHASH_AgentData); + msg->addUUIDFast(_PREHASH_AgentID, gAgent.getID()); + msg->addUUIDFast(_PREHASH_SessionID, gAgent.getSessionID()); + msg->nextBlockFast(_PREHASH_MoneyData); + msg->addUUIDFast(_PREHASH_SourceID, gAgent.getID()); + msg->addUUIDFast(_PREHASH_DestID, LLUUID::null); + msg->addU8("Flags", 0); + // we tell the sim how much we were expecting to pay so it + // can respond to any discrepancy + msg->addS32Fast(_PREHASH_Amount, expected_upload_cost); + msg->addU8Fast(_PREHASH_AggregatePermNextOwner, (U8)LLAggregatePermissions::AP_EMPTY); + msg->addU8Fast(_PREHASH_AggregatePermInventory, (U8)LLAggregatePermissions::AP_EMPTY); + msg->addS32Fast(_PREHASH_TransactionType, TRANS_UPLOAD_CHARGE); + msg->addStringFast(_PREHASH_Description, NULL); + msg->sendReliable(region->getHost()); + } } - } - if(is_balance_sufficient) - { - // Actually add the upload to inventory - llinfos << "Adding " << uuid << " to inventory." << llendl; - const LLUUID folder_id = gInventory.findCategoryUUIDForType(dest_loc); - if(folder_id.notNull()) + if(is_balance_sufficient) { - U32 next_owner_perms = data->mNextOwnerPerm; - if(PERM_NONE == next_owner_perms) + // Actually add the upload to inventory + llinfos << "Adding " << uuid << " to inventory." << llendl; + const LLUUID folder_id = gInventory.findCategoryUUIDForType(dest_loc); + if(folder_id.notNull()) { - next_owner_perms = PERM_MOVE | PERM_TRANSFER; + U32 next_owner_perms = data->mNextOwnerPerm; + if(PERM_NONE == next_owner_perms) + { + next_owner_perms = PERM_MOVE | PERM_TRANSFER; + } + create_inventory_item(gAgent.getID(), gAgent.getSessionID(), + folder_id, data->mAssetInfo.mTransactionID, data->mAssetInfo.getName(), + data->mAssetInfo.getDescription(), data->mAssetInfo.mType, + data->mInventoryType, NOT_WEARABLE, next_owner_perms, + LLPointer<LLInventoryCallback>(NULL)); + } + else + { + llwarns << "Can't find a folder to put it in" << llendl; } - create_inventory_item(gAgent.getID(), gAgent.getSessionID(), - folder_id, data->mAssetInfo.mTransactionID, data->mAssetInfo.getName(), - data->mAssetInfo.getDescription(), data->mAssetInfo.mType, - data->mInventoryType, NOT_WEARABLE, next_owner_perms, - LLPointer<LLInventoryCallback>(NULL)); - } - else - { - llwarns << "Can't find a folder to put it in" << llendl; } } - } - else // if(result >= 0) - { - LLSD args; - args["FILE"] = LLInventoryType::lookupHumanReadable(data->mInventoryType); - args["REASON"] = std::string(LLAssetStorage::getErrorString(result)); - LLNotificationsUtil::add("CannotUploadReason", args); + else // if(result >= 0) + { + LLSD args; + args["FILE"] = LLInventoryType::lookupHumanReadable(data->mInventoryType); + args["REASON"] = std::string(LLAssetStorage::getErrorString(result)); + LLNotificationsUtil::add("CannotUploadReason", args); + } } LLUploadDialog::modalUploadFinished(); delete data; + data = NULL; // *NOTE: This is a pretty big hack. What this does is check the // file picker if there are any more pending uploads. If so, diff --git a/indra/newview/llviewertexture.cpp b/indra/newview/llviewertexture.cpp index 9893eb5dce..984f003411 100644 --- a/indra/newview/llviewertexture.cpp +++ b/indra/newview/llviewertexture.cpp @@ -2995,6 +2995,10 @@ void LLViewerMediaTexture::initVirtualSize() void LLViewerMediaTexture::addMediaToFace(LLFace* facep) { + if(facep) + { + facep->setHasMedia(true) ; + } if(!mIsPlaying) { return ; //no need to add the face because the media is not in playing. @@ -3005,14 +3009,16 @@ void LLViewerMediaTexture::addMediaToFace(LLFace* facep) void LLViewerMediaTexture::removeMediaFromFace(LLFace* facep) { - if(!mIsPlaying) - { - return ; //no need to remove the face because the media is not in playing. - } if(!facep) { return ; } + facep->setHasMedia(false) ; + + if(!mIsPlaying) + { + return ; //no need to remove the face because the media is not in playing. + } mIsPlaying = FALSE ; //set to remove the media from the face. switchTexture(facep) ; diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp index 4a86e1ca41..b76a2e150f 100644 --- a/indra/newview/llviewerwindow.cpp +++ b/indra/newview/llviewerwindow.cpp @@ -2463,6 +2463,8 @@ void LLViewerWindow::updateUI() { static std::string last_handle_msg; + LLConsole::updateClass(); + // animate layout stacks so we have up to date rect for world view LLLayoutStack::updateClass(); diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index afe325856b..698b6be98b 100644 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -1492,9 +1492,9 @@ BOOL LLVOAvatar::parseSkeletonFile(const std::string& filename) //------------------------------------------------------------------------- // parse the file //------------------------------------------------------------------------- - BOOL success = sSkeletonXMLTree.parseFile( filename, FALSE ); + BOOL parsesuccess = sSkeletonXMLTree.parseFile( filename, FALSE ); - if (!success) + if (!parsesuccess) { llerrs << "Can't parse skeleton file: " << filename << llendl; return FALSE; @@ -1505,11 +1505,13 @@ BOOL LLVOAvatar::parseSkeletonFile(const std::string& filename) if (!root) { llerrs << "No root node found in avatar skeleton file: " << filename << llendl; + return FALSE; } if( !root->hasName( "linden_skeleton" ) ) { llerrs << "Invalid avatar skeleton file header: " << filename << llendl; + return FALSE; } std::string version; @@ -1517,6 +1519,7 @@ BOOL LLVOAvatar::parseSkeletonFile(const std::string& filename) if( !root->getFastAttributeString( version_string, version ) || (version != "1.0") ) { llerrs << "Invalid avatar skeleton file version: " << version << " in file: " << filename << llendl; + return FALSE; } return TRUE; @@ -2192,13 +2195,16 @@ BOOL LLVOAvatar::idleUpdate(LLAgent &agent, LLWorld &world, const F64 &time) // store off last frame's root position to be consistent with camera position LLVector3 root_pos_last = mRoot.getWorldPosition(); BOOL detailed_update = updateCharacter(agent); - BOOL voice_enabled = gVoiceClient->getVoiceEnabled( mID ) && gVoiceClient->inProximalChannel(); if (gNoRender) { return TRUE; } + static LLUICachedControl<bool> visualizers_in_calls("ShowVoiceVisualizersInCalls", false); + bool voice_enabled = (visualizers_in_calls || gVoiceClient->inProximalChannel()) && + gVoiceClient->getVoiceEnabled(mID); + idleUpdateVoiceVisualizer( voice_enabled ); idleUpdateMisc( detailed_update ); idleUpdateAppearanceAnimation(); @@ -3079,7 +3085,7 @@ BOOL LLVOAvatar::updateCharacter(LLAgent &agent) if (!visible) { - //updateMotions(LLCharacter::HIDDEN_UPDATE); + updateMotions(LLCharacter::HIDDEN_UPDATE); return FALSE; } diff --git a/indra/newview/llvoicechannel.cpp b/indra/newview/llvoicechannel.cpp index bb09a18cc3..dfd67d0c38 100644 --- a/indra/newview/llvoicechannel.cpp +++ b/indra/newview/llvoicechannel.cpp @@ -122,7 +122,8 @@ LLVoiceChannel::LLVoiceChannel(const LLUUID& session_id, const std::string& sess mState(STATE_NO_CHANNEL_INFO), mSessionName(session_name), mCallDirection(OUTGOING_CALL), - mIgnoreNextSessionLeave(FALSE) + mIgnoreNextSessionLeave(FALSE), + mCallEndedByAgent(false) { mNotifyArgs["VOICE_CHANNEL_NAME"] = mSessionName; @@ -412,7 +413,7 @@ void LLVoiceChannel::doSetState(const EState& new_state) EState old_state = mState; mState = new_state; if (!mStateChangedCallback.empty()) - mStateChangedCallback(old_state, mState, mCallDirection); + mStateChangedCallback(old_state, mState, mCallDirection, mCallEndedByAgent); } //static @@ -779,7 +780,8 @@ void LLVoiceChannelP2P::handleStatusChange(EStatusType type) } else { - // other user hung up + // other user hung up, so we didn't end the call + mCallEndedByAgent = false; } deactivate(); } @@ -810,6 +812,9 @@ void LLVoiceChannelP2P::activate() { if (callStarted()) return; + //call will be counted as ended by user unless this variable is changed in handleStatusChange() + mCallEndedByAgent = true; + LLVoiceChannel::activate(); if (callStarted()) diff --git a/indra/newview/llvoicechannel.h b/indra/newview/llvoicechannel.h index cb86671305..941cccacc3 100644 --- a/indra/newview/llvoicechannel.h +++ b/indra/newview/llvoicechannel.h @@ -58,7 +58,7 @@ public: OUTGOING_CALL } EDirection; - typedef boost::signals2::signal<void(const EState& old_state, const EState& new_state, const EDirection& direction)> state_changed_signal_t; + typedef boost::signals2::signal<void(const EState& old_state, const EState& new_state, const EDirection& direction, bool ended_by_agent)> state_changed_signal_t; // on current channel changed signal typedef boost::function<void(const LLUUID& session_id)> channel_changed_callback_t; @@ -122,6 +122,8 @@ protected: std::string mSessionName; LLSD mNotifyArgs; LLSD mCallDialogPayload; + // true if call was ended by agent + bool mCallEndedByAgent; BOOL mIgnoreNextSessionLeave; LLHandle<LLPanel> mLoginNotificationHandle; diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index bd22fc5f2e..dd9634a234 100644 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -1355,6 +1355,7 @@ void LLPipeline::updateMoveNormalAsync(LLDrawable* drawablep) if (!drawablep) { llerrs << "updateMove called with NULL drawablep" << llendl; + return; } if (drawablep->isState(LLDrawable::EARLY_MOVE)) { diff --git a/indra/newview/skins/default/xui/en/floater_outgoing_call.xml b/indra/newview/skins/default/xui/en/floater_outgoing_call.xml index cc9afe4474..2bafd1bdef 100644 --- a/indra/newview/skins/default/xui/en/floater_outgoing_call.xml +++ b/indra/newview/skins/default/xui/en/floater_outgoing_call.xml @@ -96,13 +96,24 @@ No Answer. Please try again later. height="40" layout="topleft" left="77" - name="nearby_P2P" + name="nearby_P2P_by_other" top="27" width="315" word_wrap="true"> [VOICE_CHANNEL_NAME] has ended the call. [RECONNECT_NEARBY] </text> <text + font="SansSerifLarge" + height="40" + layout="topleft" + left="77" + name="nearby_P2P_by_agent" + top="27" + width="315" + word_wrap="true"> + You have ended the call. [RECONNECT_NEARBY] + </text> + <text font="SansSerif" height="50" layout="topleft" diff --git a/indra/newview/skins/default/xui/en/floater_tools.xml b/indra/newview/skins/default/xui/en/floater_tools.xml index 5630dfbe8f..23203d227e 100644 --- a/indra/newview/skins/default/xui/en/floater_tools.xml +++ b/indra/newview/skins/default/xui/en/floater_tools.xml @@ -67,80 +67,75 @@ </floater.string> <button follows="left|top" - height="20" - image_disabled="Tool_Zoom" - image_disabled_selected="Tool_Zoom" - image_selected="Tool_Zoom_Selected" - image_unselected="Tool_Zoom" + height="25" + image_bottom_pad="1" + image_overlay="Tool_Zoom" + image_selected="PushButton_Selected_Press" layout="topleft" left="10" name="button focus" tool_tip="Focus" - width="20"> + width="35"> <button.commit_callback function="BuildTool.setTool" parameter="Focus" /> </button> <button follows="left|top" - height="20" - image_disabled="Tool_Grab" - image_disabled_selected="Tool_Grab" - image_selected="Tool_Grab_Selected" - image_unselected="Tool_Grab" + height="25" + image_bottom_pad="1" + image_overlay="Tool_Grab" + image_selected="PushButton_Selected_Press" layout="topleft" - left_pad="20" + left_pad="10" name="button move" tool_tip="Move" - width="20"> + width="35"> <button.commit_callback function="BuildTool.setTool" parameter="Move" /> </button> <button follows="left|top" - height="20" - image_disabled="Tool_Face" - image_disabled_selected="Tool_Face" - image_selected="Tool_Face_Selected" - image_unselected="Tool_Face" + height="25" + image_bottom_pad="1" + image_overlay="Tool_Face" + image_selected="PushButton_Selected_Press" layout="topleft" - left_pad="20" + left_pad="10" name="button edit" tool_tip="Edit" - width="20"> + width="35"> <button.commit_callback function="BuildTool.setTool" parameter="Edit" /> </button> <button follows="left|top" - height="20" - image_disabled="Tool_Create" - image_disabled_selected="Tool_Create" - image_selected="Tool_Create_Selected" - image_unselected="Tool_Create" + height="25" + image_bottom_pad="1" + image_overlay="Tool_Create" + image_selected="PushButton_Selected_Press" layout="topleft" - left_pad="20" + left_pad="10" name="button create" tool_tip="Create" - width="20"> + width="35"> <button.commit_callback function="BuildTool.setTool" parameter="Create" /> </button> <button follows="left|top" - height="20" - image_disabled="Tool_Dozer" - image_disabled_selected="Tool_Dozer" - image_selected="Tool_Dozer_Selected" - image_unselected="Tool_Dozer" + height="25" + image_bottom_pad="1" + image_overlay="Tool_Dozer" + image_selected="PushButton_Selected_Press" layout="topleft" - left_pad="20" + left_pad="10" name="button land" tool_tip="Land" - width="20"> + width="35"> <button.commit_callback function="BuildTool.setTool" parameter="Land" /> @@ -1043,7 +1038,7 @@ even though the user gets a free copy. <check_box height="15" width="110" - top_pad="3" + top_pad="5" label="Show in search" layout="topleft" left="100" diff --git a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml index c7e5b25e06..28c4adf67c 100644 --- a/indra/newview/skins/default/xui/en/panel_im_control_panel.xml +++ b/indra/newview/skins/default/xui/en/panel_im_control_panel.xml @@ -11,15 +11,6 @@ name="avatar_icon" top="-5" width="105"/> - <text - follows="top|left|right" - font="SansSerifLarge" - height="19" - layout="topleft" - name="avatar_name" - use_ellipses="true" - value="Unknown" - width="110" /> <layout_stack mouse_opaque="false" border_size="0" @@ -30,7 +21,7 @@ left="5" name="button_stack" orientation="vertical" - top_pad="-5" + top_pad="5" width="105"> <layout_panel mouse_opaque="false" diff --git a/indra/newview/skins/default/xui/en/panel_instant_message.xml b/indra/newview/skins/default/xui/en/panel_instant_message.xml index a0ad38cf76..34fd3352a3 100644 --- a/indra/newview/skins/default/xui/en/panel_instant_message.xml +++ b/indra/newview/skins/default/xui/en/panel_instant_message.xml @@ -56,16 +56,6 @@ name="adhoc_icon" top="3" width="18" /> - <!--<icon - follows="right" - height="20" - image_name="" - layout="topleft" - left="3" - mouse_opaque="true" - name="sys_msg_icon" - top="0" - width="20" />--> <text follows="left|right" font.style="BOLD" diff --git a/indra/newview/skins/default/xui/en/panel_picks.xml b/indra/newview/skins/default/xui/en/panel_picks.xml index 887a89d518..9ef3649d9c 100644 --- a/indra/newview/skins/default/xui/en/panel_picks.xml +++ b/indra/newview/skins/default/xui/en/panel_picks.xml @@ -24,6 +24,7 @@ bg_opaque_color="DkGray2" layout="topleft" left="6" name="picks_panel_text" + wrap="true" top="10" width="313"/> <accordion diff --git a/indra/newview/skins/default/xui/en/strings.xml b/indra/newview/skins/default/xui/en/strings.xml index a5dc14c69d..2112f7f19e 100644 --- a/indra/newview/skins/default/xui/en/strings.xml +++ b/indra/newview/skins/default/xui/en/strings.xml @@ -2129,7 +2129,7 @@ this texture in your inventory <string name="ClassifiedUpdateAfterPublish">(will update after publish)</string> <!-- panel picks --> - <string name="NoPicksClassifiedsText">There are no picks/classifieds here</string> + <string name="NoPicksClassifiedsText">You haven't created any Picks or Classifieds. Click the Plus button below to create a Pick or Classified.</string> <string name="PicksClassifiedsLoadingText">Loading...</string> <!-- Multi Preview Floater --> |