- fixed small bug in menu button (preset dirs) in fileselect. When the menu
is empty (no $HOME/.Bfs and first time use of FileSelect) it was empty, causing a nasty drawing error. It now doesn't draw the menubutton when there are no preset dirs yet. - removed 'unused variable' warnings from space.c
This commit is contained in:
@@ -1178,18 +1178,20 @@ void drawfilespace(ScrArea *sa, void *spacedata)
|
||||
}
|
||||
|
||||
menu= fsmenu_build_menu();
|
||||
uiDefButS(block, MENU, 3, menu, scrollrct.xmin, filebuty1, scrollrct.xmax-scrollrct.xmin, 21, &sfile->menu, 0, 0, 0, 0, "");
|
||||
if(menu[0]) // happens when no .Bfs is there, and first time browse
|
||||
uiDefButS(block, MENU, 3, menu, scrollrct.xmin, filebuty1, scrollrct.xmax-scrollrct.xmin, 21, &sfile->menu, 0, 0, 0, 0, "");
|
||||
MEM_freeN(menu);
|
||||
|
||||
uiDefBut(block, BUT, 4, "P", scrollrct.xmin, filebuty2, scrollrct.xmax-scrollrct.xmin, 21, 0, 0, 0, 0, 0, "Move to the parent directory (PKEY)");
|
||||
|
||||
uiDrawBlock(block);
|
||||
|
||||
draw_filescroll(sfile);
|
||||
draw_filetext(sfile);
|
||||
|
||||
/* others diskfree etc ? */
|
||||
scrarea_queue_headredraw(curarea);
|
||||
|
||||
uiDrawBlock(block);
|
||||
|
||||
curarea->win_swap= WIN_BACK_OK;
|
||||
}
|
||||
|
Reference in New Issue
Block a user