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>2019-06-04 03:53:12 +0300
committerCampbell Barton <ideasman42@gmail.com>2019-06-04 04:05:32 +0300
commit271ec9ff53e7ace452bba0a0aa6000eb5b7a7307 (patch)
tree2a292d06fb4d0b461fcd8c2d0a5866ea571e21ea /source/blender/editors/interface/view2d_ops.c
parentc13e10a7404ddae1d2ab9dc3d421ad18e8cb01ac (diff)
Cleanup: rename 2D scroll defines
- Use `V2D_SCROLL_` prefix. - Use more descriptive names.
Diffstat (limited to 'source/blender/editors/interface/view2d_ops.c')
-rw-r--r--source/blender/editors/interface/view2d_ops.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/source/blender/editors/interface/view2d_ops.c b/source/blender/editors/interface/view2d_ops.c
index a1995806937..116b95c41f9 100644
--- a/source/blender/editors/interface/view2d_ops.c
+++ b/source/blender/editors/interface/view2d_ops.c
@@ -1719,14 +1719,14 @@ static short mouse_in_scroller_handle(int mouse, int sc_min, int sc_max, int sh_
/* check if mouse is in or past either handle */
/* TODO: check if these extents are still valid or not */
- in_max = ((mouse >= (sh_max - V2D_SCROLLER_HANDLE_SIZE)) &&
- (mouse <= (sh_max + V2D_SCROLLER_HANDLE_SIZE)));
- in_min = ((mouse <= (sh_min + V2D_SCROLLER_HANDLE_SIZE)) &&
- (mouse >= (sh_min - V2D_SCROLLER_HANDLE_SIZE)));
- in_bar = ((mouse < (sh_max - V2D_SCROLLER_HANDLE_SIZE)) &&
- (mouse > (sh_min + V2D_SCROLLER_HANDLE_SIZE)));
- out_min = mouse < (sh_min - V2D_SCROLLER_HANDLE_SIZE);
- out_max = mouse > (sh_max + V2D_SCROLLER_HANDLE_SIZE);
+ in_max = ((mouse >= (sh_max - V2D_SCROLL_HANDLE_SIZE_HOTSPOT)) &&
+ (mouse <= (sh_max + V2D_SCROLL_HANDLE_SIZE_HOTSPOT)));
+ in_min = ((mouse <= (sh_min + V2D_SCROLL_HANDLE_SIZE_HOTSPOT)) &&
+ (mouse >= (sh_min - V2D_SCROLL_HANDLE_SIZE_HOTSPOT)));
+ in_bar = ((mouse < (sh_max - V2D_SCROLL_HANDLE_SIZE_HOTSPOT)) &&
+ (mouse > (sh_min + V2D_SCROLL_HANDLE_SIZE_HOTSPOT)));
+ out_min = mouse < (sh_min - V2D_SCROLL_HANDLE_SIZE_HOTSPOT);
+ out_max = mouse > (sh_max + V2D_SCROLL_HANDLE_SIZE_HOTSPOT);
if (in_bar) {
return SCROLLHANDLE_BAR;