Skip to content

Commit

Permalink
[Mod] Main toolbar: Hide separator before VU Meters when VU Meters ar…
Browse files Browse the repository at this point in the history
…e not displayed.

git-svn-id: https://source.openmpt.org/svn/openmpt/trunk/OpenMPT@22183 56274372-70c3-4bfc-bfc3-4c3a0b034d27
  • Loading branch information
sagamusix committed Nov 13, 2024
1 parent 022c169 commit 16e1563
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion mptrack/Mainbar.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,8 @@ enum ToolbarItemIndex
EDITGLOBALVOL_INDEX = GLOBALVOLTEXT_INDEX + 1, // Edit Speed
SPINGLOBALVOL_INDEX = EDITGLOBALVOL_INDEX + 1, // Spin Speed
DIVGLOBALVOL_INDEX = SPINGLOBALVOL_INDEX + 1, // Divider at end
VUMETER_INDEX = SPINGLOBALVOL_INDEX + 6, // VU Meters
DIVVUMETER_INDEX = SPINGLOBALVOL_INDEX + 5, // Divider before VU Meters
VUMETER_INDEX = DIVVUMETER_INDEX + 1, // VU Meters
};

#define TOOLBAR_IMAGE_PAUSE 8
Expand Down Expand Up @@ -441,6 +442,7 @@ void CMainToolBar::UpdateControls()
UpdateControl(visibleItems[MainToolBarItem::GlobalVolume], m_SpinGlobalVolume, SPINGLOBALVOL_INDEX, IDC_SPIN_GLOBALVOL);
SetButtonVisibility(DIVGLOBALVOL_INDEX, visibleItems.test_any_except(MainToolBarItem::VUMeter));

SetButtonVisibility(DIVVUMETER_INDEX, visibleItems[MainToolBarItem::VUMeter]);
m_VuMeter.SetOrientation(!m_bVertical);
if(m_bVertical)
m_VuMeter.SetWindowPos(nullptr, 0, 0, VUMETER_HEIGHT, VUMETER_HEIGHT, SWP_NOMOVE | SWP_NOZORDER | SWP_NOACTIVATE);
Expand Down

0 comments on commit 16e1563

Please sign in to comment.