gnome-panel r11146 - trunk/applets/clock



Author: vuntz
Date: Wed Jun 18 12:17:27 2008
New Revision: 11146
URL: http://svn.gnome.org/viewvc/gnome-panel?rev=11146&view=rev

Log:
2008-06-18  Vincent Untz  <vuntz gnome org>

	* clock.c: (fill_time_settings_window): also select the current day on
	the calendar so that if you open the "set time" dialog on two
	different days, the calendar is always on the current day (and you
	don't accidentaly set time in past)
	Patch by Michael Meeks <michael meeks novell com>.
	https://bugzilla.novell.com/show_bug.cgi?id=395146


Modified:
   trunk/applets/clock/ChangeLog
   trunk/applets/clock/clock.c

Modified: trunk/applets/clock/clock.c
==============================================================================
--- trunk/applets/clock/clock.c	(original)
+++ trunk/applets/clock/clock.c	Wed Jun 18 12:17:27 2008
@@ -1779,6 +1779,10 @@
 	gtk_spin_button_set_value (GTK_SPIN_BUTTON (cd->seconds_spin), now.tm_sec);
 	gtk_spin_button_set_value (GTK_SPIN_BUTTON (cd->minutes_spin), now.tm_min);
 	gtk_spin_button_set_value (GTK_SPIN_BUTTON (cd->hours_spin), now.tm_hour);
+
+	gtk_calendar_select_month (GTK_CALENDAR (cd->calendar), now->tm_mon,
+				   now->tm_year + 1900);
+	gtk_calendar_select_day (GTK_CALENDAR (cd->calendar), now->tm_mday);
 }
 
 static void



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