]> err.no Git - scalable-opengroupware.org/commitdiff
work on filters
authorhelge <helge@d1b88da0-ebda-0310-925b-ed51d893ca5b>
Sat, 27 Nov 2004 23:22:56 +0000 (23:22 +0000)
committerhelge <helge@d1b88da0-ebda-0310-925b-ed51d893ca5b>
Sat, 27 Nov 2004 23:22:56 +0000 (23:22 +0000)
git-svn-id: http://svn.opengroupware.org/SOGo/trunk@456 d1b88da0-ebda-0310-925b-ed51d893ca5b

SOGo/UI/Mailer/ChangeLog
SOGo/UI/Mailer/GNUmakefile
SOGo/UI/Mailer/UIxFilterList.m [new file with mode: 0644]
SOGo/UI/Mailer/UIxFilterList.wox [new file with mode: 0644]
SOGo/UI/Mailer/UIxMailEditorAttach.m
SOGo/UI/Mailer/UIxMailListView.m
SOGo/UI/Mailer/Version
SOGo/UI/Mailer/product.plist

index 56e999c3c1cb6669fbaa60b073cfe2c123413fbf..8a14bd97172ad80ba61de2bef516c3af55fa43e3 100644 (file)
@@ -1,5 +1,11 @@
 2004-11-27  Helge Hess  <helge.hess@skyrix.com>
 
+       * v0.9.65
+       
+       * added first (empty) version of filter list page
+       
+       * UIxMailEditorAttach.m: fixed a warning
+
        * UIxMailAccountView.wox, product.plist: cleaned up account page (links
          work now), added a compose button (v0.9.64)
 
index 09cd5ec0a7c1bf96f0d6071604e50d7245209c35..cbeac454bb6916c689b6cab4b6eb4255b741db84 100644 (file)
@@ -40,6 +40,8 @@ MailerUI_OBJC_FILES += \
        UIxMailPartImageViewer.m        \
        UIxMailPartMixedViewer.m        \
        UIxMailPartAlternativeViewer.m  \
+       \
+       UIxFilterList.m                 \
 
 MailerUI_RESOURCE_FILES += \
        Version                 \
@@ -66,6 +68,8 @@ MailerUI_RESOURCE_FILES += \
        UIxMailPartMixedViewer.wox      \
        UIxMailPartImageViewer.wox      \
        UIxMailPartAlternativeViewer.wox\
+       \
+       UIxFilterList.wox               \
 
 MailerUI_RESOURCE_FILES += \
        uix.css                 \
diff --git a/SOGo/UI/Mailer/UIxFilterList.m b/SOGo/UI/Mailer/UIxFilterList.m
new file mode 100644 (file)
index 0000000..ffea50a
--- /dev/null
@@ -0,0 +1,83 @@
+/*
+  Copyright (C) 2004 SKYRIX Software AG
+
+  This file is part of OpenGroupware.org.
+
+  OGo is free software; you can redistribute it and/or modify it under
+  the terms of the GNU Lesser General Public License as published by the
+  Free Software Foundation; either version 2, or (at your option) any
+  later version.
+
+  OGo 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 Lesser General Public
+  License for more details.
+
+  You should have received a copy of the GNU Lesser General Public
+  License along with OGo; see the file COPYING.  If not, write to the
+  Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+  02111-1307, USA.
+*/
+
+#include <SOGoUI/UIxComponent.h>
+
+/*
+  UIxFilterList
+
+  This component shows a list of filter scripts and is (usually) attached to
+  a SOGoSieveScriptsFolder object.
+*/
+
+@interface UIxFilterList : UIxComponent
+{
+  NSArray *filters;
+  id filter;
+}
+
+@end
+
+#include "common.h"
+#include <SOGo/SoObjects/Mailer/SOGoMailFolder.h>
+#include <SOGo/SoObjects/Mailer/SOGoMailObject.h>
+
+@implementation UIxFilterList
+
+- (void)dealloc {
+  [self->filter  release];
+  [self->filters release];
+  [super dealloc];
+}
+
+/* notifications */
+
+- (void)sleep {
+  [self->filter  release]; self->filter  = nil;
+  [self->filters release]; self->filters = nil;
+  [super sleep];
+}
+
+/* accessors */
+
+- (void)setFilter:(id)_msg {
+  ASSIGN(self->filter, _msg);
+}
+- (id)filter {
+  return self->filter;
+}
+
+- (NSArray *)filters {
+  return self->filters;
+}
+
+/* actions */
+
+- (id)defaultAction {
+  // TODO: remove log
+  [self logWithFormat:@"default action ..."];
+
+  [self logWithFormat:@"should fetch scripts in: %@", [self clientObject]];
+
+  return self;
+}
+
+@end /* UIxFilterList */
diff --git a/SOGo/UI/Mailer/UIxFilterList.wox b/SOGo/UI/Mailer/UIxFilterList.wox
new file mode 100644 (file)
index 0000000..9f2deb8
--- /dev/null
@@ -0,0 +1,50 @@
+<?xml version='1.0' standalone='yes'?>
+<var:component
+  xmlns="http://www.w3.org/1999/xhtml"
+  xmlns:var="http://www.skyrix.com/od/binding"
+  xmlns:const="http://www.skyrix.com/od/constant"
+  xmlns:uix="OGo:uix"
+  xmlns:rsrc="OGo:url"
+  xmlns:label="OGo:label"
+  className="UIxMailMainFrame"
+  title="name"
+>
+
+  <div class="titlediv" style="white-space: nowrap;">
+    Server Side Filter Scripts
+  </div>
+
+  <div class="embedwhite_out">
+    <div class="embedwhite_in">
+
+      <table border="0" width="100%" cellspacing="0" cellpadding="1">
+        <tr class="tableview">
+          <td class="tbtv_headercell" width="17">
+            <var:entity const:name="nbsp" />
+          </td>
+          <td class="tbtv_headercell">
+            Filters
+          </td>
+        </tr>
+        <tr class="tableview">
+          <td colspan="6" class="tbtv_navcell" align="right">
+            <var:string value="filters.count" />
+            <var:string label:value="filters" />
+          </td>
+        </tr>
+       
+        <var:foreach list="filters" item="filter">
+          <tr class="tableview" var:id="msgRowID">
+            <td>
+              <a href="#" var:onclick="clickedFilterJS">
+                <var:string value="filter" />
+              </a>
+            </td>
+          </tr>
+        </var:foreach>
+      </table>
+
+    </div>
+  </div>
+
+</var:component>
index d20c27197f063bc6095b5a600b1a48658da3f314..88c33e763b471e9daef5053c3cb5c041e93bddc5 100644 (file)
   }
   
   if ((_name = [self fixupAttachmentName:_name]) == nil)
