diff --git a/UI/Scheduler/Dutch.lproj/Localizable.strings b/UI/Scheduler/Dutch.lproj/Localizable.strings index dfdc5e165..734482a43 100644 --- a/UI/Scheduler/Dutch.lproj/Localizable.strings +++ b/UI/Scheduler/Dutch.lproj/Localizable.strings @@ -371,6 +371,12 @@ "zoom_50" = "50%"; "zoom_25" = "25%"; +/* transparency */ + +"Show Time as" = "Show Time as"; +"opaque" = "opaque"; +"transparent" = "transparent"; + /* validation errors */ validate_notitle = "U heeft geen titel opgegeven. Wilt u doorgaan?"; diff --git a/UI/Scheduler/English.lproj/Localizable.strings b/UI/Scheduler/English.lproj/Localizable.strings index cbbecc12b..017f5fc84 100644 --- a/UI/Scheduler/English.lproj/Localizable.strings +++ b/UI/Scheduler/English.lproj/Localizable.strings @@ -388,6 +388,12 @@ "zoom_50" = "50%"; "zoom_25" = "25%"; +/* transparency */ + +"Show Time as" = "Show Time as"; +"opaque" = "opaque"; +"transparent" = "transparent"; + /* validation errors */ validate_notitle = "No title is set, continue?"; diff --git a/UI/Scheduler/French.lproj/Localizable.strings b/UI/Scheduler/French.lproj/Localizable.strings index 368bd0dca..8b50e20a3 100644 --- a/UI/Scheduler/French.lproj/Localizable.strings +++ b/UI/Scheduler/French.lproj/Localizable.strings @@ -386,6 +386,12 @@ "zoom_50" = "50%"; "zoom_25" = "25%"; +/* transparency */ + +"Show Time as" = "Disponibilité"; +"opaque" = "occupé"; +"transparent" = "disponible"; + /* validation errors */ validate_notitle = "Le titre n'est pas rempli. Continuer quand-même ?"; diff --git a/UI/Scheduler/German.lproj/Localizable.strings b/UI/Scheduler/German.lproj/Localizable.strings index 9b6fe9c3b..2b6f83668 100644 --- a/UI/Scheduler/German.lproj/Localizable.strings +++ b/UI/Scheduler/German.lproj/Localizable.strings @@ -372,6 +372,12 @@ "zoom_50" = "50%"; "zoom_25" = "25%"; +/* transparency */ + +"Show Time as" = "Show Time as"; +"opaque" = "opaque"; +"transparent" = "transparent"; + /* validation errors */ validate_notitle = "Sie haben keinen Titel eingegeben. Wollen Sie trotzdem fortfahren?"; diff --git a/UI/Scheduler/Italian.lproj/Localizable.strings b/UI/Scheduler/Italian.lproj/Localizable.strings index 3edf2ff35..0d20b0acb 100644 --- a/UI/Scheduler/Italian.lproj/Localizable.strings +++ b/UI/Scheduler/Italian.lproj/Localizable.strings @@ -384,6 +384,12 @@ "zoom_50" = "50%"; "zoom_25" = "25%"; +/* transparency */ + +"Show Time as" = "Show Time as"; +"opaque" = "opaque"; +"transparent" = "transparent"; + /* validation errors */ validate_notitle = "Nessun titolo inserito, continuare?"; diff --git a/UI/Scheduler/Spanish.lproj/Localizable.strings b/UI/Scheduler/Spanish.lproj/Localizable.strings index d5a745abd..598b45301 100644 --- a/UI/Scheduler/Spanish.lproj/Localizable.strings +++ b/UI/Scheduler/Spanish.lproj/Localizable.strings @@ -392,6 +392,12 @@ "zoom_50" = "50%"; "zoom_25" = "25%"; +/* transparency */ + +"Show Time as" = "Show Time as"; +"opaque" = "opaque"; +"transparent" = "transparent"; + /* validation errors */ validate_notitle = "Sin título, ¿continuar?"; diff --git a/UI/Scheduler/UIxAppointmentEditor.h b/UI/Scheduler/UIxAppointmentEditor.h index 579602958..62528fcac 100644 --- a/UI/Scheduler/UIxAppointmentEditor.h +++ b/UI/Scheduler/UIxAppointmentEditor.h @@ -33,6 +33,7 @@ iCalEvent *event; SOGoAppointmentFolder *componentCalendar; BOOL isAllDay; + NSString *transparency; NSCalendarDate *aptStartDate; NSCalendarDate *aptEndDate; NSString *item; @@ -43,13 +44,16 @@ - (iCalEvent *) event; /* icalendar values */ -- (BOOL) isAllDay; - (void) setIsAllDay: (BOOL) newIsAllDay; +- (BOOL) isAllDay; -- (void) setAptStartDate: (NSCalendarDate *) _date; +- (void) setTransparency: (NSString *) newTransparency; +- (NSString *) transparency; + +- (void) setAptStartDate: (NSCalendarDate *) newAptEndDate; - (NSCalendarDate *) aptStartDate; -- (void) setAptEndDate: (NSCalendarDate *) _date; +- (void) setAptEndDate: (NSCalendarDate *) newAptEndDate; - (NSCalendarDate *) aptEndDate; @end diff --git a/UI/Scheduler/UIxAppointmentEditor.m b/UI/Scheduler/UIxAppointmentEditor.m index f782d193e..c22c62ec5 100644 --- a/UI/Scheduler/UIxAppointmentEditor.m +++ b/UI/Scheduler/UIxAppointmentEditor.m @@ -109,6 +109,38 @@ isAllDay = newIsAllDay; } +- (NSArray *) transparencyList +{ + static NSArray *transparencies = nil; + + if (!transparencies) + { + transparencies = [NSArray arrayWithObjects: @"OPAQUE", @"TRANSPARENT", nil]; + [transparencies retain]; + } + + return transparencies; +} + +- (NSString *) transparency +{ + return transparency; +} + +- (NSString *) itemTransparencyText +{ + NSString *text; + + text = [self labelForKey: [item lowercaseString]]; + + return text; +} + +- (void) setTransparency: (NSString *) newTransparency +{ + ASSIGN (transparency, newTransparency); +} + - (void) setAptStartDate: (NSCalendarDate *) newAptStartDate { ASSIGN (aptStartDate, newAptStartDate); @@ -188,7 +220,7 @@ - (id ) defaultAction { NSCalendarDate *startDate, *endDate; - NSString *duration; + NSString *duration, *transp; unsigned int minutes; SOGoObject *co; @@ -220,6 +252,9 @@ ASSIGN (aptStartDate, startDate); ASSIGN (aptEndDate, endDate); + transp = [[event transparency] uppercaseString]; + ASSIGN (transparency, transp); + return self; } @@ -356,8 +391,8 @@ [event setStartDate: aptStartDate]; [event setEndDate: aptEndDate]; } - if ([clientObject isNew]) - [event setTransparency: @"OPAQUE"]; + + [event setTransparency: transparency]; } // TODO: add tentatively diff --git a/UI/Templates/SchedulerUI/UIxAppointmentEditor.wox b/UI/Templates/SchedulerUI/UIxAppointmentEditor.wox index b3c6c5cc7..4d2b680f4 100644 --- a/UI/Templates/SchedulerUI/UIxAppointmentEditor.wox +++ b/UI/Templates/SchedulerUI/UIxAppointmentEditor.wox @@ -27,6 +27,24 @@ var:checked="isAllDay" /> + +