summaryrefslogtreecommitdiff
path: root/PLUGINS
diff options
context:
space:
mode:
authorKlaus Schmidinger <kls (at) cadsoft (dot) de>2008-02-24 18:00:00 +0100
committerKlaus Schmidinger <kls (at) cadsoft (dot) de>2008-02-24 18:00:00 +0100
commit83d7a4b7838a8209c05c53b5e625bf965d3bf585 (patch)
tree95ed1f63a21e849514e1496df495fccc6d971d81 /PLUGINS
parent9279cb21cd311cbb141d506ba9d17c3a057b4d3c (diff)
downloadvdr-patch-lnbsharing-83d7a4b7838a8209c05c53b5e625bf965d3bf585.tar.gz
vdr-patch-lnbsharing-83d7a4b7838a8209c05c53b5e625bf965d3bf585.tar.bz2
Version 1.5.16vdr-1.5.16
- Fixed setting the current subtitle track in Transfer-Mode (reported by Petri Helin, thanks to Reinhard Nissl for pointing out that cDevice::Transferring() doesn't return the right value in the early stage of channel switching). - Updated the Danish OSD texts (thanks to Mogens Elneff). - Updated the Dutch OSD texts (thanks to Carel Willemse). - Fixed various spelling errors and improved PLUGINS.html (thanks to Ville Skyttä). - Updated the Italian OSD texts (thanks to Diego Pierotto). - Fixed the format in cRemote::Put() to use "%016llX" instead of "%016LX" (thanks to Ludwig Nussel for pointing this out). - Revised the fix of calculating the scrollbar height in the skins. The scrollbar handle now always has a height that is at least the width of the scrollbar. - When switching the device that's used for live viewing away from the current transponder in favor of an upcoming recording, an attempt is now made to stay on the current channel by possibly going into 'Transfer Mode'. - The CAM menu now stays open as long as it is automatically updated, even without pressing a remote control key. This is important when updating the CAM firmware from the transponder. - No longer trying to switch to an available channel if the primary device has no valid programme and a menu is open (avoids interference with the CAM in case a CAM menu is open). - Increased the valid range of the "Subtitle offset" setup option to -100...100 (thanks to Rolf Ahrenberg). - Added the backslash ('\') to the list of characters that need to be escaped when executing external commands (thanks to Peter Bieringer for reporting this one).
Diffstat (limited to 'PLUGINS')
-rw-r--r--PLUGINS/src/skincurses/HISTORY5
-rw-r--r--PLUGINS/src/skincurses/skincurses.c15
2 files changed, 13 insertions, 7 deletions
diff --git a/PLUGINS/src/skincurses/HISTORY b/PLUGINS/src/skincurses/HISTORY
index 45b79bb..6088c8b 100644
--- a/PLUGINS/src/skincurses/HISTORY
+++ b/PLUGINS/src/skincurses/HISTORY
@@ -70,3 +70,8 @@ VDR Plugin 'skincurses' Revision History
- Using cString::sprintf() instead of asprintf().
- Implemented cSkinCursesDisplayMenu::SetScrollbar().
+
+2008-02-23: Version 0.1.6
+
+- Revised the fix of calculating the scrollbar height in the skins. The scrollbar
+ handle now always has a height that is at least the width of the scrollbar.
diff --git a/PLUGINS/src/skincurses/skincurses.c b/PLUGINS/src/skincurses/skincurses.c
index 2f0bea9..ed30a5e 100644
--- a/PLUGINS/src/skincurses/skincurses.c
+++ b/PLUGINS/src/skincurses/skincurses.c
@@ -3,7 +3,7 @@
*
* See the README file for copyright information and how to reach the author.
*
- * $Id: skincurses.c 1.20 2008/02/17 14:28:19 kls Exp $
+ * $Id: skincurses.c 1.22 2008/02/23 10:38:04 kls Exp $
*/
#include <ncurses.h>
@@ -11,7 +11,7 @@
#include <vdr/plugin.h>
#include <vdr/skins.h>
-static const char *VERSION = "0.1.5";
+static const char *VERSION = "0.1.6";
static const char *DESCRIPTION = trNOOP("A text only skin");
static const char *MAINMENUENTRY = NULL;
@@ -296,14 +296,15 @@ void cSkinCursesDisplayMenu::DrawScrollbar(int Total, int Offset, int Shown, int
{
if (Total > 0 && Total > Shown) {
int yt = Top;
- int yb = yt + Height - 1;
+ int yb = yt + Height;
int st = yt;
int sb = yb;
- int tt = st + (sb - st + 1) * Offset / Total;
- int tb = tt + (sb - st + 1) * Shown / Total;
+ int th = max(int((sb - st) * double(Shown) / Total + 0.5), 1);
+ int tt = min(int(st + (sb - st) * double(Offset) / Total + 0.5), sb - th);
+ int tb = min(tt + th, sb);
int xl = ScOsdWidth - 1;
- osd->DrawRectangle(xl, st, xl, sb, clrWhite);
- osd->DrawRectangle(xl, tt, xl, tb, clrCyan);
+ osd->DrawRectangle(xl, st, xl, sb - 1, clrWhite);
+ osd->DrawRectangle(xl, tt, xl, tb - 1, clrCyan);
}
}