Cleanup: use bools for v2d, minor ws edits
This commit is contained in:
parent
34e749beef
commit
1ec549886b
@ -153,7 +153,7 @@ void UI_view2d_curRect_reset(struct View2D *v2d);
|
|||||||
void UI_view2d_sync(struct bScreen *screen, struct ScrArea *sa, struct View2D *v2dcur, int flag);
|
void UI_view2d_sync(struct bScreen *screen, struct ScrArea *sa, struct View2D *v2dcur, int flag);
|
||||||
|
|
||||||
void UI_view2d_totRect_set(struct View2D *v2d, int width, int height);
|
void UI_view2d_totRect_set(struct View2D *v2d, int width, int height);
|
||||||
void UI_view2d_totRect_set_resize(struct View2D *v2d, int width, int height, int resize);
|
void UI_view2d_totRect_set_resize(struct View2D *v2d, int width, int height, bool resize);
|
||||||
|
|
||||||
/* per tab offsets, returns 1 if tab changed */
|
/* per tab offsets, returns 1 if tab changed */
|
||||||
bool UI_view2d_tab_set(struct View2D *v2d, int tab);
|
bool UI_view2d_tab_set(struct View2D *v2d, int tab);
|
||||||
|
@ -63,7 +63,7 @@
|
|||||||
|
|
||||||
#include "interface_intern.h"
|
#include "interface_intern.h"
|
||||||
|
|
||||||
static void ui_view2d_curRect_validate_resize(View2D *v2d, int resize, int mask_scrollers);
|
static void ui_view2d_curRect_validate_resize(View2D *v2d, bool resize, bool mask_scrollers);
|
||||||
|
|
||||||
/* *********************************************************************** */
|
/* *********************************************************************** */
|
||||||
|
|
||||||
@ -116,7 +116,7 @@ static int view2d_scroll_mapped(int scroll)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* called each time cur changes, to dynamically update masks */
|
/* called each time cur changes, to dynamically update masks */
|
||||||
static void view2d_masks(View2D *v2d, int check_scrollers)
|
static void view2d_masks(View2D *v2d, bool check_scrollers)
|
||||||
{
|
{
|
||||||
int scroll;
|
int scroll;
|
||||||
|
|
||||||
@ -368,7 +368,7 @@ void UI_view2d_region_reinit(View2D *v2d, short type, int winx, int winy)
|
|||||||
* 'cur' is not allowed to be: larger than max, smaller than min, or outside of 'tot'
|
* 'cur' is not allowed to be: larger than max, smaller than min, or outside of 'tot'
|
||||||
*/
|
*/
|
||||||
// XXX pre2.5 -> this used to be called test_view2d()
|
// XXX pre2.5 -> this used to be called test_view2d()
|
||||||
static void ui_view2d_curRect_validate_resize(View2D *v2d, int resize, int mask_scrollers)
|
static void ui_view2d_curRect_validate_resize(View2D *v2d, bool resize, bool mask_scrollers)
|
||||||
{
|
{
|
||||||
float totwidth, totheight, curwidth, curheight, width, height;
|
float totwidth, totheight, curwidth, curheight, width, height;
|
||||||
float winx, winy;
|
float winx, winy;
|
||||||
@ -899,7 +899,7 @@ void UI_view2d_curRect_reset(View2D *v2d)
|
|||||||
/* ------------------ */
|
/* ------------------ */
|
||||||
|
|
||||||
/* Change the size of the maximum viewable area (i.e. 'tot' rect) */
|
/* Change the size of the maximum viewable area (i.e. 'tot' rect) */
|
||||||
void UI_view2d_totRect_set_resize(View2D *v2d, int width, int height, int resize)
|
void UI_view2d_totRect_set_resize(View2D *v2d, int width, int height, bool resize)
|
||||||
{
|
{
|
||||||
// int scroll = view2d_scroll_mapped(v2d->scroll);
|
// int scroll = view2d_scroll_mapped(v2d->scroll);
|
||||||
|
|
||||||
|
@ -3911,9 +3911,9 @@ static int sequencer_export_subtitles_exec(bContext *C, wmOperator *op)
|
|||||||
char timecode_str_end[32];
|
char timecode_str_end[32];
|
||||||
|
|
||||||
BLI_timecode_string_from_time(timecode_str_start, sizeof(timecode_str_start),
|
BLI_timecode_string_from_time(timecode_str_start, sizeof(timecode_str_start),
|
||||||
-2, FRA2TIME(seq->startdisp), FPS, USER_TIMECODE_SUBRIP);
|
-2, FRA2TIME(seq->startdisp), FPS, USER_TIMECODE_SUBRIP);
|
||||||
BLI_timecode_string_from_time(timecode_str_end, sizeof(timecode_str_end),
|
BLI_timecode_string_from_time(timecode_str_end, sizeof(timecode_str_end),
|
||||||
-2, FRA2TIME(seq->enddisp), FPS, USER_TIMECODE_SUBRIP);
|
-2, FRA2TIME(seq->enddisp), FPS, USER_TIMECODE_SUBRIP);
|
||||||
|
|
||||||
fprintf(file, "%d\n%s --> %s\n%s\n\n", iter++, timecode_str_start, timecode_str_end, data->text);
|
fprintf(file, "%d\n%s --> %s\n%s\n\n", iter++, timecode_str_start, timecode_str_end, data->text);
|
||||||
|
|
||||||
|
@ -7684,7 +7684,8 @@ void draw_object(Scene *scene, ARegion *ar, View3D *v3d, Base *base, const short
|
|||||||
|
|
||||||
if (((base->flag & OB_FROMDUPLI) == 0) &&
|
if (((base->flag & OB_FROMDUPLI) == 0) &&
|
||||||
(md = modifiers_findByType(ob, eModifierType_Smoke)) &&
|
(md = modifiers_findByType(ob, eModifierType_Smoke)) &&
|
||||||
(modifier_isEnabled(scene, md, eModifierMode_Realtime))) {
|
(modifier_isEnabled(scene, md, eModifierMode_Realtime)))
|
||||||
|
{
|
||||||
smd = (SmokeModifierData *)md;
|
smd = (SmokeModifierData *)md;
|
||||||
|
|
||||||
if (smd->domain) {
|
if (smd->domain) {
|
||||||
|
Loading…
Reference in New Issue
Block a user