From: Ingo Ruhnke Date: Tue, 26 Aug 2014 05:33:15 +0000 (+0200) Subject: Hooked up progress reporting into the AddonDialog, non-blocking downloads are working now X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=9625cc99df47b1e5214a54b837f1bac4436f8e68;p=supertux.git Hooked up progress reporting into the AddonDialog, non-blocking downloads are working now Code still misses proper Addon install once the Download is completed --- diff --git a/src/addon/downloader.cpp b/src/addon/downloader.cpp index 702ce246e..349dc27fb 100644 --- a/src/addon/downloader.cpp +++ b/src/addon/downloader.cpp @@ -124,6 +124,7 @@ public: void on_progress(curl_off_t dltotal, curl_off_t dlnow, curl_off_t ultotal, curl_off_t ulnow) { + log_info << "progress: " << dlnow << "/" << dltotal << std::endl; m_status->dltotal = dltotal; m_status->dlnow = dlnow; @@ -258,6 +259,7 @@ Downloader::update() { case CURLMSG_DONE: curl_multi_remove_handle(m_multi_handle, msg->easy_handle); + log_info << "DOWNLOAD DONE" << std::endl; //FIXME: finish_transfer(msg->easy_handle); break; diff --git a/src/supertux/menu/addon_dialog.cpp b/src/supertux/menu/addon_dialog.cpp index bf0e00574..92bb812c5 100644 --- a/src/supertux/menu/addon_dialog.cpp +++ b/src/supertux/menu/addon_dialog.cpp @@ -36,6 +36,8 @@ AddonDialog::update() { AddonManager::current()->update(); + update_text(); + if (m_status->done) { MenuManager::instance().set_dialog({});