Monotone-Parent: fc8e6bbe0cff3fd2f022a39f28fc8c57fac144e9

Monotone-Revision: 896895232d25506e19bd733d08a718ef9692eecd

Monotone-Author: wsourdeau@inverse.ca
Monotone-Date: 2007-08-21T19:42:16
Monotone-Branch: ca.inverse.sogo
This commit is contained in:
Wolfgang Sourdeau
2007-08-21 19:42:16 +00:00
parent bce1519a9f
commit 9086e4fd02
10 changed files with 268 additions and 0 deletions

View File

@@ -1,5 +1,11 @@
2007-08-21 Wolfgang Sourdeau <wsourdeau@inverse.ca>
* UI/SOGoElements/SOGoIEConditional.m: new extension module class
to handle "<var:if-ie>" template tags.
* UI/SOGoElements: new extension bundle containing sogo-specific
dynamic elements.
* UI/Scheduler/UIxComponentEditor.m ([UIxComponentEditor
-takeValuesFromRequest:_rqinContext:_ctx]): save the category
selected in the dialog.

View File

@@ -5,6 +5,7 @@ include $(GNUSTEP_MAKEFILES)/common.make
SUBPROJECTS += \
SOGoUI \
SOGoElements \
Common \
Contacts \
MailerUI \

View File

@@ -0,0 +1,24 @@
# GNUstep makefile
-include ../../config.make
include $(GNUSTEP_MAKEFILES)/common.make
SOPE_VERSION = 4.7
BUNDLE_NAME = SOGoElements
BUNDLE_EXTENSION = .wox
BUNDLE_INSTALL_DIR = $(GNUSTEP_INSTALLATION_DIR)/Library/WOxElemBuilders-$(SOPE_VERSION)/
SOGoElements_PRINCIPAL_CLASS = SOGoElementsBundle
SOGoElements_OBJC_FILES = \
SOGoElementsBundle.m \
SOGoElementsBuilder.m \
SOGoIEConditional.m
# building
-include GNUmakefile.preamble
include $(GNUSTEP_MAKEFILES)/bundle.make
-include GNUmakefile.postamble
-include fhs.make

View File

@@ -0,0 +1,9 @@
ifneq ($(GNUSTEP_BUILD_DIR),)
after-SOGoElements-all ::
@(cp bundle-info.plist \
$(GNUSTEP_BUILD_DIR)/$(BUNDLE_NAME)$(BUNDLE_EXTENSION))
else
after-SOGoElements-all ::
@(cd $(BUNDLE_NAME)$(BUNDLE_EXTENSION);\
cp ../bundle-info.plist .)
endif

View File

@@ -0,0 +1,31 @@
/* SOGoElementsBuilder.h - this file is part of SOGo
*
* Copyright (C) 2007 Inverse groupe conseil
*
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
*
* This file is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2, or (at your option)
* any later version.
*
* This file is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; see the file COPYING. If not, write to
* the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
#ifndef SOGOELEMENTSBUILDER_H
#define SOGOELEMENTSBUILDER_H
#import <NGObjWeb/WOxElemBuilder.h>
@interface SOGoElementsBuilder : WOxTagClassElemBuilder
@end
#endif /* SOGOELEMENTSBUILDER_H */

View File

@@ -0,0 +1,50 @@
/* SOGoElementsBuilder.m - this file is part of SOGo
*
* Copyright (C) 2007 Inverse groupe conseil
*
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
*
* This file is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2, or (at your option)
* any later version.
*
* This file is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; see the file COPYING. If not, write to
* the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
#import <Foundation/NSString.h>
#import <SaxObjC/XMLNamespaces.h>
#import "SOGoIEConditional.h"
#import "SOGoElementsBuilder.h"
@implementation SOGoElementsBuilder
- (Class) classForElement: (id<DOMElement>) _element
{
NSString *tagName;
Class zeClass;
zeClass = Nil;
if ([[_element namespaceURI] isEqualToString: XMLNS_OD_BIND])
{
tagName = [_element tagName];
if ([tagName isEqualToString: @"if-ie"])
zeClass = [SOGoIEConditional class];
}
return zeClass;
}
@end

View File

@@ -0,0 +1,29 @@
/* SOGoElementsBundle.m - this file is part of SOGo
*
* Copyright (C) 2007 Inverse groupe conseil
*
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
*
* This file is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2, or (at your option)
* any later version.
*
* This file is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; see the file COPYING. If not, write to
* the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
#import <Foundation/NSObject.h>
@interface SOGoElementsBundle : NSObject
@end
@implementation SOGoElementsBundle
@end

View File

@@ -0,0 +1,42 @@
/* SOGoIEConditional.h - this file is part of SOGo
*
* Copyright (C) 2007 Inverse groupe conseil
*
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
*
* This file is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2, or (at your option)
* any later version.
*
* This file is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; see the file COPYING. If not, write to
* the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
#ifndef SOGOIECONDITIONAL_H
#define SOGOIECONDITIONAL_H
#import <NGObjWeb/WODynamicElement.h>
@class WOContext;
@class WOElement;
@class WOResponse;
@interface SOGoIEConditional : WODynamicElement
{
WOElement *template;
}
- (void) appendToResponse: (WOResponse *) _response
inContext: (WOContext *) _ctx;
@end
#endif /* SOGOIECONDITIONAL_H */

View File

@@ -0,0 +1,53 @@
/* SOGoIEConditional.m - this file is part of SOGo
*
* Copyright (C) 2007 Inverse groupe conseil
*
* Author: Wolfgang Sourdeau <wsourdeau@inverse.ca>
*
* This file is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2, or (at your option)
* any later version.
*
* This file is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; see the file COPYING. If not, write to
* the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
#import <NGObjWeb/WOContext.h>
#import <NGObjWeb/WOResponse.h>
#import "SOGoIEConditional.h"
@implementation SOGoIEConditional
- (id) initWithName: (NSString *) name
associations: (NSDictionary *) associations
template: (WOElement *) newTemplate
{
ASSIGN (template, newTemplate);
return self;
}
- (void) dealloc
{
[template release];
[super dealloc];
}
- (void) appendToResponse: (WOResponse *) response
inContext: (WOContext *) context
{
[response appendContentString: @"<!--[if IE]>"];
[template appendToResponse: response inContext: context];
[response appendContentString: @"<![endif]-->"];
}
@end

View File

@@ -0,0 +1,23 @@
{
requires = {
bundleManagerVersion = 1;
classes = (
{ name = NSObject; }
);
};
provides = {
WOxElemBuilder = (
{ name = "SOGoElementsBuilder"; },
);
WODynamicElements = (
{ name = "SOGoIEConditional"; },
);
classes = (
{ name = "SOGoElementsBuilder"; },
);
};
}