# lv_indev_private.h (/api/indev/lv_indev_private_h)



<RelatedHeaders name="lv_indev.h" isPrivate="true" />

<ApiSummary functions="1" structs="1" macros="1" />

Functions [#functions]

<ApiMember kind="function" name="lv_indev_find_scroll_obj" file="indev/lv_indev_private.h" line="150" url="https://github.com/lvgl/lvgl/tree/a7b95c5b0839ce901c09c205610bc2c77cc3345d/src/indev/lv_indev_private.h#L150">
  lv_indev_find_scroll_obj [#lv_indev_find_scroll_obj]

  Find a scrollable object based on the current scroll vector in the indev. In handles scroll propagation to the parent if needed, and scroll directions too.

  ```c title=" " lineNumbers=1
  lv_obj_t * lv_indev_find_scroll_obj(lv_indev_t *indev)
  ```

  <span className="sr-only">
    Parameters
  </span>

  | Name    | Type                                                 | Description         |
  | ------- | ---------------------------------------------------- | ------------------- |
  | `indev` | <ApiLink name="lv_indev_t" display="lv_indev_t *" /> | pointer to an indev |

  **Returns:** <ApiLink name="lv_obj_t" display="lv_obj_t *" /> — the found scrollable object or NULL if not found.
</ApiMember>

Structs [#structs]

<ApiMember kind="struct" name="_lv_indev_t">
  \_lv_indev_t [#_lv_indev_t]

  | Member                       | Type                                                        | Description                                                                                                  |
  | ---------------------------- | ----------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ |
  | `ext_data`                   | <ApiLink name="lv_ext_data_t" />                            |                                                                                                              |
  | `type`                       | <ApiLink name="lv_indev_type_t" />                          | Input device type                                                                                            |
  | `read_cb`                    | <ApiLink name="lv_indev_read_cb_t" />                       | Function pointer to read input device data.                                                                  |
  | `state`                      | <ApiLink name="lv_indev_state_t" />                         | Current state of the input device.                                                                           |
  | `prev_state`                 | <ApiLink name="lv_indev_state_t" />                         | Previous state of the input device.                                                                          |
  | `mode`                       | <ApiLink name="lv_indev_mode_t" />                          |                                                                                                              |
  | `long_pr_sent`               | <ApiLink name="uint8_t" />                                  |                                                                                                              |
  | `reset_query`                | <ApiLink name="uint8_t" />                                  |                                                                                                              |
  | `enabled`                    | <ApiLink name="uint8_t" />                                  |                                                                                                              |
  | `wait_until_release`         | <ApiLink name="uint8_t" />                                  |                                                                                                              |
  | `stop_processing_query`      | <ApiLink name="uint8_t" />                                  |                                                                                                              |
  | `timestamp`                  | <ApiLink name="uint32_t" />                                 | Timestamp of last event                                                                                      |
  | `pr_timestamp`               | <ApiLink name="uint32_t" />                                 | Pressed time stamp                                                                                           |
  | `longpr_rep_timestamp`       | <ApiLink name="uint32_t" />                                 | Long press repeat time stamp                                                                                 |
  | `driver_data`                | `void *`                                                    |                                                                                                              |
  | `user_data`                  | `void *`                                                    | Pointer to the assigned display                                                                              |
  | `disp`                       | <ApiLink name="lv_display_t" display="lv_display_t *" />    | Timer to periodically read the input device                                                                  |
  | `read_timer`                 | <ApiLink name="lv_timer_t" display="lv_timer_t *" />        | Number of pixels to slide before actually drag the object                                                    |
  | `scroll_limit`               | <ApiLink name="uint8_t" />                                  | Drag throw slow-down in \[%]. Greater value means faster slow-down                                           |
  | `scroll_throw`               | <ApiLink name="uint8_t" />                                  | Minimum velocity: difference between consecutive points must exceed this (in pixels) to detect gesture speed |
  | `gesture_min_velocity`       | <ApiLink name="uint8_t" />                                  | Minimum distance: total travel from first to current point must exceed this (in pixels) to trigger gesture   |
  | `gesture_min_distance`       | <ApiLink name="uint8_t" />                                  | Long press time in milliseconds                                                                              |
  | `long_press_time`            | <ApiLink name="uint16_t" />                                 | Repeated trigger period in long press \[ms]                                                                  |
  | `long_press_repeat_time`     | <ApiLink name="uint16_t" />                                 | Rotary diff count will be multiplied by this value and divided by 256                                        |
  | `rotary_sensitivity`         | <ApiLink name="int32_t" />                                  |                                                                                                              |
  | `act_point`                  | <ApiLink name="lv_point_t" />                               | Current point of input device.                                                                               |
  | `last_point`                 | <ApiLink name="lv_point_t" />                               | Last point of input device.                                                                                  |
  | `last_raw_point`             | <ApiLink name="lv_point_t" />                               | Last point read from read\_cb.                                                                               |
  | `vect`                       | <ApiLink name="lv_point_t" />                               | Difference between `act_point` and `last_point`.                                                             |
  | `vect_hist`                  | `lv_point_t[8]`                                             |                                                                                                              |
  | `vect_hist_timestamp`        | `uint32_t[8]`                                               |                                                                                                              |
  | `vect_hist_index`            | <ApiLink name="uint8_t" />                                  |                                                                                                              |
  | `scroll_sum`                 | <ApiLink name="lv_point_t" />                               |                                                                                                              |
  | `scroll_throw_vect`          | <ApiLink name="lv_point_t" />                               |                                                                                                              |
  | `scroll_throw_vect_ori`      | <ApiLink name="lv_point_t" />                               |                                                                                                              |
  | `act_obj`                    | <ApiLink name="lv_obj_t" display="lv_obj_t *" />            |                                                                                                              |
  | `scroll_obj`                 | <ApiLink name="lv_obj_t" display="lv_obj_t *" />            |                                                                                                              |
  | `last_pressed`               | <ApiLink name="lv_obj_t" display="lv_obj_t *" />            |                                                                                                              |
  | `last_hovered`               | <ApiLink name="lv_obj_t" display="lv_obj_t *" />            |                                                                                                              |
  | `scroll_area`                | <ApiLink name="lv_area_t" />                                |                                                                                                              |
  | `gesture_sum`                | <ApiLink name="lv_point_t" />                               |                                                                                                              |
  | `diff`                       | <ApiLink name="int32_t" />                                  |                                                                                                              |
  | `short_click_streak`         | <ApiLink name="uint8_t" />                                  |                                                                                                              |
  | `last_short_click_point`     | <ApiLink name="lv_point_t" />                               |                                                                                                              |
  | `last_short_click_timestamp` | <ApiLink name="uint32_t" />                                 |                                                                                                              |
  | `scroll_dir`                 | <ApiLink name="uint8_t" />                                  |                                                                                                              |
  | `gesture_dir`                | <ApiLink name="uint8_t" />                                  |                                                                                                              |
  | `gesture_sent`               | <ApiLink name="uint8_t" />                                  |                                                                                                              |
  | `press_moved`                | <ApiLink name="uint8_t" />                                  |                                                                                                              |
  | `pressed`                    | <ApiLink name="uint8_t" />                                  |                                                                                                              |
  | `pointer`                    | <ApiLink name="_lv_indev_t" display="struct _lv_indev_t" /> |                                                                                                              |
  | `last_state`                 | <ApiLink name="lv_indev_state_t" />                         |                                                                                                              |
  | `last_key`                   | <ApiLink name="uint32_t" />                                 |                                                                                                              |
  | `keypad`                     | <ApiLink name="_lv_indev_t" display="struct _lv_indev_t" /> |                                                                                                              |
  | `cursor`                     | <ApiLink name="lv_obj_t" display="lv_obj_t *" />            | Cursor for LV\_INPUT\_TYPE\_POINTER                                                                          |
  | `group`                      | <ApiLink name="lv_group_t" display="lv_group_t *" />        | Keypad destination group                                                                                     |
  | `btn_points`                 | <ApiLink name="lv_point_t" display="const lv_point_t *" />  | Array points assigned to the button ()screen will be pressed here by the buttons                             |
  | `event_list`                 | <ApiLink name="lv_event_list_t" />                          |                                                                                                              |
  | `scroll_throw_anim`          | <ApiLink name="lv_anim_t" display="lv_anim_t *" />          | Key remapping callback                                                                                       |
  | `key_remap_cb`               | <ApiLink name="lv_indev_key_remap_cb_t" />                  |                                                                                                              |
  | `recognizers`                | `lv_indev_gesture_recognizer_t[LV_INDEV_GESTURE_CNT]`       |                                                                                                              |
  | `cur_gesture`                | <ApiLink name="lv_indev_gesture_type_t" />                  |                                                                                                              |
  | `gesture_data`               | `void *[LV_INDEV_GESTURE_CNT]`                              |                                                                                                              |
  | `gesture_type`               | `lv_indev_gesture_type_t[LV_INDEV_GESTURE_CNT]`             |                                                                                                              |
</ApiMember>

Macros [#macros]

<ApiMember kind="macro" name="LV_INDEV_VECT_HIST_SIZE" file="indev/lv_indev_private.h" line="25" url="https://github.com/lvgl/lvgl/tree/a7b95c5b0839ce901c09c205610bc2c77cc3345d/src/indev/lv_indev_private.h#L25">
  LV_INDEV_VECT_HIST_SIZE [#lv_indev_vect_hist_size]

  ```c title=" " lineNumbers=1
  #define LV_INDEV_VECT_HIST_SIZE 8
  ```
</ApiMember>

Dependencies [#dependencies]

<FileIncludes includes="[&#x22;lv_ext_data.h&#x22;, &#x22;lv_indev.h&#x22;, &#x22;lv_anim.h&#x22;, &#x22;lv_indev_scroll.h&#x22;, &#x22;lv_indev_gesture.h&#x22;]" transitiveIncludes="[&#x22;lv_area.h&#x22;, &#x22;lv_array.h&#x22;, &#x22;lv_assert.h&#x22;, &#x22;lv_bidi.h&#x22;, &#x22;lv_color.h&#x22;, &#x22;lv_color_op.h&#x22;, &#x22;lv_conf_internal.h&#x22;, &#x22;lv_conf_kconfig.h&#x22;, &#x22;lv_display.h&#x22;, &#x22;lv_draw.h&#x22;, &#x22;lv_draw_arc.h&#x22;, &#x22;lv_draw_blur.h&#x22;, &#x22;lv_draw_buf.h&#x22;, &#x22;lv_draw_image.h&#x22;, &#x22;lv_draw_label.h&#x22;, &#x22;lv_draw_line.h&#x22;, &#x22;lv_draw_rect.h&#x22;, &#x22;lv_draw_triangle.h&#x22;, &#x22;lv_event.h&#x22;, &#x22;lv_flex.h&#x22;, &#x22;lv_font.h&#x22;, &#x22;lv_fs.h&#x22;, &#x22;lv_grad.h&#x22;, &#x22;lv_grid.h&#x22;, &#x22;lv_group.h&#x22;, &#x22;lv_image_decoder.h&#x22;, &#x22;lv_image_dsc.h&#x22;, &#x22;lv_layout.h&#x22;, &#x22;lv_ll.h&#x22;, &#x22;lv_log.h&#x22;, &#x22;lv_math.h&#x22;, &#x22;lv_matrix.h&#x22;, &#x22;lv_mem.h&#x22;, &#x22;lv_obj.h&#x22;, &#x22;lv_obj_class.h&#x22;, &#x22;lv_obj_draw.h&#x22;, &#x22;lv_obj_event.h&#x22;, &#x22;lv_obj_pos.h&#x22;, &#x22;lv_obj_property.h&#x22;, &#x22;lv_obj_property_names.h&#x22;, &#x22;lv_obj_scroll.h&#x22;, &#x22;lv_obj_style.h&#x22;, &#x22;lv_obj_style_gen.h&#x22;, &#x22;lv_obj_tree.h&#x22;, &#x22;lv_palette.h&#x22;, &#x22;lv_profiler.h&#x22;, &#x22;lv_profiler_builtin.h&#x22;, &#x22;lv_sprintf.h&#x22;, &#x22;lv_string.h&#x22;, &#x22;lv_style.h&#x22;, &#x22;lv_style_gen.h&#x22;, &#x22;lv_style_properties.h&#x22;, &#x22;lv_symbol_def.h&#x22;, &#x22;lv_text.h&#x22;, &#x22;lv_tick.h&#x22;, &#x22;lv_timer.h&#x22;, &#x22;lv_types.h&#x22;]" />
