diff options
author | Tim Mayberry <mojofunk@gmail.com> | 2015-01-02 21:44:54 +0700 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2015-09-16 16:55:17 -0400 |
commit | 6b019a495359909a3d1a778ca10cd7df7cc302cc (patch) | |
tree | 75746a1e4a3daecd8c9cd0996b3c63d7d1657be4 /gtk2_ardour/processor_box.cc | |
parent | 45d487f16e8be102bfcdefcd950a69c886495b94 (diff) |
Move UIConfiguration Singleton into UIConfiguration header
This removes the direct dependence on ardour_ui.h from 39 files
Diffstat (limited to 'gtk2_ardour/processor_box.cc')
-rw-r--r-- | gtk2_ardour/processor_box.cc | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/gtk2_ardour/processor_box.cc b/gtk2_ardour/processor_box.cc index 6ceda3b8d8..a1e066797f 100644 --- a/gtk2_ardour/processor_box.cc +++ b/gtk2_ardour/processor_box.cc @@ -510,7 +510,7 @@ ProcessorEntry::toggle_panner_link () ProcessorEntry::Control::Control (boost::shared_ptr<AutomationControl> c, string const & n) : _control (c) , _adjustment (gain_to_slider_position_with_max (1.0, Config->get_max_gain()), 0, 1, 0.01, 0.1) - , _slider (&_adjustment, boost::shared_ptr<PBD::Controllable>(), 0, max(13.f, rintf(13.f * ARDOUR_UI::config()->get_ui_scale()))) + , _slider (&_adjustment, boost::shared_ptr<PBD::Controllable>(), 0, max(13.f, rintf(13.f * UIConfiguration::instance().get_ui_scale()))) , _slider_persistant_tooltip (&_slider) , _button (ArdourButton::led_default_elements) , _ignore_ui_adjustment (false) @@ -792,7 +792,7 @@ PluginInsertProcessorEntry::plugin_insert_splitting_changed () if (_plugin_insert->splitting () || in != sinks) { - _routing_icon.set_size_request (-1, std::max (7.f, rintf(7.f * ARDOUR_UI::config()->get_ui_scale()))); + _routing_icon.set_size_request (-1, std::max (7.f, rintf(7.f * UIConfiguration::instance().get_ui_scale()))); _routing_icon.set_visible(true); _input_icon.show(); } else { @@ -817,7 +817,7 @@ PluginInsertProcessorEntry::hide_things () ProcessorEntry::PortIcon::PortIcon(bool input) { _input = input; _ports = ARDOUR::ChanCount(ARDOUR::DataType::AUDIO, 1); - set_size_request (-1, std::max (2.f, rintf(2.f * ARDOUR_UI::config()->get_ui_scale()))); + set_size_request (-1, std::max (2.f, rintf(2.f * UIConfiguration::instance().get_ui_scale()))); } bool @@ -838,7 +838,7 @@ ProcessorEntry::PortIcon::on_expose_event (GdkEventExpose* ev) cairo_rectangle (cr, 0, 0, width, height); cairo_fill (cr); - const double dx = rint(max(2., 2. * ARDOUR_UI::config()->get_ui_scale())); + const double dx = rint(max(2., 2. * UIConfiguration::instance().get_ui_scale())); if (_ports.n_total() > 1) { for (uint32_t i = 0; i < _ports.n_total(); ++i) { if (i < _ports.n_midi()) { @@ -886,7 +886,7 @@ ProcessorEntry::RoutingIcon::on_expose_event (GdkEventExpose* ev) cairo_rectangle (cr, ev->area.x, ev->area.y, ev->area.width, ev->area.height); cairo_clip (cr); - cairo_set_line_width (cr, max (1.f, ARDOUR_UI::config()->get_ui_scale())); + cairo_set_line_width (cr, max (1.f, UIConfiguration::instance().get_ui_scale())); cairo_set_line_cap (cr, CAIRO_LINE_CAP_ROUND); Gtk::Allocation a = get_allocation(); @@ -936,7 +936,7 @@ ProcessorEntry::RoutingIcon::on_expose_event (GdkEventExpose* ev) cairo_curve_to (cr, si_x, 0, si_x0, height, si_x0, 0); cairo_stroke (cr); } else if (midi_sources == 0 && midi_sinks == 1) { - const double dx = 1 + rint(max(2., 2. * ARDOUR_UI::config()->get_ui_scale())); + const double dx = 1 + rint(max(2., 2. * UIConfiguration::instance().get_ui_scale())); // draw "T" // TODO connect back to track-input of last midi-out if any, otherwise draw "X" const float si_x = rintf(width * .2f) + .5f; |