mirror of
https://github.com/fltk/fltk.git
synced 2026-05-29 04:26:27 +08:00
Making fl_filename_... public for std::string.
New functions append "_str" to the function name to avoid ambiguities when calling them. So 'char *fl_filename_name(const char *)' becomes 'std::string fl_filename_name_str(const std::string &)'
This commit is contained in:
+11
-13
@@ -72,20 +72,18 @@ FL_EXPORT int fl_filename_isdir(const char *name);
|
||||
FL_EXPORT int fl_filename_absolute(char *to, int tolen, const char *from, const char *cwd);
|
||||
FL_EXPORT int fl_filename_relative(char *to, int tolen, const char *from, const char *cwd);
|
||||
|
||||
#include <string>
|
||||
|
||||
// FIXME: We can't do this in 1.4.x - enable this block in 1.5 or higher.
|
||||
// See fluid/fluid_filename.{h|cxx} for an implementation using Fl_String.
|
||||
|
||||
// FL_EXPORT std::string fl_filename_name(const std::string &filename);
|
||||
// FL_EXPORT std::string fl_filename_path(const std::string &filename);
|
||||
// FL_EXPORT std::string fl_filename_ext(const std::string &filename);
|
||||
// FL_EXPORT std::string fl_filename_setext(const std::string &filename, const std::string &new_extension);
|
||||
// FL_EXPORT std::string fl_filename_expand(const std::string &from);
|
||||
// FL_EXPORT std::string fl_filename_absolute(const std::string &from);
|
||||
// FL_EXPORT std::string fl_filename_absolute(const std::string &from, const std::string &base);
|
||||
// FL_EXPORT std::string fl_filename_relative(const std::string &from);
|
||||
// FL_EXPORT std::string fl_filename_relative(const std::string &from, const std::string &base);
|
||||
// FL_EXPORT std::string fl_getcwd();
|
||||
FL_EXPORT std::string fl_filename_name_str(const std::string &filename);
|
||||
FL_EXPORT std::string fl_filename_path_str(const std::string &filename);
|
||||
FL_EXPORT std::string fl_filename_ext_str(const std::string &filename);
|
||||
FL_EXPORT std::string fl_filename_setext_str(const std::string &filename, const std::string &new_extension);
|
||||
FL_EXPORT std::string fl_filename_expand_str(const std::string &from);
|
||||
FL_EXPORT std::string fl_filename_absolute_str(const std::string &from);
|
||||
FL_EXPORT std::string fl_filename_absolute_str(const std::string &from, const std::string &base);
|
||||
FL_EXPORT std::string fl_filename_relative_str(const std::string &from);
|
||||
FL_EXPORT std::string fl_filename_relative_str(const std::string &from, const std::string &base);
|
||||
FL_EXPORT std::string fl_getcwd_str();
|
||||
|
||||
# endif /* defined(__cplusplus) */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user