Changeset a2e104e in mainline for uspace/lib/gui/window.c


Ignore:
Timestamp:
2020-03-05T11:23:41Z (5 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
1e4a937
Parents:
338d0935
git-author:
Jiri Svoboda <jiri@…> (2020-03-04 19:23:29)
git-committer:
Jiri Svoboda <jiri@…> (2020-03-05 11:23:41)
Message:

Move windows by dragging decoration

Or dragging anywhere with button 2. Need to add Ctrl/Alt/Shift state
to pos_event_t and change the latter to Alt-drag/Shift-drag.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/gui/window.c

    r338d0935 ra2e104e  
    272272static void root_handle_position_event(widget_t *widget, pos_event_t event)
    273273{
     274        gfx_coord2_t pos;
     275
    274276        if (widget->window->is_decorated) {
    275277                sysarg_t width = widget->width;
     
    339341                        flags |= GF_MOVE_X;
    340342                        flags |= GF_MOVE_Y;
    341                         //win_grab(widget->window->osess, event.pos_id, flags);
     343                        pos.x = event.hpos;
     344                        pos.y = event.vpos;
     345                        (void) display_window_move_req(widget->window->dwindow,
     346                            &pos);
    342347                } else {
    343348                        list_foreach(widget->children, link, widget_t, child) {
Note: See TracChangeset for help on using the changeset viewer.