diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/internal.h | 3 | ||||
-rw-r--r-- | src/platform.h | 6 | ||||
-rw-r--r-- | src/types.h | 14 | ||||
-rw-r--r-- | src/win.h | 19 | ||||
-rw-r--r-- | src/x11.c | 3 | ||||
-rw-r--r-- | src/x11.h | 4 | ||||
-rw-r--r-- | src/x11_gl.c | 6 |
7 files changed, 18 insertions, 37 deletions
diff --git a/src/internal.h b/src/internal.h index d6d91ea..c35f9ac 100644 --- a/src/internal.h +++ b/src/internal.h @@ -83,8 +83,7 @@ PuglStatus puglDispatchSimpleEvent(PuglView* view, PuglEventType type); /// Process configure event while already in the graphics context -PUGL_WARN_UNUSED_RESULT -PuglStatus +PUGL_WARN_UNUSED_RESULT PuglStatus puglConfigure(PuglView* view, const PuglEvent* event); /// Dispatch `event` to `view`, entering graphics context if necessary diff --git a/src/platform.h b/src/platform.h index e1c71ed..e43a58e 100644 --- a/src/platform.h +++ b/src/platform.h @@ -13,8 +13,7 @@ PUGL_BEGIN_DECLS /// Allocate and initialise world internals (implemented once per platform) -PUGL_MALLOC_FUNC -PuglWorldInternals* +PUGL_MALLOC_FUNC PuglWorldInternals* puglInitWorldInternals(PuglWorldType type, PuglWorldFlags flags); /// Destroy and free world internals (implemented once per platform) @@ -22,8 +21,7 @@ void puglFreeWorldInternals(PuglWorld* world); /// Allocate and initialise view internals (implemented once per platform) -PUGL_MALLOC_FUNC -PuglInternals* +PUGL_MALLOC_FUNC PuglInternals* puglInitViewInternals(PuglWorld* world); /// Destroy and free view internals (implemented once per platform) diff --git a/src/types.h b/src/types.h index 05343f7..c3ebdb6 100644 --- a/src/types.h +++ b/src/types.h @@ -82,23 +82,21 @@ typedef void PuglSurface; /// Graphics backend interface struct PuglBackendImpl { /// Get visual information from display and setup view as necessary - PUGL_WARN_UNUSED_RESULT - PuglStatus (*configure)(PuglView*); + PUGL_WARN_UNUSED_RESULT PuglStatus (*configure)(PuglView*); /// Create surface and drawing context - PUGL_WARN_UNUSED_RESULT - PuglStatus (*create)(PuglView*); + PUGL_WARN_UNUSED_RESULT PuglStatus (*create)(PuglView*); /// Destroy surface and drawing context void (*destroy)(PuglView*); /// Enter drawing context, for drawing if expose is non-null - PUGL_WARN_UNUSED_RESULT - PuglStatus (*enter)(PuglView*, const PuglExposeEvent*); + PUGL_WARN_UNUSED_RESULT PuglStatus (*enter)(PuglView*, + const PuglExposeEvent*); /// Leave drawing context, after drawing if expose is non-null - PUGL_WARN_UNUSED_RESULT - PuglStatus (*leave)(PuglView*, const PuglExposeEvent*); + PUGL_WARN_UNUSED_RESULT PuglStatus (*leave)(PuglView*, + const PuglExposeEvent*); /// Return the puglGetContext() handle for the application, if any void* (*getContext)(PuglView*); @@ -37,28 +37,19 @@ struct PuglInternalsImpl { bool fullscreen; }; -PUGL_API -PuglWinPFD +PUGL_API PuglWinPFD puglWinGetPixelFormatDescriptor(const PuglHints hints); -PUGL_WARN_UNUSED_RESULT -PUGL_API -PuglStatus +PUGL_WARN_UNUSED_RESULT PUGL_API PuglStatus puglWinCreateWindow(PuglView* view, const char* title, HWND* hwnd, HDC* hdc); -PUGL_WARN_UNUSED_RESULT -PUGL_API -PuglStatus +PUGL_WARN_UNUSED_RESULT PUGL_API PuglStatus puglWinConfigure(PuglView* view); -PUGL_WARN_UNUSED_RESULT -PUGL_API -PuglStatus +PUGL_WARN_UNUSED_RESULT PUGL_API PuglStatus puglWinEnter(PuglView* view, const PuglExposeEvent* expose); -PUGL_WARN_UNUSED_RESULT -PUGL_API -PuglStatus +PUGL_WARN_UNUSED_RESULT PUGL_API PuglStatus puglWinLeave(PuglView* view, const PuglExposeEvent* expose); #endif // PUGL_SRC_WIN_H @@ -1664,8 +1664,7 @@ handleSelectionRequest(const PuglWorld* const world, } /// Flush pending configure and expose events for all views -PUGL_WARN_UNUSED_RESULT -static PuglStatus +PUGL_WARN_UNUSED_RESULT static PuglStatus flushExposures(PuglWorld* const world) { PuglStatus st0 = PUGL_SUCCESS; @@ -93,9 +93,7 @@ struct PuglInternalsImpl { bool mapped; }; -PUGL_WARN_UNUSED_RESULT -PUGL_API -PuglStatus +PUGL_WARN_UNUSED_RESULT PUGL_API PuglStatus puglX11Configure(PuglView* view); #endif // PUGL_SRC_X11_H diff --git a/src/x11_gl.c b/src/x11_gl.c index c43cf9f..527335b 100644 --- a/src/x11_gl.c +++ b/src/x11_gl.c @@ -101,8 +101,7 @@ puglX11GlConfigure(PuglView* view) return PUGL_SUCCESS; } -PUGL_WARN_UNUSED_RESULT -static PuglStatus +PUGL_WARN_UNUSED_RESULT static PuglStatus puglX11GlEnter(PuglView* view, const PuglExposeEvent* PUGL_UNUSED(expose)) { PuglX11GlSurface* surface = (PuglX11GlSurface*)view->impl->surface; @@ -115,8 +114,7 @@ puglX11GlEnter(PuglView* view, const PuglExposeEvent* PUGL_UNUSED(expose)) : PUGL_FAILURE; } -PUGL_WARN_UNUSED_RESULT -static PuglStatus +PUGL_WARN_UNUSED_RESULT static PuglStatus puglX11GlLeave(PuglView* view, const PuglExposeEvent* expose) { Display* const display = view->world->impl->display; |