Create a header file dockedapp.h to address a long-standing warning
which pollutes the compilation output with --enable-silent-rules:

Making all in src
  CC     dock.o
dock.c: In function ‘wDockDetach’:
dock.c:2118:3: warning: call to function ‘DestroyDockAppSettingsPanel’ without 
a real prototype [-Wunprototyped-calls]
dock.c:65:13: note: ‘DestroyDockAppSettingsPanel’ was declared here
  CCLD   wmaker

Signed-off-by: Carlos R. Mafra <[email protected]>
---
 src/dock.c      |    5 +---
 src/dockedapp.c |   40 +--------------------------------
 src/dockedapp.h |   66 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 68 insertions(+), 43 deletions(-)
 create mode 100644 src/dockedapp.h

diff --git a/src/dock.c b/src/dock.c
index 0332d65..193bc01 100644
--- a/src/dock.c
+++ b/src/dock.c
@@ -43,6 +43,7 @@
 #include "actions.h"
 #include "stacking.h"
 #include "dock.h"
+#include "dockedapp.h"
 #include "dialog.h"
 #include "funcs.h"
 #include "properties.h"
@@ -60,10 +61,6 @@
 #define CLIP_FORWARD      2
 
 /**** Global variables ****/
-
-/* in dockedapp.c */
-extern void DestroyDockAppSettingsPanel();
-extern void ShowDockAppSettingsPanel(WAppIcon * aicon);
 extern Cursor wCursor[WCUR_LAST];
 extern WPreferences wPreferences;
 extern XContext wWinContext;
diff --git a/src/dockedapp.c b/src/dockedapp.c
index 5ef64f6..02c9a22 100644
--- a/src/dockedapp.c
+++ b/src/dockedapp.c
@@ -31,6 +31,7 @@
 #include "icon.h"
 #include "appicon.h"
 #include "dock.h"
+#include "dockedapp.h"
 #include "dialog.h"
 #include "funcs.h"
 #include "defaults.h"
@@ -40,45 +41,6 @@
 /**** Global variables ****/
 extern WPreferences wPreferences;
 
-typedef struct _AppSettingsPanel {
-       WMWindow *win;
-       WAppIcon *editedIcon;
-
-       WWindow *wwin;
-
-       WMLabel *iconLabel;
-       WMLabel *nameLabel;
-
-       WMFrame *commandFrame;
-       WMTextField *commandField;
-
-       WMFrame *dndCommandFrame;
-       WMTextField *dndCommandField;
-       WMLabel *dndCommandLabel;
-
-       WMFrame *pasteCommandFrame;
-       WMTextField *pasteCommandField;
-       WMLabel *pasteCommandLabel;
-
-       WMFrame *iconFrame;
-       WMTextField *iconField;
-       WMButton *browseBtn;
-
-       WMButton *autoLaunchBtn;
-       WMButton *lockBtn;
-
-       WMButton *okBtn;
-       WMButton *cancelBtn;
-
-       Window parent;
-
-       /* kluge */
-       unsigned int destroyed:1;
-       unsigned int choosingIcon:1;
-} AppSettingsPanel;
-
-void DestroyDockAppSettingsPanel(AppSettingsPanel * panel);
-
 static void updateCommand(WAppIcon * icon, char *command)
 {
        if (icon->command)
diff --git a/src/dockedapp.h b/src/dockedapp.h
new file mode 100644
index 0000000..5f5118b
--- /dev/null
+++ b/src/dockedapp.h
@@ -0,0 +1,66 @@
+/*
+ *  Window Maker window manager
+ *
+ *  Copyright (c) 1997-2003 Alfredo K. Kojima
+ *  Copyright (c) 1998-2003 Dan Pascu
+ *
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation; either version 2 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program 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 General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License along
+ *  with this program; if not, write to the Free Software Foundation, Inc.,
+ *  51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
+#ifndef WMDOCKEDAPP_H_
+#define WMDOCKEDAPP_H_
+
+
+typedef struct _AppSettingsPanel {
+       WMWindow *win;
+       WAppIcon *editedIcon;
+
+       WWindow *wwin;
+
+       WMLabel *iconLabel;
+       WMLabel *nameLabel;
+
+       WMFrame *commandFrame;
+       WMTextField *commandField;
+
+       WMFrame *dndCommandFrame;
+       WMTextField *dndCommandField;
+       WMLabel *dndCommandLabel;
+
+       WMFrame *pasteCommandFrame;
+       WMTextField *pasteCommandField;
+       WMLabel *pasteCommandLabel;
+
+       WMFrame *iconFrame;
+       WMTextField *iconField;
+       WMButton *browseBtn;
+
+       WMButton *autoLaunchBtn;
+       WMButton *lockBtn;
+
+       WMButton *okBtn;
+       WMButton *cancelBtn;
+
+       Window parent;
+
+       /* kluge */
+       unsigned int destroyed:1;
+       unsigned int choosingIcon:1;
+} AppSettingsPanel;
+
+void DestroyDockAppSettingsPanel(AppSettingsPanel *panel);
+void ShowDockAppSettingsPanel(WAppIcon *aicon);
+
+#endif
-- 
1.7.7


-- 
To unsubscribe, send mail to [email protected].

Reply via email to