diff --git a/gtk2_ardour/midi_time_axis.cc b/gtk2_ardour/midi_time_axis.cc
index 6987680..8527bea 100644
--- a/gtk2_ardour/midi_time_axis.cc
+++ b/gtk2_ardour/midi_time_axis.cc
@@ -330,18 +330,22 @@ MidiTimeAxisView::set_route (boost::shared_ptr<Route> rt)
 	
 	_midi_controls_box.pack_start (_channel_status_box, false, false, 10);
 
+	const string midnum_custom_device_mode = gui_property(X_("midnam-custom-device-mode"));
+
 	if (!patch_manager.all_models().empty()) {
 
 		_midnam_model_selector.show ();
 		_midi_controls_box.pack_start (_midnam_model_selector, false, false, 2);
 
-		_midnam_custom_device_mode_selector.show ();
-
-		_midi_controls_box.pack_start (_midnam_custom_device_mode_selector, false, false, 2);
-	} 
+		if (midnum_custom_device_mode != "") {
+			_midnam_custom_device_mode_selector.show ();
+			_midi_controls_box.pack_start (_midnam_custom_device_mode_selector,
+						       false, false, 2);
+		}
+	}
 
 	model_changed(gui_property(X_("midnam-model-name")));
-	custom_device_mode_changed(gui_property(X_("midnam-custom-device-mode")));
+	custom_device_mode_changed(midnum_custom_device_mode);
 
 	controls_vbox.pack_start(_midi_controls_box, false, false);
 
