From 832dc72652a7799cee9f2c30d65fcf96bd850a5e Mon Sep 17 00:00:00 2001 From: Ichthyostega Date: Tue, 10 Jan 2023 02:48:45 +0100 Subject: [PATCH] fix indentation --- src/stage/timeline/track-head-widget.cpp | 82 ++++++++++++------------ 1 file changed, 41 insertions(+), 41 deletions(-) diff --git a/src/stage/timeline/track-head-widget.cpp b/src/stage/timeline/track-head-widget.cpp index 11dc5abfe..4b03dfd6b 100644 --- a/src/stage/timeline/track-head-widget.cpp +++ b/src/stage/timeline/track-head-widget.cpp @@ -82,63 +82,63 @@ namespace timeline { void TrackHeadWidget::setTrackName (cuString& trackName) - { - nameTODO_.set_label (trackName); - } + { + nameTODO_.set_label (trackName); + } uint TrackHeadWidget::getHeightAt (int left, int top) const - { - auto* cell = this->get_child_at(left,top); - if (cell == nullptr) return 0; - int actual = cell->get_height(); - int minimal=0, natural=0; - cell->get_preferred_height(minimal, natural); - return max (0, max (actual, natural)); - } + { + auto* cell = this->get_child_at(left,top); + if (cell == nullptr) return 0; + int actual = cell->get_height(); + int minimal=0, natural=0; + cell->get_preferred_height(minimal, natural); + return max (0, max (actual, natural)); + } uint TrackHeadWidget::calcContentHeight() const - { - if (childCnt_ == 0) return calcOverallHeight(); - - int h1 = getHeightAt (0,0); - int h2 = getHeightAt (1,0); - - return max (0, max (h1,h2)); - } + { + if (childCnt_ == 0) return calcOverallHeight(); + + int h1 = getHeightAt (0,0); + int h2 = getHeightAt (1,0); + + return max (0, max (h1,h2)); + } uint TrackHeadWidget::calcOverallHeight() const - { - uint heightSum = 0; - for (uint line=0; line <= max(1u, childCnt_); ++line) - { - int h1 = getHeightAt (0,line); - int h2 = getHeightAt (1,line); - - heightSum += max (0, max (h1,h2)); - } - return heightSum; - } + { + uint heightSum = 0; + for (uint line=0; line <= max(1u, childCnt_); ++line) + { + int h1 = getHeightAt (0,line); + int h2 = getHeightAt (1,line); + + heightSum += max (0, max (h1,h2)); + } + return heightSum; + } void TrackHeadWidget::accommodateContentHeight(uint contentHeight) - { - uint localHeight = calcContentHeight(); - if (contentHeight > localHeight) - increaseContentHeight (contentHeight-localHeight); - } + { + uint localHeight = calcContentHeight(); + if (contentHeight > localHeight) + increaseContentHeight (contentHeight-localHeight); + } /** apply the Δ to some child in first row */ void TrackHeadWidget::increaseContentHeight(uint delta) - { - auto* cell = this->get_child_at(1,0); - REQUIRE (cell); - uint h = getHeightAt (1,0); - cell->set_size_request (-1, h+delta); - } + { + auto* cell = this->get_child_at(1,0); + REQUIRE (cell); + uint h = getHeightAt (1,0); + cell->set_size_request (-1, h+delta); + }