diff --git a/MonoGame.Framework/Media/MediaPlayer.cs b/MonoGame.Framework/Media/MediaPlayer.cs index af3a0eb59a5..7006d709a7f 100644 --- a/MonoGame.Framework/Media/MediaPlayer.cs +++ b/MonoGame.Framework/Media/MediaPlayer.cs @@ -291,7 +291,6 @@ private static void NextSong(int direction) private static void PlaySong(Song song) { - song.SetEventHandler(OnSongFinishedPlaying); song.Volume = IsMuted ? 0.0f : Volume; song.Play(); State = MediaState.Playing; diff --git a/MonoGame.Framework/SDL2/Input/SDL2_GamePad.cs b/MonoGame.Framework/SDL2/Input/SDL2_GamePad.cs index 55f017e06ab..c05f5f387ea 100644 --- a/MonoGame.Framework/SDL2/Input/SDL2_GamePad.cs +++ b/MonoGame.Framework/SDL2/Input/SDL2_GamePad.cs @@ -323,7 +323,8 @@ private static void INTERNAL_AutoConfig() osConfigFile += Environment.GetEnvironmentVariable("HOME"); if (osConfigFile.Length == 0) { - osConfigFile += "MonoGameJoystick.cfg"; // Oh well. + // Home wasn't found, so just try file in current directory. + osConfigFile = "MonoGameJoystick.cfg"; } else { @@ -339,7 +340,8 @@ private static void INTERNAL_AutoConfig() osConfigFile += Environment.GetEnvironmentVariable("HOME"); if (osConfigFile.Length == 0) { - osConfigFile += "MonoGameJoystick.cfg"; // Oh well. + // Home wasn't found, so just try file in current directory. + osConfigFile = "MonoGameJoystick.cfg"; } else { diff --git a/MonoGame.Framework/SDL2/Media/Song.cs b/MonoGame.Framework/SDL2/Media/Song.cs index 019190dc9ed..d84657c4201 100644 --- a/MonoGame.Framework/SDL2/Media/Song.cs +++ b/MonoGame.Framework/SDL2/Media/Song.cs @@ -229,14 +229,6 @@ internal void Stop() #region Internal Event Handler Methods - /// - /// Set the event handler for "Finished Playing". Done this way to prevent multiple bindings. - /// - internal void SetEventHandler(FinishedPlayingHandler handler) - { - // No-op - } - internal void OnFinishedPlaying() { MediaPlayer.OnSongFinishedPlaying(null, null); diff --git a/MonoGame.Framework/SDL2/Media/Video.cs b/MonoGame.Framework/SDL2/Media/Video.cs index 17c9bd75ec5..91fbc165025 100644 --- a/MonoGame.Framework/SDL2/Media/Video.cs +++ b/MonoGame.Framework/SDL2/Media/Video.cs @@ -154,7 +154,7 @@ internal static string Normalize(string FileName) return FileName; } - // Check the file extension + // Valid video asset names should not already have an extension, if (!string.IsNullOrEmpty(Path.GetExtension(FileName))) { return null; @@ -170,7 +170,7 @@ internal static string Normalize(string FileName) return FileName + ".ogg"; } - return null; + return null; // File not found with supported extension. } #endregion @@ -187,7 +187,7 @@ internal void Initialize() // Initialize the decoder. theoraDecoder = TheoraPlay.THEORAPLAY_startDecodeFile( FileName, - 150, // Arbitrarily 5 seconds in a 30fps movie. + 150, // Max frames to buffer. Arbitrarily set 5 seconds, assuming 30fps. #if VIDEOPLAYER_OPENGL TheoraPlay.THEORAPLAY_VideoFormat.THEORAPLAY_VIDFMT_IYUV #else diff --git a/MonoGame.Framework/SDL2/SDL2_GameWindow.cs b/MonoGame.Framework/SDL2/SDL2_GameWindow.cs index f0fdf204250..1ee343e122f 100644 --- a/MonoGame.Framework/SDL2/SDL2_GameWindow.cs +++ b/MonoGame.Framework/SDL2/SDL2_GameWindow.cs @@ -401,8 +401,6 @@ internal void INTERNAL_RunLoop() #endif while (SDL.SDL_PollEvent(out evt) == 1) { - // TODO: All events... - // Keyboard if (evt.type == SDL.SDL_EventType.SDL_KEYDOWN) {