diff --git a/ChangeLog b/ChangeLog index ac1ae32f3..49f303d4a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2007-04-03 Wolfgang Sourdeau + + * UI/Scheduler/UIxCalTasksListView.m ([UIxCalTasksListView + -shouldDisplayCurrentTask]): the current task is not displayed if + it is NOT completed or if the "showCompletedTasks" flag is set. + The logic was inverted in Lightning and is now in SOGo too. + 2007-04-02 Wolfgang Sourdeau * UI/Contacts/UIxContactView.m ([UIxContactView -workUrl]): we diff --git a/UI/Scheduler/English.lproj/Localizable.strings b/UI/Scheduler/English.lproj/Localizable.strings index aa881ef13..4d51efadb 100644 --- a/UI/Scheduler/English.lproj/Localizable.strings +++ b/UI/Scheduler/English.lproj/Localizable.strings @@ -314,7 +314,7 @@ validate_invalid_enddate = "Incorrect enddate field!"; validate_endbeforestart = "Enddate is before startdate!"; "Tasks" = "Tasks"; -"Hide completed tasks" = "Hide completed tasks"; +"Show completed tasks" = "Show completed tasks"; /* tabs */ "Task" = "Task"; diff --git a/UI/Scheduler/French.lproj/Localizable.strings b/UI/Scheduler/French.lproj/Localizable.strings index 37002e785..b71756444 100644 --- a/UI/Scheduler/French.lproj/Localizable.strings +++ b/UI/Scheduler/French.lproj/Localizable.strings @@ -315,7 +315,7 @@ validate_invalid_enddate = "La date de fin est invalide !"; validate_endbeforestart = "La date de fin est avant la date de début !"; "Tasks" = "Tâches"; -"Hide completed tasks" = "Masquer les tâches accomplies"; +"Show completed tasks" = "Afficher les tâches accomplies"; /* tabs */ "Task" = "Tâche"; diff --git a/UI/Scheduler/UIxCalTasksListView.h b/UI/Scheduler/UIxCalTasksListView.h index dd1ab3fd8..5cdc7f84d 100644 --- a/UI/Scheduler/UIxCalTasksListView.h +++ b/UI/Scheduler/UIxCalTasksListView.h @@ -32,8 +32,8 @@ NSCalendarDate *startDate; NSCalendarDate *endDate; - BOOL knowsToHide; - BOOL hideCompleted; + BOOL knowsToShow; + BOOL showCompleted; NSDictionary *currentTask; } diff --git a/UI/Scheduler/UIxCalTasksListView.m b/UI/Scheduler/UIxCalTasksListView.m index a939a76f8..349cee29c 100644 --- a/UI/Scheduler/UIxCalTasksListView.m +++ b/UI/Scheduler/UIxCalTasksListView.m @@ -39,8 +39,8 @@ { startDate = nil; endDate = nil; - knowsToHide = NO; - hideCompleted = NO; + knowsToShow = NO; + showCompleted = NO; } return self; @@ -105,27 +105,27 @@ - (BOOL) shouldDisplayCurrentTask { - if (!knowsToHide) + if (!knowsToShow) { - hideCompleted - = [[self queryParameterForKey: @"hide-completed"] intValue]; - knowsToHide = YES; + showCompleted + = [[self queryParameterForKey: @"show-completed"] intValue]; + knowsToShow = YES; } - return !(hideCompleted - && [[currentTask objectForKey: @"status"] intValue] == 1); + return ([[currentTask objectForKey: @"status"] intValue] != 1 + || showCompleted); } -- (BOOL) shouldHideCompletedTasks +- (BOOL) shouldShowCompletedTasks { - if (!knowsToHide) + if (!knowsToShow) { - hideCompleted - = [[self queryParameterForKey: @"hide-completed"] intValue]; - knowsToHide = YES; + showCompleted + = [[self queryParameterForKey: @"show-completed"] intValue]; + knowsToShow = YES; } - return hideCompleted; + return showCompleted; } - (BOOL) isCurrentTaskCompleted diff --git a/UI/Templates/SchedulerUI/UIxCalTasksListView.wox b/UI/Templates/SchedulerUI/UIxCalTasksListView.wox index 37853c907..2ec74999b 100644 --- a/UI/Templates/SchedulerUI/UIxCalTasksListView.wox +++ b/UI/Templates/SchedulerUI/UIxCalTasksListView.wox @@ -7,10 +7,10 @@ xmlns:label="OGo:label">