X-Git-Url: http://git.chise.org/gitweb/?a=blobdiff_plain;f=src%2FExternalShell.c;h=767c3ab4052d9d631b241ffcb5ccd69615998237;hb=de3ad3e5c2c0feb4bfcf3d6376de9b64cbe949d3;hp=941a10d8a5562f6a6bf84a838d709235781b5f66;hpb=6883ee56ec887c2c48abe5b06b5e66aa74031910;p=chise%2Fxemacs-chise.git.1 diff --git a/src/ExternalShell.c b/src/ExternalShell.c index 941a10d..767c3ab 100644 --- a/src/ExternalShell.c +++ b/src/ExternalShell.c @@ -171,19 +171,22 @@ void ExternalShellUnrealize (Widget w); static XtResource resources[] = { #define offset(field) XtOffset(ExternalShellWidget, externalShell.field) - { XtNwindow, XtCWindow, XtRWindow, sizeof (Window), - offset (external_window), XtRImmediate, (XtPointer)0}, - { XtNclientTimeout, XtCClientTimeout, XtRInt, sizeof(int), - offset(client_timeout), XtRImmediate,(XtPointer)DEFAULT_WM_TIMEOUT}, - { XtNdeadClient, XtCDeadClient, XtRBoolean, sizeof(Boolean), - offset(dead_client), XtRImmediate, (XtPointer)False}, + { XtNwindow, XtCWindow, + XtRWindow, sizeof (Window), + offset (external_window), XtRImmediate, (XtPointer)0 }, + { XtNclientTimeout, XtCClientTimeout, + XtRInt, sizeof (int), + offset(client_timeout), XtRImmediate,(XtPointer)DEFAULT_WM_TIMEOUT }, + { XtNdeadClient, XtCDeadClient, + XtRBoolean, sizeof (Boolean), + offset(dead_client), XtRImmediate, (XtPointer)False }, }; static CompositeClassExtensionRec compositeClassExtRec = { NULL, NULLQUARK, XtCompositeExtensionVersion, - sizeof(CompositeClassExtensionRec), + sizeof (CompositeClassExtensionRec), TRUE, }; @@ -191,7 +194,7 @@ static ShellClassExtensionRec shellClassExtRec = { NULL, NULLQUARK, XtShellExtensionVersion, - sizeof(ShellClassExtensionRec), + sizeof (ShellClassExtensionRec), ExternalShellRootGeometryManager }; @@ -201,7 +204,7 @@ ExternalShellClassRec externalShellClassRec = { */ /* superclass */ (WidgetClass) &shellClassRec, /* class_name */ "ExternalShell", - /* size */ sizeof(ExternalShellRec), + /* size */ sizeof (ExternalShellRec), /* Class Initializer */ NULL, /* class_part_initialize*/ NULL, /* XtInheritClassPartInitialize, */ /* Class init'ed ? */ FALSE, @@ -221,9 +224,9 @@ ExternalShellClassRec externalShellClassRec = { /* resize */ XtInheritResize, /* expose */ NULL, /* set_values */ NULL, /* XtInheritSetValues, */ - /* set_values_hook */ NULL, - /* set_values_almost */ XtInheritSetValuesAlmost, - /* get_values_hook */ NULL, + /* set_values_hook */ NULL, + /* set_values_almost */ XtInheritSetValuesAlmost, + /* get_values_hook */ NULL, /* accept_focus */ NULL, /* intrinsics version */ XtVersion, /* callback offsets */ NULL, @@ -319,7 +322,7 @@ static void EventHandler(wid, closure, event, continue_to_dispatch) case extw_notify_focus_in: { XFocusChangeEvent evnt; - + evnt.type = FocusIn; evnt.serial = LastKnownRequestProcessed (XtDisplay (wid)); evnt.send_event = True; @@ -334,10 +337,10 @@ static void EventHandler(wid, closure, event, continue_to_dispatch) #endif break; } - + case extw_notify_focus_out: { XFocusChangeEvent evnt; - + evnt.type = FocusOut; evnt.serial = LastKnownRequestProcessed (XtDisplay (wid)); evnt.send_event = True; @@ -368,11 +371,11 @@ GetGeometry (Widget W, Widget child) int x, y, win_gravity = -1, flag; XSizeHints hints; Window win = w->externalShell.external_window; - + { Window dummy_root; unsigned int dummy_bd_width, dummy_depth, width, height; - + /* determine the existing size of the window. */ XGetGeometry(XtDisplay(W), win, &dummy_root, &x, &y, &width, &height, &dummy_bd_width, &dummy_depth); @@ -466,8 +469,8 @@ static void ExternalShellRealize (Widget wid, Mask *vmask, w->core.background_pixmap = (*childP)->core.background_pixmap; } else { - attr->background_pixel = - w->core.background_pixel = + attr->background_pixel = + w->core.background_pixel = (*childP)->core.background_pixel; } break; @@ -609,7 +612,7 @@ hack_event_masks_1 (Display *display, Window w, int this_window_propagate) { Window root, parent, *children; unsigned int nchildren; - int i; + unsigned int i; if (!XQueryTree (display, w, &root, &parent, &children, &nchildren)) return;