Add SDL_messagebox.h

This commit is contained in:
Ethan Lee 2013-07-13 14:21:00 -04:00
parent f42d304eff
commit 284c1cde76
2 changed files with 53 additions and 30 deletions

View file

@ -9,6 +9,7 @@ DEPS = \
# Source Lists
SDL2 = \
src/LPUtf8StrMarshaler.cs \
src/SDL2.cs \
src/SDL2_image.cs \
src/SDL2_mixer.cs \

View file

@ -365,6 +365,28 @@ namespace SDL2
#endregion
#region SDL_messagebox.h
public enum SDL_MessageBoxFlags : uint
{
SDL_MESSAGEBOX_ERROR = 0x00000010,
SDL_MESSAGEBOX_WARNING = 0x00000020,
SDL_MESSAGEBOX_INFORMATION = 0x00000040
}
/* window refers to an SDL_Window* */
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
public static extern int SDL_ShowSimpleMessageBox(
UInt32 flags,
[In()] [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef = typeof(LPUtf8StrMarshaler))]
string title,
[In()] [MarshalAs(UnmanagedType.CustomMarshaler, MarshalTypeRef = typeof(LPUtf8StrMarshaler))]
string message,
IntPtr window
);
#endregion
#region SDL_version.h, SDL_revision.h
/* Similar to the headers, this is the version we're expecting to be