From 95e42d38f754dc701de20a9c300dc9b0d34c6b9b Mon Sep 17 00:00:00 2001 From: Francis Lachapelle Date: Fri, 9 Dec 2011 16:34:11 +0000 Subject: [PATCH] Monotone-Parent: b4900cbcd7c48cfd36bb5a262eec357e3ac1033a Monotone-Revision: 533c5fea139373885b136bf6d41275a80a56967b Monotone-Author: flachapelle@inverse.ca Monotone-Date: 2011-12-09T16:34:11 --- UI/MailerUI/Toolbars/SOGoDraftObject.toolbar | 2 +- UI/MailerUI/Toolbars/SOGoMailFolder.toolbar | 2 +- UI/SOGoUI/UIxComponent.h | 6 -- UI/SOGoUI/UIxComponent.m | 23 +----- UI/Templates/PreferencesUI/UIxPreferences.wox | 14 ++-- UI/Templates/UIxPageFrame.wox | 78 ++++++++----------- 6 files changed, 40 insertions(+), 85 deletions(-) diff --git a/UI/MailerUI/Toolbars/SOGoDraftObject.toolbar b/UI/MailerUI/Toolbars/SOGoDraftObject.toolbar index c4c1020ad..63d1f38a6 100644 --- a/UI/MailerUI/Toolbars/SOGoDraftObject.toolbar +++ b/UI/MailerUI/Toolbars/SOGoDraftObject.toolbar @@ -12,7 +12,7 @@ { link = "#"; onclick = "return onContactAdd(this);"; image = "tb-compose-contacts-flat-24x24.png"; - cssClass = "tbicon_addressbook"; + cssClass = "tbicon_addressbook single-window-not-conditional"; label = "Contacts"; tooltip = "Select a recipient from an Address Book"; }, { link = "#"; diff --git a/UI/MailerUI/Toolbars/SOGoMailFolder.toolbar b/UI/MailerUI/Toolbars/SOGoMailFolder.toolbar index a84c9780c..1c9d1968d 100644 --- a/UI/MailerUI/Toolbars/SOGoMailFolder.toolbar +++ b/UI/MailerUI/Toolbars/SOGoMailFolder.toolbar @@ -59,7 +59,7 @@ ( { link = "#"; onclick = "return onPrintCurrentMessage(event);"; - cssClass = "tbicon_print"; + cssClass = "tbicon_print single-window-not-conditional"; image = "tb-mail-print-flat-24x24.png"; label = "Print"; tooltip = "Print this message"; }, diff --git a/UI/SOGoUI/UIxComponent.h b/UI/SOGoUI/UIxComponent.h index 05477b801..c343773f2 100644 --- a/UI/SOGoUI/UIxComponent.h +++ b/UI/SOGoUI/UIxComponent.h @@ -66,12 +66,6 @@ - (NSString *)ownPath; - (NSString *)relativePathToUserFolderSubPath:(NSString *)_sub; -/* module access */ -- (BOOL) isCalendarEnabled; -- (BOOL) isContactsEnabled; -- (BOOL) isMailEnabled; -- (BOOL) isPreferencesEnabled; - /* date selection */ - (NSCalendarDate *) selectedDate; diff --git a/UI/SOGoUI/UIxComponent.m b/UI/SOGoUI/UIxComponent.m index ed2194008..e57f10256 100644 --- a/UI/SOGoUI/UIxComponent.m +++ b/UI/SOGoUI/UIxComponent.m @@ -460,7 +460,7 @@ static NSMutableArray *abbrMonthLabelKeys = nil; value = [[context request] cookieValueForKey: @"SOGoWindowMode"]; result = ([value isEqualToString: @"single"]); - NSLog(@"Single window mode %@", result?@"enabled":@"disabled"); + //NSLog(@"Single window mode %@", result?@"enabled":@"disabled"); return result; } @@ -483,27 +483,6 @@ static NSMutableArray *abbrMonthLabelKeys = nil; return [user canAccessModule: @"Mail"]; } -#warning we might want to refine the tests here... -- (BOOL) isCalendarEnabled -{ - return [self userHasCalendarAccess] && ![self singleWindowModeEnabled]; -} - -- (BOOL) isContactsEnabled -{ - return ![self singleWindowModeEnabled]; -} - -- (BOOL) isMailEnabled -{ - return [self userHasMailAccess]; -} - -- (BOOL) isPreferencesEnabled -{ - return ![self singleWindowModeEnabled]; -} - /* SoUser */ - (NSString *) shortUserNameForDisplay diff --git a/UI/Templates/PreferencesUI/UIxPreferences.wox b/UI/Templates/PreferencesUI/UIxPreferences.wox index 06d0771c1..2b3cce7e4 100644 --- a/UI/Templates/PreferencesUI/UIxPreferences.wox +++ b/UI/Templates/PreferencesUI/UIxPreferences.wox @@ -20,15 +20,13 @@