Changeset 8ce56a6 in mainline for uspace/lib/ui/src/ui.c


Ignore:
Timestamp:
2021-09-07T08:53:42Z (3 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
ebb3538
Parents:
a0aeb8f
git-author:
Jiri Svoboda <jiri@…> (2021-09-06 17:53:32)
git-committer:
Jiri Svoboda <jiri@…> (2021-09-07 08:53:42)
Message:

Translate window rendering in console/SSR with translation GC

In full-screen mode (such as text/console) and server-side rendering
we need other mechanism than memory GC to translate the coordinates
while rendering. We use a translation GC (xlategc).

Note the extensively elaborate testing of this very simple GC seems
quite overboard. At least the very elaborate test_gc_t could be hoisted
into a library and used wherever a test GC is required.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/ui/src/ui.c

    ra0aeb8f r8ce56a6  
    248248        case CEV_POS:
    249249                pos = event->ev.pos;
    250 #ifdef CONFIG_UI_CS_RENDER
    251                 /*
    252                  * TODO Enable translation for server-side rendering
    253                  * once we can translate rendering operations in this
    254                  * case.
    255                  */
     250                /* Translate event to window-relative coordinates */
    256251                pos.hpos -= awnd->dpos.x;
    257252                pos.vpos -= awnd->dpos.y;
    258 #endif
    259253
    260254                claim = ui_wdecor_pos_event(awnd->wdecor, &pos);
Note: See TracChangeset for help on using the changeset viewer.