Changeset aefdccd in mainline for uspace/app/nav/menu.c


Ignore:
Timestamp:
2025-10-20T06:14:54Z (7 weeks ago)
Author:
GitHub <noreply@…>
Parents:
adbd7e1 (diff), 3e41cc4 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
git-author:
boba-buba <120932204+boba-buba@…> (2025-10-20 06:14:54)
git-committer:
GitHub <noreply@…> (2025-10-20 06:14:54)
Message:

Merge branch 'HelenOS:master' into ticket/packet-capture

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/app/nav/menu.c

    radbd7e1 raefdccd  
    5454        nav_menu_t *menu;
    5555        ui_menu_t *mfile;
     56        ui_menu_entry_t *mnew;
    5657        ui_menu_entry_t *mopen;
    5758        ui_menu_entry_t *medit;
     
    7879                goto error;
    7980
     81        rc = ui_menu_entry_create(mfile, "~N~ew File", "Ctrl-M", &mnew);
     82        if (rc != EOK)
     83                goto error;
     84
     85        ui_menu_entry_set_cb(mnew, nav_menu_file_new_file, (void *) menu);
     86
    8087        rc = ui_menu_entry_create(mfile, "~O~pen", "Enter", &mopen);
    8188        if (rc != EOK)
     
    148155}
    149156
     157/** File / New File menu entry selected.
     158 *
     159 * @param mentry Menu entry
     160 * @param arg Argument (navigator_t *)
     161 */
     162void nav_menu_file_new_file(ui_menu_entry_t *mentry, void *arg)
     163{
     164        nav_menu_t *menu = (nav_menu_t *)arg;
     165
     166        if (menu->cb != NULL && menu->cb->file_new_file != NULL)
     167                menu->cb->file_new_file(menu->cb_arg);
     168}
     169
    150170/** File / Open menu entry selected.
    151171 *
Note: See TracChangeset for help on using the changeset viewer.