Skip to content

Commit

Permalink
C++ 11 lacks glorious chrono literals
Browse files Browse the repository at this point in the history
  • Loading branch information
Vultraz committed Aug 3, 2019
1 parent a43c526 commit 0bd6f91
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/gui/dialogs/network_transmission.cpp
Expand Up @@ -33,8 +33,6 @@ namespace gui2
{
namespace dialogs
{
using namespace std::chrono_literals;

REGISTER_DIALOG(network_transmission)

network_transmission::pump_monitor::pump_monitor(connection_data*& connection)
Expand All @@ -55,7 +53,7 @@ network_transmission::pump_monitor::pump_monitor(connection_data*& connection)
completed_ = connection_->current();
total_ = connection_->total();

std::this_thread::sleep_for(10ms);
std::this_thread::sleep_for(std::chrono::milliseconds(10));
}
}))
{
Expand All @@ -68,7 +66,7 @@ void network_transmission::pump_monitor::process(events::pump_info&)
}

// Check if the thread is complete. If it is, loading is done.
if(poller_.wait_for(0ms) == std::future_status::ready) {
if(poller_.wait_for(std::chrono::milliseconds(0)) == std::future_status::ready) {
window_.get().set_retval(retval::OK);
return;
}
Expand Down

0 comments on commit 0bd6f91

Please sign in to comment.