[gimp] plug-ins/imagemap: Kill #define COMMAND_PROTO



commit 136499d1ae5e86dbbb18badb4c4cecf711468c9c
Author: Martin Nordholts <martinn src gnome org>
Date:   Fri Sep 3 09:04:00 2010 +0200

    plug-ins/imagemap: Kill #define COMMAND_PROTO
    
    Kill #define COMMAND_PROTO and move its definition to the only client,
    and get rid of warnings about defined functions not being used.

 plug-ins/imagemap/imap_cmd_move_sash.c |    7 ++++---
 plug-ins/imagemap/imap_command.h       |    6 ------
 2 files changed, 4 insertions(+), 9 deletions(-)
---
diff --git a/plug-ins/imagemap/imap_cmd_move_sash.c b/plug-ins/imagemap/imap_cmd_move_sash.c
index f312528..c7b7a25 100644
--- a/plug-ins/imagemap/imap_cmd_move_sash.c
+++ b/plug-ins/imagemap/imap_cmd_move_sash.c
@@ -29,13 +29,14 @@
 
 #include "libgimp/stdplugins-intl.h"
 
-COMMAND_PROTO(move_sash_command);
+static void move_sash_command_destruct(Command_t *command);
+static CmdExecuteValue_t move_sash_command_execute(Command_t *command);
 
 static CommandClass_t move_sash_command_class = {
    move_sash_command_destruct,
    move_sash_command_execute,
-   NULL, 			/* move_sash_command_undo */
-   NULL				/* move_sash_command_redo */
+   NULL /*undo*/,
+   NULL /*redo*/
 };
 
 typedef struct {
diff --git a/plug-ins/imagemap/imap_command.h b/plug-ins/imagemap/imap_command.h
index 7b07bca..7397dee 100644
--- a/plug-ins/imagemap/imap_command.h
+++ b/plug-ins/imagemap/imap_command.h
@@ -33,12 +33,6 @@ typedef struct CommandList_t CommandList_t;
 
 typedef enum {CMD_APPEND, CMD_DESTRUCT, CMD_IGNORE} CmdExecuteValue_t;
 
-#define COMMAND_PROTO(class) \
-static void class##_destruct(Command_t *command); \
-static CmdExecuteValue_t class##_execute(Command_t *command); \
-static void class##_undo(Command_t *command); \
-static void class##_redo(Command_t *command)
-
 struct CommandClass_t {
    void (*destruct)(Command_t*);
    CmdExecuteValue_t (*execute)(Command_t*);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]