From bc7e76ec5dd18ed949edc5453c930cb687a00269 Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Sun, 15 Feb 2009 15:10:47 +0000 Subject: Yet more warning fixes. svn-id: r38253 --- engines/sci/engine/kmenu.cpp | 8 ++++---- engines/sci/engine/kpathing.cpp | 14 +++----------- 2 files changed, 7 insertions(+), 15 deletions(-) (limited to 'engines') diff --git a/engines/sci/engine/kmenu.cpp b/engines/sci/engine/kmenu.cpp index 8f7203ef87..b4510d3d1a 100644 --- a/engines/sci/engine/kmenu.cpp +++ b/engines/sci/engine/kmenu.cpp @@ -393,20 +393,20 @@ kMenuSelect(state_t *s, int funct_nr, int argc, reg_t *argv) old_menu = -1; while (menu_mode) { - sci_event_t event = gfxop_get_event(s->gfx_state, SCI_EVT_ANY); + sci_event_t ev = gfxop_get_event(s->gfx_state, SCI_EVT_ANY); claimed = 0; - switch (event.type) { + switch (ev.type) { case SCI_EVT_QUIT: quit_vm(); return NULL_REG; case SCI_EVT_KEYBOARD: - switch (event.data) { + switch (ev.data) { case '`': - if (event.buckybits & SCI_EVM_CTRL) + if (ev.buckybits & SCI_EVM_CTRL) s->visual->print(GFXW(s->visual), 0); break; diff --git a/engines/sci/engine/kpathing.cpp b/engines/sci/engine/kpathing.cpp index 4679a45f9a..cb83604b53 100644 --- a/engines/sci/engine/kpathing.cpp +++ b/engines/sci/engine/kpathing.cpp @@ -80,20 +80,12 @@ /* Floating point struct */ typedef struct pointf { + pointf() : x(0), y(0) {} + pointf(float x_, float y_) : x(x_), y(y_) {} + float x, y; } pointf_t; -pointf_t -pointf(float x, float y) -{ - pointf_t p; - - p.x = x; - p.y = y; - - return p; -} - pointf_t to_pointf(point_t p) { -- cgit v1.2.3