Allow SDL_uikitkeyboard.h to be included in C++ applications
authorSam Lantinga <slouken@libsdl.org>
Fri, 25 May 2012 18:21:10 -0400
changeset 6309 53a0e9f5db8d
parent 6308 263e2c049c22
child 6310 f830e73e2acf
Allow SDL_uikitkeyboard.h to be included in C++ applications
src/video/uikit/SDL_uikitkeyboard.h
--- a/src/video/uikit/SDL_uikitkeyboard.h	Fri May 25 15:35:41 2012 -0300
+++ b/src/video/uikit/SDL_uikitkeyboard.h	Fri May 25 18:21:10 2012 -0400
@@ -22,11 +22,25 @@
 #ifndef sdl_uikitkeyboard_h
 #define sdl_uikitkeyboard_h
 
+/* Set up for C function definitions, even when using C++ */
+#ifdef __cplusplus
+/* *INDENT-OFF* */
+extern "C" {
+/* *INDENT-ON* */
+#endif
+
 extern DECLSPEC int SDLCALL SDL_iPhoneKeyboardShow(SDL_Window * window);
 extern DECLSPEC int SDLCALL SDL_iPhoneKeyboardHide(SDL_Window * window);
 extern DECLSPEC SDL_bool SDLCALL SDL_iPhoneKeyboardIsShown(SDL_Window * window);
 extern DECLSPEC int SDLCALL SDL_iPhoneKeyboardToggle(SDL_Window * window);
 
+/* Ends C function definitions when using C++ */
+#ifdef __cplusplus
+/* *INDENT-OFF* */
+}
+/* *INDENT-ON* */
 #endif
 
+#endif /* sdl_uikitkeyboard_h */
+
 /* vi: set ts=4 sw=4 expandtab: */