Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2013-04-04 08:22:38 +0400
committerCampbell Barton <ideasman42@gmail.com>2013-04-04 08:22:38 +0400
commit2804caff4ce6c9f6d5ebdd101e77c92b7ac65db4 (patch)
treeb3f91af65a3d29c253cae82117bfb4477b834f69 /source/blender/editors/interface/interface_regions.c
parent966e86cd2dbe2c627e65766d0361cc79f63d7cc7 (diff)
code cleanup: use bools, (float)sin/(float)cos -> sinf/cosf, more meaningful var names.
Diffstat (limited to 'source/blender/editors/interface/interface_regions.c')
-rw-r--r--source/blender/editors/interface/interface_regions.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/editors/interface/interface_regions.c b/source/blender/editors/interface/interface_regions.c
index 8d7edf1b044..2ccba2e35f0 100644
--- a/source/blender/editors/interface/interface_regions.c
+++ b/source/blender/editors/interface/interface_regions.c
@@ -742,8 +742,8 @@ typedef struct uiSearchboxData {
uiFontStyle fstyle;
uiSearchItems items;
int active; /* index in items array */
- int noback; /* when menu opened with enough space for this */
- int preview; /* draw thumbnail previews, rather than list */
+ bool noback; /* when menu opened with enough space for this */
+ bool preview; /* draw thumbnail previews, rather than list */
int prv_rows, prv_cols;
} uiSearchboxData;
@@ -1023,7 +1023,7 @@ static void ui_searchbox_region_draw_cb(const bContext *UNUSED(C), ARegion *ar)
/* pixel space */
wmOrtho2(-0.01f, ar->winx - 0.01f, -0.01f, ar->winy - 0.01f);
- if (!data->noback)
+ if (data->noback == false)
ui_draw_search_back(NULL, NULL, &data->bbox); /* style not used yet */
/* draw text */
@@ -1136,10 +1136,10 @@ ARegion *ui_searchbox_create(bContext *C, ARegion *butregion, uiBut *but)
/* special case, hardcoded feature, not draw backdrop when called from menus,
* assume for design that popup already added it */
if (but->block->flag & UI_BLOCK_SEARCH_MENU)
- data->noback = 1;
+ data->noback = true;
if (but->a1 > 0 && but->a2 > 0) {
- data->preview = 1;
+ data->preview = true;
data->prv_rows = but->a1;
data->prv_cols = but->a2;
}