Skip to content

Commit

Permalink
Use new SkipEmptyParts only when available in Qt
Browse files Browse the repository at this point in the history
  • Loading branch information
LouiseABowler committed Jul 5, 2024
1 parent 75afd96 commit 734febb
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2103,7 +2103,11 @@ bool AtrialFibresView::GetUserScarProjectionInputs(){
MITK_INFO << "[UI] Creating list of thresholds";
separated_thresh_list.removeLast();
separated_thresh_list.removeLast();
separated_thresh_list = thresh_list.split(",", Qt::SkipEmptyParts);
#if QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)
separated_thresh_list = thresh_list.split(",", Qt::SkipEmptyParts);
#else
separated_thresh_list = thresh_list.split(",", QString::SkipEmptyParts);
#endif
int listspaces = separated_thresh_list.removeAll(" ");
int listduplicates = separated_thresh_list.removeDuplicates();
std::cout << "Spaces in list: " << listspaces << " Duplicates in list: " << listduplicates << '\n';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -420,7 +420,11 @@ void AtrialScarView::AutomaticAnalysis() {
MITK_INFO << "[UI] Creating list of thresholds";
separated_thresh_list.removeLast();
separated_thresh_list.removeLast();
separated_thresh_list = thresh_list.split(",", Qt::SkipEmptyParts);
#if QT_VERSION >= QT_VERSION_CHECK(5, 14, 0)
separated_thresh_list = thresh_list.split(",", Qt::SkipEmptyParts);
#else
separated_thresh_list = thresh_list.split(",", QString::SkipEmptyParts);
#endif
int listspaces = separated_thresh_list.removeAll(" ");
int listduplicates = separated_thresh_list.removeDuplicates();
separated_thresh_list.sort();
Expand Down

0 comments on commit 734febb

Please sign in to comment.