This commit was generated by cvs2svn to compensate for changes in r1383,
[chise/xemacs-chise.git.1] / lwlib / lwlib-Xaw.c
index b19dd8c..dd766dc 100644 (file)
@@ -33,21 +33,21 @@ Boston, MA 02111-1307, USA.  */
 #include <X11/Shell.h>
 
 #ifdef LWLIB_SCROLLBARS_ATHENA
-#include <X11/Xaw/Scrollbar.h>
+#include ATHENA_INCLUDE(Scrollbar.h)
 #endif
 #ifdef LWLIB_DIALOGS_ATHENA
-#include <X11/Xaw/Dialog.h>
-#include <X11/Xaw/Form.h>
-#include <X11/Xaw/Command.h>
-#include <X11/Xaw/Label.h>
+#include ATHENA_INCLUDE(Dialog.h)
+#include ATHENA_INCLUDE(Form.h)
+#include ATHENA_INCLUDE(Command.h)
+#include ATHENA_INCLUDE(Label.h)
 #endif
 #ifdef LWLIB_WIDGETS_ATHENA
-#include <X11/Xaw/Toggle.h>
+#include ATHENA_INCLUDE(Toggle.h)
 #include "xlwradio.h"
 #include "xlwcheckbox.h"
 #include "xlwgauge.h"
 #ifndef NEED_MOTIF
-#include <X11/Xaw/AsciiText.h>
+#include ATHENA_INCLUDE(AsciiText.h)
 #endif
 #endif
 #include <X11/Xatom.h>
@@ -126,8 +126,8 @@ void
 xaw_update_one_widget (widget_instance *instance, Widget widget,
                       widget_value *val, Boolean deep_p)
 {
-  if (val->nargs)
-    XtSetValues (widget, val->args, val->nargs);
+  if (val->args && val->args->nargs)
+    XtSetValues (widget, val->args->args, val->args->nargs);
 
   if (0)
     ;
@@ -329,8 +329,8 @@ static XtActionsRec xaw_actions [] = {
 static Boolean actions_initted = False;
 
 static Widget
-make_dialog (CONST char* name, Widget parent, Boolean pop_up_p,
-            CONST char* shell_title, CONST char* icon_name,
+make_dialog (const char* name, Widget parent, Boolean pop_up_p,
+            const char* shell_title, const char* icon_name,
              Boolean text_input_slot,
             Boolean radio_box, Boolean list,
             int left_buttons, int right_buttons)
@@ -438,8 +438,8 @@ xaw_create_dialog (widget_instance* instance)
   Widget parent = instance->parent;
   Widget widget;
   Boolean pop_up_p = instance->pop_up_p;
-  CONST char *shell_name = 0;
-  CONST char *icon_name = 0;
+  const char *shell_name = 0;
+  const char *icon_name = 0;
   Boolean text_input_slot = False;
   Boolean radio_box = False;
   Boolean list = False;
@@ -788,7 +788,7 @@ xaw_create_progress (widget_instance *instance)
   int ac = 0;
   Widget scale = 0;
   widget_value* val = instance->info->val;
-
+#if 0          /* This looks too awful, although more correct. */
   if (!val->call_data)
     {
       XtSetArg (al [ac], XtNsensitive, False);         ac++;
@@ -797,6 +797,10 @@ xaw_create_progress (widget_instance *instance)
     {
       XtSetArg (al [ac], XtNsensitive, val->enabled);          ac++;
     }
+#else
+  XtSetArg (al [ac], XtNsensitive, True);              ac++;
+#endif
+
   XtSetArg (al [ac], XtNmappedWhenManaged, FALSE);     ac++;
   XtSetArg (al [ac], XtNorientation, XtorientHorizontal);      ac++;
   XtSetArg (al [ac], XtNhighlightThickness, (Dimension)0);ac++;