From 313db338c27518824e43e697c2b29fcb208b0d16 Mon Sep 17 00:00:00 2001 From: Jacek Jendrzej Date: Thu, 18 Oct 2012 17:11:56 +0200 Subject: [PATCH] buttons.cpp: -fix skip last button txt Origin commit data ------------------ Commit: https://github.com/neutrino-images/ni-neutrino/commit/840ba47db1261b26ece9d204cce0ac31709aea0b Author: Jacek Jendrzej Date: 2012-10-18 (Thu, 18 Oct 2012) --- src/gui/widget/buttons.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gui/widget/buttons.cpp b/src/gui/widget/buttons.cpp index bffb99a66..a97a5a3bc 100644 --- a/src/gui/widget/buttons.cpp +++ b/src/gui/widget/buttons.cpp @@ -132,7 +132,7 @@ int paintButtons( const int &x, //workaround for to small screen (1) int skip_last_button_txt = false; - if( (w_footer > 0) && ( (w_button*cnt) > (uint) w_footer) ){ + if( (w_footer > 0) && ( ((w_button*cnt) + ((cnt -1) * w_space)) > (uint) w_footer) ){ w_button= ((w_footer+w_max_icon)/(cnt)); skip_last_button_txt = true; }