save the panels/dockwindows/desktopwindows/alldesktops options when the focus cycling popup is shown
This commit is contained in:
parent
12bbc0cc43
commit
c090f63011
1 changed files with 23 additions and 17 deletions
|
@ -74,13 +74,14 @@ static ObFocusCyclePopup popup;
|
||||||
/*! This popup shows a single window */
|
/*! This popup shows a single window */
|
||||||
static ObIconPopup *single_popup;
|
static ObIconPopup *single_popup;
|
||||||
|
|
||||||
|
static gboolean cycle_iconic_windows;
|
||||||
|
static gboolean cycle_all_desktops;
|
||||||
|
static gboolean cycle_dock_windows;
|
||||||
|
static gboolean cycle_desktop_windows;
|
||||||
|
|
||||||
static gchar *popup_get_name (ObClient *c);
|
static gchar *popup_get_name (ObClient *c);
|
||||||
static void popup_setup (ObFocusCyclePopup *p,
|
static void popup_setup (ObFocusCyclePopup *p,
|
||||||
gboolean create_targets,
|
gboolean create_targets);
|
||||||
gboolean iconic_windows,
|
|
||||||
gboolean all_desktops,
|
|
||||||
gboolean dock_windows,
|
|
||||||
gboolean desktop_windows);
|
|
||||||
static void popup_render (ObFocusCyclePopup *p,
|
static void popup_render (ObFocusCyclePopup *p,
|
||||||
const ObClient *c);
|
const ObClient *c);
|
||||||
|
|
||||||
|
@ -155,9 +156,7 @@ void focus_cycle_popup_shutdown(gboolean reconfig)
|
||||||
RrAppearanceFree(popup.a_bg);
|
RrAppearanceFree(popup.a_bg);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void popup_setup(ObFocusCyclePopup *p, gboolean create_targets,
|
static void popup_setup(ObFocusCyclePopup *p, gboolean create_targets)
|
||||||
gboolean iconic_windows, gboolean all_desktops,
|
|
||||||
gboolean dock_windows, gboolean desktop_windows)
|
|
||||||
{
|
{
|
||||||
gint maxwidth, n;
|
gint maxwidth, n;
|
||||||
GList *it;
|
GList *it;
|
||||||
|
@ -175,10 +174,10 @@ static void popup_setup(ObFocusCyclePopup *p, gboolean create_targets,
|
||||||
ObClient *ft = it->data;
|
ObClient *ft = it->data;
|
||||||
|
|
||||||
if (focus_cycle_target_valid(ft,
|
if (focus_cycle_target_valid(ft,
|
||||||
iconic_windows,
|
cycle_iconic_windows,
|
||||||
all_desktops,
|
cycle_all_desktops,
|
||||||
dock_windows,
|
cycle_dock_windows,
|
||||||
desktop_windows))
|
cycle_desktop_windows))
|
||||||
{
|
{
|
||||||
gchar *text = popup_get_name(ft);
|
gchar *text = popup_get_name(ft);
|
||||||
|
|
||||||
|
@ -445,9 +444,13 @@ void focus_cycle_popup_show(ObClient *c, gboolean iconic_windows,
|
||||||
g_assert(c != NULL);
|
g_assert(c != NULL);
|
||||||
|
|
||||||
/* do this stuff only when the dialog is first showing */
|
/* do this stuff only when the dialog is first showing */
|
||||||
if (!popup.mapped)
|
if (!popup.mapped) {
|
||||||
popup_setup(&popup, TRUE, iconic_windows, all_desktops,
|
cycle_iconic_windows = iconic_windows;
|
||||||
dock_windows, desktop_windows);
|
cycle_all_desktops = all_desktops;
|
||||||
|
cycle_dock_windows = dock_windows;
|
||||||
|
cycle_desktop_windows = desktop_windows;
|
||||||
|
popup_setup(&popup, TRUE);
|
||||||
|
}
|
||||||
g_assert(popup.targets != NULL);
|
g_assert(popup.targets != NULL);
|
||||||
|
|
||||||
popup_render(&popup, c);
|
popup_render(&popup, c);
|
||||||
|
@ -499,8 +502,11 @@ void focus_cycle_popup_single_show(struct _ObClient *c,
|
||||||
if (!popup.mapped) {
|
if (!popup.mapped) {
|
||||||
Rect *a;
|
Rect *a;
|
||||||
|
|
||||||
popup_setup(&popup, FALSE, iconic_windows, all_desktops,
|
cycle_iconic_windows = iconic_windows;
|
||||||
dock_windows, desktop_windows);
|
cycle_all_desktops = all_desktops;
|
||||||
|
cycle_dock_windows = dock_windows;
|
||||||
|
cycle_desktop_windows = desktop_windows;
|
||||||
|
popup_setup(&popup, FALSE);
|
||||||
g_assert(popup.targets == NULL);
|
g_assert(popup.targets == NULL);
|
||||||
|
|
||||||
/* position the popup */
|
/* position the popup */
|
||||||
|
|
Loading…
Reference in a new issue