Changeset c9927c66 in mainline for uspace/lib/display/include


Ignore:
Timestamp:
2021-06-10T13:22:33Z (4 years ago)
Author:
jxsvoboda <5887334+jxsvoboda@…>
Branches:
master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
9e84d2c
Parents:
c68c18b9
git-author:
Jiri Svoboda <jiri@…> (2021-05-27 17:00:30)
git-committer:
jxsvoboda <5887334+jxsvoboda@…> (2021-06-10 13:22:33)
Message:

Set menu popup position based on parent window position

Added a method for getting the position of a display window.
This is then combined with the menu bar entry rectangle (which is
relative to the parent window) to compute a screen-relative
rectangle close to which the popup should be placed.

Location:
uspace/lib/display/include
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/display/include/disp_srv.h

    rc68c18b9 rc9927c66  
    11/*
    2  * Copyright (c) 2019 Jiri Svoboda
     2 * Copyright (c) 2021 Jiri Svoboda
    33 * All rights reserved.
    44 *
     
    6161            gfx_coord2_t *);
    6262        errno_t (*window_move)(void *, sysarg_t, gfx_coord2_t *);
     63        errno_t (*window_get_pos)(void *, sysarg_t, gfx_coord2_t *);
    6364        errno_t (*window_resize)(void *, sysarg_t, gfx_coord2_t *, gfx_rect_t *);
    6465        errno_t (*window_set_cursor)(void *, sysarg_t, display_stock_cursor_t);
  • uspace/lib/display/include/display.h

    rc68c18b9 rc9927c66  
    11/*
    2  * Copyright (c) 2019 Jiri Svoboda
     2 * Copyright (c) 2021 Jiri Svoboda
    33 * All rights reserved.
    44 *
     
    5858    display_wnd_rsztype_t, gfx_coord2_t *);
    5959extern errno_t display_window_move(display_window_t *, gfx_coord2_t *);
     60extern errno_t display_window_get_pos(display_window_t *, gfx_coord2_t *);
    6061extern errno_t display_window_resize(display_window_t *,
    6162    gfx_coord2_t *, gfx_rect_t *);
  • uspace/lib/display/include/ipc/display.h

    rc68c18b9 rc9927c66  
    11/*
    2  * Copyright (c) 2019 Jiri Svoboda
     2 * Copyright (c) 2021 Jiri Svoboda
    33 * All rights reserved.
    44 *
     
    4444        DISPLAY_WINDOW_MOVE,
    4545        DISPLAY_WINDOW_MOVE_REQ,
     46        DISPLAY_WINDOW_GET_POS,
    4647        DISPLAY_WINDOW_RESIZE,
    4748        DISPLAY_WINDOW_RESIZE_REQ,
Note: See TracChangeset for help on using the changeset viewer.