Remove inclusion of frontend.h from backendz.h
[xboard.git] / xedittags.c
index 27bb722..d27aca3 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * xedittags.c -- Tags edit window, part of X front end for XBoard
  *
- * Copyright 1995, 2009, 2010, 2011 Free Software Foundation, Inc.
+ * Copyright 1995, 2009, 2010, 2011, 2012 Free Software Foundation, Inc.
  *
  * ------------------------------------------------------------------------
  *
@@ -81,6 +81,7 @@ extern char *getenv();
 #include "backend.h"
 #include "xboard.h"
 #include "xedittags.h"
+#include "dialogs.h"
 #include "gettext.h"
 
 #ifdef ENABLE_NLS
@@ -93,39 +94,28 @@ extern char *getenv();
 
 Position tagsX = -1, tagsY = -1;
 
-void TagsPopUp(tags, msg)
-     char *tags, *msg;
+void
+TagsPopUp (char *tags, char *msg)
 {
     NewTagsPopup(tags, cmailMsgLoaded ? msg : NULL);
 }
 
 
-void EditTagsPopUp(tags, dest)
-     char *tags;
-     char **dest;
+void
+EditTagsPopUp (char *tags, char **dest)
 {
     NewTagsPopup(tags, NULL);
 }
 
-void TagsPopDown()
+void
+TagsPopDown()
 {
-    PopDown(2);
+    PopDown(TagsDlg);
+    bookUp = False;
 }
 
 void
-EditTagsProc(w, event, prms, nprms)
-     Widget w;
-     XEvent *event;
-     String *prms;
-     Cardinal *nprms;
+EditTagsProc ()
 {
-    Arg args[5];
-    int j;
-    if (PopDown(2)) {
-       j = 0;
-       XtSetArg(args[j], XtNleftBitmap, None); j++;
-       XtSetValues(XtNameToWidget(menuBarWidget, "menuView.Show Tags"), args, j);
-    } else {
-       EditTagsEvent();
-    }
+  if (bookUp || !PopDown(TagsDlg)) EditTagsEvent();
 }