From 014c6e7850fbba2a2b272edc53f3863b3a63b3a9 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Wed, 3 Aug 2022 11:42:58 -0600 Subject: [PATCH] replace INT32_MAX with CueRecord::stop_all (gui) --- gtk2_ardour/editor_rulers.cc | 2 +- gtk2_ardour/marker.cc | 2 +- gtk2_ardour/mini_timeline.cc | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/gtk2_ardour/editor_rulers.cc b/gtk2_ardour/editor_rulers.cc index 3f0d2df156..aa671139da 100644 --- a/gtk2_ardour/editor_rulers.cc +++ b/gtk2_ardour/editor_rulers.cc @@ -246,7 +246,7 @@ Editor::popup_ruler_menu (timepos_t const & where, ItemType t) break; case CueMarkerBarItem: - ruler_items.push_back (MenuElem (_("Stop All Cues"), sigc::bind (sigc::mem_fun (*this, &Editor::mouse_add_new_marker), where, Location::IsCueMarker, INT32_MAX))); + ruler_items.push_back (MenuElem (_("Stop All Cues"), sigc::bind (sigc::mem_fun (*this, &Editor::mouse_add_new_marker), where, Location::IsCueMarker, CueRecord::stop_all))); for (int32_t n = 0; n < default_triggers_per_box; ++n) { ruler_items.push_back (MenuElem (string_compose (_("Cue %1"), cue_marker_name (n)), sigc::bind (sigc::mem_fun(*this, &Editor::mouse_add_new_marker), where, Location::IsCueMarker, n))); } diff --git a/gtk2_ardour/marker.cc b/gtk2_ardour/marker.cc index 9de6d34775..eb2a1d7912 100644 --- a/gtk2_ardour/marker.cc +++ b/gtk2_ardour/marker.cc @@ -500,7 +500,7 @@ ArdourMarker::setup_name_display () _name_item->clamp_width (name_width); if (_type == Cue) { - if (_cue_index != INT32_MAX) { + if (_cue_index != CueRecord::stop_all) { _name_item->set (cue_marker_name (_cue_index)); _pcue->show(); //show the circle _pmark->hide(); diff --git a/gtk2_ardour/mini_timeline.cc b/gtk2_ardour/mini_timeline.cc index 3453ebd4c2..9fba4aaa16 100644 --- a/gtk2_ardour/mini_timeline.cc +++ b/gtk2_ardour/mini_timeline.cc @@ -424,14 +424,14 @@ MiniTimeline::draw_cue (cairo_t* cr, int marker_loc, int next_cue_left_edge, int }; // draw a bar to show that the Cue continues forever - if (cue_index!=INT32_MAX) { + if (cue_index!=CueRecord::stop_all) { cairo_rectangle (cr, marker_loc, y_center-2*scale, next_cue_left_edge - marker_loc, 4*scale); set_source_rgba (cr, color); cairo_fill (cr); } // draw the Cue - if (cue_index!=INT32_MAX) { //regular cues are a circle + if (cue_index!=CueRecord::stop_all) { //regular cues are a circle cairo_arc(cr, marker_loc, y_center, (h/2), 0, 2*M_PI); cairo_set_source_rgb (cr, 0, 0, 0); //black cairo_fill (cr); @@ -450,7 +450,7 @@ MiniTimeline::draw_cue (cairo_t* cr, int marker_loc, int next_cue_left_edge, int } //draw cue letter - if (cue_index!=INT32_MAX) { + if (cue_index!=CueRecord::stop_all) { _layout->set_text (cue_marker_name (cue_index)); cairo_set_source_rgb (cr, 0, 0, 0); //black cairo_move_to (cr, marker_loc, y_center); //move to center of circle