Cleanup: spelling
This commit is contained in:
@@ -959,7 +959,7 @@ static void ui_apply_but_undo(uiBut *but)
|
||||
str = "";
|
||||
}
|
||||
|
||||
/* delayed, after all other funcs run, popups are closed, etc */
|
||||
/* Delayed, after all other functions run, popups are closed, etc. */
|
||||
uiAfterFunc *after = ui_afterfunc_new();
|
||||
BLI_strncpy(after->undostr, str, min_zz(str_len_clip + 1, sizeof(after->undostr)));
|
||||
}
|
||||
@@ -991,7 +991,7 @@ static void ui_apply_but_autokey(bContext *C, uiBut *but)
|
||||
|
||||
static void ui_apply_but_funcs_after(bContext *C)
|
||||
{
|
||||
/* copy to avoid recursive calls */
|
||||
/* Copy to avoid recursive calls. */
|
||||
ListBase funcs = UIAfterFuncs;
|
||||
BLI_listbase_clear(&UIAfterFuncs);
|
||||
|
||||
|
||||
@@ -1635,7 +1635,7 @@ static void UI_OT_jump_to_target_button(wmOperatorType *ot)
|
||||
#ifdef WITH_PYTHON
|
||||
|
||||
/* ------------------------------------------------------------------------- */
|
||||
/* EditSource Utility funcs and operator,
|
||||
/* EditSource Utility functions and operator,
|
||||
* NOTE: this includes utility functions and button matching checks. */
|
||||
|
||||
struct uiEditSourceStore {
|
||||
@@ -1847,7 +1847,7 @@ static void UI_OT_editsource(wmOperatorType *ot)
|
||||
* \{ */
|
||||
|
||||
/**
|
||||
* EditTranslation utility funcs and operator,
|
||||
* EditTranslation utility functions and operator.
|
||||
*
|
||||
* \note this includes utility functions and button matching checks.
|
||||
* this only works in conjunction with a Python operator!
|
||||
|
||||
@@ -322,7 +322,7 @@ uiPopupBlockHandle *ui_popup_menu_create(
|
||||
|
||||
uiPopupMenu *pup = MEM_cnew<uiPopupMenu>(__func__);
|
||||
pup->block = UI_block_begin(C, nullptr, __func__, UI_EMBOSS_PULLDOWN);
|
||||
pup->block->flag |= UI_BLOCK_NUMSELECT; /* default menus to numselect */
|
||||
pup->block->flag |= UI_BLOCK_NUMSELECT; /* Default menus to numeric-selection. */
|
||||
pup->layout = UI_block_layout(
|
||||
pup->block, UI_LAYOUT_VERTICAL, UI_LAYOUT_MENU, 0, 0, 200, 0, UI_MENU_PADDING, style);
|
||||
pup->slideout = but ? ui_block_is_menu(but->block) : false;
|
||||
|
||||
@@ -767,7 +767,7 @@ static void ui_template_list_layout_draw(const bContext *C,
|
||||
uiItemL(col, "", ICON_NONE);
|
||||
}
|
||||
|
||||
/* add scrollbar */
|
||||
/* Add scroll-bar. */
|
||||
if (items->tot_items > visual_info.visual_items) {
|
||||
uiLayoutColumn(row, false);
|
||||
uiDefButI(block,
|
||||
@@ -916,7 +916,7 @@ static void ui_template_list_layout_draw(const bContext *C,
|
||||
uiItemL(subrow, "", ICON_NONE);
|
||||
}
|
||||
|
||||
/* add scrollbar */
|
||||
/* Add scroll-bar. */
|
||||
if (items->tot_items > visual_info.visual_items) {
|
||||
/* col = */ uiLayoutColumn(row, false);
|
||||
uiDefButI(block,
|
||||
@@ -940,7 +940,7 @@ static void ui_template_list_layout_draw(const bContext *C,
|
||||
box = uiLayoutListBox(layout, ui_list, &input_data->active_dataptr, input_data->activeprop);
|
||||
/* For grip button. */
|
||||
glob = uiLayoutColumn(box, true);
|
||||
/* For scrollbar. */
|
||||
/* For scroll-bar. */
|
||||
row = uiLayoutRow(glob, false);
|
||||
|
||||
const bool show_names = (flags & UI_TEMPLATE_LIST_NO_NAMES) == 0;
|
||||
|
||||
@@ -87,11 +87,11 @@ BLI_INLINE void clamp_rctf_to_rcti(rcti *dst, const rctf *src)
|
||||
* \{ */
|
||||
|
||||
/**
|
||||
* helper to allow scrollbars to dynamically hide
|
||||
* - returns a copy of the scrollbar settings with the flags to display
|
||||
* horizontal/vertical scrollbars removed
|
||||
* - input scroll value is the v2d->scroll var
|
||||
* - hide flags are set per region at drawtime
|
||||
* Helper to allow scroll-bars to dynamically hide:
|
||||
* - Returns a copy of the scroll-bar settings with the flags to display
|
||||
* horizontal/vertical scroll-bars removed.
|
||||
* - Input scroll value is the v2d->scroll var.
|
||||
* - Hide flags are set per region at draw-time.
|
||||
*/
|
||||
static int view2d_scroll_mapped(int scroll)
|
||||
{
|
||||
@@ -115,7 +115,7 @@ void UI_view2d_mask_from_win(const View2D *v2d, rcti *r_mask)
|
||||
/**
|
||||
* Called each time #View2D.cur changes, to dynamically update masks.
|
||||
*
|
||||
* \param mask_scroll: Optionally clamp scrollbars by this region.
|
||||
* \param mask_scroll: Optionally clamp scroll-bars by this region.
|
||||
*/
|
||||
static void view2d_masks(View2D *v2d, const rcti *mask_scroll)
|
||||
{
|
||||
@@ -177,7 +177,7 @@ static void view2d_masks(View2D *v2d, const rcti *mask_scroll)
|
||||
|
||||
/* Currently, all regions that have vertical scale handles,
|
||||
* also have the scrubbing area at the top.
|
||||
* So the scrollbar has to move down a bit. */
|
||||
* So the scroll-bar has to move down a bit. */
|
||||
if (scroll & V2D_SCROLL_VERTICAL_HANDLES) {
|
||||
v2d->vert.ymax -= UI_TIME_SCRUB_MARGIN_Y;
|
||||
}
|
||||
@@ -377,7 +377,7 @@ static void ui_view2d_curRect_validate_resize(View2D *v2d, bool resize)
|
||||
rctf *cur, *tot;
|
||||
|
||||
/* use mask as size of region that View2D resides in, as it takes into account
|
||||
* scrollbars already - keep in sync with zoomx/zoomy in view_zoomstep_apply_ex! */
|
||||
* scroll-bars already - keep in sync with zoomx/zoomy in #view_zoomstep_apply_ex! */
|
||||
winx = (float)(BLI_rcti_size_x(&v2d->mask) + 1);
|
||||
winy = (float)(BLI_rcti_size_y(&v2d->mask) + 1);
|
||||
|
||||
@@ -1326,8 +1326,8 @@ struct View2DScrollers {
|
||||
/* focus bubbles */
|
||||
/* focus bubbles */
|
||||
/* focus bubbles */
|
||||
int vert_min, vert_max; /* vertical scrollbar */
|
||||
int hor_min, hor_max; /* horizontal scrollbar */
|
||||
int vert_min, vert_max; /* vertical scroll-bar */
|
||||
int hor_min, hor_max; /* horizontal scroll-bar */
|
||||
|
||||
/** Exact size of slider backdrop. */
|
||||
rcti hor, vert;
|
||||
@@ -1380,7 +1380,7 @@ void UI_view2d_scrollers_calc(View2D *v2d,
|
||||
r_scrollers->hor = hor;
|
||||
|
||||
/* scroller 'buttons':
|
||||
* - These should always remain within the visible region of the scrollbar
|
||||
* - These should always remain within the visible region of the scroll-bar
|
||||
* - They represent the region of 'tot' that is visible in 'cur'
|
||||
*/
|
||||
|
||||
@@ -1473,14 +1473,14 @@ void UI_view2d_scrollers_draw_ex(View2D *v2d, const rcti *mask_custom, bool use_
|
||||
|
||||
uchar scrollers_back_color[4];
|
||||
|
||||
/* Color for scrollbar backs */
|
||||
/* Color for scroll-bar backs. */
|
||||
UI_GetThemeColor4ubv(TH_BACK, scrollers_back_color);
|
||||
|
||||
/* make copies of rects for less typing */
|
||||
vert = scrollers.vert;
|
||||
hor = scrollers.hor;
|
||||
|
||||
/* horizontal scrollbar */
|
||||
/* Horizontal scroll-bar. */
|
||||
if (scroll & V2D_SCROLL_HORIZONTAL) {
|
||||
uiWidgetColors wcol = btheme->tui.wcol_scroll;
|
||||
/* 0..255 -> min...1 */
|
||||
@@ -1515,7 +1515,7 @@ void UI_view2d_scrollers_draw_ex(View2D *v2d, const rcti *mask_custom, bool use_
|
||||
UI_draw_widget_scroll(&wcol, &hor, &slider, state);
|
||||
}
|
||||
|
||||
/* vertical scrollbar */
|
||||
/* Vertical scroll-bar. */
|
||||
if (scroll & V2D_SCROLL_VERTICAL) {
|
||||
uiWidgetColors wcol = btheme->tui.wcol_scroll;
|
||||
rcti slider;
|
||||
|
||||
@@ -1821,11 +1821,11 @@ static bool scroller_activate_poll(bContext *C)
|
||||
View2D *v2d = ®ion->v2d;
|
||||
wmEvent *event = win->eventstate;
|
||||
|
||||
/* check if mouse in scrollbars, if they're enabled */
|
||||
/* Check if mouse in scroll-bars, if they're enabled. */
|
||||
return (UI_view2d_mouse_in_scrollers(region, v2d, event->xy) != 0);
|
||||
}
|
||||
|
||||
/* initialize customdata for scroller manipulation operator */
|
||||
/* Initialize #wmOperator.customdata for scroller manipulation operator. */
|
||||
static void scroller_activate_init(bContext *C,
|
||||
wmOperator *op,
|
||||
const wmEvent *event,
|
||||
@@ -2065,7 +2065,7 @@ static int scroller_activate_invoke(bContext *C, wmOperator *op, const wmEvent *
|
||||
ARegion *region = CTX_wm_region(C);
|
||||
View2D *v2d = ®ion->v2d;
|
||||
|
||||
/* check if mouse in scrollbars, if they're enabled */
|
||||
/* check if mouse in scroll-bars, if they're enabled */
|
||||
const char in_scroller = UI_view2d_mouse_in_scrollers(region, v2d, event->xy);
|
||||
|
||||
/* if in a scroller, init customdata then set modal handler which will
|
||||
|
||||
Reference in New Issue
Block a user