Index: pitivi/ui/actions.xml
===================================================================
RCS file: /cvs/gnome/pitivi/pitivi/ui/actions.xml,v
retrieving revision 1.4
diff -u -r1.4 actions.xml
--- pitivi/ui/actions.xml	24 Apr 2006 19:27:52 -0000	1.4
+++ pitivi/ui/actions.xml	24 Sep 2006 19:54:24 -0000
@@ -5,6 +5,7 @@
       <menuitem action="OpenProject" />
       <menuitem action="SaveProject" />
       <menuitem action="SaveProjectAs" />
+      <menuitem action="ExportProject" />
       <menuitem action="ProjectSettings" />
       <separator />
       <menuitem action="ImportSources" />
Index: pitivi/ui/mainwindow.py
===================================================================
RCS file: /cvs/gnome/pitivi/pitivi/ui/mainwindow.py,v
retrieving revision 1.31
diff -u -r1.31 mainwindow.py
--- pitivi/ui/mainwindow.py	21 Aug 2006 10:06:38 -0000	1.31
+++ pitivi/ui/mainwindow.py	24 Sep 2006 19:54:24 -0000
@@ -36,7 +36,7 @@
 
 from timeline import TimelineWidget
 from sourcefactories import SourceFactoriesWidget
-from viewer import PitiviViewer
+from viewer import PitiviViewer, EncodingDialog
 from projectsettings import ProjectSettingsDialog
 from pitivi.configure import pitivi_version, APPNAME
 
@@ -75,6 +75,7 @@
             ("SaveProject", gtk.STOCK_SAVE, None, None, "Save the current project", self._saveProjectCb),
             ("SaveProjectAs", gtk.STOCK_SAVE_AS, None, None, "Save the current project", self._saveProjectAsCb),
             ("ProjectSettings", gtk.STOCK_PROPERTIES, "Project Settings", None, "Edit the project settings", self._projectSettingsCb),
+            ("ExportProject", gtk.STOCK_MEDIA_RECORD, "Export Project", None, "Export the current project", self._recordCb),
             ("ImportSources", gtk.STOCK_ADD, "_Import Sources...", None, "Import sources to use", self._importSourcesCb),
             ("Quit", gtk.STOCK_QUIT, None, None, None, self._quitCb),
             ("FullScreen", gtk.STOCK_FULLSCREEN, None, None, "View the main window on the whole screen", self._fullScreenCb),
@@ -97,7 +98,7 @@
         for action in self.actiongroup.list_actions():
             if action.get_name() in ["ProjectSettings", "Quit", "File", "Help",
                                      "About", "View", "FullScreen", "ImportSources",
-                                     "AdvancedView"]:
+                                     "AdvancedView", "ExportProject"]:
                 action.set_sensitive(True)
             else:
                 action.set_sensitive(False)
@@ -204,6 +205,18 @@
 
     def _saveProjectAsCb(self, unused_action):
         raise NotImplementedError
+    
+    ## The next two functions below are copied for the most part out of viewer.py.
+    ## Shouldn't we have a common location for callbacks to keep maintenance
+    ## easier while keeping the callbacks available to all buttons and menus?
+    def _encodingDialogDestroyCb(self, unused_dialog):
+        instance.PiTiVi.gui.set_sensitive(True)
+        
+    def _recordCb(self, unused_button):
+        win = EncodingDialog(instance.PiTiVi.current)
+        win.window.connect("destroy", self._encodingDialogDestroyCb)
+        instance.PiTiVi.gui.set_sensitive(False)
+        win.show()
 
     def _projectSettingsCb(self, unused_action):
         l = ProjectSettingsDialog(self, instance.PiTiVi.current)
