Skip to content

Commit

Permalink
invalidate options only after set
Browse files Browse the repository at this point in the history
  • Loading branch information
Nir-Az committed Oct 4, 2021
1 parent 7d902a7 commit e2b902c
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions common/model-views.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -774,14 +774,15 @@ namespace rs2
{
delay_set = false;
last_set_value = static_cast<float>(int_value);
*invalidate_flag = true;
model.add_log( to_string() << "Setting " << opt << " to " << int_value );
}
else
{
delay_set = true;
last_requested_value = static_cast< float >( int_value );
}
*invalidate_flag = true;

res = true;
}
else
Expand All @@ -796,6 +797,7 @@ namespace rs2
{
model.add_log(to_string() << "Setting " << opt << " to " << last_requested_value);
delay_set = false;
*invalidate_flag = true;
}
}
else
Expand Down Expand Up @@ -856,14 +858,15 @@ namespace rs2
{
delay_set = false;
last_set_value = tmp_value;
*invalidate_flag = true;
model.add_log(to_string() << "Setting " << opt << " to " << tmp_value);
}
else
{
delay_set = true;
last_requested_value = tmp_value;
}
*invalidate_flag = true;

res = true;
}
else
Expand All @@ -877,6 +880,7 @@ namespace rs2
if (set_ok)
{
model.add_log(to_string() << "Setting " << opt << " to " << last_requested_value);
*invalidate_flag = true;
delay_set = false;
}
}
Expand Down

0 comments on commit e2b902c

Please sign in to comment.