| [ Return to Bugs & Features | Roadmap 1.1 | SVN ⇄ GIT ]
STR #819
Application: | FLTK Library |
Status: | 1 - Closed w/Resolution |
Priority: | 2 - Low, e.g. a documentation error or undocumented side-effect |
Scope: | 3 - Applies to all machines and operating systems |
Subsystem: | Core Library |
Summary: | fl_dir_chooser() needs to return trailing slash |
Version: | 1.1.6 |
Created By: | bpittman |
Assigned To: | mike |
Fix Version: | 1.1-current (SVN: v4335) |
Update Notification: | |
Trouble Report Files:
Trouble Report Comments:
|
#1 | bpittman 12:41 Apr 20, 2005 |
| When using fl_dir_chooser in relative mode, I'm getting incorrect results because the path sent to fl_filename_relative() does not have a trailing slash. Example:
cwd: C:/dir1/dir2/dir3 1) Call fl_dir_chooser, go up one directory, hit OK 2) fl_dir_chooser passes "C:/dir1/dir2" to fl_filename_relative (Even though a trailing slash is shown in the chooser, there is no trailing slash in the returned string.) 3) fl_filename_relative thinks dir2 is a _file_, returns "../dir2" The correct relative path would be simply "../"
As a workaround I am calling fl_dir_chooser in absolute path mode, strcat'ing a "/" onto the return path, and running the result through fl_filename_relative. This works as expected. | |
|
#2 | mike 08:01 May 12, 2005 |
| Fixed in Subversion repository.
See attached patch... | |
[ Return to Bugs & Features ]
|
| |