gnustep-dev
[Top][All Lists]
Advanced

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

Possible patches from upstream source


From: Alex Perez
Subject: Possible patches from upstream source
Date: Mon, 31 May 2004 23:14:02 -0700
User-agent: Mozilla Thunderbird 0.6 (X11/20040519)

Folks,

Please reply / CC to my personal address, as I am not a member of either wm-dev or gnustep-dev

I'm a GNUstep package maintainer who found these three patches were being used/applied against the WindowMaker 0.80.2 package in Fedora 2 (Extras). I do not know if they are dubious or not, so could someone with knowledge of whether or not they'll break anything if they are applied to CVS, assuming they are not already. If they are, could someone let me know? I tried applying them to the latest CVS checkout and some hunks patched properly while others did not.

I am CC'ing this to the GNUstep-dev mailing list as well so they can take a peek and make sure I'm not introducing some sort of insanity that will break GNUstep related stuff, since that's what I'm hoping to actually improve.

Cheers,
Alex Perez
--- src/actions.c       Mon Aug 11 15:29:31 2003
+++ src/actions.c       Mon Aug 11 15:31:56 2003
@@ -144,6 +144,14 @@
       old_scr=scr;
     old_focused=old_scr->focused_window;

+    /*
+     * Safeguard: make sure the timestamp is monotonically increasing
+     * (very unlikely that this will be needed, still a safeguard)
+     */
+    if (timestamp <= LastFocusChange)
+           timestamp = LastFocusChange + 1;
+
+
     LastFocusChange = timestamp;

 /*
@@ -150,8 +158,8 @@
  * This is a hack, because XSetInputFocus() should have a proper
  * timestamp instead of CurrentTime but it seems that some times
  * clients will not receive focus properly that way.
+ */
     if (ignoreTimestamp)
-*/
       timestamp = CurrentTime;

     if (old_focused)
--- src/event.c Mon Aug 11 15:29:31 2003
+++ src/event.c Mon Aug 11 15:32:06 2003
@@ -402,7 +402,6 @@
 static void
 saveTimestamp(XEvent *event)
 {
-    LastTimestamp = CurrentTime;
 
     switch (event->type) {
      case ButtonRelease:
--- src/workspace.c     Mon Aug 11 15:29:33 2003
+++ src/workspace.c     Mon Aug 11 15:33:33 2003
@@ -574,10 +574,12 @@
                               &foo, &foo, &foo, &foo, &mask)) {
                tmp = wWindowFor(win);
            }
-           if (!tmp && wPreferences.focus_mode == WKF_SLOPPY) {
-               wSetFocusTo(scr, foc);
-           } else {
-               wSetFocusTo(scr, tmp);
+           if (!tmp) {
+               if (wPreferences.focus_mode == WKF_SLOPPY) {
+                   wSetFocusTo(scr, foc);
+               } else {
+                   wSetFocusTo(scr, tmp);
+               }
            }
        }
     }

reply via email to

[Prev in Thread] Current Thread [Next in Thread]