Cleanup: UI: Remove more uses of a1 and a2 arguments
Remove uses for `uiDefButS`. -1 was passed as a2 still in a few places, but that was most likely just because of copy & paste, it doesn't look like that's actually used anywhere.
This commit is contained in:
@@ -1048,8 +1048,6 @@ uiBut *uiDefButS(uiBlock *block,
|
||||
short *poin,
|
||||
float min,
|
||||
float max,
|
||||
float a1,
|
||||
float a2,
|
||||
const char *tip);
|
||||
uiBut *uiDefButBitS(uiBlock *block,
|
||||
int type,
|
||||
@@ -3292,7 +3290,7 @@ ARegion *UI_tooltip_create_from_search_item_generic(
|
||||
|
||||
/* Float precision helpers */
|
||||
#define UI_PRECISION_FLOAT_MAX 6
|
||||
/* For float buttons the 'step' (or a1), is scaled */
|
||||
/* For float buttons the 'step', is scaled */
|
||||
#define UI_PRECISION_FLOAT_SCALE 0.01f
|
||||
|
||||
/* Typical UI text */
|
||||
|
||||
@@ -5076,8 +5076,6 @@ uiBut *uiDefButS(uiBlock *block,
|
||||
short *poin,
|
||||
float min,
|
||||
float max,
|
||||
float a1,
|
||||
float a2,
|
||||
const char *tip)
|
||||
{
|
||||
return uiDefBut(block,
|
||||
@@ -5091,8 +5089,8 @@ uiBut *uiDefButS(uiBlock *block,
|
||||
(void *)poin,
|
||||
min,
|
||||
max,
|
||||
a1,
|
||||
a2,
|
||||
0.0f,
|
||||
0.0f,
|
||||
tip);
|
||||
}
|
||||
uiBut *uiDefButBitS(uiBlock *block,
|
||||
|
||||
@@ -3286,8 +3286,6 @@ void uiTemplatePreview(uiLayout *layout,
|
||||
pr_texture,
|
||||
10,
|
||||
TEX_PR_TEXTURE,
|
||||
0,
|
||||
0,
|
||||
"");
|
||||
if (GS(parent->name) == ID_MA) {
|
||||
uiDefButS(block,
|
||||
@@ -3301,8 +3299,6 @@ void uiTemplatePreview(uiLayout *layout,
|
||||
pr_texture,
|
||||
10,
|
||||
TEX_PR_OTHER,
|
||||
0,
|
||||
0,
|
||||
"");
|
||||
}
|
||||
else if (GS(parent->name) == ID_LA) {
|
||||
@@ -3317,8 +3313,6 @@ void uiTemplatePreview(uiLayout *layout,
|
||||
pr_texture,
|
||||
10,
|
||||
TEX_PR_OTHER,
|
||||
0,
|
||||
0,
|
||||
"");
|
||||
}
|
||||
else if (GS(parent->name) == ID_WO) {
|
||||
@@ -3333,8 +3327,6 @@ void uiTemplatePreview(uiLayout *layout,
|
||||
pr_texture,
|
||||
10,
|
||||
TEX_PR_OTHER,
|
||||
0,
|
||||
0,
|
||||
"");
|
||||
}
|
||||
else if (GS(parent->name) == ID_LS) {
|
||||
@@ -3349,8 +3341,6 @@ void uiTemplatePreview(uiLayout *layout,
|
||||
pr_texture,
|
||||
10,
|
||||
TEX_PR_OTHER,
|
||||
0,
|
||||
0,
|
||||
"");
|
||||
}
|
||||
uiDefButS(block,
|
||||
@@ -3364,8 +3354,6 @@ void uiTemplatePreview(uiLayout *layout,
|
||||
pr_texture,
|
||||
10,
|
||||
TEX_PR_BOTH,
|
||||
0,
|
||||
0,
|
||||
"");
|
||||
|
||||
/* Alpha button for texture preview */
|
||||
@@ -3724,8 +3712,6 @@ static void colorband_buttons_layout(uiLayout *layout,
|
||||
&coba->cur,
|
||||
0.0,
|
||||
float(std::max(0, coba->tot - 1)),
|
||||
0,
|
||||
0,
|
||||
TIP_("Choose active color stop"));
|
||||
UI_but_number_step_size_set(bt, 1);
|
||||
|
||||
@@ -3751,8 +3737,6 @@ static void colorband_buttons_layout(uiLayout *layout,
|
||||
&coba->cur,
|
||||
0.0,
|
||||
float(std::max(0, coba->tot - 1)),
|
||||
0,
|
||||
0,
|
||||
TIP_("Choose active color stop"));
|
||||
UI_but_number_step_size_set(bt, 1);
|
||||
|
||||
|
||||
@@ -88,8 +88,6 @@ static void ui_imageuser_slot_menu(bContext * /*C*/, uiLayout *layout, void *ima
|
||||
&image->render_slot,
|
||||
float(slot_id),
|
||||
0.0,
|
||||
0,
|
||||
-1,
|
||||
"");
|
||||
}
|
||||
|
||||
@@ -182,8 +180,6 @@ static void ui_imageuser_layer_menu(bContext * /*C*/, uiLayout *layout, void *rn
|
||||
&iuser->layer,
|
||||
0.0,
|
||||
0.0,
|
||||
0,
|
||||
-1,
|
||||
"");
|
||||
}
|
||||
|
||||
@@ -200,8 +196,6 @@ static void ui_imageuser_layer_menu(bContext * /*C*/, uiLayout *layout, void *rn
|
||||
&iuser->layer,
|
||||
float(nr),
|
||||
0.0,
|
||||
0,
|
||||
-1,
|
||||
"");
|
||||
}
|
||||
|
||||
@@ -276,8 +270,6 @@ static void ui_imageuser_pass_menu(bContext * /*C*/, uiLayout *layout, void *rnd
|
||||
&iuser->pass,
|
||||
float(nr),
|
||||
0.0,
|
||||
0,
|
||||
-1,
|
||||
"");
|
||||
}
|
||||
|
||||
@@ -355,8 +347,6 @@ static void ui_imageuser_view_menu_rr(bContext * /*C*/, uiLayout *layout, void *
|
||||
&iuser->view,
|
||||
float(nr),
|
||||
0.0,
|
||||
0,
|
||||
-1,
|
||||
"");
|
||||
}
|
||||
|
||||
@@ -405,8 +395,6 @@ static void ui_imageuser_view_menu_multiview(bContext * /*C*/, uiLayout *layout,
|
||||
&iuser->view,
|
||||
float(nr),
|
||||
0.0,
|
||||
0,
|
||||
-1,
|
||||
"");
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user