New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Alt-Tab (warp) does not work as expected #1
Comments
Only WarpFore is affected, WarpBack works perfectly. |
I addressed this issue (along w/several others, mostly clicktofocus-related issues - I use "clicktofocus"!) awhile back and it's been working well for me for quite some while now. I'm using "AutoReverse 2" and "AutoTabThroughDesks". This patch file is not against original source but only isolates changes related to this issue, so you'll pbly have to make the changes manually. I've been using AfterStep since the '90s and still love and use it! Msg. me back if you have ?s or are interested on my other fixes. Regards, Jim aswindow.c.diff:--- /tmp/aswindow.c.BEFORE 2019-03-13 09:44:20.635877129 -0500
+++ /tmp/aswindow.c.AFTER 2019-03-13 09:44:45.175878317 -0500
@@ -1408,7 +1408,7 @@ is_status_overlaping (ASStatusHints * ab
&& above->y + above->height > below->y);
}
-inline Bool is_canvas_overlaping (ASCanvas * above, ASCanvas * below)
+static inline Bool is_canvas_overlaping (ASCanvas * above, ASCanvas * below)
{
if (above == NULL)
return False;
@@ -1958,23 +1958,22 @@ void warp_to_aswindow (ASWindow * asw, B
*********************************************************************************/
ASWindow *warp_aswindow_list (ASWindowList * list, Bool backwards)
{
- register int i;
- register int dir = backwards ? -1 : 1;
- int end_i;
- ASWindow **clients;
- int loop_count = 0;
-
if (list == NULL)
return NULL;
- end_i = VECTOR_USED (*(list->circulate_list));
- clients = VECTOR_HEAD (ASWindow *, *(list->circulate_list));
-
+ int end_i = VECTOR_USED (*(list->circulate_list));
if (end_i <= 1)
return NULL;
+ register int i;
+ register int dir = backwards ? -1 : 1;
+ int loop_count = 0;
+
+ ASWindow **clients = VECTOR_HEAD (ASWindow *, *(list->circulate_list));
+
if (list->warp_curr_index < 0) { /* need to initialize warping : */
- list->warp_curr_index = (dir > 0) ? 0 : end_i;
+ /* JWT:CHGD. TO NEXT 20180325 TO ENSURE AT LEAST ONE CHECK: list->warp_curr_index = (dir > 0) ? 0 : end_i; */
+ list->warp_curr_index = (dir > 0) ? 0 : end_i-1;
list->warp_user_dir = dir;
list->warp_init_dir = dir;
list->warp_curr_dir = dir;
@@ -1987,7 +1986,8 @@ ASWindow *warp_aswindow_list (ASWindowLi
list->warp_curr_dir = dir;
}
- i = (dir > 0) ? 1 : end_i - 1; /*list->warp_curr_index + dir */
+ /* JWT:CHGD TO NEXT 20180322: i = (dir > 0) ? 1 : end_i - 1; */ /* list->warp_curr_index + dir */
+ i = list->warp_curr_index;
do {
LOCAL_DEBUG_OUT ("checking i(%d)->end_i(%d)->dir(%d)->AutoReverse(%d)",
i, end_i, dir, Scr.Feel.AutoReverse);
@@ -2004,12 +2004,13 @@ ASWindow *warp_aswindow_list (ASWindowLi
return NULL;
}
- list->warp_curr_index = i;
- if (!(ASWIN_HFLAGS (clients[i], AS_DontCirculate)) &&
+ /* JWT:CHGD TO NEXT 20180322 TO FIX TAB-THRU-WINDOWS: if (!(ASWIN_HFLAGS (clients[i], AS_DontCirculate)) && */
+ if (list->warp_curr_index != i && !(ASWIN_HFLAGS (clients[i], AS_DontCirculate)) &&
!(ASWIN_GET_FLAGS (clients[i], AS_Iconic)
&& get_flags (Scr.Feel.flags, CirculateSkipIcons))
&& (ASWIN_DESK (clients[i]) == Scr.CurrentDesk
|| get_flags (Scr.Feel.flags, AutoTabThroughDesks))) {
+ list->warp_curr_index = i; /* JWT:MOVED HERE FROM ABOVE IF 20180322, SINCE TEST ADDED TO IF. */
return clients[i];
}
i += dir; |
I have "AutoReverse 1" and "AutoTabThroughDesks" in my feel file, Alt-Tab will sometime cycle between two windows and then do nothing.
I also tried to use Alt-Tab with the default feel file and it doesn't seem to behave correctly either.
The text was updated successfully, but these errors were encountered: