Fix error in indev driver template (#1476)

This commit is contained in:
Wielebny666
2020-04-25 18:11:10 +02:00
committed by GitHub
parent f7f675afd8
commit 271ec3f6ee

View File

@@ -140,14 +140,14 @@ void lv_port_indev_init(void)
/*Register a encoder input device*/
lv_indev_drv_init(&indev_drv);
indev_drv.type = LV_INDEV_TYPE_KEYPAD;
indev_drv.type = LV_INDEV_TYPE_ENCODER;
indev_drv.read_cb = encoder_read;
indev_encoder = lv_indev_drv_register(&indev_drv);
/* Later you should create group(s) with `lv_group_t * group = lv_group_create()`,
* add objects to the group with `lv_group_add_obj(group, obj)`
* and assign this input device to group to navigate in it:
* `lv_indev_set_group(indev_keypad, group);` */
* `lv_indev_set_group(indev_encoder, group);` */
/*------------------
* Button