From 69b02defca8bac1133f28cc8b476cbee064dbc95 Mon Sep 17 00:00:00 2001 From: NiranV Date: Sat, 26 Jul 2014 14:09:59 +0200 Subject: STORM-2040: Removed: Unnecessary code for hiding/showing "Constrain proportions" checkbox. It's either shown/hidden internally in each panel or is simply disabled/enabled depending on the resolution choice, it doesn't make any sense having this extra bit of code additionally hiding it. --- indra/newview/llpanelsnapshot.cpp | 19 ------------------- 1 file changed, 19 deletions(-) (limited to 'indra/newview/llpanelsnapshot.cpp') diff --git a/indra/newview/llpanelsnapshot.cpp b/indra/newview/llpanelsnapshot.cpp index 5924448671..56569e3207 100755 --- a/indra/newview/llpanelsnapshot.cpp +++ b/indra/newview/llpanelsnapshot.cpp @@ -65,8 +65,6 @@ void LLPanelSnapshot::onOpen(const LLSD& key) { LLFloaterSnapshot::getInstance()->notify(LLSD().with("image-format-change", true)); } - - updateCustomResControls(); } LLFloaterSnapshot::ESnapshotFormat LLPanelSnapshot::getImageFormat() const @@ -77,11 +75,6 @@ LLFloaterSnapshot::ESnapshotFormat LLPanelSnapshot::getImageFormat() const void LLPanelSnapshot::enableControls(BOOL enable) { setCtrlsEnabled(enable); - if (enable) - { - // Make sure only relevant controls are enabled/shown. - updateCustomResControls(); - } } LLSpinCtrl* LLPanelSnapshot::getWidthSpinner() @@ -121,16 +114,6 @@ LLSideTrayPanelContainer* LLPanelSnapshot::getParentContainer() return parent; } -// virtual -void LLPanelSnapshot::updateCustomResControls() -{ - // Only show width/height spinners and the aspect ratio checkbox - // when a custom resolution is chosen. - LLComboBox* combo = getChild(getImageSizeComboName()); - const bool show = combo->getFirstSelectedIndex() == (combo->getItemCount() - 1); - getChild(getImageSizePanelName())->setVisible(show); -} - void LLPanelSnapshot::updateImageQualityLevel() { LLSliderCtrl* quality_slider = getChild("image_quality_slider"); @@ -188,8 +171,6 @@ void LLPanelSnapshot::onCustomResolutionCommit() void LLPanelSnapshot::onResolutionComboCommit(LLUICtrl* ctrl) { - updateCustomResControls(); - LLSD info; info["combo-res-change"]["control-name"] = ctrl->getName(); LLFloaterSnapshot::getInstance()->notify(info); -- cgit v1.2.3