[Scummvm-git-logs] scummvm master -> 437678110e80e2ad2227090bb0ae16e841ed70ab

digitall noreply at scummvm.org
Mon May 2 15:19:38 UTC 2022


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:
437678110e AGS: Fix GCC Compiler Warnings


Commit: 437678110e80e2ad2227090bb0ae16e841ed70ab
    https://github.com/scummvm/scummvm/commit/437678110e80e2ad2227090bb0ae16e841ed70ab
Author: D G Turner (digitall at scummvm.org)
Date: 2022-05-02T16:19:16+01:00

Commit Message:
AGS: Fix GCC Compiler Warnings

Changed paths:
    engines/ags/engine/ac/draw.cpp
    engines/ags/shared/gui/gui_listbox.cpp
    engines/ags/shared/gui/gui_main.h


diff --git a/engines/ags/engine/ac/draw.cpp b/engines/ags/engine/ac/draw.cpp
index 34e22352cb3..61b0be6b489 100644
--- a/engines/ags/engine/ac/draw.cpp
+++ b/engines/ags/engine/ac/draw.cpp
@@ -844,7 +844,7 @@ int sort_out_walk_behinds(Bitmap *sprit, int xx, int yy, int basel, int zoom = 1
 	int maskcol = sprit->GetMaskColor();
 	int spcoldep = sprit->GetColorDepth();
 	int screenhit = _GP(thisroom).WalkBehindMask->GetHeight();
-	short *shptr, *shptr2;
+	short *shptr;
 	int *loptr;
 	int pixelsChanged = 0;
 	int ee = 0;
@@ -1124,7 +1124,7 @@ void apply_tint_or_light(int actspsindex, int light_level,
 }
 
 Bitmap *transform_sprite(Bitmap *src, bool src_has_alpha, Bitmap *&dst, const Size dst_sz, BitmapFlip flip) {
-	if ((src->GetSize() == dst_sz) && (flip == kFlip_None))
+	if ((src->GetSize() == dst_sz) && (flip == kBitmap_NoFlip))
 		return src; // No transform: return source image
 
 	dst = recycle_bitmap(dst, src->GetColorDepth(), dst_sz.Width, dst_sz.Height, true);
@@ -1138,7 +1138,7 @@ Bitmap *transform_sprite(Bitmap *src, bool src_has_alpha, Bitmap *&dst, const Si
 		if (_G(in_new_room) > 0)
 			select_palette(_G(palette));
 
-		if (flip != kFlip_None) {
+		if (flip != kBitmap_NoFlip) {
 			Bitmap tempbmp;
 			tempbmp.CreateTransparent(dst_sz.Width, dst_sz.Height, src->GetColorDepth());
 			if ((IS_ANTIALIAS_SPRITES) && !src_has_alpha)
diff --git a/engines/ags/shared/gui/gui_listbox.cpp b/engines/ags/shared/gui/gui_listbox.cpp
index 89da68878c7..47524f979db 100644
--- a/engines/ags/shared/gui/gui_listbox.cpp
+++ b/engines/ags/shared/gui/gui_listbox.cpp
@@ -87,7 +87,6 @@ Rect GUIListBox::CalcGraphicRect(bool clipped) {
 	Rect rc = RectWH(X, Y, Width, Height);
 	UpdateMetrics();
 	const int width = Width - 1;
-	const int height = Height - 1;
 	const int pixel_size = get_fixed_pixel_size(1);
 	int right_hand_edge = width - pixel_size - 1;
 	// calculate the scroll bar's width if necessary
diff --git a/engines/ags/shared/gui/gui_main.h b/engines/ags/shared/gui/gui_main.h
index 4e111a19a25..dce0388725f 100644
--- a/engines/ags/shared/gui/gui_main.h
+++ b/engines/ags/shared/gui/gui_main.h
@@ -258,10 +258,6 @@ extern int get_adjusted_spritewidth(int spr);
 extern int get_adjusted_spriteheight(int spr);
 extern bool is_sprite_alpha(int spr);
 
-extern void draw_gui_sprite(Shared::Bitmap *ds, bool use_alpha, int x, int y,
-	Shared::Bitmap *image, bool src_has_alpha,
-	Shared::BlendMode blend_mode, int alpha);
-
 #define SET_EIP(x) set_our_eip(x);
 extern void set_eip_guiobj(int eip);
 extern int get_eip_guiobj();




More information about the Scummvm-git-logs mailing list