mirror of
https://forgejo.xatacraft.ru/Sunshine/mkxp-sunshine.git
synced 2026-08-19 21:39:57 +00:00
Add fallthrough notes to intentional fallthroughs against compiler warnings and for better code readability
This commit is contained in:
parent
f7b3f1ba17
commit
e75ef54a75
3 changed files with 7 additions and 0 deletions
|
|
@ -78,9 +78,11 @@ void ALStream::close()
|
|||
case Playing:
|
||||
case Paused:
|
||||
stopStream();
|
||||
/* falls through */
|
||||
case Stopped:
|
||||
closeSource();
|
||||
state = Closed;
|
||||
/* falls through */
|
||||
case Closed:
|
||||
return;
|
||||
}
|
||||
|
|
@ -95,8 +97,10 @@ void ALStream::open(const std::string &filename)
|
|||
case Playing:
|
||||
case Paused:
|
||||
stopStream();
|
||||
/* falls through */
|
||||
case Stopped:
|
||||
closeSource();
|
||||
/* falls through */
|
||||
case Closed:
|
||||
openSource(filename);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -119,9 +119,11 @@ void AudioStream::play(const std::string &filename,
|
|||
case ALStream::Paused :
|
||||
case ALStream::Playing :
|
||||
stream.stop();
|
||||
/* falls through */
|
||||
case ALStream::Stopped :
|
||||
if (diffFile)
|
||||
stream.close();
|
||||
/* falls through */
|
||||
case ALStream::Closed :
|
||||
if (diffFile)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -455,6 +455,7 @@ void EventThread::process(RGSSThreadData &rtData)
|
|||
case SDL_FINGERDOWN :
|
||||
i = event.tfinger.fingerId;
|
||||
touchState.fingers[i].down = true;
|
||||
/* falls through */
|
||||
|
||||
case SDL_FINGERMOTION :
|
||||
i = event.tfinger.fingerId;
|
||||
|
|
|
|||
Loading…
Reference in a new issue