mirror of
https://github.com/Oibaf66/frodo-wii.git
synced 2025-02-19 22:02:41 +01:00
Only display network traffic string during connections
This commit is contained in:
parent
3073af1d84
commit
2ce92d07e2
@ -558,17 +558,14 @@ void C64::network_vblank()
|
|||||||
else
|
else
|
||||||
remote->ResetNetworkUpdate();
|
remote->ResetNetworkUpdate();
|
||||||
|
|
||||||
if (1)
|
static uint32_t last_traffic_update;
|
||||||
{
|
|
||||||
static uint32_t last_traffic_update;
|
|
||||||
|
|
||||||
if (last_time_update - last_traffic_update > 300)
|
if (last_time_update - last_traffic_update > 300)
|
||||||
{
|
{
|
||||||
TheDisplay->NetworkTrafficMeter(remote->GetKbps() / (8 * 1024.0),
|
TheDisplay->NetworkTrafficMeter(remote->GetKbps() / (8 * 1024.0),
|
||||||
has_throttled);
|
has_throttled);
|
||||||
last_traffic_update = now;
|
last_traffic_update = now;
|
||||||
has_throttled = false;
|
has_throttled = false;
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -231,7 +231,8 @@ void C64Display::Update(uint8 *src_pixels)
|
|||||||
SDL_SoftStretch(sdl_screen, &srcrect, real_screen, &dstrect);
|
SDL_SoftStretch(sdl_screen, &srcrect, real_screen, &dstrect);
|
||||||
}
|
}
|
||||||
|
|
||||||
draw_string(real_screen, 0, 0, networktraffic_string, black, fill_gray);
|
if (this->TheC64->network_connection_type != NONE)
|
||||||
|
draw_string(real_screen, 0, 0, networktraffic_string, black, fill_gray);
|
||||||
if (this->on_screen_message) {
|
if (this->on_screen_message) {
|
||||||
Uint32 time_now = SDL_GetTicks();
|
Uint32 time_now = SDL_GetTicks();
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user