]> err.no Git - scalable-opengroupware.org/commitdiff
work on mailer UI
authorhelge <helge@d1b88da0-ebda-0310-925b-ed51d893ca5b>
Tue, 12 Oct 2004 11:23:37 +0000 (11:23 +0000)
committerhelge <helge@d1b88da0-ebda-0310-925b-ed51d893ca5b>
Tue, 12 Oct 2004 11:23:37 +0000 (11:23 +0000)
git-svn-id: http://svn.opengroupware.org/SOGo/trunk@382 d1b88da0-ebda-0310-925b-ed51d893ca5b

SOGo/UI/Mailer/ChangeLog
SOGo/UI/Mailer/UIxMailEditor.wox
SOGo/UI/Mailer/UIxMailMainFrame.wox
SOGo/UI/Mailer/Version
SOGo/UI/Mailer/mailer.js
SOGo/UI/Mailer/product.plist

index ec090689b1057b212a91c5ba082f880eac2efcd5..d2b497f8ad9e208a6eff43a398f0b54c9eb288a4 100644 (file)
@@ -1,3 +1,11 @@
+2004-10-12  Helge Hess  <helge.hess@opengroupware.org>
+
+       * v0.9.31
+
+       * mailer.js: prepared JavaScript functions for editor
+
+       * UIxMailMainFrame.wox: embed all content in a form called 'pageform'
+
 2004-10-11  Helge Hess  <helge.hess@opengroupware.org>
 
        * v0.9.30
index f5c758c5ef9ba5ec5663c9423d6453fedb140803..7c6f291fdc31807d9efcbb625b0ef8ba2b17ffea 100644 (file)
@@ -11,6 +11,7 @@
   const:hideFolderTree="1"
 >
  <div id="compose_panel">
+
 <!-- we don't support multiple accounts ...
   <div id="compose_fromline">
     From:
index ccd85102b054e90956301185a9b04fce1a8c7b01..36265f3ec6e15fd4faa95c1503848b1500bea513 100644 (file)
   </head>
 
   <body style="background-color: #D4D0C8;">
+   <!-- 
+     Note: the 'href' is required, otherwise an element-id will get created
+     -->
+   <form name="pageform" href="#" sidInUrl="NO">
     <table border="0" width="100%" cellspacing="0" cellpadding="2"
            style="position: fixed; height: 48px; z-index: 100;"
     >
         </tr>
       </table>
     </var:if>
+   </form>
   </body>
 </html>
index d5906740cda9371acdbbdbd031e924c2a75dadff..7fd6910f13bcaf504b8452bd7ef2569adf17a4bf 100644 (file)
@@ -1,3 +1,3 @@
 # $Id$
 
-SUBMINOR_VERSION:=30
+SUBMINOR_VERSION:=31
index 6236aa3d4ef9610df907bfd0fce1c95cd703509a..d4c01cef0547a640167735e0fda57d279bc71430 100644 (file)
@@ -1,19 +1,10 @@
 /* JavaScript for SOGo Mailer */
 
 /*
-  window.open('url to open','window name','attribute1,attribute2')
-  window.open('http://www.pageresource.com/jscript/jex5.htm','mywindow',
-              'width=400,height=200')
-
-  width,height
-  resizable=yes or no
-  scrollbars=yes or no
-  toolbar=yes or no
-  location=yes or no
-  directories=yes or no
-  status=yes or no
-  menubar=yes or no
-  copyhistory=yes or no
+  Window Properties:
+    width, height
+    bool: resizable, scrollbars, toolbar, location, directories, status,
+          menubar, copyhistory
 */
 
 function clickedUid(sender, msguid) {
@@ -21,7 +12,7 @@ function clickedUid(sender, msguid) {
   
   urlstr = msguid + "/view?markread=1";
   window.open(urlstr, "SOGo_msg_" + msguid,
-             "width=680,height=480,resizable=1,scrollbars=1,toolbar=0," +
+             "width=640,height=480,resizable=1,scrollbars=1,toolbar=0," +
              "location=0,directories=0,status=0,menubar=0,copyhistory=0")
   return true;
 }
@@ -51,3 +42,37 @@ function clickedCompose(sender) {
              "location=0,directories=0,status=0,menubar=0,copyhistory=0");
   return false; /* stop following the link */
 }
+
+
+/* mail editor */
+
+function validateEditorInput(sender) {
+  var errortext = "";
+  var field;
+  
+  field = document.pageform.subject;
+  if (field.value == "")
+    errortext = errortext + "Missing Subject\n";
+  
+  if (errortext.length > 0) {
+    alert("validation failed:\n" + errortext);
+    return false;
+  }
+  return true;
+}
+
+function clickedEditorSend(sender) {
+  if (!validateEditorInput(sender))
+    return false;
+  
+  alert("SEND");
+  // if everything is ok, close the window
+}
+
+function clickedEditorAttach(sender) {
+  alert("ATTACH");
+}
+
+function clickedEditorSave(sender) {
+  alert("SAVE");
+}
index 9c3382c3d95fc199cbb66dc985496ce736bee847..3bba8b1ecdc100d3843a623e2940f99b81c4ce99 100644 (file)
 
     SOGoDraftObject = {
       slots = {
-        toolbar = { /* need the 'send' toolbar here */
+        toolbar = {
           protectedBy = "View";
           value = ( /* the toolbar groups */
             ( /* first group */
-              { link  = "send";
-                cssClass = "tbicon_send"; 
-                label = "Send"; },
+              { link  = "#";
+                onclick  = "clickedEditorSend(this);return false;";
+                cssClass = "tbicon_send"; label = "Send"; },
               { link  = "contacts"; target = "addressbook";
                 cssClass = "tbicon_addressbook"; label = "Contacts"; },
-              { link  = "attach"; 
+              { link  = "#"; 
+                onclick  = "clickedEditorAttach(this);return false;";
                 cssClass = "tbicon_attach"; label = "Attach"; },
-              { link  = "save"; 
+              { link  = "#"; 
+                onclick  = "clickedEditorSave(this);return false;";
                 cssClass = "tbicon_save"; label = "Save"; },
             )
           );