Backed out changeset 85f1bec4ee87 (FIRE-21263) Firestorm_5.0.11

Mon, 08 Jan 2018 17:23:58 +0100

author
Ansariel
date
Mon, 08 Jan 2018 17:23:58 +0100
branch
Firestorm_5.0.11
changeset 53593
b1a175b3f4dd
parent 53592
bb849e9bc0fc
child 53594
54c17cd8cbb3

Backed out changeset 85f1bec4ee87 (FIRE-21263)

indra/newview/llfloatertools.cpp file | annotate | diff | revisions
indra/newview/llfloatertools.h file | annotate | diff | revisions
indra/newview/llselectmgr.cpp file | annotate | diff | revisions
indra/newview/llselectmgr.h file | annotate | diff | revisions
indra/newview/skins/default/xui/en/floater_tools.xml file | annotate | diff | revisions
indra/newview/skins/starlight/xui/en/floater_tools.xml file | annotate | diff | revisions
indra/newview/skins/starlightcui/xui/en/floater_tools.xml file | annotate | diff | revisions
indra/newview/skins/vintage/xui/en/floater_tools.xml file | annotate | diff | revisions
     1.1 --- a/indra/newview/llfloatertools.cpp	Mon Jan 08 14:20:58 2018 +0100
     1.2 +++ b/indra/newview/llfloatertools.cpp	Mon Jan 08 17:23:58 2018 +0100
     1.3 @@ -126,6 +126,9 @@
     1.4  void commit_grid_mode(LLUICtrl *);
     1.5  void commit_slider_zoom(LLUICtrl *ctrl);
     1.6  
     1.7 +// <FS:KC> show/hide build highlight
     1.8 +void commit_show_highlight(void *ctrl);
     1.9 +
    1.10  /**
    1.11   * Class LLLandImpactsObserver
    1.12   *
    1.13 @@ -268,9 +271,13 @@
    1.14  
    1.15  	// <FS:KC> show highlight
    1.16  	mCheckShowHighlight = getChild<LLCheckBoxCtrl>("checkbox show highlight");
    1.17 +	mCheckShowHighlight->setValue(gSavedSettings.getBOOL("RenderHighlightSelections"));
    1.18 +	LLSelectMgr::instance().setFSShowHideHighlight(FS_SHOW_HIDE_HIGHLIGHT_NORMAL);
    1.19 +
    1.20  	mCheckActualRoot = getChild<LLCheckBoxCtrl>("checkbox actual root");
    1.21  	// </FS:KC>
    1.22  
    1.23 +
    1.24  	//
    1.25  	// Create Buttons
    1.26  	//
    1.27 @@ -476,6 +483,9 @@
    1.28  	// <FS:Ansariel> FIRE-7802: Grass and tree selection in build tool
    1.29  	mCommitCallbackRegistrar.add("BuildTool.TreeGrass",			boost::bind(&LLFloaterTools::onSelectTreeGrassCombo, this));
    1.30  
    1.31 +	// <FS:KC> show/hide build highlight
    1.32 +	mCommitCallbackRegistrar.add("BuildTool.commitShowHighlight",	boost::bind(&commit_show_highlight, this));
    1.33 +
    1.34  	mLandImpactsObserver = new LLLandImpactsObserver();
    1.35  	LLViewerParcelMgr::getInstance()->addObserver(mLandImpactsObserver);
    1.36  }
    1.37 @@ -1070,6 +1080,15 @@
    1.38  {
    1.39  	mParcelSelection = LLViewerParcelMgr::getInstance()->getFloatingParcelSelection();
    1.40  	mObjectSelection = LLSelectMgr::getInstance()->getEditSelection();
    1.41 +	
    1.42 +	// <FS:KC> Set the check box value from the saved setting
    1.43 +	// this function runs on selection change
    1.44 +	if (!mOpen)
    1.45 +	{
    1.46 +		mOpen = TRUE;
    1.47 +		mCheckShowHighlight->setValue(gSavedSettings.getBOOL("RenderHighlightSelections"));
    1.48 +	}
    1.49 +	// </FS:KC>
    1.50  
    1.51  	std::string panel = key.asString();
    1.52  	if (!panel.empty())
    1.53 @@ -1099,6 +1118,12 @@
    1.54  	LLSelectMgr::getInstance()->promoteSelectionToRoot();
    1.55  	gSavedSettings.setBOOL("EditLinkedParts", FALSE);
    1.56  
    1.57 +	// <FS:KC>
    1.58 +	LLSelectMgr::instance().setFSShowHideHighlight(FS_SHOW_HIDE_HIGHLIGHT_NORMAL);
    1.59 +
    1.60 +	mOpen = FALSE; //hack cause onOpen runs on every selection change but onClose doesnt.
    1.61 +	// </FS:KC>
    1.62 +
    1.63  	gViewerWindow->showCursor();
    1.64  
    1.65  	resetToolState();
    1.66 @@ -1295,6 +1320,23 @@
    1.67  	}
    1.68  }
    1.69  
    1.70 +// <FS:KC> show/hide build highlight
    1.71 +void commit_show_highlight(void *data)
    1.72 +{
    1.73 +	LLFloaterTools* floaterp = (LLFloaterTools*)data;
    1.74 +	BOOL show_highlight = floaterp->mCheckShowHighlight->get();
    1.75 +	if (show_highlight)
    1.76 +	{
    1.77 +		LLSelectMgr::getInstance()->setFSShowHideHighlight(FS_SHOW_HIDE_HIGHLIGHT_SHOW);
    1.78 +	}
    1.79 +	else
    1.80 +	{
    1.81 +		LLSelectMgr::getInstance()->setFSShowHideHighlight(FS_SHOW_HIDE_HIGHLIGHT_HIDE);
    1.82 +	}
    1.83 +}
    1.84 +// </FS:KC>
    1.85 +
    1.86 +
    1.87  // static 
    1.88  void LLFloaterTools::setObjectType( LLPCode pcode )
    1.89  {
     2.1 --- a/indra/newview/llfloatertools.h	Mon Jan 08 14:20:58 2018 +0100
     2.2 +++ b/indra/newview/llfloatertools.h	Mon Jan 08 17:23:58 2018 +0100
     2.3 @@ -224,12 +224,14 @@
     2.4  private:
     2.5  	BOOL					mDirty;
     2.6  	BOOL                    mHasSelection;
     2.7 +	BOOL					mOpen; //Phoenix:KC
     2.8  
     2.9  	//Phoenix:KC
    2.10  	S32					mCollapsedHeight;
    2.11  	S32					mExpandedHeight;
    2.12  	std::map<std::string, std::string> mStatusText;
    2.13  
    2.14 +
    2.15  protected:
    2.16  	LLSD				mMediaSettings;
    2.17  
     3.1 --- a/indra/newview/llselectmgr.cpp	Mon Jan 08 14:20:58 2018 +0100
     3.2 +++ b/indra/newview/llselectmgr.cpp	Mon Jan 08 17:23:58 2018 +0100
     3.3 @@ -238,6 +238,11 @@
     3.4  
     3.5  	mForceSelection = FALSE;
     3.6  	mShowSelection = FALSE;
     3.7 +	
     3.8 +	// <FS:KC> show/hide build highlight
     3.9 +	mFSShowHideHighlight = FS_SHOW_HIDE_HIGHLIGHT_NORMAL;
    3.10 +	// </FS:KC>
    3.11 +
    3.12  }
    3.13  
    3.14  
    3.15 @@ -5948,7 +5953,10 @@
    3.16  }
    3.17  void LLSelectMgr::renderSilhouettes(BOOL for_hud)
    3.18  {
    3.19 -	if (!mRenderSilhouettes || !mRenderHighlightSelections)
    3.20 +	// <FS:KC> show/hide build highlight
    3.21 +	// if (!mRenderSilhouettes || !mRenderHighlightSelections)
    3.22 +	if (((mFSShowHideHighlight == FS_SHOW_HIDE_HIGHLIGHT_NORMAL) && (!mRenderSilhouettes || !mRenderHighlightSelections)) || (mFSShowHideHighlight == FS_SHOW_HIDE_HIGHLIGHT_HIDE))
    3.23 +	// </FS:KC>
    3.24  	{
    3.25  		return;
    3.26  	}
     4.1 --- a/indra/newview/llselectmgr.h	Mon Jan 08 14:20:58 2018 +0100
     4.2 +++ b/indra/newview/llselectmgr.h	Mon Jan 08 17:23:58 2018 +0100
     4.3 @@ -69,6 +69,15 @@
     4.4  const S32 MAX_CHILDREN_PER_PHYSICAL_TASK = 32;
     4.5  // </FS:Ansariel>
     4.6  
     4.7 +// <FS:KC> show/hide build highlight
     4.8 +enum EFSShowHideHighlight
     4.9 +{
    4.10 +	FS_SHOW_HIDE_HIGHLIGHT_NORMAL = 0,
    4.11 +	FS_SHOW_HIDE_HIGHLIGHT_SHOW = 1,
    4.12 +	FS_SHOW_HIDE_HIGHLIGHT_HIDE = 2
    4.13 +};
    4.14 +// </FS:KC>
    4.15 +
    4.16  // This is used by the DeRezObject message to determine where to put
    4.17  // derezed tasks.
    4.18  enum EDeRezDestination
    4.19 @@ -612,6 +621,10 @@
    4.20  	void renderSilhouettes(BOOL for_hud);
    4.21  	void enableSilhouette(BOOL enable) { mRenderSilhouettes = enable; }
    4.22  	
    4.23 +	// <FS:KC> show/hide build highlight
    4.24 +	void setFSShowHideHighlight(EFSShowHideHighlight state) { mFSShowHideHighlight = state; }
    4.25 +	// </FS:KC>
    4.26 +	
    4.27  	////////////////////////////////////////////////////////////////
    4.28  	// Utility functions that operate on the current selection
    4.29  	////////////////////////////////////////////////////////////////
    4.30 @@ -913,6 +926,10 @@
    4.31  
    4.32  	LLAnimPauseRequest		mPauseRequest;
    4.33  
    4.34 +// <FS:KC> show/hide build highlight
    4.35 +	EFSShowHideHighlight	mFSShowHideHighlight;
    4.36 +// </FS:KC>
    4.37 +
    4.38  // <FS:Zi> Warning when trying to duplicate while in edit linked parts/select face mode
    4.39  public:
    4.40  	// returns TRUE if current selection does not contain individual selections
     5.1 --- a/indra/newview/skins/default/xui/en/floater_tools.xml	Mon Jan 08 14:20:58 2018 +0100
     5.2 +++ b/indra/newview/skins/default/xui/en/floater_tools.xml	Mon Jan 08 17:23:58 2018 +0100
     5.3 @@ -395,12 +395,15 @@
     5.4       width="134" />
     5.5    <check_box
     5.6       height="18"
     5.7 -     control_name="RenderHighlightSelections"
     5.8 +     initial_value="true"
     5.9       label="Show Highlight"
    5.10       layout="topleft"
    5.11       top_pad="-2"
    5.12       name="checkbox show highlight"
    5.13 -     width="134"/>
    5.14 +     width="134" >
    5.15 +		  <check_box.commit_callback
    5.16 +			function="BuildTool.commitShowHighlight"/>
    5.17 +	</check_box>
    5.18      <button
    5.19       left_pad="0"
    5.20       image_selected="ForwardArrow_Press"
     6.1 --- a/indra/newview/skins/starlight/xui/en/floater_tools.xml	Mon Jan 08 14:20:58 2018 +0100
     6.2 +++ b/indra/newview/skins/starlight/xui/en/floater_tools.xml	Mon Jan 08 17:23:58 2018 +0100
     6.3 @@ -393,12 +393,15 @@
     6.4       width="134" />
     6.5    <check_box
     6.6       height="18"
     6.7 -     control_name="RenderHighlightSelections"
     6.8 +     initial_value="true"
     6.9       label="Show Highlight"
    6.10       layout="topleft"
    6.11       top_pad="-2"
    6.12       name="checkbox show highlight"
    6.13 -     width="134"/>
    6.14 +     width="134" >
    6.15 +     <check_box.commit_callback
    6.16 +         function="BuildTool.commitShowHighlight"/>
    6.17 +    </check_box>
    6.18      <button
    6.19       left_pad="0"
    6.20       image_selected="ForwardArrow_Press"
     7.1 --- a/indra/newview/skins/starlightcui/xui/en/floater_tools.xml	Mon Jan 08 14:20:58 2018 +0100
     7.2 +++ b/indra/newview/skins/starlightcui/xui/en/floater_tools.xml	Mon Jan 08 17:23:58 2018 +0100
     7.3 @@ -393,12 +393,15 @@
     7.4       width="134" />
     7.5    <check_box
     7.6       height="18"
     7.7 -     control_name="RenderHighlightSelections"
     7.8 +     initial_value="true"
     7.9       label="Show Highlight"
    7.10       layout="topleft"
    7.11       top_pad="-2"
    7.12       name="checkbox show highlight"
    7.13 -     width="134"/>
    7.14 +     width="134" >
    7.15 +     <check_box.commit_callback
    7.16 +         function="BuildTool.commitShowHighlight"/>
    7.17 +    </check_box>
    7.18      <button
    7.19       left_pad="0"
    7.20       image_selected="ForwardArrow_Press"
     8.1 --- a/indra/newview/skins/vintage/xui/en/floater_tools.xml	Mon Jan 08 14:20:58 2018 +0100
     8.2 +++ b/indra/newview/skins/vintage/xui/en/floater_tools.xml	Mon Jan 08 17:23:58 2018 +0100
     8.3 @@ -395,12 +395,15 @@
     8.4       width="134" />
     8.5    <check_box
     8.6       height="18"
     8.7 -     control_name="RenderHighlightSelections"
     8.8 +     initial_value="true"
     8.9       label="Show Highlight"
    8.10       layout="topleft"
    8.11       top_pad="-2"
    8.12       name="checkbox show highlight"
    8.13 -     width="134"/>
    8.14 +     width="134" >
    8.15 +     <check_box.commit_callback
    8.16 +         function="BuildTool.commitShowHighlight"/>
    8.17 +    </check_box>
    8.18      <button
    8.19       left_pad="0"
    8.20       layout="topleft"

mercurial