2 Copyright (C) 2000-2004 SKYRIX Software AG
4 This file is part of OpenGroupware.org.
6 OGo is free software; you can redistribute it and/or modify it under
7 the terms of the GNU Lesser General Public License as published by the
8 Free Software Foundation; either version 2, or (at your option) any
11 OGo is distributed in the hope that it will be useful, but WITHOUT ANY
12 WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
14 License for more details.
16 You should have received a copy of the GNU Lesser General Public
17 License along with OGo; see the file COPYING. If not, write to the
18 Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
23 #ifndef __WEExtensions_WECalendarField_H__
24 #define __WEExtensions_WECalendarField_H__
33 icon_popupcalendar.gif
42 #define HEAD_BACKGROUND_COLOR @"#FFDAAA"
43 #define HEAD_COLOR @"#000000"
44 #define HEAD_NAVIGATION_COLOR @"#6F1537"
46 #include <NGObjWeb/NGObjWeb.h>
48 @interface WECalendarField : WODynamicElement
57 WOAssociation *format;
61 WOAssociation *minute;
62 WOAssociation *second;
63 WOAssociation *useTextField;
64 WOAssociation *hourInterval;
65 WOAssociation *minuteInterval;
66 WOAssociation *secondInterval;
72 @interface WEDateFieldScript : WODynamicElement
74 WOAssociation *headBackground;
75 WOAssociation *headColor;
76 WOAssociation *headNavColor;
77 WOAssociation *labels;
78 WOAssociation *useImages;
81 + (void)appendWEDateFieldScriptToResponse:(WOResponse *)_response
82 inContext:(WOContext *)_ctx
83 headBackground: (NSString *) _hBack
84 headColor: (NSString *) _hCol
85 headNavColor: (NSString *) _hNav
87 useImages: (BOOL)_useImg;
91 @interface WECalendarField(WETimeFieldImplementation)
93 - (void)_takeValuesFromTimeFieldRequest:(WORequest *)_rq
94 inContext:(WOContext *)_ctx;
95 - (id)_invokeActionForTimeFieldRequest:(WORequest *)_rq
96 inContext:(WOContext *)_ctx;
97 - (void)_appendTimeFieldToResponse:(WOResponse *)_r inContext:(WOContext *)_cx;
99 @end /* WECalendarField(WETimeFieldImplementation) */
101 @interface WECalendarField(WEDateFieldImplementation)
103 - (void)_takeValuesFromDateFieldRequest:(WORequest *)_rq
104 inContext:(WOContext *)_ctx;
105 - (id)_invokeActionForDateFieldRequest:(WORequest *)_rq
106 inContext:(WOContext *)_ctx;
107 - (void)_appendDateFieldToResponse:(WOResponse *)_r inContext:(WOContext *)_cx;
109 @end /* WECalendarField(WEDateFieldImplementation) */
111 @interface WECalendarField(Accessors)
113 - (NSString *)elementIdWithSuffix:(NSString *)_suffix ctx:(WOContext *)_ctx;
115 - (void)setSecond:(int)_second inComponent:(WOComponent *)_comp;
116 - (int)secondInComponent:(WOComponent *)_comp;
118 - (void)setMinute:(int)_minute inComponent:(WOComponent *)_comp;
119 - (int)minuteInComponent:(WOComponent *)_comp;
121 - (void)setHour:(int)_hour inComponent:(WOComponent *)_comp;
122 - (int)hourInComponent:(WOComponent *)_comp;
124 - (void)setDay:(int)_day inComponent:(WOComponent *)_comp;
125 - (int)dayInComponent:(WOComponent *)_comp;
127 - (void)setMonth:(int)_month inComponent:(WOComponent *)_comp;
128 - (int)monthInComponent:(WOComponent *)_comp;
130 - (void)setYear:(int)_year inComponent:(WOComponent *)_comp;
131 - (int)yearInComponent:(WOComponent *)_comp;
133 - (BOOL)isSecondSettable;
134 - (BOOL)isMinuteSettable;
135 - (BOOL)isHourSettable;
136 - (BOOL)isDaySettable;
137 - (BOOL)isMonthSettable;
138 - (BOOL)isYearSettable;
140 - (BOOL)hasSecondInComponent:(WOComponent *)_comp;
141 - (BOOL)hasMinuteInComponent:(WOComponent *)_comp;
142 - (BOOL)hasHourInComponent:(WOComponent *)_comp;
143 - (BOOL)hasDayInComponent:(WOComponent *)_comp;
144 - (BOOL)hasMonthInComponent:(WOComponent *)_comp;
145 - (BOOL)hasYearInComponent:(WOComponent *)_comp;
149 #endif /* __WEExtensions_WECalendarField_H__ */