Browse Source

libobs: Actually mark obs_[add|remove]_data_path as deprecated

3311a7105e2df15825ed9a5915543257f18eacb8 was meant to mark these as
deprecated, but put the deprecated marker in the .c file which doesn't
work.
Sebastian Beckmann 4 months ago
parent
commit
8e66418dc9
2 changed files with 6 additions and 6 deletions
  1. 2 4
      libobs/obs.c
  2. 4 2
      libobs/obs.h

+ 2 - 4
libobs/obs.c

@@ -1273,15 +1273,13 @@ char *obs_find_data_file(const char *file)
 	return NULL;
 }
 
-// TODO: Remove after deprecation grace period
-OBS_DEPRECATED void obs_add_data_path(const char *path)
+void obs_add_data_path(const char *path)
 {
 	struct dstr *new_path = da_push_back_new(core_module_paths);
 	dstr_init_copy(new_path, path);
 }
 
-// TODO: Remove after deprecation grace period
-OBS_DEPRECATED bool obs_remove_data_path(const char *path)
+bool obs_remove_data_path(const char *path)
 {
 	for (size_t i = 0; i < core_module_paths.num; ++i) {
 		int result = dstr_cmp(&core_module_paths.array[i], path);

+ 4 - 2
libobs/obs.h

@@ -321,13 +321,15 @@ struct obs_cmdline_args {
  */
 EXPORT char *obs_find_data_file(const char *file);
 
+// TODO: Remove after deprecation grace period
 /**
  * Add a path to search libobs data files in.
  * @param path Full path to directory to look in.
  *             The string is copied.
  */
-EXPORT void obs_add_data_path(const char *path);
+OBS_DEPRECATED EXPORT void obs_add_data_path(const char *path);
 
+// TODO: Remove after deprecation grace period
 /**
  * Remove a path from libobs core data paths.
  * @param path The path to compare to currently set paths.
@@ -336,7 +338,7 @@ EXPORT void obs_add_data_path(const char *path);
  * @return Whether or not the path was successfully removed.
  *         If false, the path could not be found.
  */
-EXPORT bool obs_remove_data_path(const char *path);
+OBS_DEPRECATED EXPORT bool obs_remove_data_path(const char *path);
 
 /**
  * Initializes OBS