[Scummvm-cvs-logs] scummvm master -> 3a466a29ea91f829c542f9537b3f578e72af31f3

dreammaster dreammaster at scummvm.org
Wed Aug 3 02:04:19 CEST 2016


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
3a466a29ea TITANIC: Fix compiler warnings


Commit: 3a466a29ea91f829c542f9537b3f578e72af31f3
    https://github.com/scummvm/scummvm/commit/3a466a29ea91f829c542f9537b3f578e72af31f3
Author: Paul Gilbert (dreammaster at scummvm.org)
Date: 2016-08-02T20:04:06-04:00

Commit Message:
TITANIC: Fix compiler warnings

Changed paths:
    engines/titanic/npcs/true_talk_npc.cpp
    engines/titanic/pet_control/pet_slider.cpp
    engines/titanic/pet_control/pet_sound.cpp
    engines/titanic/support/movie.cpp



diff --git a/engines/titanic/npcs/true_talk_npc.cpp b/engines/titanic/npcs/true_talk_npc.cpp
index faadc2d..290922f 100644
--- a/engines/titanic/npcs/true_talk_npc.cpp
+++ b/engines/titanic/npcs/true_talk_npc.cpp
@@ -222,13 +222,13 @@ void CTrueTalkNPC::startTalker(CViewItem *view) {
 		gameManager->getTalkManager()->start4(this, view);
 }
 
-void CTrueTalkNPC::performAction(bool startTalking, CViewItem *view_) {
+void CTrueTalkNPC::performAction(bool startTalkingFlag, CViewItem *destView) {
 	CPetControl *pet = getPetControl();
 	if (pet)
 		pet->resetActiveNPC();
 
-	if (startTalking)
-		startTalker(view_);
+	if (startTalkingFlag)
+		startTalker(destView);
 
 	if (pet)
 		pet->convResetNPC();
diff --git a/engines/titanic/pet_control/pet_slider.cpp b/engines/titanic/pet_control/pet_slider.cpp
index 166ba30..eb07012 100644
--- a/engines/titanic/pet_control/pet_slider.cpp
+++ b/engines/titanic/pet_control/pet_slider.cpp
@@ -94,10 +94,10 @@ double CPetSlider::getOffsetPixels() const {
 
 void CPetSlider::setSliderOffset(double offset) {
 	if (_orientation & ORIENTATION_HORIZONTAL)
-		_sliderOffset = offset * (_slidingRect.right - _slidingRect.left);
+		_sliderOffset = (int)(offset * (_slidingRect.right - _slidingRect.left));
 
 	if (_orientation & ORIENTATION_VERTICAL)
-		_sliderOffset = offset * (_slidingRect.bottom - _slidingRect.top);
+		_sliderOffset = (int)(offset * (_slidingRect.bottom - _slidingRect.top));
 }
 
 void CPetSlider::setOffsetPixels(int offset) {
diff --git a/engines/titanic/pet_control/pet_sound.cpp b/engines/titanic/pet_control/pet_sound.cpp
index 4d2bf37..7bfeb25 100644
--- a/engines/titanic/pet_control/pet_sound.cpp
+++ b/engines/titanic/pet_control/pet_sound.cpp
@@ -146,7 +146,7 @@ bool CPetSound::MouseButtonDownMsg(const Point &pt) {
 		CPetSlider *slider = sliders[idx];
 		bool isLeft = rectLeft.contains(pt);
 		bool isRight = rectRight.contains(pt);
-		int offset;
+		double offset;
 
 		if (isLeft) {
 			slider->stepPosition(-1);
diff --git a/engines/titanic/support/movie.cpp b/engines/titanic/support/movie.cpp
index 2784bda..8810cf0 100644
--- a/engines/titanic/support/movie.cpp
+++ b/engines/titanic/support/movie.cpp
@@ -133,7 +133,7 @@ void OSMovie::playClip(const Point &drawPos, uint startFrame, uint endFrame) {
 		drawPos.y + (heightLess ? CLIP_HEIGHT_REDUCED : CLIP_HEIGHT)
 	);
 
-	uint timePerFrame = 1000 / _aviSurface._frameRate;
+	uint timePerFrame = (uint)(1000.0 / _aviSurface._frameRate);
 
 	for (; endFrame >= startFrame; ++startFrame) {
 		// Set the frame






More information about the Scummvm-git-logs mailing list