[pitivi] render: Don't show the details of the errors raised by GStreamer pipelines



commit d36f05487c8cbb2df3e70f0ed5aef3d03b27c31e
Author: Jean-François Fortin Tam <nekohayo gmail com>
Date:   Sun Nov 9 17:01:47 2014 -0500

    render: Don't show the details of the errors raised by GStreamer pipelines
    
    They're useless for users as they're a string of the path/hierarchy of objects,
    and they'll never be enough information to troubleshoot the issue by themselves.
    
    Fixes bug #739832

 pitivi/render.py |   20 +++++++-------------
 1 files changed, 7 insertions(+), 13 deletions(-)
---
diff --git a/pitivi/render.py b/pitivi/render.py
index ac1c608..84b3466 100644
--- a/pitivi/render.py
+++ b/pitivi/render.py
@@ -829,26 +829,20 @@ class RenderDialog(Loggable):
         self.dialog.ok_btn.connect(
             "clicked", self._okButtonClickedCb, settings_attr)
 
-    def _showRenderErrorDialog(self, error, details):
+    def _showRenderErrorDialog(self, error, unused_details):
         primary_message = _("Sorry, something didn’t work right.")
         secondary_message = _("An error occured while trying to render your "
-                              "project. You might want to check our troubleshooting guide or "
-                              "file a bug report. See the details below for some basic "
-                              "information that may help identify the problem.")
+                              "project. You might want to check our "
+                              "troubleshooting guide or file a bug report. "
+                              "The GStreamer error was:") \
+                            + "\n\n<i>" + error + "</i>"
 
         dialog = Gtk.MessageDialog(transient_for=self.window, modal=True,
                                    message_type=Gtk.MessageType.ERROR, buttons=Gtk.ButtonsType.OK,
                                    text=primary_message)
         dialog.set_property("secondary-text", secondary_message)
-
-        expander = Gtk.Expander()
-        expander.set_label(_("Details"))
-        details_label = Gtk.Label(label=str(error) + "\n\n" + str(details))
-        details_label.set_line_wrap(True)
-        details_label.set_selectable(True)
-        expander.add(details_label)
-        dialog.get_message_area().add(expander)
-        dialog.show_all()  # Ensure the expander and its children show up
+        dialog.set_property("secondary-use-markup", True)
+        dialog.show_all()
         dialog.run()
         dialog.destroy()
 


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