sidebar: display full signal when network strength is GREAT (#21259)

* full signal when network strength is GREAT

* apply review

* space
old-commit-hash: 648b60a381
commatwo_master
Dean Lee 4 years ago committed by GitHub
parent dcc1f28bb2
commit 1b51d71ef4
  1. 3
      selfdrive/ui/qt/sidebar.cc

@ -55,7 +55,8 @@ void Sidebar::updateState(const UIState &s) {
auto deviceState = sm["deviceState"].getDeviceState(); auto deviceState = sm["deviceState"].getDeviceState();
setProperty("netType", network_type[deviceState.getNetworkType()]); setProperty("netType", network_type[deviceState.getNetworkType()]);
setProperty("netStrength", (int)deviceState.getNetworkStrength()); int strength = (int)deviceState.getNetworkStrength();
setProperty("netStrength", strength > 0 ? strength + 1 : 0);
auto last_ping = deviceState.getLastAthenaPingTime(); auto last_ping = deviceState.getLastAthenaPingTime();
if (last_ping == 0) { if (last_ping == 0) {

Loading…
Cancel
Save