Re: [f14-branch 1/2] memory: check_memory() displays GUI dialog on livecd (#624534).

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



See my comments.

--
Martin Sivák
msivak@xxxxxxxxxx
Red Hat Czech
Anaconda team / Brno, CZ


> +def gtk_warning(title, reason):
> +    import gtk
> +    dialog = gtk.MessageDialog(type = gtk.MESSAGE_ERROR,
> +                               buttons = gtk.BUTTONS_CLOSE,
> +                               message_format=reason)
> +    dialog.set_title(title)
> +    dialog.run()
> +    sys.exit(1)

You should replace sys.exit(1) with dialog.destroy() to hide the dialog and let the calling method to do the exit.


> +        if opts.liveinst:
> +            stdoutLog.warning(reason)
> +            gtk_warning(livecd_title, reason)
> +        else:
> +            reason += reboot_extra
> +            screen = SnackScreen()
> +            ButtonChoiceWindow(screen, _('Fatal Error'),
> +                               reason,
> +                               buttons = (_("OK"),))
> +            screen.finish()
> +        sys.exit(1)

Here..
  
)
> -                dialog.set_title(title)
> -                dialog.run()
> +            if opts.liveinst:
> +                reason += livecd_extra
> +                stdoutLog.warning(reason)
> +                title = livecd_title
> +                gtk_warning(title, reason)
>                  sys.exit(1)

And here..



_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list



[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux