aboutsummaryrefslogtreecommitdiff
path: root/src/Remember.cc
diff options
context:
space:
mode:
authormarkt <markt>2006-08-04 21:43:47 (GMT)
committermarkt <markt>2006-08-04 21:43:47 (GMT)
commit1dd5e0143e6ab63833851f4b3a42c500a9777162 (patch)
tree37273c4214f11483a0f24d8f0d4011e7a3e8c326 /src/Remember.cc
parentc2b35f06715e67e263b3ae70509930c474a9351c (diff)
downloadfluxbox-1dd5e0143e6ab63833851f4b3a42c500a9777162.zip
fluxbox-1dd5e0143e6ab63833851f4b3a42c500a9777162.tar.bz2
don't re-apply remembered settings on restart if they are set as window properties
Diffstat (limited to 'src/Remember.cc')
-rw-r--r--src/Remember.cc29
1 files changed, 17 insertions, 12 deletions
diff --git a/src/Remember.cc b/src/Remember.cc
index 2a28dda..3d8db2e 100644
--- a/src/Remember.cc
+++ b/src/Remember.cc
@@ -962,15 +962,31 @@ void Remember::setupFrame(FluxboxWindow &win) {
962 if (app == 0) 962 if (app == 0)
963 return; // nothing to do 963 return; // nothing to do
964 964
965 // first, set the options that aren't preserved as window properties on
966 // restart, then return if fluxbox is starting up -- we want restart to
967 // disturb the current window state as little as possible
965 if (app->is_grouped && app->group == 0) 968 if (app->is_grouped && app->group == 0)
966 app->group = &win; 969 app->group = &win;
967 970
971 if (app->focushiddenstate_remember)
972 win.setFocusHidden(true);
973 if (app->iconhiddenstate_remember)
974 win.setIconHidden(true);
975 if (app->layer_remember)
976 win.moveToLayer(app->layer);
977 if (app->decostate_remember)
978 win.setDecorationMask(app->decostate);
979
980 // now check if fluxbox is starting up
981 if (Fluxbox::instance()->isStartup())
982 return;
983
968 BScreen &screen = winclient.screen(); 984 BScreen &screen = winclient.screen();
969 985
970 if (app->workspace_remember) { 986 if (app->workspace_remember) {
971 // we use setWorkspace and not reassoc because we're still initialising 987 // we use setWorkspace and not reassoc because we're still initialising
972 win.setWorkspace(app->workspace); 988 win.setWorkspace(app->workspace);
973 if (app->jumpworkspace_remember && !Fluxbox::instance()->isStartup()) 989 if (app->jumpworkspace_remember)
974 screen.changeWorkspaceID(app->workspace); 990 screen.changeWorkspaceID(app->workspace);
975 } 991 }
976 992
@@ -978,10 +994,6 @@ void Remember::setupFrame(FluxboxWindow &win) {
978 win.screen().setOnHead<FluxboxWindow>(win, app->head); 994 win.screen().setOnHead<FluxboxWindow>(win, app->head);
979 } 995 }
980 996
981 if (app->decostate_remember)
982 win.setDecorationMask(app->decostate);
983
984
985 if (app->dimensions_remember) 997 if (app->dimensions_remember)
986 win.resize(app->w, app->h); 998 win.resize(app->w, app->h);
987 999
@@ -1032,13 +1044,6 @@ void Remember::setupFrame(FluxboxWindow &win) {
1032 if (win.isStuck() && !app->stuckstate || 1044 if (win.isStuck() && !app->stuckstate ||
1033 !win.isStuck() && app->stuckstate) 1045 !win.isStuck() && app->stuckstate)
1034 win.stick(); // toggles 1046 win.stick(); // toggles
1035 if (app->focushiddenstate_remember)
1036 win.setFocusHidden(true);
1037 if (app->iconhiddenstate_remember)
1038 win.setIconHidden(true);
1039
1040 if (app->layer_remember)
1041 win.moveToLayer(app->layer);
1042 1047
1043} 1048}
1044 1049