aboutsummaryrefslogtreecommitdiffstats
path: root/pugl
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2019-07-22 12:48:25 +0200
committerDavid Robillard <d@drobilla.net>2019-07-29 01:59:11 +0200
commit982ea3f09aa968bd89b00f445272984cb629b346 (patch)
treeeb36abf0c2db8585d84badf8773dcc0b97060245 /pugl
parente23890324d169d03868855a3e265ab4e3cd43745 (diff)
downloadpugl-982ea3f09aa968bd89b00f445272984cb629b346.tar.gz
pugl-982ea3f09aa968bd89b00f445272984cb629b346.tar.bz2
pugl-982ea3f09aa968bd89b00f445272984cb629b346.zip
Add deprecation macro and deprecate puglInitResizable()
Diffstat (limited to 'pugl')
-rw-r--r--pugl/pugl.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/pugl/pugl.h b/pugl/pugl.h
index adeeb0e..1567b1f 100644
--- a/pugl/pugl.h
+++ b/pugl/pugl.h
@@ -41,6 +41,14 @@
# define PUGL_API
#endif
+#if defined(__clang__)
+# define PUGL_DEPRECATED_BY(name) __attribute__((deprecated("", name)))
+#elif defined(__GNUC__)
+# define PUGL_DEPRECATED_BY(name) __attribute__((deprecated("Use " name)))
+#else
+# define PUGL_DEPRECATED_BY(name)
+#endif
+
#ifdef __cplusplus
extern "C" {
#endif
@@ -474,8 +482,10 @@ puglInitWindowAspectRatio(PuglView* view,
/**
Enable or disable resizing before creating a window.
+
+ @deprecated Use puglInitWindowHint() with @ref PUGL_RESIZABLE.
*/
-PUGL_API void
+PUGL_API PUGL_DEPRECATED_BY("puglInitWindowHint") void
puglInitResizable(PuglView* view, bool resizable);
/**