aboutsummaryrefslogtreecommitdiff
path: root/src/Remember.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/Remember.cc')
-rw-r--r--src/Remember.cc15
1 files changed, 4 insertions, 11 deletions
diff --git a/src/Remember.cc b/src/Remember.cc
index fbb4a2e..d8f1d83 100644
--- a/src/Remember.cc
+++ b/src/Remember.cc
@@ -339,6 +339,7 @@ Application * Remember::add(WinClient &winclient) {
339 p->addTerm(win_class, ClientPattern::CLASS); 339 p->addTerm(win_class, ClientPattern::CLASS);
340 if (!win_role.empty()) 340 if (!win_role.empty())
341 p->addTerm(win_role, ClientPattern::ROLE); 341 p->addTerm(win_role, ClientPattern::ROLE);
342 p->addTerm(winclient.isTransient() ? "yes" : "no", ClientPattern::TRANSIENT);
342 m_clients[&winclient] = app; 343 m_clients[&winclient] = app;
343 p->addMatch(); 344 p->addMatch();
344 m_pats->push_back(make_pair(p, app)); 345 m_pats->push_back(make_pair(p, app));
@@ -594,7 +595,7 @@ void Remember::reconfigure() {
594 '[', ']'); 595 '[', ']');
595 596
596 if (pos > 0 && strcasecmp(key.c_str(), "app") == 0) { 597 if (pos > 0 && strcasecmp(key.c_str(), "app") == 0) {
597 ClientPattern *pat = new ClientPattern(line.c_str() + pos); 598 ClientPattern *pat = new ClientPattern(line.c_str() + pos, true);
598 if (!in_group) { 599 if (!in_group) {
599 if ((err = pat->error()) == 0) { 600 if ((err = pat->error()) == 0) {
600 Application *app = findMatchingPatterns(pat, old_pats, false); 601 Application *app = findMatchingPatterns(pat, old_pats, false);
@@ -620,7 +621,7 @@ void Remember::reconfigure() {
620 } else if (pos > 0 && strcasecmp(key.c_str(), "group") == 0) { 621 } else if (pos > 0 && strcasecmp(key.c_str(), "group") == 0) {
621 in_group = true; 622 in_group = true;
622 if (line.find('(') != string::npos) 623 if (line.find('(') != string::npos)
623 pat = new ClientPattern(line.c_str() + pos); 624 pat = new ClientPattern(line.c_str() + pos, true);
624 } else if (in_group) { 625 } else if (in_group) {
625 // otherwise assume that it is the start of the attributes 626 // otherwise assume that it is the start of the attributes
626 Application *app = 0; 627 Application *app = 0;
@@ -1020,13 +1021,6 @@ void Remember::forgetAttrib(WinClient &winclient, Attribute attrib) {
1020 1021
1021void Remember::setupFrame(FluxboxWindow &win) { 1022void Remember::setupFrame(FluxboxWindow &win) {
1022 WinClient &winclient = win.winClient(); 1023 WinClient &winclient = win.winClient();
1023 // we don't touch the window if it is a transient
1024 // of something else
1025
1026
1027 if (winclient.transientFor())
1028 return;
1029
1030 Application *app = find(winclient); 1024 Application *app = find(winclient);
1031 if (app == 0) 1025 if (app == 0)
1032 return; // nothing to do 1026 return; // nothing to do
@@ -1123,8 +1117,7 @@ void Remember::setupFrame(FluxboxWindow &win) {
1123void Remember::setupClient(WinClient &winclient) { 1117void Remember::setupClient(WinClient &winclient) {
1124 1118
1125 // leave windows alone on restart 1119 // leave windows alone on restart
1126 // don't apply settings to transient windows 1120 if (winclient.screen().isRestart())
1127 if (winclient.screen().isRestart() || winclient.transientFor())
1128 return; 1121 return;
1129 1122
1130 Application *app = find(winclient); 1123 Application *app = find(winclient);