]> code.citadel.org Git - citadel.git/blobdiff - webcit-ng/server/webcit.h
Obsolete sys/time.h and HAVE_TIME_WITH_SYS_TIME
[citadel.git] / webcit-ng / server / webcit.h
index d8321b49f0586d673d54dc2c6ad6a76ed3930bc6..d06e3800c7117205be8c9868f96ac6c2be4f2c16 100644 (file)
@@ -1,6 +1,6 @@
 // webcit.h - "header of headers"
 //
-// Copyright (c) 1996-2022 by the citadel.org team
+// Copyright (c) 1996-2023 by the citadel.org team
 //
 // This program is open source software.  You can redistribute it and/or
 // modify it under the terms of the GNU General Public License, version 3.
@@ -22,7 +22,7 @@
 #include <netdb.h>
 #include <sys/un.h>
 #include <sys/poll.h>
-#include <sys/time.h>
+#include <time.h>
 #include <string.h>
 #include <pwd.h>
 #include <errno.h>
@@ -83,8 +83,9 @@ struct ctdlsession {
        char room[128];                         // What room we are currently in
        int room_current_view;
        int room_default_view;
+       int is_trash_folder;                    // nonzero if this room is the user's Trash folder
        int is_room_aide;                       // nonzero if the user has aide rights to THIS room
-       int can_delete_messages;                // nonzeri if the user is permitted to delete messages in THIS room
+       int can_delete_messages;                // nonzero if the user is permitted to delete messages in THIS room
        long last_seen;
        int new_messages;
        int total_messages;
@@ -118,6 +119,9 @@ enum {
 #define DEVELOPER_ID           0
 #define CLIENT_ID              4
 #define TARGET                 "webcit02"      /* Window target for inline URL's */
+#define ROOMNAMELEN            128             // The size of a roomname string
+#define        DAV_MOVE                0               // MOVE=0 COPY=1 don't change these!
+#define DAV_COPY               1               // they are the values used in the Citadel Server MOVE command
 
 void worker_entry(int *);
 void perform_one_http_transaction(struct client_handle *ch);
@@ -147,6 +151,7 @@ void ctdl_delete_msgs(struct ctdlsession *c, long *msgnums, int num_msgs);
 void dav_delete_message(struct http_transaction *h, struct ctdlsession *c, long msgnum);
 void dav_get_message(struct http_transaction *h, struct ctdlsession *c, long msgnum);
 void dav_put_message(struct http_transaction *h, struct ctdlsession *c, char *euid, long old_msgnum);
+void dav_move_or_copy_message(struct http_transaction *h, struct ctdlsession *c, long msgnum, int move_or_copy);
 ssize_t ctdl_write(struct ctdlsession *ctdl, const void *buf, size_t count);
 int login_to_citadel(struct ctdlsession *c, char *auth, char *resultbuf);
 StrBuf *ctdl_readtextmsg(struct ctdlsession *ctdl);