diff options
Diffstat (limited to 'source/blender/src/headerbuttons.c')
-rw-r--r-- | source/blender/src/headerbuttons.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/source/blender/src/headerbuttons.c b/source/blender/src/headerbuttons.c index 035468d89c0..1a91ada1562 100644 --- a/source/blender/src/headerbuttons.c +++ b/source/blender/src/headerbuttons.c @@ -545,9 +545,9 @@ static void filesel_u_pythondir(char *name) allqueue(REDRAWALL, 0); /* act on the change */ - BPyMenu_RemoveAllEntries(); - BPY_rebuild_syspath(); - if (BPyMenu_Init(1) == -1) error("Invalid scripts dir: check console"); + if (BPY_path_update()==0) { + error("Invalid scripts dir: check console"); + } } static void filesel_u_sounddir(char *name) @@ -1527,9 +1527,7 @@ void do_global_buttons(unsigned short event) case B_PYMENUEVAL: /* is button from space.c *info* */ waitcursor( 1 ); /* can take some time */ - BPyMenu_RemoveAllEntries(); /* free old data */ - BPY_rebuild_syspath(); - if (BPyMenu_Init(1) == -1) { /* re-eval scripts registration in menus */ + if (BPY_path_update() == 0) { /* re-eval scripts registration in menus */ waitcursor( 0 ); error("Invalid scripts dir: check console"); } @@ -1630,6 +1628,7 @@ void do_global_buttons(unsigned short event) allqueue(REDRAWOOPS, 1); allqueue(REDRAWACTION, 1); allqueue(REDRAWNLA, 1); + allqueue(REDRAWVIEW3D, 1); /* name scene also in set PUPmenu */ allqueue(REDRAWBUTSALL, 0); allqueue(REDRAWIMAGE, 0); |