mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-11 00:56:33 +01:00
Improve master-strip layout spacing
Simply removing the items from the rec_mon_table still leaves a space since the table itself is still packed and the global-vpacker uses a spacing of 2px. So the rec-mon table has to be unpacked. explicit hide/show calls in set_route() are also not helpful since the widget is managed by a VisibilityGroup.
This commit is contained in:
parent
4ccd3c9740
commit
612746f3b0
4 changed files with 21 additions and 4 deletions
|
|
@ -419,7 +419,7 @@ MixerStrip::init ()
|
||||||
*/
|
*/
|
||||||
_visibility.add (&input_button_box, X_("Input"), _("Input"), false);
|
_visibility.add (&input_button_box, X_("Input"), _("Input"), false);
|
||||||
_visibility.add (&_invert_button_box, X_("PhaseInvert"), _("Phase Invert"), false);
|
_visibility.add (&_invert_button_box, X_("PhaseInvert"), _("Phase Invert"), false);
|
||||||
_visibility.add (&rec_mon_table, X_("RecMon"), _("Record & Monitor"), false);
|
_visibility.add (&rec_mon_table, X_("RecMon"), _("Record & Monitor"), false, boost::bind (&MixerStrip::override_rec_mon_visibility, this));
|
||||||
_visibility.add (&solo_iso_table, X_("SoloIsoLock"), _("Solo Iso / Lock"), false);
|
_visibility.add (&solo_iso_table, X_("SoloIsoLock"), _("Solo Iso / Lock"), false);
|
||||||
_visibility.add (&output_button, X_("Output"), _("Output"), false);
|
_visibility.add (&output_button, X_("Output"), _("Output"), false);
|
||||||
_visibility.add (&_comment_button, X_("Comments"), _("Comments"), false);
|
_visibility.add (&_comment_button, X_("Comments"), _("Comments"), false);
|
||||||
|
|
@ -592,7 +592,6 @@ MixerStrip::set_route (boost::shared_ptr<Route> rt)
|
||||||
if (route()->is_master()) {
|
if (route()->is_master()) {
|
||||||
solo_button->hide ();
|
solo_button->hide ();
|
||||||
mute_button->show ();
|
mute_button->show ();
|
||||||
rec_mon_table.hide ();
|
|
||||||
mute_solo_table.attach (*mute_button, 0, 2, 0, 1);
|
mute_solo_table.attach (*mute_button, 0, 2, 0, 1);
|
||||||
if (Config->get_use_master_volume ()) {
|
if (Config->get_use_master_volume ()) {
|
||||||
master_volume_table.show ();
|
master_volume_table.show ();
|
||||||
|
|
@ -641,7 +640,6 @@ MixerStrip::set_route (boost::shared_ptr<Route> rt)
|
||||||
mute_solo_table.attach (*solo_button, 1, 2, 0, 1);
|
mute_solo_table.attach (*solo_button, 1, 2, 0, 1);
|
||||||
mute_button->show ();
|
mute_button->show ();
|
||||||
solo_button->show ();
|
solo_button->show ();
|
||||||
rec_mon_table.show ();
|
|
||||||
master_volume_table.hide ();
|
master_volume_table.hide ();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -2446,13 +2444,24 @@ MixerStrip::parameter_changed (string p)
|
||||||
boost::optional<bool>
|
boost::optional<bool>
|
||||||
MixerStrip::override_solo_visibility () const
|
MixerStrip::override_solo_visibility () const
|
||||||
{
|
{
|
||||||
if (_route && _route->is_master ()) {
|
if (is_master ()) {
|
||||||
return boost::optional<bool> (false);
|
return boost::optional<bool> (false);
|
||||||
}
|
}
|
||||||
|
|
||||||
return boost::optional<bool> ();
|
return boost::optional<bool> ();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
boost::optional<bool>
|
||||||
|
MixerStrip::override_rec_mon_visibility () const
|
||||||
|
{
|
||||||
|
if (is_master ()) {
|
||||||
|
return boost::optional<bool> (false);
|
||||||
|
}
|
||||||
|
|
||||||
|
return boost::optional<bool> ();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
MixerStrip::add_input_port (DataType t)
|
MixerStrip::add_input_port (DataType t)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -331,6 +331,7 @@ private:
|
||||||
*/
|
*/
|
||||||
VisibilityGroup _visibility;
|
VisibilityGroup _visibility;
|
||||||
boost::optional<bool> override_solo_visibility () const;
|
boost::optional<bool> override_solo_visibility () const;
|
||||||
|
boost::optional<bool> override_rec_mon_visibility () const;
|
||||||
|
|
||||||
PBD::ScopedConnectionList _config_connection;
|
PBD::ScopedConnectionList _config_connection;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1871,6 +1871,12 @@ RouteUI::is_track () const
|
||||||
return boost::dynamic_pointer_cast<Track>(_route) != 0;
|
return boost::dynamic_pointer_cast<Track>(_route) != 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool
|
||||||
|
RouteUI::is_master () const
|
||||||
|
{
|
||||||
|
return _route && _route->is_master ();
|
||||||
|
}
|
||||||
|
|
||||||
boost::shared_ptr<Track>
|
boost::shared_ptr<Track>
|
||||||
RouteUI::track() const
|
RouteUI::track() const
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -100,6 +100,7 @@ public:
|
||||||
virtual void set_button_names () = 0;
|
virtual void set_button_names () = 0;
|
||||||
|
|
||||||
bool is_track() const;
|
bool is_track() const;
|
||||||
|
bool is_master() const;
|
||||||
bool is_audio_track() const;
|
bool is_audio_track() const;
|
||||||
bool is_midi_track() const;
|
bool is_midi_track() const;
|
||||||
bool has_audio_outputs () const;
|
bool has_audio_outputs () const;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue