From b63050dac99c289e7500c14d5d71b65cde5b5897 Mon Sep 17 00:00:00 2001 From: Wolfgang Sourdeau Date: Thu, 2 Jul 2009 14:24:36 +0000 Subject: [PATCH 1/6] Monotone-Parent: 53683aad48259504e699908753251ef4902e4139 Monotone-Revision: ef38d39938984cb34954a23cdc1d54fecf577117 Monotone-Author: wsourdeau@inverse.ca Monotone-Date: 2009-07-02T14:24:36 Monotone-Branch: ca.inverse.sogo --- SOPE/sope-patchset-r1657.diff | 109 +++++++++++++++++++++++++++++++++- 1 file changed, 106 insertions(+), 3 deletions(-) diff --git a/SOPE/sope-patchset-r1657.diff b/SOPE/sope-patchset-r1657.diff index 043e5ff28..43c0b7424 100644 --- a/SOPE/sope-patchset-r1657.diff +++ b/SOPE/sope-patchset-r1657.diff @@ -4043,7 +4043,18 @@ Index: sope-appserver/NGObjWeb/ChangeLog =================================================================== --- sope-appserver/NGObjWeb/ChangeLog (revision 1660) +++ sope-appserver/NGObjWeb/ChangeLog (working copy) -@@ -1,3 +1,11 @@ +@@ -1,3 +1,22 @@ ++2009-07-02 Wolfgang Sourdeau ++ ++ * WOMessage.m (-setHeaders:, -setHeader:forKey:, headerForKey:, ++ -appendHeader:forKey:, -appendHeaders:forKey:, setHeaders:forKey:, ++ -headersForKey:): convert the specified header key to lowercase, ++ to ensure they are managed case-insensitively. ++ * WOHttpAdaptor/WOHttpTransaction.m ++ (-deliverResponse:toRequest:onStream:): if the content-type is ++ specified and already has "text/plain" as prefix, we don't ++ override it. ++ +2009-07-01 Wolfgang Sourdeau + + * WOHttpAdaptor/WOHttpTransaction.m @@ -4154,6 +4165,88 @@ Index: sope-appserver/NGObjWeb/DynamicElements/WOHyperlinkInfo.h BOOL sidInUrl; /* 'ivar' associations */ +Index: sope-appserver/NGObjWeb/WOMessage.m +=================================================================== +--- sope-appserver/NGObjWeb/WOMessage.m (revision 1660) ++++ sope-appserver/NGObjWeb/WOMessage.m (working copy) +@@ -182,7 +182,7 @@ + NSString *key; + + keys = [_headers keyEnumerator]; +- while ((key = [keys nextObject])) { ++ while ((key = [[keys nextObject] lowercaseString])) { + id value; + + value = [_headers objectForKey:key]; +@@ -198,34 +198,39 @@ + } + + - (void)setHeader:(NSString *)_header forKey:(NSString *)_key { +- [self->header setObject:[_header stringValue] forKey:_key]; ++ [self->header setObject:[_header stringValue] ++ forKey:[_key lowercaseString]]; + } + - (NSString *)headerForKey:(NSString *)_key { +- return [[self->header objectEnumeratorForKey:_key] nextObject]; ++ return [[self->header objectEnumeratorForKey:[_key lowercaseString]] ++ nextObject]; + } + + - (void)appendHeader:(NSString *)_header forKey:(NSString *)_key { +- [self->header addObject:_header forKey:_key]; ++ [self->header addObject:_header forKey:[_key lowercaseString]]; + } + - (void)appendHeaders:(NSArray *)_headers forKey:(NSString *)_key { +- [self->header addObjects:_headers forKey:_key]; ++ [self->header addObjects:_headers forKey:[_key lowercaseString]]; + } + + - (void)setHeaders:(NSArray *)_headers forKey:(NSString *)_key { + NSEnumerator *e; + id value; ++ NSString *lowerKey; + ++ lowerKey = [_key lowercaseString]; + e = [_headers objectEnumerator]; + +- [self->header removeAllObjectsForKey:_key]; ++ [self->header removeAllObjectsForKey:lowerKey]; + + while ((value = [e nextObject])) +- [self->header addObject:value forKey:_key]; ++ [self->header addObject:value forKey:lowerKey]; + } + - (NSArray *)headersForKey:(NSString *)_key { + NSEnumerator *values; + +- if ((values = [self->header objectEnumeratorForKey:_key])) { ++ if ((values ++ = [self->header objectEnumeratorForKey:[_key lowercaseString]])) { + NSMutableArray *array = nil; + id value = nil; + +@@ -243,17 +248,14 @@ + NSEnumerator *values; + + if ((values = [self->header keyEnumerator])) { +- NSMutableArray *array = nil; ++ NSMutableArray *array; + id name = nil; +- array = [[NSMutableArray alloc] init]; +- ++ array = [NSMutableArray array]; ++ + while ((name = [values nextObject])) + [array addObject:name]; + +- name = [array copy]; +- [array release]; +- +- return [name autorelease]; ++ return array; + } + return nil; + } Index: sope-appserver/NGObjWeb/SoObjects/SoObject.m =================================================================== --- sope-appserver/NGObjWeb/SoObjects/SoObject.m (revision 1660) @@ -4326,15 +4419,25 @@ Index: sope-appserver/NGObjWeb/WOHttpAdaptor/WOHttpTransaction.m doZip = [_response shouldZipResponseToRequest:_request]; -@@ -738,7 +739,10 @@ +@@ -738,7 +739,11 @@ /* add content length header */ - snprintf((char *)buf, sizeof(buf), "%d", [body length]); -+ if ((length = [body length]) == 0) { ++ if ((length = [body length]) == 0 ++ && ![[_response headerForKey: @"content-type"] hasPrefix:@"text/plain"]) { + [_response setHeader:@"text/plain" forKey:@"content-type"]; + } + snprintf((char *)buf, sizeof(buf), "%d", length); t1 = [[NSString alloc] initWithCString:(char *)buf]; [_response setHeader:t1 forKey:@"content-length"]; [t1 release]; t1 = nil; +@@ -766,7 +771,7 @@ + NSString *value; + + if (!hasConnectionHeader) { +- if ([fieldName caseInsensitiveCompare:@"connection"]==NSOrderedSame) ++ if ([fieldName isEqualToString:@"connection"]) + hasConnectionHeader = YES; + } + From 951389b21696d3f50f908cf1c45e451ef25ca7ef Mon Sep 17 00:00:00 2001 From: C Robert Date: Thu, 2 Jul 2009 15:40:45 +0000 Subject: [PATCH 2/6] Monotone-Parent: bde131451e61cf9c2c9b12131c6ea839e28e3bf2 Monotone-Revision: 7acfed7c7506c279e2946ae835c4ef8a1cf52114 Monotone-Author: crobert@inverse.ca Monotone-Date: 2009-07-02T15:40:45 Monotone-Branch: ca.inverse.sogo --- UI/WebServerResources/UIxPreferences.js | 52 +++++++++------------- UI/WebServerResources/ckeditor/ckeditor.js | 2 +- 2 files changed, 23 insertions(+), 31 deletions(-) diff --git a/UI/WebServerResources/UIxPreferences.js b/UI/WebServerResources/UIxPreferences.js index 7d5af1fe9..6c6cee417 100644 --- a/UI/WebServerResources/UIxPreferences.js +++ b/UI/WebServerResources/UIxPreferences.js @@ -4,6 +4,7 @@ function savePreferences(sender) { var sigList = $("signaturePlacementList"); if (sigList) sigList.disabled=false; + $("mainForm").submit(); return false; @@ -22,6 +23,9 @@ function _setupEvents(enable) { widget.stopObserving("change", onChoiceChanged); } } + + $("replyPlacementList").observe ("change", onReplyPlacementListChange); + $("composeMessagesType").observe ("change", onComposeMessagesTypeChange); } function onChoiceChanged(event) { @@ -37,26 +41,6 @@ function initPreferences() { initAdditionalPreferences(); if ($("signature")) { - CKEDITOR.replace('signature', - { - skin: "v2", - height: "90px", - toolbar : - [['Bold', 'Italic', '-', 'Link', - 'Font','FontSize','-','TextColor', - 'BGColor'] - ] - } - ); - - $("replyPlacementList").observe ("change", onReplyPlacementListChange); - onReplyPlacementListChange(); - - $("composeMessagesType").observe ("change", onComposeMessagesTypeChange); - - if (!UserDefaults["ComposeMessagesType"]) - UserDefaults["ComposeMessagesType"] = "text"; - onComposeMessagesTypeChange (); } } @@ -76,19 +60,27 @@ function onComposeMessagesTypeChange () { var textArea = $('signature'); var editor = $('cke_signature'); - if (!editor) { - setTimeout ("onComposeMessagesTypeChange ()", 10); - return; - } - + // Textmode if ($("composeMessagesType").value == 0) { - textArea.style.display = 'block'; - textArea.style.visibility = ''; - editor.style.display = 'none'; + if (editor) { + CKEDITOR.instances.signature.removeListener () + CKEDITOR.instances.signature.destroy (false); + CKEDITOR.instances.signature = null; + delete (CKEDITOR.instances.signature); + } } else { - textArea.style.display = 'none'; - editor.style.display = 'block'; + CKEDITOR.replace('signature', + { + skin: "v2", + height: "90px", + toolbar : + [['Bold', 'Italic', '-', 'Link', + 'Font','FontSize','-','TextColor', + 'BGColor'] + ] + } + ); } } diff --git a/UI/WebServerResources/ckeditor/ckeditor.js b/UI/WebServerResources/ckeditor/ckeditor.js index 0b8f83362..c28887610 100644 --- a/UI/WebServerResources/ckeditor/ckeditor.js +++ b/UI/WebServerResources/ckeditor/ckeditor.js @@ -15,7 +15,7 @@ if(i&&i!=l.type)return l.getNextSourceNode(false,i,j);return l;},getPreviousSour if(!i||!i.is||!i.is('br'))j.append(b.opera?j.getDocument().createText(''):j.getDocument().createElement('br'));},breakParent:function(i){var l=this;var j=new d.range(l.getDocument());j.setStartAfter(l);j.setEndAfter(i);var k=j.extractContents();j.insertNode(l.remove());k.insertAfterNode(l);},contains:c||b.webkit?function(i){var j=this.$;return i.type!=1?j.contains(i.getParent().$):j!=i.$&&j.contains(i.$);}:function(i){return!!(this.$.compareDocumentPosition(i.$)&16);},focus:function(){try{this.$.focus();}catch(i){}},getHtml:function(){return this.$.innerHTML;},getOuterHtml:function(){var j=this;if(j.$.outerHTML)return j.$.outerHTML.replace(/<\?[^>]*>/,'');var i=j.$.ownerDocument.createElement('div');i.appendChild(j.$.cloneNode(true));return i.innerHTML;},setHtml:function(i){return this.$.innerHTML=i;},setText:function(i){h.prototype.setText=this.$.innerText!=undefined?function(j){return this.$.innerText=j;}:function(j){return this.$.textContent=j;};return this.setText(i);},getAttribute:(function(){var i=function(j){return this.$.getAttribute(j,2);};if(c&&(b.ie7Compat||b.ie6Compat))return function(j){var m=this;switch(j){case 'class':j='className';break;case 'tabindex':var k=i.call(m,j);if(k!==0&&m.$.tabIndex===0)k=null;return k;break;case 'checked':return m.$.checked;break;case 'style':var l=m.$.style.cssText;return l.toLowerCase().replace(/\s*(?:;\s*|$)/,';').replace(/([^;])$/,'$1;');}return i.call(m,j);};else return i;})(),getChildren:function(){return new d.nodeList(this.$.childNodes);},getComputedStyle:c?function(i){return this.$.currentStyle[e.cssStyleToDomStyle(i)];}:function(i){return this.getWindow().$.getComputedStyle(this.$,'').getPropertyValue(i);},getDtd:function(){var i=f[this.getName()];this.getDtd=function(){return i;};return i;},getElementsByTag:g.prototype.getElementsByTag,getTabIndex:c?function(){var i=this.$.tabIndex;if(i===0&&!f.$tabIndex[this.getName()]&&parseInt(this.getAttribute('tabindex'),10)!==0)i=-1;return i;}:b.webkit?function(){var i=this.$.tabIndex;if(i==undefined){i=parseInt(this.getAttribute('tabindex'),10);if(isNaN(i))i=-1;}return i;}:function(){return this.$.tabIndex;},getText:function(){return this.$.textContent||this.$.innerText||'';},getWindow:function(){return this.getDocument().getWindow();},getId:function(){return this.$.id||null;},getNameAtt:function(){return this.$.name||null;},getName:function(){var i=this.$.nodeName.toLowerCase();if(c){var j=this.$.scopeName;if(j!='HTML')i=j.toLowerCase()+':'+i;}return(this.getName=function(){return i; })();},getValue:function(){return this.$.value;},getFirst:function(){var i=this.$.firstChild;return i?new d.node(i):null;},getLast:function(i){var j=this.$.lastChild;if(i&&j&&j.nodeType==3&&!e.trim(j.nodeValue))return new d.node(j).getPrevious(true);else return j?new d.node(j):null;},getStyle:function(i){return this.$.style[e.cssStyleToDomStyle(i)];},is:function(){var i=this.getName();for(var j=0;j0)return true;case '_cke_expando':continue;default:if(k.specified)return true;}}return false;}:function(){var i=this.$.attributes;return i.length>1||i.length==1&&i[0].nodeName!='_cke_expando';},hasAttribute:function(i){var j=this.$.attributes.getNamedItem(i);return!!(j&&j.specified);},hide:function(){this.setStyle('display','none');},moveChildren:function(i,j){var k=this.$;i=i.$;if(k==i)return;var l;if(j)while(l=k.lastChild)i.insertBefore(k.removeChild(l),i.firstChild);else while(l=k.firstChild)i.appendChild(k.removeChild(l));},show:function(){this.setStyles({display:'',visibility:''});},setAttribute:(function(){var i=function(j,k){this.$.setAttribute(j,k);return this;};if(c&&(b.ie7Compat||b.ie6Compat))return function(j,k){var l=this;if(j=='class')l.$.className=k;else if(j=='style')l.$.style.cssText=k;else if(j=='tabindex')l.$.tabIndex=k;else if(j=='checked')l.$.checked=k;else i.apply(l,arguments);return l;};else return i;})(),setAttributes:function(i){for(var j in i)this.setAttribute(j,i[j]);return this;},setValue:function(i){this.$.value=i;return this;},removeAttribute:(function(){var i=function(j){this.$.removeAttribute(j);};if(c&&(b.ie7Compat||b.ie6Compat))return function(j){if(j=='class')j='className'; else if(j=='tabindex')j='tabIndex';i.call(this,j);};else return i;})(),removeAttributes:function(i){for(var j=0;j=100?'':'progid:DXImageTransform.Microsoft.Alpha(opacity='+i+')');}else this.setStyle('opacity',i);},unselectable:b.gecko?function(){this.$.style.MozUserSelect='none';}:b.webkit?function(){this.$.style.KhtmlUserSelect='none';}:function(){if(c||b.opera){var i=this.$,j,k=0;i.unselectable='on';while(j=i.all[k++])switch(j.tagName.toLowerCase()){case 'iframe':case 'textarea':case 'input':case 'select':break;default:j.unselectable='on';}}},getPositionedAncestor:function(){var i=this;while(i.getName()!='html'){if(i.getComputedStyle('position')!='static')return i;i=i.getParent();}return null;},getDocumentPosition:function(i){var D=this;var j=0,k=0,l=D.getDocument().getBody(),m=D.getDocument().$.compatMode=='BackCompat',n=D.getDocument();if(document.documentElement.getBoundingClientRect){var o=D.$.getBoundingClientRect(),p=n.$,q=p.documentElement,r=q.clientTop||l.$.clientTop||0,s=q.clientLeft||l.$.clientLeft||0,t=true;if(c){var u=n.getDocumentElement().contains(D),v=n.getBody().contains(D);t=m&&v||!m&&u;}if(t){j=o.left+(!m&&q.scrollLeft||l.$.scrollLeft);j-=s;k=o.top+(!m&&q.scrollTop||l.$.scrollTop);k-=r;}}else{var w=D,x=null,y;while(w&&!(w.getName()=='body'||w.getName()=='html')){j+=w.$.offsetLeft-w.$.scrollLeft;k+=w.$.offsetTop-w.$.scrollTop;if(!w.equals(D)){j+=w.$.clientLeft||0;k+=w.$.clientTop||0;}var z=x;while(z&&!z.equals(w)){j-=z.$.scrollLeft;k-=z.$.scrollTop;z=z.getParent();}x=w;w=(y=w.$.offsetParent)?new h(y):null;}}if(i){var A=D.getWindow(),B=i.getWindow();if(!A.equals(B)&&A.$.frameElement){var C=new h(A.$.frameElement).getDocumentPosition(i);j+=C.x;k+=C.y;}}if(!document.documentElement.getBoundingClientRect)if(b.gecko&&!m){j+=D.$.clientLeft?1:0;k+=D.$.clientTop?1:0;}return{x:j,y:k};},scrollIntoView:function(i){var o=this;var j=o.getWindow(),k=j.getViewPaneSize().height,l=k*-1;if(i)l+=k;else{l+=o.$.offsetHeight||0;l+=parseInt(o.getComputedStyle('marginBottom')||0,10)||0;}var m=o.getDocumentPosition(); -l+=m.y;var n=j.getScrollPosition().y;j.$.scrollTo(0,l>0?l:0);},setState:function(i){var j=this;switch(i){case 1:j.addClass('cke_on');j.removeClass('cke_off');j.removeClass('cke_disabled');break;case 0:j.addClass('cke_disabled');j.removeClass('cke_off');j.removeClass('cke_on');break;default:j.addClass('cke_off');j.removeClass('cke_on');j.removeClass('cke_disabled');break;}},getFrameDocument:function(){var i=this.$;try{i.contentWindow.document;}catch(j){i.src=i.src;if(c&&b.version<7)window.showModalDialog('javascript:document.write("")');}return i&&new g(i.contentWindow.document);},copyAttributes:function(i,j){var p=this;var k=p.$.attributes;j=j||{};for(var l=0;l0&&j)j=j.childNodes[i.shift()];return j?new d.node(j):null;},getChildCount:function(){return this.$.childNodes.length;}});a.command=function(i,j){this.exec=function(k){if(this.state==0)return false;i.focus();return j.exec.call(this,i,k)!==false;};e.extend(this,j,{modes:{wysiwyg:1},state:2});a.event.call(this);};a.command.prototype={enable:function(){var i=this;if(i.state==0)i.setState(!i.preserveState||typeof i.previousState=='undefined'?2:i.previousState);},disable:function(){this.setState(0);},setState:function(i){var j=this;if(j.state==i)return false;j.previousState=j.state;j.state=i;j.fire('state');return true;},toggleState:function(){var i=this;if(i.state==2)i.setState(1);else if(i.state==1)i.setState(2);}};a.event.implementOn(a.command.prototype,true);a.ENTER_P=1;a.ENTER_BR=2;a.ENTER_DIV=3;a.config={customConfig:a.getUrl('config.js'),autoUpdateElement:true,baseHref:'',contentsCss:a.basePath+'contents.css',contentsLangDirection:'ltr',language:'',defaultLanguage:'en',enterMode:1,shiftEnterMode:2,corePlugins:'',docType:'',fullPage:false,height:200,plugins:'about,basicstyles,blockquote,button,clipboard,colorbutton,contextmenu,elementspath,enterkey,entities,filebrowser,find,flash,font,format,forms,horizontalrule,htmldataprocessor,image,indent,justify,keystrokes,link,list,maximize,newpage,pagebreak,pastefromword,pastetext,popup,preview,print,removeformat,resize,save,scayt,smiley,showblocks,sourcearea,stylescombo,table,tabletools,specialchar,tab,templates,toolbar,undo,wysiwygarea,wsc',extraPlugins:'',removePlugins:'',protectedSource:[],tabIndex:0,theme:'default',skin:'kama',width:'100%',baseFloatZIndex:10000}; +l+=m.y;var n=j.getScrollPosition().y;j.$.scrollTo(0,l>0?l:0);},setState:function(i){var j=this;switch(i){case 1:j.addClass('cke_on');j.removeClass('cke_off');j.removeClass('cke_disabled');break;case 0:j.addClass('cke_disabled');j.removeClass('cke_off');j.removeClass('cke_on');break;default:j.addClass('cke_off');j.removeClass('cke_on');j.removeClass('cke_disabled');break;}},getFrameDocument:function(){var i=this.$;try{i.contentWindow.document;}catch(j){i.src=i.src;if(c&&b.version<7)window.showModalDialog('javascript:document.write("")');}return i&&i.contentWindow&&new g(i.contentWindow.document);},copyAttributes:function(i,j){var p=this;var k=p.$.attributes;j=j||{};for(var l=0;l0&&j)j=j.childNodes[i.shift()];return j?new d.node(j):null;},getChildCount:function(){return this.$.childNodes.length;}});a.command=function(i,j){this.exec=function(k){if(this.state==0)return false;i.focus();return j.exec.call(this,i,k)!==false;};e.extend(this,j,{modes:{wysiwyg:1},state:2});a.event.call(this);};a.command.prototype={enable:function(){var i=this;if(i.state==0)i.setState(!i.preserveState||typeof i.previousState=='undefined'?2:i.previousState);},disable:function(){this.setState(0);},setState:function(i){var j=this;if(j.state==i)return false;j.previousState=j.state;j.state=i;j.fire('state');return true;},toggleState:function(){var i=this;if(i.state==2)i.setState(1);else if(i.state==1)i.setState(2);}};a.event.implementOn(a.command.prototype,true);a.ENTER_P=1;a.ENTER_BR=2;a.ENTER_DIV=3;a.config={customConfig:a.getUrl('config.js'),autoUpdateElement:true,baseHref:'',contentsCss:a.basePath+'contents.css',contentsLangDirection:'ltr',language:'',defaultLanguage:'en',enterMode:1,shiftEnterMode:2,corePlugins:'',docType:'',fullPage:false,height:200,plugins:'about,basicstyles,blockquote,button,clipboard,colorbutton,contextmenu,elementspath,enterkey,entities,filebrowser,find,flash,font,format,forms,horizontalrule,htmldataprocessor,image,indent,justify,keystrokes,link,list,maximize,newpage,pagebreak,pastefromword,pastetext,popup,preview,print,removeformat,resize,save,scayt,smiley,showblocks,sourcearea,stylescombo,table,tabletools,specialchar,tab,templates,toolbar,undo,wysiwygarea,wsc',extraPlugins:'',removePlugins:'',protectedSource:[],tabIndex:0,theme:'default',skin:'kama',width:'100%',baseFloatZIndex:10000}; var i=a.config;a.focusManager=function(j){if(j.focusManager)return j.focusManager;this.hasFocus=false;this._={editor:j};return this;};a.focusManager.prototype={focus:function(){var k=this;if(k._.timer)clearTimeout(k._.timer);if(!k.hasFocus){if(a.currentInstance)a.currentInstance.focusManager.forceBlur();var j=k._.editor;j.container.getFirst().addClass('cke_focus');k.hasFocus=true;j.fire('focus');}},blur:function(){var j=this;if(j._.timer)clearTimeout(j._.timer);j._.timer=setTimeout(function(){delete j._.timer;j.forceBlur();},100);},forceBlur:function(){if(this.hasFocus){var j=this._.editor;j.container.getFirst().removeClass('cke_focus');this.hasFocus=false;j.fire('blur');}}};(function(){var j={};a.lang={languages:{af:1,ar:1,bg:1,bn:1,bs:1,ca:1,cs:1,da:1,de:1,el:1,'en-au':1,'en-ca':1,'en-uk':1,en:1,eo:1,es:1,et:1,eu:1,fa:1,fi:1,fo:1,'fr-ca':1,fr:1,gl:1,gu:1,he:1,hi:1,hr:1,hu:1,is:1,it:1,ja:1,km:1,ko:1,lt:1,lv:1,mn:1,ms:1,nb:1,nl:1,no:1,pl:1,'pt-br':1,pt:1,ro:1,ru:1,sk:1,sl:1,'sr-latn':1,sr:1,sv:1,th:1,tr:1,uk:1,vi:1,'zh-cn':1,zh:1},load:function(k,l,m){if(!k)k=this.detect(l);if(!this[k])a.scriptLoader.load(a.getUrl('lang/'+k+'.js'),function(){m(k,this[k]);},this);else m(k,this[k]);},detect:function(k){var l=this.languages,m=(navigator.userLanguage||navigator.language).toLowerCase().match(/([a-z]+)(?:-([a-z]+))?/),n=m[1],o=m[2];if(l[n+'-'+o])n=n+'-'+o;else if(!l[n])n=null;a.lang.detect=n?function(){return n;}:function(p){return p;};return n||k;}};})();a.scriptLoader=(function(){var j={},k={};return{load:function(l,m,n,o){var p=typeof l=='string';if(p)l=[l];if(!n)n=a;var q=l.length,r=[],s=[],t=function(y){if(m)if(p)m.call(n,y);else m.call(n,r,s);};if(q===0){t(true);return;}var u=function(y,z){(z?r:s).push(y);if(--q<=0)t(z);},v=function(y,z){j[y]=1;var A=k[y];delete k[y];for(var B=0;B1)return;var A=new h('script');A.setAttributes({type:'text/javascript',src:y});if(m)if(c)A.$.onreadystatechange=function(){if(A.$.readyState=='loaded'||A.$.readyState=='complete'){A.$.onreadystatechange=null;v(y,true);}};else{A.$.onload=function(){setTimeout(function(){v(y,true);},0);};A.$.onerror=function(){v(y,false);};}A.appendTo(a.document.getHead());};for(var x=0;x0){s(t);a.imageCacher.load(t,function(){l[o]=1;n(o,p,q);});return;}l[o]=1;}p=r[p];var u=!p||!!p._isLoaded;if(u)q&&q();else{var v=p._pending||(p._pending=[]);v.push(q);if(v.length>1)return;var w=!p.css||!p.css.length,x=!p.js||!p.js.length,y=function(){if(w&&x){p._isLoaded=1;for(var A=0;A=0?x.langCode:J[0];if(!I.lang[L])G.push(a.getUrl(K+'lang/'+L+'.js'));else{e.extend(x.lang,I.lang[L]);L=null;}}F.push(L);E.push(I);}a.scriptLoader.load(G,function(){var M=['beforeInit','init','afterInit']; From f36a8dd18513de2386fd13eda2277917b94c2ed9 Mon Sep 17 00:00:00 2001 From: C Robert Date: Thu, 2 Jul 2009 17:06:21 +0000 Subject: [PATCH 3/6] reindent Monotone-Parent: d4edd90811440e920dfccfcb2c0e4305732b5cfc Monotone-Revision: 158571d4f7e1fd1da2b47567f93275d509fff71d Monotone-Author: crobert@inverse.ca Monotone-Date: 2009-07-02T17:06:21 Monotone-Branch: ca.inverse.sogo --- UI/MailerUI/UIxMailFolderActions.m | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/UI/MailerUI/UIxMailFolderActions.m b/UI/MailerUI/UIxMailFolderActions.m index 81a056d1c..05a50745e 100644 --- a/UI/MailerUI/UIxMailFolderActions.m +++ b/UI/MailerUI/UIxMailFolderActions.m @@ -62,12 +62,12 @@ connection = [co imap4Connection]; error = [connection createMailbox: folderName atURL: [co imap4URL]]; if (error) - { - response = [self responseWithStatus: 500]; - [response appendContentString: @"Unable to create folder."]; - } + { + response = [self responseWithStatus: 500]; + [response appendContentString: @"Unable to create folder."]; + } else - response = [self responseWith204]; + response = [self responseWith204]; } else { From af20a0658f532466ea8e24dd4e04f5a7e6728bf2 Mon Sep 17 00:00:00 2001 From: C Robert Date: Thu, 2 Jul 2009 17:21:07 +0000 Subject: [PATCH 4/6] Monotone-Parent: 158571d4f7e1fd1da2b47567f93275d509fff71d Monotone-Revision: 0f0cf5779a3cca5a823d91514f517fcd43c8eb4c Monotone-Author: crobert@inverse.ca Monotone-Date: 2009-07-02T17:21:07 Monotone-Branch: ca.inverse.sogo --- ChangeLog | 5 +++++ UI/MailerUI/UIxMailFolderActions.m | 9 +++++++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 1d2532981..3d095d57e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2009-07-02 Cyril Robert + + * UI/MailerUI/UIxMailFolderActions.m: Added auto-subscribe on imap folder + creation. + 2009-07-01 Wolfgang Sourdeau * SoObjects/Appointments/SOGoAppointmentFolder.m diff --git a/UI/MailerUI/UIxMailFolderActions.m b/UI/MailerUI/UIxMailFolderActions.m index 05a50745e..7320dd1e4 100644 --- a/UI/MailerUI/UIxMailFolderActions.m +++ b/UI/MailerUI/UIxMailFolderActions.m @@ -52,7 +52,7 @@ WOResponse *response; NGImap4Connection *connection; NSException *error; - NSString *folderName; + NSString *folderName, *path; co = [self clientObject]; @@ -67,7 +67,12 @@ [response appendContentString: @"Unable to create folder."]; } else - response = [self responseWith204]; + { + path = [NSString stringWithFormat: @"%@%@", + [[co imap4URL] path], folderName]; + [[connection client] subscribe: path]; + response = [self responseWith204]; + } } else { From adc9a7e486d04351ffd0bb7868751d971fd954da Mon Sep 17 00:00:00 2001 From: Ludovic Marcotte Date: Thu, 2 Jul 2009 17:29:40 +0000 Subject: [PATCH 5/6] Updated NEWS file Monotone-Parent: 0f0cf5779a3cca5a823d91514f517fcd43c8eb4c Monotone-Revision: 2561a08cc5b89c3a3a7f29f655b0f7816645867a Monotone-Author: ludovic@Sophos.ca Monotone-Date: 2009-07-02T17:29:40 Monotone-Branch: ca.inverse.sogo --- NEWS | 1 + 1 file changed, 1 insertion(+) diff --git a/NEWS b/NEWS index 172a41ad3..933b2eef8 100644 --- a/NEWS +++ b/NEWS @@ -8,6 +8,7 @@ - added drag and drop in the addressbook and mail modules - improved the attendees modification dialog by implementing slots management - added the capability to display the size of messages in the mail module +- added the capability of limiting the number of returned events from DAV requests 1.0-20090605 (1.0.2) -------------------- From 2bfde9c350e0893a66f78e9917199c199431a69a Mon Sep 17 00:00:00 2001 From: Ludovic Marcotte Date: Thu, 2 Jul 2009 17:30:27 +0000 Subject: [PATCH 6/6] Updated again the NEWS file Monotone-Parent: 2561a08cc5b89c3a3a7f29f655b0f7816645867a Monotone-Revision: a5d600790eb0a570287e3f58d9d92d701c3f4f3a Monotone-Author: ludovic@Sophos.ca Monotone-Date: 2009-07-02T17:30:27 Monotone-Branch: ca.inverse.sogo --- NEWS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 933b2eef8..4cf93f666 100644 --- a/NEWS +++ b/NEWS @@ -6,7 +6,7 @@ - greatly reduced the number of SQL requests performed in many situations - added HTML composition in the web mail module - added drag and drop in the addressbook and mail modules -- improved the attendees modification dialog by implementing slots management +- improved the attendees modification dialog by implementing slots management and zooming - added the capability to display the size of messages in the mail module - added the capability of limiting the number of returned events from DAV requests