From d04d25e7c79b6e1787761565ae5a7cec0ff2b046 Mon Sep 17 00:00:00 2001 From: Todd Naugle Date: Mon, 13 Dec 2021 21:26:45 -0600 Subject: [PATCH] Mackie Control: Clean up detection of QCon master display and meter. Only enable the master display and meter modes for Qcon devices if this surface is in the master position. Extenders don't have master meters or master displays. --- libs/surfaces/mackie/surface.cc | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/libs/surfaces/mackie/surface.cc b/libs/surfaces/mackie/surface.cc index ba993e7f0b..5de3bda690 100644 --- a/libs/surfaces/mackie/surface.cc +++ b/libs/surfaces/mackie/surface.cc @@ -127,19 +127,19 @@ Surface::Surface (MackieControlProtocol& mcp, const std::string& device_name, ui } //Store Qcon flag - if( mcp.device_info().is_qcon() ) { - is_qcon = true; - _has_master_display = (mcp.device_info().has_master_fader() && mcp.device_info().has_qcon_second_lcd()); - _has_master_meter = mcp.device_info().has_qcon_master_meters(); - } else { - is_qcon = false; - } + is_qcon = mcp.device_info().is_qcon(); /* only the first Surface object has global controls */ /* lets use master_position instead */ uint32_t mp = _mcp.device_info().master_position(); if (_number == mp) { DEBUG_TRACE (DEBUG::MackieControl, "Surface matches MasterPosition. Might have global controls.\n"); + + if ( is_qcon ) { + _has_master_display = (mcp.device_info().has_master_fader() && mcp.device_info().has_qcon_second_lcd()); + _has_master_meter = mcp.device_info().has_qcon_master_meters(); + } + if (_mcp.device_info().has_global_controls()) { init_controls (); DEBUG_TRACE (DEBUG::MackieControl, "init_controls done\n");