Enlightenment CVS committal
Author : lordchaos
Project : e17
Module : apps/evfs
Dir : e17/apps/evfs/src/include
Modified Files:
evfs.h evfs_event_helper.h evfs_io.h evfs_macros.h
Log Message:
Pass the command we're dealing with back to the client
===================================================================
RCS file: /cvsroot/enlightenment/e17/apps/evfs/src/include/evfs.h,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -3 -r1.12 -r1.13
--- evfs.h 7 Oct 2005 11:01:27 -0000 1.12
+++ evfs.h 8 Oct 2005 01:53:25 -0000 1.13
@@ -132,13 +132,15 @@
typedef enum evfs_eventpart {
EVFS_EV_PART_TYPE = 1,
EVFS_EV_PART_SUB_TYPE = 2,
-
EVFS_EV_PART_FILE_MONITOR_TYPE = 3,
EVFS_EV_PART_FILE_MONITOR_FILENAME = 4,
-
EVFS_EV_PART_DATA = 5,
-
EVFS_EV_PART_STAT_SIZE = 6,
+
+ EVFS_COMMAND_TYPE = 7,
+ EVFS_FILE_REFERENCE = 8,
+ EVFS_COMMAND_END = 9,
+
EVFS_EV_PART_END = 1000
} evfs_eventpart;
@@ -152,6 +154,7 @@
typedef struct evfs_event_id_notify evfs_event_id_notify;
struct evfs_event_id_notify {
evfs_eventtype type;
+ evfs_command resp_command;
int id;
};
@@ -159,8 +162,9 @@
typedef struct evfs_event_file_monitor evfs_event_file_monitor;
struct evfs_event_file_monitor {
evfs_eventtype type;
+ evfs_command resp_command;
+
evfs_file_monitor_type fileev_type;
-
char* filename;
int filename_len;
};
@@ -169,6 +173,9 @@
typedef struct evfs_event_stat evfs_event_stat;
struct evfs_event_stat {
evfs_eventtype type;
+ evfs_command resp_command;
+
+
struct stat stat_obj;
};
@@ -176,6 +183,7 @@
typedef union evfs_event {
evfs_eventtype type;
+ evfs_command resp_command;
evfs_event_id_notify id_notify;
evfs_event_file_monitor file_monitor;
@@ -187,7 +195,7 @@
struct evfs_connection {
Ecore_Ipc_Server* server;
unsigned long id;
- void (*callback_func)(void* data);
+ void (*callback_func)(evfs_event* data);
evfs_event* prog_event;
};
===================================================================
RCS file: /cvsroot/enlightenment/e17/apps/evfs/src/include/evfs_event_helper.h,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -3 -r1.3 -r1.4
--- evfs_event_helper.h 5 Oct 2005 03:50:33 -0000 1.3
+++ evfs_event_helper.h 8 Oct 2005 01:53:25 -0000 1.4
@@ -3,4 +3,4 @@
#include <unistd.h>
void evfs_file_monitor_event_create(evfs_client* client, int type, const char*
path);
-void evfs_stat_event_create(evfs_client* client, struct stat* stat_obj);
+void evfs_stat_event_create(evfs_client* client, evfs_command* command, struct
stat* stat_obj);
===================================================================
RCS file: /cvsroot/enlightenment/e17/apps/evfs/src/include/evfs_io.h,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -3 -r1.5 -r1.6
--- evfs_io.h 19 Aug 2005 12:15:12 -0000 1.5
+++ evfs_io.h 8 Oct 2005 01:53:25 -0000 1.6
@@ -25,22 +25,24 @@
EVFS_EVENT
} EVFS_IO_TYPE;
-typedef enum EVFS_IO_PART_TYPE {
+/*typedef enum EVFS_IO_PART_TYPE {
EVFS_COMMAND_TYPE,
EVFS_FILE_REFERENCE,
EVFS_COMMAND_END
-} EVFS_IO_PART_TYPE;
+} EVFS_IO_PART_TYPE;*/
ecore_ipc_message* ecore_ipc_message_new(int major, int minor, int ref, int
ref_to, int response, void* data, int len);
int evfs_process_incoming_command(evfs_command* command, ecore_ipc_message*
message);
void evfs_write_command_end(evfs_connection* conn);
void evfs_write_command(evfs_connection* conn, evfs_command* command);
+void evfs_write_command_client(evfs_client* client, evfs_command* command);
void evfs_write_file_command(evfs_connection* conn, evfs_command* command);
+void evfs_write_file_command_client(evfs_client* client, evfs_command*
command);
void evfs_event_client_id_notify(evfs_client* client);
void evfs_write_file_command(evfs_connection* conn, evfs_command* command);
void evfs_write_ecore_ipc_client_message(Ecore_Ipc_Client* client,
ecore_ipc_message* msg);
void evfs_write_ecore_ipc_server_message(Ecore_Ipc_Server* server,
ecore_ipc_message* msg);
-void evfs_write_event(evfs_client* client, evfs_event* event);
+void evfs_write_event(evfs_client* client, evfs_command* command, evfs_event*
event);
int evfs_read_event(evfs_event* event, ecore_ipc_message* msg);
===================================================================
RCS file: /cvsroot/enlightenment/e17/apps/evfs/src/include/evfs_macros.h,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -3 -r1.3 -r1.4
--- evfs_macros.h 19 Aug 2005 12:15:12 -0000 1.3
+++ evfs_macros.h 8 Oct 2005 01:53:25 -0000 1.4
@@ -1,7 +1,7 @@
#ifndef __EVFS_MACROS_H_
#define __EVFS_MACROS_H_
-#define NEW(X) ((X*) malloc(sizeof(X)))
+#define NEW(X) ((X*) calloc(sizeof(X), 1))
#define LOCK(X) (pthread_mutex_lock(X))
#define UNLOCK(X) (pthread_mutex_unlock(X))
-------------------------------------------------------
This SF.Net email is sponsored by:
Power Architecture Resource Center: Free content, downloads, discussions,
and more. http://solutions.newsforge.com/ibmarch.tmpl
_______________________________________________
enlightenment-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs