From 76bd63e2dc6ac5aaaf7f2cc98c2a83ab88ccc46c Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Mon, 14 Apr 2014 17:12:09 +0200 Subject: force fancy progressbar redraw on window size change We always reacted on the size change, but the bar is only redraw if the precentage changes, which can take quiet a while in big upgrades, so with a bit of refactoring we can now call for a redraw immediate to fix this. This refactor also helps in avoiding obscure pitfalls clangs static analyser was complaining about (namely failure of ioctl resulting in garbage values in the struct). --- apt-pkg/install-progress.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'apt-pkg/install-progress.h') diff --git a/apt-pkg/install-progress.h b/apt-pkg/install-progress.h index 112b034fb..5d1a20e9b 100644 --- a/apt-pkg/install-progress.h +++ b/apt-pkg/install-progress.h @@ -1,6 +1,8 @@ #ifndef PKGLIB_IPROGRESS_H #define PKGLIB_IPROGRESS_H +#include + #include #include #include @@ -120,6 +122,7 @@ namespace Progress { private: static void staticSIGWINCH(int); static std::vector instances; + APT_HIDDEN bool DrawStatusLine(); protected: void SetupTerminalScrollArea(int nr_rows); -- cgit v1.2.3