Skip to content

Commit

Permalink
ok maybe labelsTempReset is enough and we do not need to replace all …
Browse files Browse the repository at this point in the history
…double labels by Label after all
  • Loading branch information
JorisGoosen committed Nov 6, 2024
1 parent 671e8b4 commit 8691b8b
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion CommonData/column.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1817,8 +1817,18 @@ void Column::labelsOrderByValue(bool doDbUpdateEtc)
{
JASPTIMER_SCOPE(Column::labelsOrderByValue);

bool replaceAllDoubles = false;
static double dummy;
replaceDoublesTillLabelsRowWithLabels(labelsTempCount());

for(Label * label : labels())
if(!label->isEmptyValue() && !(label->originalValue().isDouble() || ColumnUtils::getDoubleValue(label->originalValueAsString(), dummy)))
{
replaceAllDoubles = true;
break;
}

if(replaceAllDoubles)
replaceDoublesTillLabelsRowWithLabels(labelsTempCount());

doublevec asc = valuesNumericOrdered();
auto alpha = valuesAlphabeticalOffsets();
Expand Down

0 comments on commit 8691b8b

Please sign in to comment.