+
Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions fvwm/fvwm.h
Original file line number Diff line number Diff line change
Expand Up @@ -603,6 +603,7 @@ typedef struct style_flags
unsigned has_initial_map_command_string : 1;
unsigned has_title_format_string : 1;
unsigned has_icon_title_format_string : 1;
unsigned initial_placement_done : 1;
} style_flags;

typedef struct style_id_t
Expand Down
9 changes: 5 additions & 4 deletions fvwm/placement.c
Original file line number Diff line number Diff line change
Expand Up @@ -1556,8 +1556,6 @@ static int __place_get_nowm_pos(
attr_g->y = final_g.y;
}

UPDATE_FVWM_SCREEN(fw);

return 0;
}

Expand Down Expand Up @@ -1693,14 +1691,14 @@ static int __place_window(
FScreenGetScrRect(&arg, FSCREEN_BY_NAME,
&screen_g.x, &screen_g.y,
&screen_g.width, &screen_g.height);
free(e);

/* FIXME: Set the monitor here, but make
* UPDATE_FVWM_SCREEN aware of how to do this.
*
* This is necessary for StartsOnScreen
*/
fw->m = monitor_by_name(arg.name);
free(e);
}
else
{
Expand Down Expand Up @@ -1810,6 +1808,7 @@ static int __place_window(
}
}

#if 0
{
/* migo - I am not sure this block is ever needed */

Expand All @@ -1834,6 +1833,7 @@ static int __place_window(
}
}
}
#endif
}
reason->desk.desk = fw->Desk;
/* I think it would be good to switch to the selected desk
Expand Down Expand Up @@ -1904,7 +1904,8 @@ static int __place_window(
((!Restarting && Scr.flags.are_windows_captured))) {
struct monitor *mnew = FindScreenOfXY(attr_g->x, attr_g->y);
fw->m = mnew;
fw->Desk = mnew->virtual_scr.CurrentDesk;
do_move_window_to_desk(fw, mnew->virtual_scr.CurrentDesk);
pstyle->flags.initial_placement_done = 1;
}

reason->pos.x = attr_g->x;
Expand Down
29 changes: 21 additions & 8 deletions fvwm/screen.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,11 @@
#ifndef _SCREEN_
#define _SCREEN_

#include "config.h"

#include "fvwm/update.h"
#include "fvwm/style.h"

#include "libs/flist.h"
#include "libs/Bindings.h"

Expand Down Expand Up @@ -469,14 +474,22 @@ typedef struct ScreenInfo
} last_added_item;
} ScreenInfo;

#define UPDATE_FVWM_SCREEN(fw) \
do { \
rectangle g; \
struct monitor *mnew; \
get_unshaded_geometry((fw), &g); \
mnew = FindScreenOfXY((fw)->g.frame.x, (fw)->g.frame.y); \
(fw)->m_prev = (fw)->m; \
(fw)->m = mnew; \
#define UPDATE_FVWM_SCREEN(fw) \
do { \
rectangle g; \
struct monitor *mnew; \
window_style style; \
\
lookup_style((fw), &style); \
get_unshaded_geometry((fw), &g); \
mnew = FindScreenOfXY((fw)->g.frame.x, (fw)->g.frame.y); \
/* Avoid unnecessary updates. */ \
if (mnew == (fw)->m) \
break; \
(fw)->m_prev = (fw)->m; \
(fw)->m = mnew; \
(fw)->Desk = mnew->virtual_scr.CurrentDesk; \
BroadcastConfig(M_CONFIGURE_WINDOW, (fw)); \
} while(0)

/* A macro to to simplify he "ewmh desktop code" */
Expand Down
4 changes: 4 additions & 0 deletions fvwm/stack.c
Original file line number Diff line number Diff line change
Expand Up @@ -1511,6 +1511,7 @@ static Bool is_on_top_of_layer_ignore_rom(FvwmWindow *fw)
{
FvwmWindow *t;
Bool ontop = True;
struct monitor *m = fw->m;

if (IS_SCHEDULED_FOR_DESTROY(fw))
{
Expand All @@ -1523,6 +1524,9 @@ static Bool is_on_top_of_layer_ignore_rom(FvwmWindow *fw)
}
for (t = fw->stack_prev; t != &Scr.FvwmRoot; t = t->stack_prev)
{
if (t->m != m)
continue;

if (t->layer > fw->layer)
{
break;
Expand Down
点击 这是indexloc提供的php浏览器服务,不要输入任何密码和下载