commit 39a1da2a0ce3f362e7465e5335a922dfd6823230
parent d9dc98c231517bef44161be1cdd86fd6ac393c9d
Author: Alexandre Bique <bique.alexandre@gmail.com>
Date: Tue, 7 Mar 2023 17:27:25 +0100
clarify the location
Diffstat:
1 file changed, 10 insertions(+), 3 deletions(-)
diff --git a/include/clap/factory/draft/preset-discovery.h b/include/clap/factory/draft/preset-discovery.h
@@ -55,10 +55,13 @@ extern "C" {
#endif
enum clap_preset_discovery_location_kind {
- // The preset are located in a file on the OS filesystem
+ // The preset are located in a file on the OS filesystem.
+ // The location is then a path which works with the OS file system functions (open, stat, ...)
+ // So both '/' and '\' shall work on Windows as a separator.
CLAP_PRESET_DISCOVERY_LOCATION_FILE = 0,
- // The preset is bundled within the plugin DSO itself
+ // The preset is bundled within the plugin DSO itself.
+ // Thes location is arbitrary.
CLAP_PRESET_DISCOVERY_LOCATION_PLUGIN = 1,
};
@@ -196,7 +199,11 @@ typedef struct clap_preset_discovery_location {
uint32_t flags; // see enum clap_preset_discovery_flags
const char *name; // name of this location
uint32_t kind; // See clap_preset_discovery_location_kind
- const char *location; // Actual location in which to crawl presets
+
+ // Actual location in which to crawl presets.
+ // For FILE kind, the location can be either a path to a directory or a file.
+ // For PLUGIN kind, the location is arbitrary.
+ const char *location;
} clap_preset_discovery_location_t;
// Describes an installed sound pack.