Changeset 4fbdc3d in mainline for uspace/srv/hid/display/test/display.c
- Timestamp:
- 2019-12-11T16:58:30Z (5 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 4d9c807
- Parents:
- 5bded44
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/hid/display/test/display.c
r5bded44 r4fbdc3d 309 309 } 310 310 311 /** Test ds_display_post_p os_event() with click on window switches focus311 /** Test ds_display_post_ptd_event() with click on window switches focus 312 312 */ 313 PCUT_TEST(display_post_p os_event_wnd_switch)313 PCUT_TEST(display_post_ptd_event_wnd_switch) 314 314 { 315 315 ds_display_t *disp; … … 317 317 ds_client_t *client; 318 318 ds_window_t *w0, *w1; 319 p os_event_t event;319 ptd_event_t event; 320 320 bool called_cb = false; 321 321 errno_t rc; … … 342 342 w1->dpos.y = 400; 343 343 344 PCUT_ASSERT_FALSE(called_cb); 345 344 346 ds_seat_set_focus(seat, w0); 345 347 346 event.type = POS_PRESS; 348 event.type = PTD_MOVE; 349 event.dmove.x = 400; 350 event.dmove.y = 400; 351 rc = ds_display_post_ptd_event(disp, &event); 352 PCUT_ASSERT_ERRNO_VAL(EOK, rc); 353 PCUT_ASSERT_FALSE(called_cb); 354 355 event.type = PTD_PRESS; 347 356 event.btn_num = 1; 348 349 PCUT_ASSERT_FALSE(called_cb); 350 351 event.hpos = 400; 352 event.vpos = 400; 353 rc = ds_display_post_pos_event(disp, &event); 357 rc = ds_display_post_ptd_event(disp, &event); 354 358 PCUT_ASSERT_ERRNO_VAL(EOK, rc); 355 359 PCUT_ASSERT_FALSE(called_cb); … … 357 361 PCUT_ASSERT_EQUALS(w1, seat->focus); 358 362 359 event.hpos = 10; 360 event.vpos = 10; 361 rc = ds_display_post_pos_event(disp, &event); 363 event.type = PTD_MOVE; 364 event.dmove.x = -400; 365 event.dmove.y = -400; 366 rc = ds_display_post_ptd_event(disp, &event); 367 PCUT_ASSERT_ERRNO_VAL(EOK, rc); 368 PCUT_ASSERT_FALSE(called_cb); 369 370 event.type = PTD_PRESS; 371 event.btn_num = 1; 372 rc = ds_display_post_ptd_event(disp, &event); 362 373 PCUT_ASSERT_ERRNO_VAL(EOK, rc); 363 374 PCUT_ASSERT_FALSE(called_cb);
Note:
See TracChangeset
for help on using the changeset viewer.