mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-20 04:48:06 +01:00
Fixed problem with not saving all windows in a session when the shared
application icon is enabled (only one instance/shared application was saved)
This commit is contained in:
@@ -15,6 +15,8 @@ Changes since version 0.80.0:
|
||||
- Fixed Legal Panel not to display rectangles in place of new lines.
|
||||
- Fixed problem with losing focus when changing to an empty workspace and back.
|
||||
- Fixed another focus related problem when changing workspaces.
|
||||
- Fixed problem with saving session when shared appicon is enabled (not
|
||||
all instances were saved in the session, only one per shared appicon)
|
||||
|
||||
|
||||
Changes since version 0.70.0:
|
||||
|
||||
@@ -220,8 +220,8 @@ makeWindowState(WWindow *wwin, WApplication *wapp)
|
||||
WMPropList *shaded, *miniaturized, *hidden, *geometry;
|
||||
WMPropList *dock, *shortcut;
|
||||
|
||||
if (wwin->main_window!=None && wwin->main_window!=wwin->client_win)
|
||||
win = wwin->main_window;
|
||||
if (wwin->orig_main_window!=None && wwin->orig_main_window!=wwin->client_win)
|
||||
win = wwin->orig_main_window;
|
||||
else
|
||||
win = wwin->client_win;
|
||||
|
||||
@@ -332,10 +332,11 @@ wSessionSaveState(WScreen *scr)
|
||||
|
||||
while (wwin) {
|
||||
WApplication *wapp=wApplicationOf(wwin->main_window);
|
||||
Window appId = wwin->orig_main_window;
|
||||
|
||||
if ((wwin->transient_for==None
|
||||
|| wwin->transient_for==wwin->screen_ptr->root_win)
|
||||
&& WMGetFirstInArray(wapp_list, wapp)==WANotFound
|
||||
&& WMGetFirstInArray(wapp_list, (void*)appId)==WANotFound
|
||||
&& !WFLAGP(wwin, dont_save_session)) {
|
||||
/* A entry for this application was not yet saved. Save one. */
|
||||
if ((win_info = makeWindowState(wwin, wapp))!=NULL) {
|
||||
@@ -346,7 +347,7 @@ wSessionSaveState(WScreen *scr)
|
||||
* application list, so no multiple entries for the same
|
||||
* application are saved.
|
||||
*/
|
||||
WMAddToArray(wapp_list, wapp);
|
||||
WMAddToArray(wapp_list, (void*)appId);
|
||||
}
|
||||
}
|
||||
wwin = wwin->prev;
|
||||
|
||||
@@ -807,6 +807,8 @@ wManageWindow(WScreen *scr, Window window)
|
||||
wwin->main_window = wwin->client_win;
|
||||
}
|
||||
|
||||
wwin->orig_main_window = wwin->main_window;
|
||||
|
||||
if (wwin->flags.is_gnustep) {
|
||||
WSETUFLAG(wwin, shared_appicon, 0);
|
||||
}
|
||||
|
||||
@@ -229,6 +229,9 @@ typedef struct WWindow {
|
||||
|
||||
Window main_window; /* main window for the application */
|
||||
|
||||
Window orig_main_window; /* original main window of application.
|
||||
used for the shared appicon thing */
|
||||
|
||||
int cmap_window_no;
|
||||
Window *cmap_windows;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user