forked from bartvdbraak/blender
- small patch to make sure buttons are fully used for strings (when it
doesnt fit), plus the 'user count' button now increases in size when amount is larger than 10. was report #1049
This commit is contained in:
parent
29baa5026e
commit
d82ab2bfc3
@ -439,7 +439,7 @@ int std_libbuttons(uiBlock *block, short xco, short yco,
|
||||
uiSetButLock (pin && *pinpoin, "Can't make pinned data single-user");
|
||||
|
||||
sprintf(str1, "%d", id->us);
|
||||
if(id->us<100) {
|
||||
if(id->us<10) {
|
||||
|
||||
uiDefBut(block, BUT, users, str1, xco,yco,XIC,YIC, 0, 0, 0, 0, 0, "Displays number of users of this data. Click to make a single-user copy.");
|
||||
xco+= XIC;
|
||||
|
@ -3354,11 +3354,11 @@ void ui_check_but(uiBut *but)
|
||||
|
||||
ui_is_but_sel(but);
|
||||
|
||||
|
||||
/* safety is 4 to enable small number buttons (like 'users') */
|
||||
if(but->type==NUMSLI || but->type==HSVSLI)
|
||||
okwidth= -7 + (but->x2 - but->x1)/2.0;
|
||||
okwidth= -4 + (but->x2 - but->x1)/2.0;
|
||||
else
|
||||
okwidth= -7 + (but->x2 - but->x1);
|
||||
okwidth= -4 + (but->x2 - but->x1);
|
||||
|
||||
/* name: */
|
||||
switch( but->type ) {
|
||||
|
Loading…
Reference in New Issue
Block a user