diff --git a/source/blender/blenkernel/intern/library.c b/source/blender/blenkernel/intern/library.c index 3d9c6560cb4..3b325a06627 100644 --- a/source/blender/blenkernel/intern/library.c +++ b/source/blender/blenkernel/intern/library.c @@ -562,9 +562,9 @@ static void IDnames_to_dyn_pupstring(DynStr *pupds, ListBase *lb, ID *link, shor { int i, nids= BLI_countlist(lb); - *nr= -1; + if (nr) *nr= -1; - if (nids>MAX_IDPUP) { + if (nr && nids>MAX_IDPUP) { BLI_dynstr_append(pupds, "DataBrowse %x-2"); } else { ID *id; @@ -572,8 +572,7 @@ static void IDnames_to_dyn_pupstring(DynStr *pupds, ListBase *lb, ID *link, shor for (i=0, id= lb->first; id; id= id->next, i++) { char buf[32]; - if (id==link) - *nr= i+1; + if (nr && id==link) *nr= i+1; get_flags_for_id(id, buf); @@ -633,6 +632,7 @@ static void IPOnames_to_dyn_pupstring(DynStr *pupds, ListBase *lb, ID *link, sho } // used by headerbuttons.c buttons.c editobject.c editseq.c +// if nr==NULL no MAX_IDPUP, this for non-header browsing void IDnames_to_pupstring(char **str, char *title, char *extraops, ListBase *lb, ID *link, short *nr) { DynStr *pupds= BLI_dynstr_new(); diff --git a/source/blender/src/editseq.c b/source/blender/src/editseq.c index 9efc120f065..0256217a1ef 100644 --- a/source/blender/src/editseq.c +++ b/source/blender/src/editseq.c @@ -1022,9 +1022,9 @@ void add_sequence(int type) break; case 101: /* new menu: */ - IDnames_to_pupstring(&str, NULL, NULL, &G.main->scene, (ID *)G.scene, &nr); - - event= pupmenu(str); + IDnames_to_pupstring(&str, NULL, NULL, &G.main->scene, (ID *)G.scene, NULL); + + event= pupmenu_col(str, 20); if(event> -1) { nr= 1; diff --git a/source/blender/src/interface.c b/source/blender/src/interface.c index eb60aede2ab..a5610c730cb 100644 --- a/source/blender/src/interface.c +++ b/source/blender/src/interface.c @@ -4299,7 +4299,7 @@ short pupmenu_col(char *instr, int maxrow) MenuData *md; block= uiNewBlock(&listb, "menu", UI_EMBOSSP, UI_HELV, G.curscreen->mainwin); - uiBlockSetFlag(block, UI_BLOCK_LOOP|UI_BLOCK_REDRAW|UI_BLOCK_NUMSELECT); + uiBlockSetFlag(block, UI_BLOCK_LOOP|UI_BLOCK_REDRAW|UI_BLOCK_RET_1|UI_BLOCK_NUMSELECT); block->themecol= TH_MENU_ITEM; md= decompose_menu_string(instr);