[pitivi] Automatically set the year in the project metadata
- From: Edward Hervey <edwardrv src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pitivi] Automatically set the year in the project metadata
- Date: Fri, 10 Dec 2010 17:53:58 +0000 (UTC)
commit 7e1d0e5a4de34cb9aefe1f97ded9a5cd5ab22e4e
Author: Jean-François Fortin Tam <nekohayo gmail com>
Date: Thu Nov 25 18:08:36 2010 -0500
Automatically set the year in the project metadata
pitivi/ui/projectsettings.glade | 2 +-
pitivi/ui/projectsettings.py | 6 ++++++
2 files changed, 7 insertions(+), 1 deletions(-)
---
diff --git a/pitivi/ui/projectsettings.glade b/pitivi/ui/projectsettings.glade
index 67634e2..b4fbb18 100644
--- a/pitivi/ui/projectsettings.glade
+++ b/pitivi/ui/projectsettings.glade
@@ -593,7 +593,7 @@
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="invisible_char">â??</property>
- <property name="adjustment">2009 1900 2500 1 10 10</property>
+ <property name="adjustment">1900 1900 2500 1 10 10</property>
</widget>
<packing>
<property name="left_attach">1</property>
diff --git a/pitivi/ui/projectsettings.py b/pitivi/ui/projectsettings.py
index ee011bd..90e9784 100644
--- a/pitivi/ui/projectsettings.py
+++ b/pitivi/ui/projectsettings.py
@@ -26,6 +26,7 @@ Dialog box for project settings
import gtk
import gst
+from datetime import datetime
from gettext import gettext as _
from pitivi.ui.glade import GladeWindow
from pitivi.ui.dynamic import FractionWidget
@@ -102,6 +103,11 @@ class ProjectSettingsDialog(GladeWindow):
self.channels_combo.set_model(audio_channels)
self.sample_rate_combo.set_model(audio_rates)
self.sample_depth_combo.set_model(audio_depths)
+
+ # set the project metadata
+ # FIXME: not saved in the project file
+ if self.year_spinbutton.get_value_as_int() == 1900:
+ self.year_spinbutton.set_value(datetime.now().year)
# behavior
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]