diff options
-rw-r--r-- | src/palimpsest/gdu-main.c | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/src/palimpsest/gdu-main.c b/src/palimpsest/gdu-main.c index c3e6654..676e72d 100644 --- a/src/palimpsest/gdu-main.c +++ b/src/palimpsest/gdu-main.c @@ -27,6 +27,35 @@ #include "gdu-shell.h" +static gboolean +show_nag_dialog (GtkWidget *toplevel) +{ + GtkWidget *dialog; + gint response; + gboolean ret; + + ret = TRUE; + + dialog = gtk_message_dialog_new_with_markup (GTK_WINDOW (toplevel), + GTK_DIALOG_MODAL, + GTK_MESSAGE_WARNING, + GTK_BUTTONS_OK, + _("<b><big>WARNING WARNING WARNING</big></b>")); + gtk_message_dialog_format_secondary_markup (GTK_MESSAGE_DIALOG (dialog), + _("The Palimpsest Disk Utility is still under development and " + "may still have bugs that can lead to data loss.\n" + "\n" + "Use at your own risk.")); + response = gtk_dialog_run (GTK_DIALOG (dialog)); + + if (response != GTK_RESPONSE_OK) + ret = FALSE; + + gtk_widget_destroy (dialog); + + return ret; +} + int main (int argc, char **argv) { @@ -40,8 +69,12 @@ main (int argc, char **argv) gtk_widget_show_all (gdu_shell_get_toplevel (shell)); gdu_shell_update (shell); + if (!show_nag_dialog (gdu_shell_get_toplevel (shell))) + goto out; + gtk_main (); + out: g_object_unref (shell); return 0; } |