diff options
author | Ton Roosendaal <ton@blender.org> | 2009-07-09 19:40:04 +0400 |
---|---|---|
committer | Ton Roosendaal <ton@blender.org> | 2009-07-09 19:40:04 +0400 |
commit | 5e659c0b0895e07351bd2b2425deea342141e515 (patch) | |
tree | 7e6bd849591c0eb75fdefe37c061519806edf309 /source/blender/editors/space_file | |
parent | 77c61f545fb3248ae4e06afafa816764222405c4 (diff) |
2.5
Monthly cleaning round to make it compile warning free.
Mostly it was const stuff (strings, Context), but also
a couple useful fixes, like wrong use of temp pointers.
Only Mathutils callback struct I left alone... design issue.
Diffstat (limited to 'source/blender/editors/space_file')
-rw-r--r-- | source/blender/editors/space_file/file_ops.c | 2 | ||||
-rw-r--r-- | source/blender/editors/space_file/file_panels.c | 4 | ||||
-rw-r--r-- | source/blender/editors/space_file/filelist.c | 2 | ||||
-rw-r--r-- | source/blender/editors/space_file/filelist.h | 2 |
4 files changed, 4 insertions, 6 deletions
diff --git a/source/blender/editors/space_file/file_ops.c b/source/blender/editors/space_file/file_ops.c index bb56ec94d7b..9f703a9802b 100644 --- a/source/blender/editors/space_file/file_ops.c +++ b/source/blender/editors/space_file/file_ops.c @@ -358,9 +358,9 @@ void FILE_OT_add_bookmark(wmOperatorType *ot) static int bookmark_delete_invoke(bContext *C, wmOperator *op, wmEvent *event) { ScrArea *sa= CTX_wm_area(C); - SpaceFile *sfile= (SpaceFile*)CTX_wm_space_data(C); struct FSMenu* fsmenu = fsmenu_get(); int nentries = fsmenu_get_nentries(fsmenu, FS_CATEGORY_BOOKMARKS); + if(RNA_struct_find_property(op->ptr, "index")) { int index = RNA_int_get(op->ptr, "index"); if ( (index >-1) && (index < nentries)) { diff --git a/source/blender/editors/space_file/file_panels.c b/source/blender/editors/space_file/file_panels.c index 29c759d43c0..72a4133fe75 100644 --- a/source/blender/editors/space_file/file_panels.c +++ b/source/blender/editors/space_file/file_panels.c @@ -57,11 +57,9 @@ static void do_file_panel_events(bContext *C, void *arg, int event) static void file_panel_category(const bContext *C, Panel *pa, FSMenuCategory category, int icon, int allow_delete) { uiBlock *block; - uiStyle *style= U.uistyles.first; - int i; - int fontsize = file_font_pointsize(); struct FSMenu* fsmenu = fsmenu_get(); int nentries = fsmenu_get_nentries(fsmenu, category); + int i; uiLayoutSetAlignment(pa->layout, UI_LAYOUT_ALIGN_LEFT); block= uiLayoutFreeBlock(pa->layout); diff --git a/source/blender/editors/space_file/filelist.c b/source/blender/editors/space_file/filelist.c index ab5dac1a727..6e442c654ca 100644 --- a/source/blender/editors/space_file/filelist.c +++ b/source/blender/editors/space_file/filelist.c @@ -367,7 +367,7 @@ struct ListBase* folderlist_new() return p; } -void folderlist_popdir(struct ListBase* folderlist, const char *dir) +void folderlist_popdir(struct ListBase* folderlist, char *dir) { const char *prev_dir; struct FolderList *folder; diff --git a/source/blender/editors/space_file/filelist.h b/source/blender/editors/space_file/filelist.h index 0f8db98b7ab..dd3c2c766c1 100644 --- a/source/blender/editors/space_file/filelist.h +++ b/source/blender/editors/space_file/filelist.h @@ -73,7 +73,7 @@ void filelist_setfiletypes(struct FileList* filelist, short has_quicktime); struct ListBase * folderlist_new(); void folderlist_free(struct ListBase* folderlist); -void folderlist_popdir(struct ListBase* folderlist, const char *dir); +void folderlist_popdir(struct ListBase* folderlist, char *dir); void folderlist_pushdir(struct ListBase* folderlist, const char *dir); int folderlist_clear_next(struct SpaceFile* sfile); |