Changeset 3c54869 in mainline for uspace/lib/wndmgt


Ignore:
Timestamp:
2023-01-04T20:24:44Z (3 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
master, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
5d86797
Parents:
cdd6fc9
Message:

Highlight active window in task bar

Location:
uspace/lib/wndmgt
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/wndmgt/include/types/wndmgt.h

    rcdd6fc9 r3c54869  
    11/*
    2  * Copyright (c) 2022 Jiri Svoboda
     2 * Copyright (c) 2023 Jiri Svoboda
    33 * All rights reserved.
    44 *
     
    8989        /** Window flags */
    9090        unsigned flags;
     91        /** Number of foci on this window */
     92        unsigned nfocus;
    9193} wndmgt_window_info_t;
    9294
  • uspace/lib/wndmgt/src/wndmgt.c

    rcdd6fc9 r3c54869  
    11/*
    2  * Copyright (c) 2022 Jiri Svoboda
     2 * Copyright (c) 2023 Jiri Svoboda
    33 * All rights reserved.
    44 *
     
    271271        info->caption = caption;
    272272        info->flags = ipc_get_arg1(&answer);
     273        info->nfocus = ipc_get_arg2(&answer);
    273274        *rinfo = info;
    274275        return EOK;
  • uspace/lib/wndmgt/src/wndmgt_srv.c

    rcdd6fc9 r3c54869  
    200200        }
    201201
    202         async_answer_1(icall, EOK, info->flags);
     202        async_answer_2(icall, EOK, info->flags, info->nfocus);
    203203        wndmgt_free_window_info(info);
    204204}
  • uspace/lib/wndmgt/test/wndmgt.c

    rcdd6fc9 r3c54869  
    11/*
    2  * Copyright (c) 2022 Jiri Svoboda
     2 * Copyright (c) 2023 Jiri Svoboda
    33 * All rights reserved.
    44 *
     
    282282        resp.get_window_info_rinfo->caption = str_dup("Hello");
    283283        resp.get_window_info_rinfo->flags = 42;
     284        resp.get_window_info_rinfo->nfocus = 123;
    284285        PCUT_ASSERT_NOT_NULL(resp.get_window_info_rinfo->caption);
    285286        wnd_id = 1;
     
    292293        PCUT_ASSERT_STR_EQUALS("Hello", info->caption);
    293294        PCUT_ASSERT_INT_EQUALS(42, info->flags);
     295        PCUT_ASSERT_INT_EQUALS(123, info->nfocus);
    294296
    295297        wndmgt_free_window_info(info);
Note: See TracChangeset for help on using the changeset viewer.