diff options
author | Campbell Barton <ideasman42@gmail.com> | 2010-06-06 01:19:59 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2010-06-06 01:19:59 +0400 |
commit | 4da179749eb8d6b53f5c2eba4b3e4132656c3d4f (patch) | |
tree | 59b4dbfac1c894687f022efb72a9c010c93e555f /source/blender/windowmanager/intern | |
parent | c12068920391c006cf5e72c1fafb4ebf8f807a55 (diff) |
- [#22492] [29159] commit breaks importing of script file that has a reload to self in it
broke when including the blend path in the modules filename.
- new function BLI_path_basename(), matches pythons os.path.basename().
replace a number of cases where BLI_split_dirfile was being used to get the filename only.
Diffstat (limited to 'source/blender/windowmanager/intern')
-rw-r--r-- | source/blender/windowmanager/intern/wm_operators.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/source/blender/windowmanager/intern/wm_operators.c b/source/blender/windowmanager/intern/wm_operators.c index 842e43b98cf..4ab110cc275 100644 --- a/source/blender/windowmanager/intern/wm_operators.c +++ b/source/blender/windowmanager/intern/wm_operators.c @@ -1212,10 +1212,7 @@ static uiBlock *wm_block_create_splash(bContext *C, ARegion *ar, void *arg_unuse col = uiLayoutColumn(split, 0); uiItemL(col, "Recent", 0); for(recent = G.recent_files.first, i=0; (i<5) && (recent); recent = recent->next, i++) { - char *display_name= BLI_last_slash(recent->filename); - if(display_name) display_name++; /* skip the slash */ - else display_name= recent->filename; - uiItemStringO(col, display_name, ICON_FILE_BLEND, "WM_OT_open_mainfile", "path", recent->filename); + uiItemStringO(col, BLI_path_basename(recent->filename), ICON_FILE_BLEND, "WM_OT_open_mainfile", "path", recent->filename); } uiItemS(col); uiItemO(col, NULL, ICON_RECOVER_LAST, "WM_OT_recover_last_session"); |