diff options
53 files changed, 330 insertions, 78 deletions
diff --git a/indra/llcommon/llchat.h b/indra/llcommon/llchat.h index 5af7991006..46456882ba 100644 --- a/indra/llcommon/llchat.h +++ b/indra/llcommon/llchat.h @@ -87,7 +87,8 @@ public: mTimeStr(), mPosAgent(), mURL(), - mChatStyle(CHAT_STYLE_NORMAL) + mChatStyle(CHAT_STYLE_NORMAL), + mSessionID() { } std::string mText; // UTF-8 line of text @@ -102,6 +103,7 @@ public: LLVector3 mPosAgent; std::string mURL; EChatStyle mChatStyle; + LLUUID mSessionID; }; #endif diff --git a/indra/llmath/llinterp.h b/indra/llmath/llinterp.h index 36ca2e9865..88af004170 100644 --- a/indra/llmath/llinterp.h +++ b/indra/llmath/llinterp.h @@ -54,7 +54,7 @@ template <typename Type> class LLInterp { public: - LLInterp(); + LLInterp(); virtual ~LLInterp() {} virtual void start(); @@ -151,6 +151,7 @@ protected: template <typename Type> LLInterp<Type>::LLInterp() +: mStartVal(Type()), mEndVal(Type()), mCurVal(Type()) { mStartTime = 0.f; mEndTime = 1.f; diff --git a/indra/llprimitive/llprimitive.cpp b/indra/llprimitive/llprimitive.cpp index 5ad758072c..b75d1b0f67 100644 --- a/indra/llprimitive/llprimitive.cpp +++ b/indra/llprimitive/llprimitive.cpp @@ -154,6 +154,7 @@ bool LLPrimitive::cleanupVolumeManager() //=============================================================== LLPrimitive::LLPrimitive() : mTextureList(), + mNumTEs(0), mMiscFlags(0) { mPrimitiveCode = 0; diff --git a/indra/llui/llcombobox.cpp b/indra/llui/llcombobox.cpp index f29e8785eb..9d23daf56d 100644 --- a/indra/llui/llcombobox.cpp +++ b/indra/llui/llcombobox.cpp @@ -103,7 +103,8 @@ LLComboBox::LLComboBox(const LLComboBox::Params& p) mPrearrangeCallback(p.prearrange_callback()), mTextEntryCallback(p.text_entry_callback()), mListPosition(p.list_position), - mLastSelectedIndex(-1) + mLastSelectedIndex(-1), + mLabel(p.label) { // Text label button @@ -490,6 +491,7 @@ void LLComboBox::createLineEditor(const LLComboBox::Params& p) params.handle_edit_keys_directly(true); params.commit_on_focus_lost(false); params.follows.flags(FOLLOWS_ALL); + params.label(mLabel); mTextEntry = LLUICtrlFactory::create<LLLineEditor> (params); mTextEntry->setText(cur_label); mTextEntry->setIgnoreTab(TRUE); @@ -505,7 +507,8 @@ void LLComboBox::createLineEditor(const LLComboBox::Params& p) mButton->setRect(rect); mButton->setTabStop(TRUE); mButton->setHAlign(LLFontGL::LEFT); - + mButton->setLabel(mLabel.getString()); + if (mTextEntry) { mTextEntry->setVisible(FALSE); @@ -633,7 +636,7 @@ void LLComboBox::hideList() if(mLastSelectedIndex >= 0) mList->selectNthItem(mLastSelectedIndex); } - else + else if(mLastSelectedIndex >= 0) mList->selectNthItem(mLastSelectedIndex); mButton->setToggleState(FALSE); diff --git a/indra/llui/lldraghandle.cpp b/indra/llui/lldraghandle.cpp index a93c666648..832f148902 100644 --- a/indra/llui/lldraghandle.cpp +++ b/indra/llui/lldraghandle.cpp @@ -113,6 +113,7 @@ void LLDragHandleTop::setTitle(const std::string& title) params.follows.flags(FOLLOWS_TOP | FOLLOWS_LEFT | FOLLOWS_RIGHT); params.font_shadow(LLFontGL::DROP_SHADOW_SOFT); params.use_ellipses = true; + params.allow_html = false; //cancel URL replacement in floater title mTitleBox = LLUICtrlFactory::create<LLTextBox> (params); addChild( mTitleBox ); } diff --git a/indra/llui/llfloater.cpp b/indra/llui/llfloater.cpp index 79d8f90fec..de46d89d6f 100644 --- a/indra/llui/llfloater.cpp +++ b/indra/llui/llfloater.cpp @@ -1916,9 +1916,10 @@ static LLDefaultChildRegistry::Register<LLFloaterView> r("floater_view"); LLFloaterView::LLFloaterView (const Params& p) : LLUICtrl (p), + mFocusCycleMode(FALSE), - mSnapOffsetBottom(0) - ,mSnapOffsetRight(0) + mSnapOffsetBottom(0), + mSnapOffsetRight(0) { } diff --git a/indra/llui/llfloater.h b/indra/llui/llfloater.h index f70495c0f0..8c9dacbd20 100644 --- a/indra/llui/llfloater.h +++ b/indra/llui/llfloater.h @@ -468,9 +468,6 @@ public: void setSnapOffsetRight(S32 offset) { mSnapOffsetRight = offset; } private: - S32 mColumn; - S32 mNextLeft; - S32 mNextTop; BOOL mFocusCycleMode; S32 mSnapOffsetBottom; S32 mSnapOffsetRight; diff --git a/indra/llui/llmenugl.cpp b/indra/llui/llmenugl.cpp index ceb1e9820e..7fa9a88059 100644 --- a/indra/llui/llmenugl.cpp +++ b/indra/llui/llmenugl.cpp @@ -1651,6 +1651,7 @@ LLMenuGL::LLMenuGL(const LLMenuGL::Params& p) mBackgroundColor( p.bg_color() ), mBgVisible( p.bg_visible ), mDropShadowed( p.drop_shadow ), + mHasSelection(false), mHorizontalLayout( p.horizontal_layout ), mScrollable(mHorizontalLayout ? FALSE : p.scrollable), // Scrolling is supported only for vertical layout mMaxScrollableItems(p.max_scrollable_items), @@ -2813,7 +2814,7 @@ BOOL LLMenuGL::handleHover( S32 x, S32 y, MASK mask ) ((LLMenuItemGL*)viewp)->setHighlight(TRUE); LLMenuGL::setKeyboardMode(FALSE); } - mHasSelection = TRUE; + mHasSelection = true; } } } @@ -2892,7 +2893,7 @@ void LLMenuGL::setVisible(BOOL visible) } else { - mHasSelection = FALSE; + mHasSelection = true; mFadeTimer.stop(); } diff --git a/indra/llui/llmenugl.h b/indra/llui/llmenugl.h index 61e06f9e5f..8441aaadd4 100644 --- a/indra/llui/llmenugl.h +++ b/indra/llui/llmenugl.h @@ -546,7 +546,7 @@ private: LLHandle<LLView> mParentMenuItem; LLUIString mLabel; BOOL mDropShadowed; // Whether to drop shadow - BOOL mHasSelection; + bool mHasSelection; LLFrameTimer mFadeTimer; LLTimer mScrollItemsTimer; BOOL mTornOff; diff --git a/indra/llui/llscrolllistctrl.cpp b/indra/llui/llscrolllistctrl.cpp index 78386220d9..478e270c98 100644 --- a/indra/llui/llscrolllistctrl.cpp +++ b/indra/llui/llscrolllistctrl.cpp @@ -1534,7 +1534,7 @@ LLRect LLScrollListCtrl::getCellRect(S32 row_index, S32 column_index) S32 rect_bottom = getRowOffsetFromIndex(row_index); LLScrollListColumn* columnp = getColumn(column_index); cell_rect.setOriginAndSize(rect_left, rect_bottom, - rect_left + columnp->getWidth(), mLineHeight); + /*rect_left + */columnp->getWidth(), mLineHeight); return cell_rect; } diff --git a/indra/llui/llstyle.cpp b/indra/llui/llstyle.cpp index 71511f69a4..b8f93b6a0e 100644 --- a/indra/llui/llstyle.cpp +++ b/indra/llui/llstyle.cpp @@ -49,7 +49,10 @@ LLStyle::Params::Params() LLStyle::LLStyle(const LLStyle::Params& p) -: mVisible(p.visible), +: mItalic(FALSE), + mBold(FALSE), + mUnderline(FALSE), + mVisible(p.visible), mColor(p.color()), mReadOnlyColor(p.readonly_color()), mFont(p.font()), diff --git a/indra/llui/lltooltip.cpp b/indra/llui/lltooltip.cpp index 01c7a81309..173fde8e76 100644 --- a/indra/llui/lltooltip.cpp +++ b/indra/llui/lltooltip.cpp @@ -400,7 +400,8 @@ bool LLToolTip::hasClickCallback() // LLToolTipMgr::LLToolTipMgr() -: mToolTip(NULL), +: mToolTipsBlocked(false), + mToolTip(NULL), mNeedsToolTip(false) {} diff --git a/indra/llui/lluistring.h b/indra/llui/lluistring.h index 7ec0fd603a..32cfc0d9cd 100644 --- a/indra/llui/lluistring.h +++ b/indra/llui/lluistring.h @@ -64,7 +64,7 @@ class LLUIString public: // These methods all perform appropriate argument substitution // and modify mOrig where appropriate - LLUIString() {} + LLUIString() : mNeedsResult(false), mNeedsWResult(false) {} LLUIString(const std::string& instring, const LLStringUtil::format_map_t& args); LLUIString(const std::string& instring) { assign(instring); } diff --git a/indra/newview/llchathistory.cpp b/indra/newview/llchathistory.cpp index dd9f0c2ebe..f1e7e622b3 100644 --- a/indra/newview/llchathistory.cpp +++ b/indra/newview/llchathistory.cpp @@ -34,6 +34,7 @@ #include "llinstantmessage.h" +#include "llimview.h" #include "llchathistory.h" #include "llcommandhandler.h" #include "llpanel.h" @@ -219,6 +220,7 @@ public: void setup(const LLChat& chat,const LLStyle::Params& style_params) { mAvatarID = chat.mFromID; + mSessionID = chat.mSessionID; mSourceType = chat.mSourceType; gCacheName->get(mAvatarID, FALSE, boost::bind(&LLChatHistoryHeader::nameUpdatedCallback, this, _1, _2, _3, _4)); if(chat.mFromID.isNull()) @@ -341,6 +343,11 @@ protected: menu->setItemEnabled("Remove Friend", false); } + if (mSessionID == LLIMMgr::computeSessionID(IM_NOTHING_SPECIAL, mAvatarID)) + { + menu->setItemVisible("Send IM", false); + } + menu->buildDrawLabels(); menu->updateParent(LLMenuGL::sMenuContainer); LLMenuGL::showPopup(this, menu, x, y); @@ -380,6 +387,7 @@ protected: std::string mFirstName; std::string mLastName; std::string mFrom; + LLUUID mSessionID; S32 mMinUserNameWidth; }; diff --git a/indra/newview/llcompilequeue.cpp b/indra/newview/llcompilequeue.cpp index 5c05a54120..a96981a108 100644 --- a/indra/newview/llcompilequeue.cpp +++ b/indra/newview/llcompilequeue.cpp @@ -92,7 +92,8 @@ struct LLScriptQueueData // Default constructor LLFloaterScriptQueue::LLFloaterScriptQueue(const LLSD& key) : LLFloater(key), - mDone(FALSE) + mDone(false), + mMono(false) { //Called from floater reg: LLUICtrlFactory::getInstance()->buildFloater(this,"floater_script_queue.xml", FALSE); } @@ -216,7 +217,7 @@ BOOL LLFloaterScriptQueue::nextObject() } while((mObjectIDs.count() > 0) && !successful_start); if(isDone() && !mDone) { - mDone = TRUE; + mDone = true; getChild<LLScrollListCtrl>("queue output")->setCommentText(getString("Done")); childSetEnabled("close",TRUE); } diff --git a/indra/newview/llcompilequeue.h b/indra/newview/llcompilequeue.h index 063d573239..2d061f5d8a 100644 --- a/indra/newview/llcompilequeue.h +++ b/indra/newview/llcompilequeue.h @@ -104,10 +104,10 @@ protected: // Object Queue LLDynamicArray<LLUUID> mObjectIDs; LLUUID mCurrentObjectID; - BOOL mDone; + bool mDone; std::string mStartString; - BOOL mMono; + bool mMono; }; //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ diff --git a/indra/newview/lleventnotifier.cpp b/indra/newview/lleventnotifier.cpp index edfb9dc864..f096ba604f 100644 --- a/indra/newview/lleventnotifier.cpp +++ b/indra/newview/lleventnotifier.cpp @@ -174,6 +174,7 @@ void LLEventNotifier::remove(const U32 event_id) LLEventNotification::LLEventNotification() : mEventID(0), + mEventDate(0), mEventName("") { } diff --git a/indra/newview/llfloateranimpreview.h b/indra/newview/llfloateranimpreview.h index dd2c0b809a..3ee1f419ab 100644 --- a/indra/newview/llfloateranimpreview.h +++ b/indra/newview/llfloateranimpreview.h @@ -127,7 +127,6 @@ protected: LLRectf mPreviewImageRect; LLAssetID mMotionID; LLTransactionID mTransactionID; - BOOL mEnabled; LLAnimPauseRequest mPauseRequest; std::map<std::string, LLUUID> mIDList; diff --git a/indra/newview/llfloaterhardwaresettings.cpp b/indra/newview/llfloaterhardwaresettings.cpp index 31b494b590..b2564eb2b6 100644 --- a/indra/newview/llfloaterhardwaresettings.cpp +++ b/indra/newview/llfloaterhardwaresettings.cpp @@ -50,7 +50,17 @@ #include "llsliderctrl.h" LLFloaterHardwareSettings::LLFloaterHardwareSettings(const LLSD& key) - : LLFloater(key) + : LLFloater(key), + + // these should be set on imminent refresh() call, + // but init them anyway + mUseVBO(0), + mUseAniso(0), + mFSAASamples(0), + mGamma(0.0), + mVideoCardMem(0), + mFogRatio(0.0), + mProbeHardwareOnStartup(FALSE) { //LLUICtrlFactory::getInstance()->buildFloater(this, "floater_hardware_settings.xml"); } diff --git a/indra/newview/llfloaterjoystick.cpp b/indra/newview/llfloaterjoystick.cpp index 06fe2a84c8..78bc63ac8c 100644 --- a/indra/newview/llfloaterjoystick.cpp +++ b/indra/newview/llfloaterjoystick.cpp @@ -52,6 +52,7 @@ LLFloaterJoystick::LLFloaterJoystick(const LLSD& data) { //Called from floater reg: LLUICtrlFactory::getInstance()->buildFloater(this, "floater_joystick.xml"); + initFromSettings(); } void LLFloaterJoystick::draw() @@ -123,10 +124,8 @@ void LLFloaterJoystick::apply() { } -void LLFloaterJoystick::refresh() +void LLFloaterJoystick::initFromSettings() { - LLFloater::refresh(); - mJoystickEnabled = gSavedSettings.getBOOL("JoystickEnabled"); mJoystickAxis[0] = gSavedSettings.getS32("JoystickAxis0"); @@ -194,6 +193,12 @@ void LLFloaterJoystick::refresh() mFlycamFeathering = gSavedSettings.getF32("FlycamFeathering"); } +void LLFloaterJoystick::refresh() +{ + LLFloater::refresh(); + initFromSettings(); +} + void LLFloaterJoystick::cancel() { gSavedSettings.setBOOL("JoystickEnabled", mJoystickEnabled); diff --git a/indra/newview/llfloaterjoystick.h b/indra/newview/llfloaterjoystick.h index f3559c28e9..7a2f497c69 100644 --- a/indra/newview/llfloaterjoystick.h +++ b/indra/newview/llfloaterjoystick.h @@ -55,6 +55,8 @@ private: LLFloaterJoystick(const LLSD& data); virtual ~LLFloaterJoystick(); + + void initFromSettings(); static void onCommitJoystickEnabled(LLUICtrl*, void*); static void onClickRestoreSNDefaults(void*); diff --git a/indra/newview/llfloatermap.cpp b/indra/newview/llfloatermap.cpp index d18f127f85..568f4b254e 100644 --- a/indra/newview/llfloatermap.cpp +++ b/indra/newview/llfloatermap.cpp @@ -112,6 +112,7 @@ BOOL LLFloaterMap::postBuild() sendChildToBack(getDragHandle()); setIsChrome(TRUE); + getDragHandle()->setTitleVisible(TRUE); // keep onscreen gFloaterView->adjustToFitScreen(this, FALSE); diff --git a/indra/newview/llfloatersnapshot.cpp b/indra/newview/llfloatersnapshot.cpp index afb58c9407..94c7ff6f94 100644 --- a/indra/newview/llfloatersnapshot.cpp +++ b/indra/newview/llfloatersnapshot.cpp @@ -1028,7 +1028,8 @@ class LLFloaterSnapshot::Impl public: Impl() : mAvatarPauseHandles(), - mLastToolset(NULL) + mLastToolset(NULL), + mAspectRatioCheckOff(false) { } ~Impl() @@ -1079,7 +1080,7 @@ public: LLToolset* mLastToolset; LLHandle<LLView> mPreviewHandle; - BOOL mAspectRatioCheckOff ; + bool mAspectRatioCheckOff ; }; // static @@ -1606,7 +1607,7 @@ void LLFloaterSnapshot::Impl::checkAspectRatio(LLFloaterSnapshot *view, S32 inde if(0 == index) //current window size { - view->impl.mAspectRatioCheckOff = TRUE ; + view->impl.mAspectRatioCheckOff = true ; view->childSetEnabled("keep_aspect_check", FALSE) ; if(previewp) @@ -1616,7 +1617,7 @@ void LLFloaterSnapshot::Impl::checkAspectRatio(LLFloaterSnapshot *view, S32 inde } else if(-1 == index) //custom { - view->impl.mAspectRatioCheckOff = FALSE ; + view->impl.mAspectRatioCheckOff = false ; //if(LLSnapshotLivePreview::SNAPSHOT_TEXTURE != gSavedSettings.getS32("LastSnapshotType")) { view->childSetEnabled("keep_aspect_check", TRUE) ; @@ -1629,7 +1630,7 @@ void LLFloaterSnapshot::Impl::checkAspectRatio(LLFloaterSnapshot *view, S32 inde } else { - view->impl.mAspectRatioCheckOff = TRUE ; + view->impl.mAspectRatioCheckOff = true ; view->childSetEnabled("keep_aspect_check", FALSE) ; if(previewp) diff --git a/indra/newview/llfolderview.cpp b/indra/newview/llfolderview.cpp index b833c611bf..c6135d3bc3 100644 --- a/indra/newview/llfolderview.cpp +++ b/indra/newview/llfolderview.cpp @@ -1508,10 +1508,26 @@ BOOL LLFolderView::handleKeyHere( KEY key, MASK mask ) { if (next == last_selected) { + //special case for LLAccordionCtrl + if(notifyParent(LLSD().with("action","select_next")) > 0 )//message was processed + { + clearSelection(); + return TRUE; + } return FALSE; } setSelection( next, FALSE, TRUE ); } + else + { + //special case for LLAccordionCtrl + if(notifyParent(LLSD().with("action","select_next")) > 0 )//message was processed + { + clearSelection(); + return TRUE; + } + return FALSE; + } } scrollToShowSelection(); mSearchString.clear(); @@ -1556,6 +1572,13 @@ BOOL LLFolderView::handleKeyHere( KEY key, MASK mask ) { if (prev == this) { + // If case we are in accordion tab notify parent to go to the previous accordion + if(notifyParent(LLSD().with("action","select_prev")) > 0 )//message was processed + { + clearSelection(); + return TRUE; + } + return FALSE; } setSelection( prev, FALSE, TRUE ); @@ -2241,6 +2264,83 @@ void LLFolderView::updateRenamerPosition() } } +bool LLFolderView::selectFirstItem() +{ + for (folders_t::iterator iter = mFolders.begin(); + iter != mFolders.end();) + { + LLFolderViewFolder* folder = (*iter ); + if (folder->getVisible()) + { + LLFolderViewItem* itemp = folder->getNextFromChild(0,true); + if(itemp) + setSelection(itemp,FALSE,TRUE); + return true; + } + + } + for(items_t::iterator iit = mItems.begin(); + iit != mItems.end(); ++iit) + { + LLFolderViewItem* itemp = (*iit); + if (itemp->getVisible()) + { + setSelection(itemp,FALSE,TRUE); + return true; + } + } + return false; +} +bool LLFolderView::selectLastItem() +{ + for(items_t::reverse_iterator iit = mItems.rbegin(); + iit != mItems.rend(); ++iit) + { + LLFolderViewItem* itemp = (*iit); + if (itemp->getVisible()) + { + setSelection(itemp,FALSE,TRUE); + return true; + } + } + for (folders_t::reverse_iterator iter = mFolders.rbegin(); + iter != mFolders.rend();) + { + LLFolderViewFolder* folder = (*iter); + if (folder->getVisible()) + { + LLFolderViewItem* itemp = folder->getPreviousFromChild(0,true); + if(itemp) + setSelection(itemp,FALSE,TRUE); + return true; + } + } + return false; +} + + +S32 LLFolderView::notify(const LLSD& info) +{ + if(info.has("action")) + { + std::string str_action = info["action"]; + if(str_action == "select_first") + { + setFocus(true); + selectFirstItem(); + return 1; + + } + else if(str_action == "select_last") + { + setFocus(true); + selectLastItem(); + return 1; + } + } + return 0; +} + ///---------------------------------------------------------------------------- /// Local function definitions diff --git a/indra/newview/llfolderview.h b/indra/newview/llfolderview.h index 89e1865e35..56ebdfcf79 100644 --- a/indra/newview/llfolderview.h +++ b/indra/newview/llfolderview.h @@ -266,6 +266,8 @@ public: LLPanel* getParentPanel() { return mParentPanel; } // DEBUG only void dumpSelectionInformation(); + + virtual S32 notify(const LLSD& info) ; private: void updateRenamerPosition(); @@ -278,6 +280,9 @@ protected: void finishRenamingItem( void ); void closeRenamer( void ); + + bool selectFirstItem(); + bool selectLastItem(); protected: LLHandle<LLView> mPopupMenuHandle; diff --git a/indra/newview/llimfloater.cpp b/indra/newview/llimfloater.cpp index 73597e7de3..c0f22fcea2 100644 --- a/indra/newview/llimfloater.cpp +++ b/indra/newview/llimfloater.cpp @@ -599,6 +599,7 @@ void LLIMFloater::updateMessages() LLChat chat; chat.mFromID = from_id; + chat.mSessionID = mSessionID; chat.mFromName = from; chat.mText = message; chat.mTimeStr = time; diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp index c4b1d7a9f4..1254664330 100644 --- a/indra/newview/llimview.cpp +++ b/indra/newview/llimview.cpp @@ -1498,9 +1498,11 @@ void LLCallDialogManager::onVoiceChannelStateChanged(const LLVoiceChannel::EStat //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ // Class LLCallDialog //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -LLCallDialog::LLCallDialog(const LLSD& payload) : -LLDockableFloater(NULL, false, payload), -mPayload(payload) +LLCallDialog::LLCallDialog(const LLSD& payload) + : LLDockableFloater(NULL, false, payload), + + mPayload(payload), + mLifetime(DEFAULT_LIFETIME) { } diff --git a/indra/newview/lllocationinputctrl.cpp b/indra/newview/lllocationinputctrl.cpp index 7f49a7defb..050cfcc3d9 100644 --- a/indra/newview/lllocationinputctrl.cpp +++ b/indra/newview/lllocationinputctrl.cpp @@ -39,6 +39,7 @@ #include "llbutton.h" #include "llfocusmgr.h" #include "llmenugl.h" +#include "llparcel.h" #include "llstring.h" #include "lltrans.h" #include "lluictrlfactory.h" @@ -672,11 +673,12 @@ void LLLocationInputCtrl::refreshParcelIcons() if (show_properties) { LLViewerParcelMgr* vpm = LLViewerParcelMgr::getInstance(); - bool allow_buy = vpm->canAgentBuyParcel( vpm->getAgentParcel(), false); + LLParcel* agent_parcel = vpm->getAgentParcel(); + bool allow_buy = vpm->canAgentBuyParcel( agent_parcel, false); bool allow_voice = vpm->allowAgentVoice(); bool allow_fly = vpm->allowAgentFly(); bool allow_push = vpm->allowAgentPush(); - bool allow_build = vpm->allowAgentBuild(); + bool allow_build = agent_parcel && agent_parcel->getAllowModify(); // true when anyone is allowed to build. See EXT-4610. bool allow_scripts = vpm->allowAgentScripts(); bool allow_damage = vpm->allowAgentDamage(); diff --git a/indra/newview/llmanipscale.cpp b/indra/newview/llmanipscale.cpp index 84a5eb7352..ee3ffa2450 100644 --- a/indra/newview/llmanipscale.cpp +++ b/indra/newview/llmanipscale.cpp @@ -180,6 +180,7 @@ LLManipScale::LLManipScale( LLToolComposite* composite ) mScaleSnapUnit2(1.f), mSnapRegimeOffset(0.f), mSnapGuideLength(0.f), + mInSnapRegime(FALSE), mScaleSnapValue(0.f) { mManipulatorScales = new F32[NUM_MANIPULATORS]; diff --git a/indra/newview/llmaniptranslate.cpp b/indra/newview/llmaniptranslate.cpp index 5f30ab4e01..52fe31fbba 100644 --- a/indra/newview/llmaniptranslate.cpp +++ b/indra/newview/llmaniptranslate.cpp @@ -123,9 +123,13 @@ LLManipTranslate::LLManipTranslate( LLToolComposite* composite ) mAxisArrowLength(50), mConeSize(0), mArrowLengthMeters(0.f), + mGridSizeMeters(1.f), mPlaneManipOffsetMeters(0.f), mUpdateTimer(), mSnapOffsetMeters(0.f), + mSubdivisions(10.f), + mInSnapRegime(FALSE), + mSnapped(FALSE), mArrowScales(1.f, 1.f, 1.f), mPlaneScales(1.f, 1.f, 1.f), mPlaneManipPositions(1.f, 1.f, 1.f, 1.f) diff --git a/indra/newview/llpanelavatar.cpp b/indra/newview/llpanelavatar.cpp index fe5b20813a..48dd5513bd 100644 --- a/indra/newview/llpanelavatar.cpp +++ b/indra/newview/llpanelavatar.cpp @@ -635,6 +635,9 @@ void LLPanelAvatarProfile::fillCommonData(const LLAvatarData* avatar_data) childSetValue("2nd_life_pic", avatar_data->image_id); childSetValue("real_world_pic", avatar_data->fl_image_id); childSetValue("homepage_edit", avatar_data->profile_url); + + // Hide home page textbox if no page was set to fix "homepage URL appears clickable without URL - EXT-4734" + childSetVisible("homepage_edit", !avatar_data->profile_url.empty()); } void LLPanelAvatarProfile::fillPartnerData(const LLAvatarData* avatar_data) diff --git a/indra/newview/llpanelgroup.cpp b/indra/newview/llpanelgroup.cpp index ac58c35b06..469f1c1739 100644 --- a/indra/newview/llpanelgroup.cpp +++ b/indra/newview/llpanelgroup.cpp @@ -89,8 +89,8 @@ BOOL LLPanelGroupTab::postBuild() LLPanelGroup::LLPanelGroup() : LLPanel(), LLGroupMgrObserver( LLUUID() ), - mAllowEdit( TRUE ) - ,mShowingNotifyDialog(false) + mSkipRefresh(FALSE), + mShowingNotifyDialog(false) { // Set up the factory callbacks. // Roles sub tabs @@ -168,7 +168,6 @@ BOOL LLPanelGroup::postBuild() button = getChild<LLButton>("btn_refresh"); button->setClickedCallback(onBtnRefresh, this); - button->setVisible(mAllowEdit); getChild<LLButton>("btn_create")->setVisible(false); @@ -492,7 +491,12 @@ bool LLPanelGroup::apply(LLPanelGroupTab* tab) std::string apply_mesg; if(tab->apply( apply_mesg ) ) + { + //we skip refreshing group after ew manually apply changes since its very annoying + //for those who are editing group + mSkipRefresh = TRUE; return true; + } if ( !apply_mesg.empty() ) { @@ -539,6 +543,11 @@ void LLPanelGroup::draw() void LLPanelGroup::refreshData() { + if(mSkipRefresh) + { + mSkipRefresh = FALSE; + return; + } LLGroupMgr::getInstance()->clearGroupData(getID()); setGroupID(getID()); diff --git a/indra/newview/llpanelgroup.h b/indra/newview/llpanelgroup.h index 8c84695677..6e23eedffb 100644 --- a/indra/newview/llpanelgroup.h +++ b/indra/newview/llpanelgroup.h @@ -85,9 +85,6 @@ public: virtual void reshape(S32 width, S32 height, BOOL called_from_parent = TRUE); - void setAllowEdit(BOOL v) { mAllowEdit = v; } - - static void refreshCreatedGroup(const LLUUID& group_id); static void showNotice(const std::string& subject, @@ -126,7 +123,7 @@ protected: LLTimer mRefreshTimer; - BOOL mAllowEdit; + BOOL mSkipRefresh; std::string mDefaultNeedsApplyMesg; std::string mWantApplyMesg; @@ -169,8 +166,6 @@ public: virtual BOOL isVisibleByAgent(LLAgent* agentp); - void setAllowEdit(BOOL v) { mAllowEdit = v; } - virtual void setGroupID(const LLUUID& id) {mGroupID = id;}; void notifyObservers() {}; diff --git a/indra/newview/llpanelplaces.h b/indra/newview/llpanelplaces.h index 5de78b1595..110d7a1054 100644 --- a/indra/newview/llpanelplaces.h +++ b/indra/newview/llpanelplaces.h @@ -32,9 +32,9 @@ #ifndef LL_LLPANELPLACES_H #define LL_LLPANELPLACES_H -#include "llpanel.h" +#include "lltimer.h" -class LLTimer; +#include "llpanel.h" class LLInventoryItem; class LLFilterEditor; diff --git a/indra/newview/llplacesinventorypanel.cpp b/indra/newview/llplacesinventorypanel.cpp index 4de953a59d..8edeebaeeb 100644 --- a/indra/newview/llplacesinventorypanel.cpp +++ b/indra/newview/llplacesinventorypanel.cpp @@ -143,6 +143,23 @@ void LLPlacesInventoryPanel::restoreFolderState() getRootFolder()->scrollToShowSelection(); } +S32 LLPlacesInventoryPanel::notify(const LLSD& info) +{ + if(info.has("action")) + { + std::string str_action = info["action"]; + if(str_action == "select_first") + { + return getRootFolder()->notify(info); + } + else if(str_action == "select_last") + { + return getRootFolder()->notify(info); + } + } + return 0; +} + /************************************************************************/ /* PROTECTED METHODS */ /************************************************************************/ diff --git a/indra/newview/llplacesinventorypanel.h b/indra/newview/llplacesinventorypanel.h index 7b34045d32..86937e7c7f 100644 --- a/indra/newview/llplacesinventorypanel.h +++ b/indra/newview/llplacesinventorypanel.h @@ -57,6 +57,8 @@ public: void saveFolderState(); void restoreFolderState(); + virtual S32 notify(const LLSD& info) ; + private: LLSaveFolderState* mSavedFolderState; }; diff --git a/indra/newview/llselectmgr.cpp b/indra/newview/llselectmgr.cpp index 6f76715e73..bf08756051 100644 --- a/indra/newview/llselectmgr.cpp +++ b/indra/newview/llselectmgr.cpp @@ -218,7 +218,8 @@ LLSelectMgr::LLSelectMgr() mHoverObjects = new LLObjectSelection(); mHighlightedObjects = new LLObjectSelection(); - + mForceSelection = FALSE; + mShowSelection = FALSE; } diff --git a/indra/newview/lltoastimpanel.cpp b/indra/newview/lltoastimpanel.cpp index d62017cc2f..89a58cd736 100644 --- a/indra/newview/lltoastimpanel.cpp +++ b/indra/newview/lltoastimpanel.cpp @@ -33,22 +33,25 @@ #include "llviewerprecompiledheaders.h" #include "lltoastimpanel.h" +#include "llfloaterreg.h" #include "llnotifications.h" #include "llinstantmessage.h" +#include "lltooltip.h" + #include "llviewerchat.h" const S32 LLToastIMPanel::DEFAULT_MESSAGE_MAX_LINE_COUNT = 6; //-------------------------------------------------------------------------- LLToastIMPanel::LLToastIMPanel(LLToastIMPanel::Params &p) : LLToastPanel(p.notification), - mAvatar(NULL), mUserName(NULL), + mAvatarIcon(NULL), mAvatarName(NULL), mTime(NULL), mMessage(NULL) { LLUICtrlFactory::getInstance()->buildPanel(this, "panel_instant_message.xml"); LLIconCtrl* sys_msg_icon = getChild<LLIconCtrl>("sys_msg_icon"); - mAvatar = getChild<LLAvatarIconCtrl>("avatar_icon"); - mUserName = getChild<LLTextBox>("user_name"); + mAvatarIcon = getChild<LLAvatarIconCtrl>("avatar_icon"); + mAvatarName = getChild<LLTextBox>("user_name"); mTime = getChild<LLTextBox>("time_box"); mMessage = getChild<LLTextBox>("message"); @@ -77,22 +80,23 @@ LLToastIMPanel::LLToastIMPanel(LLToastIMPanel::Params &p) : LLToastPanel(p.notif mMessage->setValue(p.message); } - mUserName->setValue(p.from); + mAvatarName->setValue(p.from); mTime->setValue(p.time); mSessionID = p.session_id; + mAvatarID = p.avatar_id; mNotification = p.notification; if(p.from == SYSTEM_FROM) { - mAvatar->setVisible(FALSE); + mAvatarIcon->setVisible(FALSE); sys_msg_icon->setVisible(TRUE); } else { - mAvatar->setVisible(TRUE); + mAvatarIcon->setVisible(TRUE); sys_msg_icon->setVisible(FALSE); - mAvatar->setValue(p.avatar_id); + mAvatarIcon->setValue(p.avatar_id); } S32 maxLinesCount; @@ -119,3 +123,36 @@ BOOL LLToastIMPanel::handleMouseDown(S32 x, S32 y, MASK mask) return TRUE; } + +//virtual +BOOL LLToastIMPanel::handleToolTip(S32 x, S32 y, MASK mask) +{ + // It's not our direct child, so parentPointInView() doesn't work. + LLRect name_rect; + mAvatarName->localRectToOtherView(mAvatarName->getLocalRect(), &name_rect, this); + if (!name_rect.pointInRect(x, y)) + return LLToastPanel::handleToolTip(x, y, mask); + + // Spawn at right side of the name textbox. + LLRect sticky_rect = mAvatarName->calcScreenRect(); + S32 icon_x = llmin(sticky_rect.mLeft + mAvatarName->getTextPixelWidth() + 3, sticky_rect.mRight - 16); + LLCoordGL pos(icon_x, sticky_rect.mTop); + + LLToolTip::Params params; + params.background_visible(false); + params.click_callback(boost::bind(&LLToastIMPanel::showInspector, this)); + params.delay_time(0.0f); // spawn instantly on hover + params.image(LLUI::getUIImage("Info_Small")); + params.message(""); + params.padding(0); + params.pos(pos); + params.sticky_rect(sticky_rect); + + LLToolTipMgr::getInstance()->show(params); + return TRUE; +} + +void LLToastIMPanel::showInspector() +{ + LLFloaterReg::showInstance("inspect_avatar", LLSD().with("avatar_id", mAvatarID)); +} diff --git a/indra/newview/lltoastimpanel.h b/indra/newview/lltoastimpanel.h index 53661f2cf6..154e6dae16 100644 --- a/indra/newview/lltoastimpanel.h +++ b/indra/newview/lltoastimpanel.h @@ -58,13 +58,16 @@ public: LLToastIMPanel(LLToastIMPanel::Params &p); virtual ~LLToastIMPanel(); /*virtual*/ BOOL handleMouseDown(S32 x, S32 y, MASK mask); + /*virtual*/ BOOL handleToolTip(S32 x, S32 y, MASK mask); private: + void showInspector(); static const S32 DEFAULT_MESSAGE_MAX_LINE_COUNT; LLNotificationPtr mNotification; LLUUID mSessionID; - LLAvatarIconCtrl* mAvatar; - LLTextBox* mUserName; + LLUUID mAvatarID; + LLAvatarIconCtrl* mAvatarIcon; + LLTextBox* mAvatarName; LLTextBox* mTime; LLTextBox* mMessage; }; diff --git a/indra/newview/lltoolgrab.cpp b/indra/newview/lltoolgrab.cpp index 26dbe6a489..d837a334f1 100644 --- a/indra/newview/lltoolgrab.cpp +++ b/indra/newview/lltoolgrab.cpp @@ -78,9 +78,15 @@ LLToolGrab::LLToolGrab( LLToolComposite* composite ) : LLTool( std::string("Grab"), composite ), mMode( GRAB_INACTIVE ), mVerticalDragging( FALSE ), + mHitLand(FALSE), + mLastMouseX(0), + mLastMouseY(0), + mAccumDeltaX(0), + mAccumDeltaY(0), mHasMoved( FALSE ), mOutsideSlop(FALSE), mDeselectedThisClick(FALSE), + mLastFace(0), mSpinGrabbing( FALSE ), mSpinRotation(), mHideBuildHighlight(FALSE) diff --git a/indra/newview/llviewerjoint.cpp b/indra/newview/llviewerjoint.cpp index c425d95ff8..95f05b5f5f 100644 --- a/indra/newview/llviewerjoint.cpp +++ b/indra/newview/llviewerjoint.cpp @@ -59,14 +59,9 @@ BOOL LLViewerJoint::sDisableLOD = FALSE; // Class Constructor //----------------------------------------------------------------------------- LLViewerJoint::LLViewerJoint() + : LLJoint() { - mUpdateXform = TRUE; - mValid = FALSE; - mComponents = SC_JOINT | SC_BONE | SC_AXES; - mMinPixelArea = DEFAULT_LOD; - mPickName = PN_DEFAULT; - mVisible = TRUE; - mMeshID = 0; + init(); } @@ -74,13 +69,21 @@ LLViewerJoint::LLViewerJoint() // LLViewerJoint() // Class Constructor //----------------------------------------------------------------------------- -LLViewerJoint::LLViewerJoint(const std::string &name, LLJoint *parent) : - LLJoint(name, parent) +LLViewerJoint::LLViewerJoint(const std::string &name, LLJoint *parent) + : LLJoint(name, parent) +{ + init(); +} + + +void LLViewerJoint::init() { mValid = FALSE; mComponents = SC_JOINT | SC_BONE | SC_AXES; mMinPixelArea = DEFAULT_LOD; mPickName = PN_DEFAULT; + mVisible = TRUE; + mMeshID = 0; } diff --git a/indra/newview/llviewerjoint.h b/indra/newview/llviewerjoint.h index 08c4ec36fd..0d3092a044 100644 --- a/indra/newview/llviewerjoint.h +++ b/indra/newview/llviewerjoint.h @@ -142,6 +142,8 @@ public: void setMeshID( S32 id ) {mMeshID = id;} protected: + void init(); + BOOL mValid; U32 mComponents; F32 mMinPixelArea; diff --git a/indra/newview/llviewermessage.h b/indra/newview/llviewermessage.h index 8404d6fde0..1415c16090 100644 --- a/indra/newview/llviewermessage.h +++ b/indra/newview/llviewermessage.h @@ -205,7 +205,9 @@ void open_inventory_offer(const std::vector<LLUUID>& items, const std::string& f struct LLOfferInfo { - LLOfferInfo() {}; + LLOfferInfo() + : mFromGroup(FALSE), mFromObject(FALSE), + mIM(IM_NOTHING_SPECIAL), mType(LLAssetType::AT_NONE) {}; LLOfferInfo(const LLSD& sd); void forceResponse(InventoryOfferResponse response); diff --git a/indra/newview/llviewerparcelmgr.cpp b/indra/newview/llviewerparcelmgr.cpp index 10a95443f1..b3450a8f36 100644 --- a/indra/newview/llviewerparcelmgr.cpp +++ b/indra/newview/llviewerparcelmgr.cpp @@ -706,8 +706,8 @@ bool LLViewerParcelMgr::allowAgentScripts() const bool LLViewerParcelMgr::allowAgentDamage() const { LLViewerRegion* region = gAgent.getRegion(); - return region && region->getAllowDamage() - && mAgentParcel && mAgentParcel->getAllowDamage(); + return (region && region->getAllowDamage()) + || (mAgentParcel && mAgentParcel->getAllowDamage()); } BOOL LLViewerParcelMgr::isOwnedAt(const LLVector3d& pos_global) const diff --git a/indra/newview/llvoiceclient.cpp b/indra/newview/llvoiceclient.cpp index 8ca0fd6ef6..a0d42d9b5f 100644 --- a/indra/newview/llvoiceclient.cpp +++ b/indra/newview/llvoiceclient.cpp @@ -296,8 +296,14 @@ void LLVivoxProtocolParser::reset() ignoringTags = false; accumulateText = false; energy = 0.f; + hasText = false; + hasAudio = false; + hasVideo = false; + terminated = false; ignoreDepth = 0; isChannel = false; + incoming = false; + enabled = false; isEvent = false; isLocallyMuted = false; isModeratorMuted = false; @@ -6408,6 +6414,7 @@ void LLVoiceClient::filePlaybackSetMode(bool vox, float speed) } LLVoiceClient::sessionState::sessionState() : + mErrorStatusCode(0), mMediaStreamState(streamStateUnknown), mTextStreamState(streamStateUnknown), mCreateInProgress(false), diff --git a/indra/newview/llvosky.cpp b/indra/newview/llvosky.cpp index 5ff8f0d267..0550ed770b 100644 --- a/indra/newview/llvosky.cpp +++ b/indra/newview/llvosky.cpp @@ -343,7 +343,6 @@ LLVOSky::LLVOSky(const LLUUID &id, const LLPCode pcode, LLViewerRegion *regionp) cloud_pos_density1 = LLColor3(); cloud_pos_density2 = LLColor3(); - mInitialized = FALSE; mbCanSelect = FALSE; mUpdateTimer.reset(); @@ -385,6 +384,10 @@ LLVOSky::LLVOSky(const LLUUID &id, const LLPCode pcode, LLViewerRegion *regionp) mBloomTexturep->setAddressMode(LLTexUnit::TAM_CLAMP); mHeavenlyBodyUpdated = FALSE ; + + mDrawRefl = 0; + mHazeConcentration = 0.f; + mInterpVal = 0.f; } @@ -1072,10 +1075,10 @@ BOOL LLVOSky::updateSky() ++next_frame; next_frame = next_frame % cycle_frame_no; - sInterpVal = (!mInitialized) ? 1 : (F32)next_frame / cycle_frame_no; + mInterpVal = (!mInitialized) ? 1 : (F32)next_frame / cycle_frame_no; // sInterpVal = (F32)next_frame / cycle_frame_no; - LLSkyTex::setInterpVal( sInterpVal ); - LLHeavenBody::setInterpVal( sInterpVal ); + LLSkyTex::setInterpVal( mInterpVal ); + LLHeavenBody::setInterpVal( mInterpVal ); calcAtmospherics(); if (mForceUpdate || total_no_tiles == frame) diff --git a/indra/newview/llvosky.h b/indra/newview/llvosky.h index ef74324e58..8366909755 100644 --- a/indra/newview/llvosky.h +++ b/indra/newview/llvosky.h @@ -613,7 +613,7 @@ protected: LLColor3 mLastTotalAmbient; F32 mAmbientScale; LLColor3 mNightColorShift; - F32 sInterpVal; + F32 mInterpVal; LLColor4 mFogColor; LLColor4 mGLFogCol; @@ -636,8 +636,8 @@ protected: public: //by bao //fake vertex buffer updating - //to guaranttee at least updating one VBO buffer every frame - //to walk around the bug caused by ATI card --> DEV-3855 + //to guarantee at least updating one VBO buffer every frame + //to work around the bug caused by ATI card --> DEV-3855 // void createDummyVertexBuffer() ; void updateDummyVertexBuffer() ; diff --git a/indra/newview/skins/default/xui/en/floater_map.xml b/indra/newview/skins/default/xui/en/floater_map.xml index 3a5ceed5fb..3ddb7bc349 100644 --- a/indra/newview/skins/default/xui/en/floater_map.xml +++ b/indra/newview/skins/default/xui/en/floater_map.xml @@ -1,14 +1,17 @@ <?xml version="1.0" encoding="utf-8" standalone="yes" ?> <floater legacy_header_height="18" - can_minimize="false" + can_minimize="true" can_resize="true" + center_horiz="true" + center_vert="true" follows="top|right" height="225" layout="topleft" min_height="60" min_width="174" name="Map" + title="Mini Map" help_topic="map" save_rect="true" save_visibility="true" diff --git a/indra/newview/skins/default/xui/en/panel_group_info_sidetray.xml b/indra/newview/skins/default/xui/en/panel_group_info_sidetray.xml index 0893c204e7..1968d96205 100644 --- a/indra/newview/skins/default/xui/en/panel_group_info_sidetray.xml +++ b/indra/newview/skins/default/xui/en/panel_group_info_sidetray.xml @@ -37,6 +37,7 @@ background_visible="true" top="2" width="23" /> <text + allow_html="false" follows="top|left|right" font="SansSerifHugeBold" height="26" diff --git a/indra/newview/skins/default/xui/en/panel_group_list_item.xml b/indra/newview/skins/default/xui/en/panel_group_list_item.xml index c243d08b97..b674b39d9b 100644 --- a/indra/newview/skins/default/xui/en/panel_group_list_item.xml +++ b/indra/newview/skins/default/xui/en/panel_group_list_item.xml @@ -36,6 +36,7 @@ top="2" width="20" /> <text + allow_html="false" follows="left|right" font="SansSerifSmall" height="15" diff --git a/indra/newview/skins/default/xui/en/panel_landmark_info.xml b/indra/newview/skins/default/xui/en/panel_landmark_info.xml index 67a4edbf32..396699ad6c 100644 --- a/indra/newview/skins/default/xui/en/panel_landmark_info.xml +++ b/indra/newview/skins/default/xui/en/panel_landmark_info.xml @@ -229,6 +229,7 @@ value="Title:" width="290" /> <text + allow_html="false" follows="left|top" height="22" layout="topleft" diff --git a/indra/newview/skins/default/xui/en/panel_place_profile.xml b/indra/newview/skins/default/xui/en/panel_place_profile.xml index 8fc2ae39f0..7ac771de27 100644 --- a/indra/newview/skins/default/xui/en/panel_place_profile.xml +++ b/indra/newview/skins/default/xui/en/panel_place_profile.xml @@ -246,6 +246,7 @@ </layout_panel> </layout_stack> <text + allow_html="false" follows="left|top|right" font="SansSerifLarge" height="14" @@ -258,6 +259,7 @@ value="SampleRegion" width="290" /> <text + allow_html="false" follows="left|top|right" height="14" layout="topleft" diff --git a/indra/newview/skins/default/xui/en/widgets/location_input.xml b/indra/newview/skins/default/xui/en/widgets/location_input.xml index 1c0a8ba7c5..70a58b8e03 100644 --- a/indra/newview/skins/default/xui/en/widgets/location_input.xml +++ b/indra/newview/skins/default/xui/en/widgets/location_input.xml @@ -96,7 +96,7 @@ name="damage_icon" width="14" height="13" - top="25" + top="21" left="2" follows="right|top" image_name="Parcel_Damage_Dark" |