From acd66d449ef681ff92c38a6d4fb93aa3ade2652e Mon Sep 17 00:00:00 2001 From: helge Date: Mon, 18 Jul 2005 08:55:04 +0000 Subject: [PATCH] added localized labels git-svn-id: http://svn.opengroupware.org/SOGo/trunk@781 d1b88da0-ebda-0310-925b-ed51d893ca5b --- SOGo/UI/MailPartViewers/ChangeLog | 5 ++++ .../English.lproj/Localizable.strings | 8 +++++++ .../French.lproj/Localizable.strings | 8 +++++++ SOGo/UI/MailPartViewers/GNUmakefile | 5 ++++ .../MailPartViewers/UIxMailPartICalViewer.m | 24 +++++++++++++++++++ SOGo/UI/MailPartViewers/Version | 2 +- .../MailPartViewers/UIxMailPartICalViewer.wox | 2 +- 7 files changed, 52 insertions(+), 2 deletions(-) create mode 100644 SOGo/UI/MailPartViewers/English.lproj/Localizable.strings create mode 100644 SOGo/UI/MailPartViewers/French.lproj/Localizable.strings diff --git a/SOGo/UI/MailPartViewers/ChangeLog b/SOGo/UI/MailPartViewers/ChangeLog index b8ce7026..0b2d961e 100644 --- a/SOGo/UI/MailPartViewers/ChangeLog +++ b/SOGo/UI/MailPartViewers/ChangeLog @@ -1,3 +1,8 @@ +2005-07-18 Helge Hess + + * UIxMailPartICalViewer.m: added -attendeeStatusLabel to produce a + readable and localized part-stat (v0.9.13) + 2005-07-18 Helge Hess * UIxMailPartICalViewer.m: added code to support iMIP REPLY messages diff --git a/SOGo/UI/MailPartViewers/English.lproj/Localizable.strings b/SOGo/UI/MailPartViewers/English.lproj/Localizable.strings new file mode 100644 index 00000000..67f0c597 --- /dev/null +++ b/SOGo/UI/MailPartViewers/English.lproj/Localizable.strings @@ -0,0 +1,8 @@ +"icalstatus_ACCEPTED" = "accepted" +"icalstatus_COMPLETED" = "completed" +"icalstatus_DECLINED" = "declined" +"icalstatus_DELEGATED" = "delegated" +"icalstatus_IN-PROCESS" = "in process" +"icalstatus_NEEDS-ACTION" = "needs action" +"icalstatus_TENTATIVE" = "tentative" +"icalstatus_extended_prefix" = "extended: " diff --git a/SOGo/UI/MailPartViewers/French.lproj/Localizable.strings b/SOGo/UI/MailPartViewers/French.lproj/Localizable.strings new file mode 100644 index 00000000..5a9683e2 --- /dev/null +++ b/SOGo/UI/MailPartViewers/French.lproj/Localizable.strings @@ -0,0 +1,8 @@ +"icalstatus_ACCEPTED" = "TODO: accepted" +"icalstatus_COMPLETED" = "TODO: completed" +"icalstatus_DECLINED" = "TODO: declined" +"icalstatus_DELEGATED" = "TODO: delegated" +"icalstatus_IN-PROCESS" = "TODO: in process" +"icalstatus_NEEDS-ACTION" = "TODO: needs action" +"icalstatus_TENTATIVE" = "TODO: tentative" +"icalstatus_extended_prefix" = "TODO: extended: " diff --git a/SOGo/UI/MailPartViewers/GNUmakefile b/SOGo/UI/MailPartViewers/GNUmakefile index abf0961c..23a59d65 100644 --- a/SOGo/UI/MailPartViewers/GNUmakefile +++ b/SOGo/UI/MailPartViewers/GNUmakefile @@ -8,6 +8,8 @@ MailPartViewers_PRINCIPAL_CLASS = MailPartViewersProduct MailPartViewers_LANGUAGES = English French +MailPartViewers_LANGUAGES = English French + MailPartViewers_OBJC_FILES += \ MailPartViewersProduct.m \ \ @@ -30,6 +32,9 @@ MailPartViewers_RESOURCE_FILES += \ Version \ product.plist \ +MailPartViewers_LOCALIZED_RESOURCE_FILES += \ + Localizable.strings + # make -include GNUmakefile.preamble diff --git a/SOGo/UI/MailPartViewers/UIxMailPartICalViewer.m b/SOGo/UI/MailPartViewers/UIxMailPartICalViewer.m index f0484bbd..cd9ab67e 100644 --- a/SOGo/UI/MailPartViewers/UIxMailPartICalViewer.m +++ b/SOGo/UI/MailPartViewers/UIxMailPartICalViewer.m @@ -164,6 +164,23 @@ return date; } +/* attendee fields */ + +- (NSString *)attendeeStatusLabel { + NSString *p; + + p = [[self attendee] partStat]; + + if ([p hasPrefix:@"x-"] || [p hasPrefix:@"X-"]) { + p = [self labelForKey:@"icalstatus_extended_prefix"]; + return [p stringByAppendingString:[p substringFromIndex:2]]; + } + + if ([p length] == 0) p = @"NEEDS-ACTION"; + p = [@"icalstatus_" stringByAppendingString:p]; + return [self labelForKey:p]; +} + /* calendar folder support */ - (id)calendarFolder { @@ -303,6 +320,13 @@ return [attendees objectAtIndex:0]; } - (iCalPerson *)storedReplyAttendee { + /* + TODO: since an attendee can have multiple email addresses, maybe we + should translate the email to an internal uid and then retrieve + all emails addresses for matching the participant. + + Note: -findParticipantWithEmail: does not parse the email! + */ iCalEvent *e; iCalPerson *p; diff --git a/SOGo/UI/MailPartViewers/Version b/SOGo/UI/MailPartViewers/Version index cb1c5948..fae4f21a 100644 --- a/SOGo/UI/MailPartViewers/Version +++ b/SOGo/UI/MailPartViewers/Version @@ -1,6 +1,6 @@ # version file -SUBMINOR_VERSION:=12 +SUBMINOR_VERSION:=13 # v0.9.0 requires libNGiCal v4.5.53 # v0.9.1 requires libNGMime v4.5.213 diff --git a/SOGo/UI/Templates/MailPartViewers/UIxMailPartICalViewer.wox b/SOGo/UI/Templates/MailPartViewers/UIxMailPartICalViewer.wox index 3b550069..0fdbba57 100644 --- a/SOGo/UI/Templates/MailPartViewers/UIxMailPartICalViewer.wox +++ b/SOGo/UI/Templates/MailPartViewers/UIxMailPartICalViewer.wox @@ -154,7 +154,7 @@ - () + ()
-- 2.39.5