diff options
author | D G Turner | 2019-11-30 23:12:30 +0000 |
---|---|---|
committer | D G Turner | 2019-11-30 23:12:30 +0000 |
commit | b25c4b21fdd6f911b94fb411087078ecf756691e (patch) | |
tree | 4dd3daa421325ca6feebe081f9f522b379cc2e42 /engines | |
parent | d84ce7e4d5f148b4fb39a60a0fe1b9f9e6e7f6dc (diff) | |
download | scummvm-rg350-b25c4b21fdd6f911b94fb411087078ecf756691e.tar.gz scummvm-rg350-b25c4b21fdd6f911b94fb411087078ecf756691e.tar.bz2 scummvm-rg350-b25c4b21fdd6f911b94fb411087078ecf756691e.zip |
TINSEL: Fix Missing Default Switch Cases
These are flagged by GCC if -Wswitch-default is enabled.
Diffstat (limited to 'engines')
-rw-r--r-- | engines/tinsel/adpcm.cpp | 2 | ||||
-rw-r--r-- | engines/tinsel/dialogs.cpp | 22 | ||||
-rw-r--r-- | engines/tinsel/graphics.cpp | 2 | ||||
-rw-r--r-- | engines/tinsel/move.cpp | 12 | ||||
-rw-r--r-- | engines/tinsel/pcode.cpp | 3 | ||||
-rw-r--r-- | engines/tinsel/scroll.cpp | 3 | ||||
-rw-r--r-- | engines/tinsel/tinlib.cpp | 7 |
7 files changed, 51 insertions, 0 deletions
diff --git a/engines/tinsel/adpcm.cpp b/engines/tinsel/adpcm.cpp index 9de3dff341..2c48d6405c 100644 --- a/engines/tinsel/adpcm.cpp +++ b/engines/tinsel/adpcm.cpp @@ -132,6 +132,8 @@ int Tinsel6_ADPCMStream::readBuffer(int16 *buffer, const int numSamples) { buffer[samples] = decodeTinsel((_chunkData << 2) & 0xFC00, eVal); _blockPos[0]++; break; + default: + break; } } diff --git a/engines/tinsel/dialogs.cpp b/engines/tinsel/dialogs.cpp index 755b9275c6..1b7b9f7fff 100644 --- a/engines/tinsel/dialogs.cpp +++ b/engines/tinsel/dialogs.cpp @@ -3509,8 +3509,14 @@ static void InvCursor(InvCursorFN fn, int CurX, int CurY) { case I_BODY: restoreMain = true; break; + + default: + break; } break; + + default: + break; } if (restoreMain && ICursor != IC_NORMAL) { @@ -4489,6 +4495,9 @@ static void SlideMSlider(int x, SSFN fn) { if (g_ino == INV_CONF && cd.box == subtitlesBox) Select(_vm->_config->_language, false); break; + + default: + break; } } @@ -4822,6 +4831,9 @@ static void InvDragStart() { g_InvDragging = ID_BRIGHT; } break; + + default: + break; } } @@ -5050,6 +5062,7 @@ static void MenuAction(int i, bool dbl) { static void ConfActionSpecial(int i) { switch (i) { case IB_NONE: + default: break; case IB_UP: // Scroll up if (cd.extraBase > 0) { @@ -5291,6 +5304,9 @@ static void InvWalkTo(const Common::Point &coOrds) { InvPickup(i); } break; + + default: + break; } } @@ -5372,6 +5388,9 @@ static void InvAction() { g_ItemsChanged = true; } break; + + default: + break; } } @@ -5398,6 +5417,9 @@ static void InvLook(const Common::Point &coOrds) { ConvAction(INV_CLOSEICON); KillInventory(); break; + + default: + break; } } diff --git a/engines/tinsel/graphics.cpp b/engines/tinsel/graphics.cpp index 2ff96a9b64..90b5299ff0 100644 --- a/engines/tinsel/graphics.cpp +++ b/engines/tinsel/graphics.cpp @@ -135,6 +135,8 @@ uint8* psxPJCRLEUnwinder(uint16 imageWidth, uint16 imageHeight, uint8 *srcIdx) { decremTiles--; } break; + default: + break; } } diff --git a/engines/tinsel/move.cpp b/engines/tinsel/move.cpp index 03b0b85cf0..62d0cd9c60 100644 --- a/engines/tinsel/move.cpp +++ b/engines/tinsel/move.cpp @@ -230,6 +230,9 @@ static int ClickedOnRefer(HPOLYGON hRefpoly, int clickX, int clickY, int *ptgtX, break; } break; + + default: + break; } if (*ptgtX != -1 && *ptgtY != -1) { return NOT_SORTED; @@ -303,6 +306,9 @@ static int ClickedOnNothing(int clickX, int clickY, int *ptgtX, int *ptgtY) { return ClickedOnPath(i, clickY, ptgtX, ptgtY); } break; + + default: + break; } // Going nowhere! @@ -394,6 +400,9 @@ DIRECTION GetDirection(int fromx, int fromy, int tox, int toy, DIRECTION lastree case YB_X1_5: ychange += ychange / 2; // Double y distance to cover break; + + default: + break; } /* @@ -453,6 +462,8 @@ DIRECTION GetDirection(int fromx, int fromy, int tox, int toy, DIRECTION lastree if (ydir == Y_UP) DontBother = true; break; + default: + break; } } if (!DontBother) { @@ -744,6 +755,7 @@ static void SetNextDest(PMOVER pMover) { hNpoly = pMover->hFnpath; // The node path we're in (if any) switch (pMover->npstatus) { case NOT_IN: + default: break; case ENTERING: diff --git a/engines/tinsel/pcode.cpp b/engines/tinsel/pcode.cpp index 8899eea65b..e55adc4b16 100644 --- a/engines/tinsel/pcode.cpp +++ b/engines/tinsel/pcode.cpp @@ -773,6 +773,8 @@ void Interpret(CORO_PARAM, INT_CONTEXT *ic) { case OP_LOR: tmp = (tmp || tmp2); break; case OP_LAND: tmp = (tmp && tmp2); break; + + default: break; } ic->stack[ic->sp] = tmp; @@ -803,6 +805,7 @@ void Interpret(CORO_PARAM, INT_CONTEXT *ic) { case OP_AND: tmp &= tmp2; break; case OP_OR: tmp |= tmp2; break; case OP_EOR: tmp ^= tmp2; break; + default: break; } ic->stack[ic->sp] = tmp; break; diff --git a/engines/tinsel/scroll.cpp b/engines/tinsel/scroll.cpp index eafb238ec0..52ffca88ac 100644 --- a/engines/tinsel/scroll.cpp +++ b/engines/tinsel/scroll.cpp @@ -232,6 +232,9 @@ static void NeedScroll(int direction) { } } break; + + default: + break; } } diff --git a/engines/tinsel/tinlib.cpp b/engines/tinsel/tinlib.cpp index 9cc567b910..54dfa5d021 100644 --- a/engines/tinsel/tinlib.cpp +++ b/engines/tinsel/tinlib.cpp @@ -511,6 +511,9 @@ void TinGetVersion(WHICH_VER which, char *buffer, int length) { case VER_COMPILE: memcpy(buffer, cptr + VER_LEN, length); break; + + default: + break; } } @@ -803,6 +806,10 @@ void Control(int param) { EnableTags(); // Tags back on RestoreMainCursor(); // Re-instate cursor... + break; + + default: + break; } } |