MCPcopy Create free account
hub / github.com/JACoders/OpenJK / Item_Slider_OverSlider

Function Item_Slider_OverSlider

code/ui/ui_shared.cpp:10589–10603  ·  view source on GitHub ↗

================= Item_Slider_OverSlider ================= */

Source from the content-addressed store, hash-verified

10587=================
10588*/
10589int Item_Slider_OverSlider(itemDef_t *item, float x, float y)
10590{
10591 rectDef_t r;
10592
10593 r.x = Item_Slider_ThumbPosition(item) - (SLIDER_THUMB_WIDTH / 2);
10594 r.y = item->window.rect.y - 2;
10595 r.w = SLIDER_THUMB_WIDTH;
10596 r.h = SLIDER_THUMB_HEIGHT;
10597
10598 if (Rect_ContainsPoint(&r, x, y))
10599 {
10600 return WINDOW_LB_THUMB;
10601 }
10602 return 0;
10603}
10604
10605/*
10606=================

Callers 1

Item_StartCaptureFunction · 0.70

Calls 2

Rect_ContainsPointFunction · 0.70

Tested by

no test coverage detected