From c9b8a91edb8f1bb6186fe85c09e16941cdea1b51 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Tue, 26 Apr 2022 22:03:55 -0600 Subject: [PATCH] apply new Item method name to various other usage sites --- libs/surfaces/maschine2/ui_knob.cc | 4 ++-- libs/surfaces/push2/knob.cc | 8 ++++---- libs/surfaces/push2/layout.cc | 2 +- libs/waveview/wave_view.cc | 12 ++++++------ 4 files changed, 13 insertions(+), 13 deletions(-) diff --git a/libs/surfaces/maschine2/ui_knob.cc b/libs/surfaces/maschine2/ui_knob.cc index 9cff3aeb53..8930fcd85b 100644 --- a/libs/surfaces/maschine2/ui_knob.cc +++ b/libs/surfaces/maschine2/ui_knob.cc @@ -61,7 +61,7 @@ Maschine2Knob::Maschine2Knob (PBD::EventLoop* el, Item* parent) text->set_font_description (fd); text->set_position (Duple (-_radius, _radius + 2)); text->set_color (0xffffffff); - _bounding_box_dirty = true; + set_bbox_dirty (); } Maschine2Knob::~Maschine2Knob () @@ -153,7 +153,7 @@ Maschine2Knob::compute_bounding_box () const return; } - if (_bounding_box_dirty) { + if (bbox_dirty()) { _bounding_box = Rect (- _radius, - _radius, _radius, _radius); _bounding_box_dirty = false; } diff --git a/libs/surfaces/push2/knob.cc b/libs/surfaces/push2/knob.cc index 1f40da5e43..ff62d71a29 100644 --- a/libs/surfaces/push2/knob.cc +++ b/libs/surfaces/push2/knob.cc @@ -85,7 +85,7 @@ Push2Knob::set_radius (double r) { _r = r; text->set_position (Duple (-_r, -_r - 20)); - _bounding_box_dirty = true; + set_bbox_dirty (); redraw (); } @@ -241,14 +241,14 @@ Push2Knob::compute_bounding_box () const { if (!_canvas || _r == 0) { _bounding_box = Rect (); - _bounding_box_dirty = false; + set_bbox_clean (); return; } - if (_bounding_box_dirty) { + if (bbox_dirty()) { Rect r = Rect (_position.x - _r, _position.y - _r, _position.x + _r, _position.y + _r); _bounding_box = r; - _bounding_box_dirty = false; + set_bbox_clean (); } /* Item::bounding_box() will add children */ diff --git a/libs/surfaces/push2/layout.cc b/libs/surfaces/push2/layout.cc index 1f5078135f..e5e03f1d6c 100644 --- a/libs/surfaces/push2/layout.cc +++ b/libs/surfaces/push2/layout.cc @@ -47,7 +47,7 @@ Push2Layout::compute_bounding_box () const * child boxes do not. */ _bounding_box = Rect (0, 0, display_width(), display_height()); - _bounding_box_dirty = false; + set_bbox_clean (); } int diff --git a/libs/waveview/wave_view.cc b/libs/waveview/wave_view.cc index 0bfceab2c5..89262ccb65 100644 --- a/libs/waveview/wave_view.cc +++ b/libs/waveview/wave_view.cc @@ -202,7 +202,7 @@ WaveView::set_samples_per_pixel (double samples_per_pixel) begin_change (); _props->samples_per_pixel = samples_per_pixel; - _bounding_box_dirty = true; + set_bbox_dirty (); end_change (); } @@ -1145,7 +1145,7 @@ WaveView::compute_bounding_box () const _bounding_box = Rect (); } - _bounding_box_dirty = false; + set_bbox_clean (); } void @@ -1157,7 +1157,7 @@ WaveView::set_height (Distance height) _props->height = height; _draw_image_in_gui_thread = true; - _bounding_box_dirty = true; + set_bbox_dirty (); end_change (); } } @@ -1169,7 +1169,7 @@ WaveView::set_channel (int channel) begin_change (); _props->channel = channel; reset_cache_group (); - _bounding_box_dirty = true; + set_bbox_dirty (); end_change (); } } @@ -1319,7 +1319,7 @@ WaveView::set_region_start (sampleoffset_t start) begin_change (); _props->region_start = start; - _bounding_box_dirty = true; + set_bbox_dirty (); end_change (); } @@ -1336,7 +1336,7 @@ WaveView::region_resized () begin_change (); _props->region_start = _region->start_sample(); _props->region_end = _region->start_sample() + _region->length_samples(); - _bounding_box_dirty = true; + set_bbox_dirty (); end_change (); }