-    return nil;
+    return NO;
   
   // TODO: add size limit?
   return [[self clientObject] saveAttachment:_data withName:_name];
index 8c62a1891324ca81e36479847c0bfd8bc619c5d2..4b58be58c1f8678686cdd22980d98853a643ec35 100644 (file)
@@ -18,7 +18,6 @@
   Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
   02111-1307, USA.
 */
-// $Id$
 
 #include <SOGoUI/UIxComponent.h>
 
@@ -46,7 +45,6 @@
 @end
 
 #include "common.h"
-#include <NGImap4/NGImap4Client.h>
 #include <SOGo/SoObjects/Mailer/SOGoMailFolder.h>
 #include <SOGo/SoObjects/Mailer/SOGoMailObject.h>
 
@@ -363,6 +361,7 @@ static int attachmentFlagSize = 8096;
 /* actions */
 
 - (id)defaultAction {
+  // TODO: remove log
   [self logWithFormat:@"default action ..."];
   self->firstMessageNumber = 
     [[[[self context] request] formValueForKey:@"idx"] intValue];
index 152ef4e0d449293f856ba913634962fc94029d6a..d67abc490beab3b63b7dad99c488d09a841697d7 100644 (file)
@@ -1,7 +1,7 @@
-# $Id$
+# version file
 
-SUBMINOR_VERSION:=64
+SUBMINOR_VERSION:=65
 
-# v0.9.50 requires NGMime   v4.3.190
-# v0.9.43 requires NGObjWeb v4.3.73
-# v0.9.42 requires NGObjWeb v4.3.72
+# v0.9.50 requires libNGMime   v4.3.190
+# v0.9.43 requires libNGObjWeb v4.3.73
+# v0.9.42 requires libNGObjWeb v4.3.72
index 9ae27d8c9add333d1260f1f4476095ef51427488..cc97dcbb0af3765933b6d5c3c8395f8c10410152 100644 (file)
@@ -1,5 +1,5 @@
 {
-  requires = ( MAIN, CommonUI, Mailer );
+  requires = ( MAIN, CommonUI, Mailer, Sieve );
 
   publicResources = (
     "uix.css",
         };
       };
     };
+
+    /* Sieve */
+    
+    SOGoSieveScriptsFolder = {
+      slots = {
+        toolbar = {
+          protectedBy = "View";
+          value = ( /* the toolbar groups */
+            ( /* first group */
+              {
+                link  = "getMail";
+                cssClass = "tbicon_getmail"; label = "Get Mail";
+              },
+              {
+                link     = "#"; // "compose"; // target = "_blank";
+                onclick  = "clickedNewFilter(this);return false;";
+                cssClass = "tbicon_compose"; label = "New Filter";
+              },
+            ),
+            ( /* second group
+              { link = "#"; 
+                cssClass = "tbicon_delete"; label = "Delete"; },*/
+            ),
+          );
+        };
+      };
+      methods = {
+        view = {
+          protectedBy = "View";
+          pageName    = "UIxFilterList"; 
+        };
+      };
+    };
+    SOGoSieveScriptObject = {
+    };
   };
 }