+2004-08-02 Marcus Mueller <znek@mulle-kybernetik.com>
+
+ * UIxPageFrame.wox: removed some navigation items to avoid confusion.
+ Also applied some pretty printing. (v0.9.5)
+
2004-07-30 Marcus Mueller <znek@mulle-kybernetik.com>
* v0.9.4
<?xml version="1.0" standalone="yes"?>
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:var="http://www.skyrix.com/od/binding" xmlns:const="http://www.skyrix.com/od/constant" xmlns:rsrc="OGo:url">
+<html xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:var="http://www.skyrix.com/od/binding"
+ xmlns:const="http://www.skyrix.com/od/constant"
+ xmlns:rsrc="OGo:url"
+>
<head>
<title>
<var:string value="title"/>
<link href="mailto:hh@skyrix.com" rev="made"/>
</head>
<body>
-<!--
- <div id="header">
- <img filename="OGoLogo.gif" class="headerlogo" alt="Logo" />
- <div id="headerhistory">
- <span id="navtitle">SOGo</span>
- </div>
- </div>
- <br />
--->
<table cellpadding="5" cellspacing="0" border="0" width="100%">
<tr>
<td colspan="2">
</td>
<td align="right">
<a href="http://www.opengroupware.org:80/" target="OGo">
- <img rsrc:src="menu_logo_top.gif" align="center" border="0" ALT="" Valign="middle"/>
+ <img rsrc:src="menu_logo_top.gif"
+ align="center"
+ border="0"
+ alt=""
+ valign="middle"
+ />
</a>
</td>
</tr>
<td valign="top">
<table cellpadding="0" cellspacing="0" border="0" width="100%">
<tr>
-<!-- $Id: SkyDock.html,v 1.13 2004/02/13 14:08:27 helge Exp $ -->
<td valign="top">
- <table border="0" cellspacing="0" cellpadding="0" class="leftmenu">
+ <table border="0"
+ cellspacing="0"
+ cellpadding="0"
+ class="leftmenu"
+ >
<tr>
<td>
<img rsrc:src="box_topleft.gif"/>
<img rsrc:src="box_left.gif"/>
</td>
<td width="100%">
- <table width="100%" border="0" cellspacing="2" cellpadding="" class="leftmenu">
+ <table width="100%"
+ border="0"
+ cellspacing="2"
+ cellpadding=""
+ class="leftmenu"
+ >
<tr>
<td>
<font class="skydockfont">
- <a var:href="userRootURL" class="skydockfont">SOGo (<var:string value="user.login" />)</a>
+ <a var:href="userRootURL"
+ class="skydockfont"
+ >SOGo (<var:string value="user.login" />)</a>
</font>
</td>
</tr>
<tr>
<td colspan="2">
- <table cellpadding="0" cellspacing="0" border="0" width="100%">
+ <table cellpadding="0"
+ cellspacing="0"
+ border="0"
+ width="100%"
+ >
<tr>
<td class="linecolor">
<img rsrc:src="line_left.gif"/>
<tr>
<td valign="middle">
<font class="skydockfont">
- <a var:href="userRootURL" class="skydockfont">News</a>
+ <a var:href="userRootURL"
+ class="skydockfont"
+ >Contacts</a>
</font>
</td>
</tr>
<tr>
<td valign="middle">
<font class="skydockfont">
- <a var:href="userRootURL" class="skydockfont">Projects</a>
- </font>
- </td>
- </tr>
- <tr>
- <td valign="middle">
- <font class="skydockfont">
- <a var:href="userRootURL" class="skydockfont">Contacts</a>
- </font>
- </td>
- </tr>
- <tr>
- <td valign="middle">
- <font class="skydockfont">
- <a var:href="userRootURL" class="skydockfont">Companies</a>
- </font>
- </td>
- </tr>
- <tr>
- <td valign="middle">
- <font class="skydockfont">
- <a var:href="calendarRootURL" class="skyDockFont">Calendar</a>
- </font>
- </td>
- </tr>
- <tr>
- <td valign="middle">
- <font class="skydockfont">
- <a var:href="userRootURL" class="skydockfont">Tasks</a>
+ <a var:href="calendarRootURL"
+ class="skyDockFont"
+ >Calendar</a>
</font>
</td>
</tr>
</td>
</tr>
</table>
-<!-- $Id: SkyDockedProjects.html,v 1.10 2004/05/07 16:05:03 helge Exp $ -->
</td>
</tr>
</table>
<br/>
-<!-- $Id: SkyFavorites.html,v 1.5 2003/10/29 18:06:00 helge Exp $ -->
-<!-- the misc box -->
<span>
- <table cellspacing="0" class="leftmenu" border="0" cellpadding="0">
+ <table cellspacing="0"
+ class="leftmenu"
+ border="0"
+ cellpadding="0"
+ >
<tr>
<td>
<img rsrc:src="box_topleft.gif"/>
<img rsrc:src="box_left.gif"/>
</td>
<td width="100%">
- <table width="100%" cellspacing="2" class="leftmenu" border="0" cellpadding="">
+ <table width="100%"
+ cellspacing="2"
+ class="leftmenu"
+ border="0"
+ cellpadding=""
+ >
<tr>
<td>
<font class="skydockfont">Misc</font>
</tr>
<tr>
<td colspan="2">
- <table width="100%" cellspacing="0" border="0" cellpadding="0">
+ <table width="100%"
+ cellspacing="0"
+ border="0"
+ cellpadding="0"
+ >
<tr>
<td class="linecolor">
<img rsrc:src="line_left.gif"/>
</tr>
<tr>
<td valign="middle">
- <a var:href="userRootURL" class="skydockfont">New Email</a>
+ <a var:href="userRootURL"
+ class="skydockfont"
+ >New Email</a>
</td>
</tr>
<tr>
<td valign="middle">
- <a var:href="userRootURL" class="skydockfont">Inbox</a>
+ <a var:href="userRootURL"
+ class="skydockfont"
+ >Inbox</a>
</td>
</tr>
<tr>
<td valign="middle">
- <a var:href="userRootURL" class="skydockfont">Preferences</a>
+ <a var:href="userRootURL"
+ class="skydockfont"
+ >Preferences</a>
</td>
</tr>
<tr>
<td valign="middle">
- <a var:href="userRootURL" target="private_desktop" class="skydockfont">Home</a>
+ <a var:href="userRootURL"
+ target="private_desktop"
+ class="skydockfont"
+ >Home</a>
</td>
</tr>
<tr>
<td valign="middle">
- <a var:href="userRootURL" target="public_desktop" class="skydockfont">Desktop</a>
+ <a var:href="userRootURL"
+ target="public_desktop"
+ class="skydockfont"
+ >Desktop</a>
</td>
</tr>
<tr>
<td valign="middle">
- <a var:href="userRootURL" class="skydockfont">Logout</a>
+ <a var:href="userRootURL"
+ class="skydockfont"
+ >Logout</a>
</td>
</tr>
</table>
<font class="defaultfont"><var:entity const:name="copy"/>
2000-2004 <a href="http://www.skyrix.com:80/knoppix/skyrix/"
target="SKYRIX"
- >SKYRIX Software AG</a>. We welcome your <a href="http://www.opengroupware.org/en/feedback.html"
- target="feedback"
- >feedback</a>.
+ >SKYRIX Software AG</a>.
+ We welcome your
+ <a href="http://www.opengroupware.org/en/feedback.html"
+ target="feedback"
+ >feedback</a>.
</font>
</td>
<td valign="top" align="right">
# $Id: Version,v 1.1 2003/11/24 01:24:40 helge Exp $
-SUBMINOR_VERSION:=4
+SUBMINOR_VERSION:=5
# 1.1.0 requires NGObjWeb 4.2.202
+2004-08-02 Marcus Mueller <znek@mulle-kybernetik.com>
+
+ * v0.9.12
+
+ * UIxCalMonthView.[hm]: fixed a nasty bug. Needed to add -startOfMonth to
+ overcome the problem associated with -startDate in the context of
+ month overview. -startDate is necessary for fetching the core infos and
+ almost always is member of the previous month. Also, -endDate isn't
+ necessarily in the same month we're talking about. I reworked this and
+ added some private category to NSCalendarDate which should be moved into
+ SxCore later on.
+
+ * UIxCalMonthOverview.m: Use -startOfMonth instead of -startDate for all
+ calculations.
+
+ * UIxCalMonthOverview.wox: applied some pretty printing and added some
+ debugging info (commented out).
+
2004-07-30 Marcus Mueller <znek@mulle-kybernetik.com>
* v0.9.11
self->weekOfYear = _week;
if(_week == 52 || _week == 53)
- date = [[self startDate] mondayOfWeek];
+ date = [[self startOfMonth] mondayOfWeek];
else
- date = [self startDate];
+ date = [self startOfMonth];
date = [date mondayOfWeek:_week];
[self setCurrentWeekStartDate:date];
}
}
- (int)year {
- return [[self startDate] yearOfCommonEra];
+ return [[self startOfMonth] yearOfCommonEra];
}
- (int)month {
- return [[self startDate] monthOfYear];
+ return [[self startOfMonth] monthOfYear];
}
- (NSString *)localizedDayOfWeekName {
- (NSString *)contentStyle {
if([self->currentDay isToday])
return @"monthoverview_content_hilite";
- else if([self->currentDay monthOfYear] != [[self startDate] monthOfYear])
+ else if([self->currentDay monthOfYear] != [[self startOfMonth] monthOfYear])
return @"monthoverview_content_dimmed";
return @"monthoverview_content";
}
className="UIxPageFrame"
title="name"
>
- <table id="skywintable" class="wintable" cellspacing="0" cellpadding="5" width="100%">
+ <table id="skywintable"
+ class="wintable"
+ cellspacing="0"
+ cellpadding="5"
+ width="100%"
+ >
<tr>
<td class="wintitle">
<table cellpadding="0" cellspacing="0" width="100%">
<td id="skywinbodycell" class="wincontent">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr bgcolor="#e8e8e0">
- <td align="left" valign="middle" width="80%">TODO: controls</td><!-- 99% -->
+ <td align="left"
+ valign="middle"
+ width="80%"
+ >TODO: controls</td><!-- 99% -->
<td align="right">
<var:component className="UIxCalBackForthNavView"
methodName="ownMethodName"
<td align="right" bgcolor="#e8e8e0">
<table border="0" cellpadding="0" cellspacing="1">
<tr>
- <td class="button_auto_env" nowrap="true" valign="middle" align="center">
+ <td class="button_auto_env"
+ nowrap="true"
+ valign="middle"
+ align="center"
+ >
<a class="button_auto"
href="monthprintview"
var:queryDictionary="queryParameters"
target="SOGoPrintView"
><var:string label:value="printview"/></a>
</td>
- <td class="button_auto_env" nowrap="true" valign="middle" align="center">
+ <td class="button_auto_env"
+ nowrap="true"
+ valign="middle"
+ align="center"
+ >
<a class="button_auto"
href="proposal"
var:queryDictionary="queryParameters"
<br />
</var:foreach>
</var:month-info>
- <var:month-label const:orientation="top" dayOfWeek="dayOfWeek" const:class="monthoverview_title">
+ <var:month-label const:orientation="top"
+ dayOfWeek="dayOfWeek"
+ const:class="monthoverview_title"
+ >
<var:string value="localizedDayOfWeekName"/>
</var:month-label>
- <var:month-label const:orientation="left" weekOfYear="weekOfYear" class="weekStyle">
+ <var:month-label const:orientation="left"
+ weekOfYear="weekOfYear"
+ class="weekStyle"
+ >
<a href="weekoverview"
var:queryDictionary="currentWeekQueryParameters"
><var:string value="weekOfYear"/></a>
</table>
<!--
<hr />
+ start: <var:string value="startDate" /><br />
+ end: <var:string value="endDate" /><br />
+ -->
+ <!--
SOGo Server - <var:string value="name"/>
<br />
Client: <var:string value="clientObject"/>
{
}
+- (NSCalendarDate *)startOfMonth;
+
- (NSDictionary *)prevMonthQueryParameters;
- (NSDictionary *)nextMonthQueryParameters;
#include "common.h"
+@interface NSCalendarDate (UIxCalMonthViewExtensions)
+- (NSCalendarDate *)dayOfWeeK:(unsigned)_day
+ offsetFromSunday:(unsigned)_offset;
+- (NSCalendarDate *)sundayOfWeek;
+@end
+
+@implementation NSCalendarDate (UIxCalMonthViewExtensions)
+- (NSCalendarDate *)dayOfWeeK:(unsigned)_day
+ offsetFromSunday:(unsigned)_offset
+{
+ unsigned dayOfWeek, distance;
+
+ /* perform "locale" correction */
+ dayOfWeek = (7 + [self dayOfWeek] - _offset) % 7;
+
+ _day = (_day % 7);
+ if(_day == dayOfWeek)
+ return self;
+
+ distance = _day - dayOfWeek;
+ return [self dateByAddingYears:0 months:0 days:distance];
+}
+
+/* this implies that monday is the start of week! */
+- (NSCalendarDate *)sundayOfWeek {
+ return [self dayOfWeeK:6 offsetFromSunday:1];
+}
+@end
+
@implementation UIxCalMonthView
+- (NSCalendarDate *)startOfMonth {
+ return [[[super startDate] firstDayOfMonth] beginOfDay];
+}
+
- (NSCalendarDate *)startDate {
- return [[[super startDate] firstDayOfMonth] beginOfDay];
+ return [[self startOfMonth] mondayOfWeek];
}
- (NSCalendarDate *)endDate {
- NSCalendarDate *startDate = [[self startDate] endOfDay];
- return [startDate dateByAddingYears:0
- months:0
- days:[startDate numberOfDaysInMonth]
- hours:0
- minutes:0
- seconds:0];
+ NSCalendarDate *date = [self startOfMonth];
+ date = [date dateByAddingYears:0
+ months:0
+ days:[date numberOfDaysInMonth]
+ hours:0
+ minutes:0
+ seconds:0];
+ date = [[date sundayOfWeek] endOfDay];
+ return date;
}
/* URLs */
- (NSDictionary *)prevMonthQueryParameters {
NSCalendarDate *date;
- date = [[self startDate] dateByAddingYears:0
- months:-1
- days:0
- hours:0
- minutes:0
- seconds:0];
+ date = [[self startOfMonth] dateByAddingYears:0
+ months:-1
+ days:0
+ hours:0
+ minutes:0
+ seconds:0];
return [self queryParametersBySettingSelectedDate:date];
}
- (NSDictionary *)nextMonthQueryParameters {
NSCalendarDate *date;
- date = [[self startDate] dateByAddingYears:0
- months:1
- days:0
- hours:0
- minutes:0
- seconds:0];
+ date = [[self startOfMonth] dateByAddingYears:0
+ months:1
+ days:0
+ hours:0
+ minutes:0
+ seconds:0];
return [self queryParametersBySettingSelectedDate:date];
}
# $Id$
-SUBMINOR_VERSION:=11
+SUBMINOR_VERSION:=12
# 1.1.0 requires NGObjWeb 4.2.202