Added an 'int' typecast to calculations involving FramesPerSecond() to avoid compiler warnings

This commit is contained in:
Klaus Schmidinger
2009-01-24 11:42:24 +01:00
parent c2ecee3d40
commit fa848a6f2e
4 changed files with 12 additions and 8 deletions

7
menu.c
View File

@@ -4,12 +4,13 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
* $Id: menu.c 2.4 2009/01/06 14:34:17 kls Exp $
* $Id: menu.c 2.5 2009/01/24 11:42:24 kls Exp $
*/
#include "menu.h"
#include <ctype.h>
#include <limits.h>
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
@@ -4170,8 +4171,8 @@ void cReplayControl::TimeSearchProcess(eKeys Key)
{
#define STAY_SECONDS_OFF_END 10
int Seconds = (timeSearchTime >> 24) * 36000 + ((timeSearchTime & 0x00FF0000) >> 16) * 3600 + ((timeSearchTime & 0x0000FF00) >> 8) * 600 + (timeSearchTime & 0x000000FF) * 60;
int Current = (lastCurrent / FramesPerSecond());
int Total = (lastTotal / FramesPerSecond());
int Current = int(round(lastCurrent / FramesPerSecond()));
int Total = int(round(lastTotal / FramesPerSecond()));
switch (Key) {
case k0 ... k9:
if (timeSearchPos < 4) {