Ignore:
File:
1 edited

Legend:

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

    ra188131 rd0dfbba  
    11/*
    2  * Copyright (c) 2025 Jiri Svoboda
     2 * Copyright (c) 2026 Jiri Svoboda
    33 * All rights reserved.
    44 *
     
    3434 */
    3535
     36#include <assert.h>
    3637#include <errno.h>
    3738#include <mem.h>
     
    285286        if (dialog->cb != NULL && dialog->cb->close != NULL)
    286287                dialog->cb->close(dialog, dialog->arg);
     288        else
     289                ui_msg_dialog_destroy(dialog);
    287290}
    288291
     
    310313                                dialog->cb->button(dialog, dialog->arg, 0);
    311314                                return;
     315                        } else {
     316                                ui_msg_dialog_destroy(dialog);
    312317                        }
    313318                } else if (event->key == KC_ESCAPE) {
     
    316321                                dialog->cb->close(dialog, dialog->arg);
    317322                                return;
     323                        } else {
     324                                ui_msg_dialog_destroy(dialog);
    318325                        }
    319326                }
     
    337344                                dialog->cb->button(dialog, dialog->arg, i);
    338345                }
     346        } else {
     347                ui_msg_dialog_destroy(dialog);
    339348        }
    340349}
Note: See TracChangeset for help on using the changeset viewer.