tasque r20 - in trunk: . src



Author: btimothy
Date: Thu Mar 13 22:46:41 2008
New Revision: 20
URL: http://svn.gnome.org/viewvc/tasque?rev=20&view=rev

Log:
* src/Application.cs, src/TaskWindow.cs: Change the code so that when
  the user selects "New task..." from the tray icon, it will open the
  task window and put their cursor in the new task entry widget
  instead of just create a task called "New task..."

Modified:
   trunk/ChangeLog
   trunk/src/Application.cs
   trunk/src/TaskWindow.cs

Modified: trunk/src/Application.cs
==============================================================================
--- trunk/src/Application.cs	(original)
+++ trunk/src/Application.cs	Thu Mar 13 22:46:41 2008
@@ -401,7 +401,7 @@
 		{
 			// Show the TaskWindow and then cause a new task to be created
 			TaskWindow.ShowWindow ();
-			TaskWindow.AddTask ();
+			TaskWindow.GrabNewTaskEntryFocus ();
 		}
 
 		private void OnQuit (object sender, EventArgs args)

Modified: trunk/src/TaskWindow.cs
==============================================================================
--- trunk/src/TaskWindow.cs	(original)
+++ trunk/src/TaskWindow.cs	Thu Mar 13 22:46:41 2008
@@ -447,6 +447,14 @@
 			}
 		}
 		
+		public static void GrabNewTaskEntryFocus ()
+		{
+			if (taskWindow == null)
+				TaskWindow.ShowWindow ();
+			
+			taskWindow.addTaskEntry.GrabFocus ();
+		}
+		
 		public static void SelectAndEdit (ITask task)
 		{
 			ShowWindow ();



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