mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-04-01 19:42:48 +00:00
printView display the parentView by default
This commit is contained in:
@@ -22,6 +22,9 @@
|
||||
#import <Foundation/NSString.h>
|
||||
#import <Foundation/NSArray.h>
|
||||
|
||||
#import <SOGo/SOGoUserSettings.h>
|
||||
#import <SOGo/SOGoUser.h>
|
||||
|
||||
#import <UIxCalViewPrint.h>
|
||||
|
||||
static NSArray *layoutItems = nil;
|
||||
@@ -73,10 +76,29 @@ static NSArray *layoutItems = nil;
|
||||
return [self labelForKey: [NSString stringWithFormat: item]];
|
||||
}
|
||||
|
||||
- (NSString *) layoutSelectedByUser
|
||||
- (NSString *) parentPrintLayout
|
||||
{
|
||||
return nil;
|
||||
// The objective here is to return the parent view layout and select the print layout corresponding. Default print view: list view
|
||||
SOGoUser *activeUser;
|
||||
NSString *parentView;
|
||||
|
||||
activeUser = [context activeUser];
|
||||
us = [activeUser userSettings];
|
||||
parentView = [[us objectForKey:@"Calendar"] objectForKey:@"View" ];
|
||||
|
||||
if ([parentView isEqualToString:@"dayview"])
|
||||
return @"Daily";
|
||||
|
||||
else if ([parentView isEqualToString:@"weekview"])
|
||||
return @"Weekly";
|
||||
|
||||
else if ([parentView isEqualToString:@"multicolumndayview"])
|
||||
return @"Multi-Columns";
|
||||
|
||||
else
|
||||
return @"LIST";
|
||||
}
|
||||
|
||||
/******************************************************************/
|
||||
/* */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user