- made option for auto open toolbox on left/mouse hold.
standard starts with 0.5 sec. Turn the threshold value up to effectively disable it when you dislike it. But give it a try! - added 'Home' after splitting window for buttonswindow
This commit is contained in:
@@ -272,6 +272,10 @@ static void setup_app_data(BlendFileData *bfd, char *filename) {
|
||||
U.menuthreshold1= 5;
|
||||
U.menuthreshold2= 2;
|
||||
}
|
||||
if(U.tb_leftmouse==0) {
|
||||
U.tb_leftmouse= 5;
|
||||
U.tb_rightmouse= 5;
|
||||
}
|
||||
}
|
||||
|
||||
R.winpos= bfd->winpos;
|
||||
|
||||
@@ -140,7 +140,8 @@ typedef struct UserDef {
|
||||
short menuthreshold1, menuthreshold2;
|
||||
char fontname[64];
|
||||
struct ListBase themes;
|
||||
short undosteps, pad0[3];
|
||||
short undosteps, pad0;
|
||||
short tb_leftmouse, tb_rightmouse;
|
||||
struct SolidLight light[3];
|
||||
} UserDef;
|
||||
|
||||
|
||||
@@ -5507,7 +5507,7 @@ void std_rmouse_transform(void (*xf_func)(int))
|
||||
else {
|
||||
PIL_sleep_ms(10);
|
||||
timer++;
|
||||
if(timer>=10*U.menuthreshold1) {
|
||||
if(timer>=10*U.tb_rightmouse) {
|
||||
toolbox_n();
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -2225,7 +2225,7 @@ static short testsplitpoint(ScrArea *sa, char dir, float fac)
|
||||
static void splitarea(ScrArea *sa, char dir, float fac)
|
||||
{
|
||||
bScreen *sc;
|
||||
ScrArea *newa;
|
||||
ScrArea *newa=NULL;
|
||||
ScrVert *sv1, *sv2;
|
||||
short split;
|
||||
|
||||
@@ -2280,6 +2280,11 @@ static void splitarea(ScrArea *sa, char dir, float fac)
|
||||
sa->v2= sv2;
|
||||
}
|
||||
|
||||
if(sa->spacetype==SPACE_BUTS) {
|
||||
addqueue(sa->win, UI_BUT_EVENT, B_BUTSHOME);
|
||||
addqueue(newa->win, UI_BUT_EVENT, B_BUTSHOME);
|
||||
}
|
||||
|
||||
/* remove double vertices en edges */
|
||||
removedouble_scrverts();
|
||||
removedouble_scredges();
|
||||
|
||||
@@ -252,7 +252,7 @@ int gesture(void)
|
||||
/* not drawing yet... check for toolbox */
|
||||
PIL_sleep_ms(10);
|
||||
timer++;
|
||||
if(timer>=10*U.menuthreshold1) {
|
||||
if(timer>=10*U.tb_leftmouse) {
|
||||
toolbox_n();
|
||||
return 1;
|
||||
}
|
||||
|
||||
@@ -2003,6 +2003,37 @@ void drawinfospace(ScrArea *sa, void *spacedata)
|
||||
"Time in 1/10 seconds for auto open sublevels");
|
||||
|
||||
|
||||
uiDefBut(block, LABEL,0,"Toolbox Thresh.:",
|
||||
(xpos+edgespace+(3*midspace)+(3*medprefbut)),y3label,medprefbut,buth,
|
||||
0, 0, 0, 0, 0, "");
|
||||
|
||||
uiDefButS(block, NUM, 0, "LMB:",
|
||||
(xpos+edgespace+(3*midspace)+(3*medprefbut)),y2,smallprefbut,buth,
|
||||
&(U.tb_leftmouse), 2, 40, 0, 0,
|
||||
"Time in 1/10 seconds leftmouse hold to open toolbox");
|
||||
|
||||
uiDefButS(block, NUM, 0, "RMB:",
|
||||
(xpos+edgespace+(3*midspace)+(3*medprefbut)),y1,smallprefbut,buth,
|
||||
&(U.tb_rightmouse), 2, 40, 0, 0,
|
||||
"Time in 1/10 seconds for rightmouse to open toolbox");
|
||||
|
||||
|
||||
uiDefBut(block, LABEL,0,"View rotation:",
|
||||
(xpos+edgespace+(3*midspace)+(3*medprefbut)+smallprefbut+2),y3label,medprefbut,buth,
|
||||
0, 0, 0, 0, 0, "");
|
||||
|
||||
uiDefButS(block, TOG|BIT|5, B_DRAWINFO, "Trackball",
|
||||
(xpos+edgespace+(3*midspace)+(3*medprefbut)+smallprefbut+2),y2,(smallprefbut+2),buth,
|
||||
&(U.flag), 0, 0, 0, 0,
|
||||
"Use trackball style rotation with middle mouse button");
|
||||
|
||||
uiDefButS(block, TOGN|BIT|5, B_DRAWINFO, "Turntable",
|
||||
(xpos+edgespace+(3*midspace)+(3*medprefbut)+smallprefbut+2),y1,(smallprefbut+2),buth,
|
||||
&(U.flag), 0, 0, 0, 0,
|
||||
"Use turntable style rotation with middle mouse button");
|
||||
|
||||
|
||||
|
||||
uiDefButS(block, TOGN|BIT|10, B_DRAWINFO, "Rotate View",
|
||||
(xpos+edgespace+(4*midspace)+(4*medprefbut)),y2,(smallprefbut+2),buth,
|
||||
&(U.flag), 0, 0, 0, 0, "Default action for the middle mouse button");
|
||||
@@ -2021,19 +2052,6 @@ void drawinfospace(ScrArea *sa, void *spacedata)
|
||||
|
||||
|
||||
|
||||
uiDefBut(block, LABEL,0,"View rotation method:",
|
||||
(xpos+edgespace+(3*midspace)+(3*medprefbut)),y3label,medprefbut,buth,
|
||||
0, 0, 0, 0, 0, "");
|
||||
|
||||
uiDefButS(block, TOG|BIT|5, B_DRAWINFO, "Trackball",
|
||||
(xpos+edgespace+(3*midspace)+(3*medprefbut)),y2,(smallprefbut+2),buth,
|
||||
&(U.flag), 0, 0, 0, 0,
|
||||
"Use trackball style rotation with middle mouse button");
|
||||
|
||||
uiDefButS(block, TOGN|BIT|5, B_DRAWINFO, "Turntable",
|
||||
(xpos+edgespace+(3*midspace)+(3*medprefbut)+smallprefbut+2),y2,(smallprefbut+2),buth,
|
||||
&(U.flag), 0, 0, 0, 0,
|
||||
"Use turntable style rotation with middle mouse button");
|
||||
|
||||
uiDefBut(block, LABEL,0,"Mousewheel:",
|
||||
(xpos+edgespace+(4*midspace)+(5*medprefbut)),y3label,medprefbut,buth,
|
||||
|
||||
Reference in New Issue
Block a user