+2007-11-20 Wolfgang Sourdeau <wsourdeau@inverse.ca>
+
+ * SoObjects/Appointments/SOGoAppointmentObject.m: don't take an
+ empty c_name as a valid response when looking up an event. Create
+ one in that case instead.
+
2007-11-19 Wolfgang Sourdeau <wsourdeau@inverse.ca>
* UI/PreferencesUI/UIxPreferences.m ([UIxPreferences -signature]):
if ([object isKindOfClass: [NSException class]])
object = nil;
}
+ else
+ object = nil;
}
if (!object)
ex = [self saveContentString: newContent];
if (!(ex || [event userIsOrganizer: [context activeUser]]))
{
- if ([[attendee rsvp] isEqualToString: @"true"])
+ if ([[attendee rsvp] isEqualToString: @"true"]
+ && [event isStillRelevant])
[self sendResponseToOrganizer];
organizerUID = [[event organizer] uid];
if (organizerUID)
/></div>
<!-- separator line --><hr/>
</div>
- <textarea name="text" rows="30" var:value="text"/>
+ <textarea id="text" name="text" rows="30" var:value="text"/>
<!-- img rsrc:src="tbird_073_compose.png" alt="screenshot" / -->
</form>
</var:component>
var anchors = messageDiv.getElementsByTagName('a');
for (var i = 0; i < anchors.length; i++)
if (anchors[i].href.substring(0,7) == "mailto:") {
- Event.observe(anchors[i], "click",
- onEmailAddressClick.bindAsEventListener(anchors[i]));
- Event.observe(anchors[i], "contextmenu",
- onEmailAddressClick.bindAsEventListener(anchors[i]));
+ $(anchors[i]).observe("click", onEmailTo);
+ $(anchors[i]).observe("contextmenu", onEmailAddressClick);
}
else
- Event.observe(anchors[i], "click",
- onMessageAnchorClick.bindAsEventListener(anchors[i]));
+ $(anchors[i]).observe("click", onMessageAnchorClick);
var editDraftButton = $("editDraftButton");
if (editDraftButton)
var link = $("iCalendarAttachment").value;
if (link) {
var urlstr = link + "/" + this.action;
- log ("click: " + urlstr);
triggerAjaxRequest(urlstr, ICalendarButtonCallback,
currentMailbox + "/"
+ currentMessages[currentMailbox]);
return false; /* stop following the link */
}
+function onEmailTo(event) {
+ return openMailTo(this.innerHTML.strip());
+}
+
function newEmailTo(sender) {
return openMailTo(document.menuTarget.innerHTML);
}
var completeEmail = contact["name"] + " <" + contact["email"] + ">";
var node = document.createElement("li");
list.appendChild(node);
- node.uid = contact["uid"];
+ node.setAttribute("uid", contact["uid"]);
node.appendChild(document.createTextNode(completeEmail));
$(node).observe("mousedown", onAttendeeResultClick);
}
var contactSelectorAction = 'mailer-contacts';
+var signatureLength = 0;
function onContactAdd() {
var selector = null;
return false;
}
+function onTextFocus() {
+ this.insertBefore(document.createTextNode("\r\n"),
+ this.lastChild);
+ if (signatureLength > 0) {
+ var length = this.getValue().length - signatureLength - 1;
+ this.setSelectionRange(length, length);
+ }
+ Event.stopObserving(this, "focus", onTextFocus);
+}
+
function initMailEditor() {
var list = $("attachments");
$(list).attachMenu("attachmentsMenu");
var list = $("addressList");
TableKit.Resizable.init(list, {'trueResize' : true, 'keepWidth' : true});
+ var textarea = $("text");
+ var textContent = textarea.getValue();
+ var sigLimit = textContent.lastIndexOf("--");
+ if (sigLimit > -1)
+ signatureLength = (textContent.length - sigLimit);
+ Event.observe(textarea, "focus",
+ onTextFocus.bindAsEventListener(textarea));
+
onWindowResize(null);
Event.observe(window, "resize", onWindowResize);
Event.observe(window, "beforeunload", onMailEditorClose);
font-size: inherit; }
TEXTAREA, INPUT.textField
-{ padding: 0px;
- margin: .15em;
+{ margin: 1px;
border-bottom: 1px solid #fff;
border-right: 1px solid #fff;
border-top: 2px solid #222;
-moz-border-top-colors: #9c9a94 #000 transparent;
-moz-border-left-colors: #9c9a94 #000 transparent; }
+TEXTAREA
+{ padding: 0px;
+ padding-left: 2px; }
+
INPUT.textField
-{ vertical-align: middle; }
+{ padding: 2px;
+ vertical-align: middle; }
DIV#toolbar
{ left: 0px;