aboutsummaryrefslogtreecommitdiff
path: root/src/Window.cc
diff options
context:
space:
mode:
authorrathnor <rathnor>2002-11-23 16:07:19 (GMT)
committerrathnor <rathnor>2002-11-23 16:07:19 (GMT)
commit3737a18dadaefa7ad07eff3e34edb757ee9a2170 (patch)
tree63533f01b6f90cc95454d423b1483086cc93ae34 /src/Window.cc
parentbdbff9c5c2300fea1f167733300c582a84cf87b2 (diff)
downloadfluxbox-3737a18dadaefa7ad07eff3e34edb757ee9a2170.zip
fluxbox-3737a18dadaefa7ad07eff3e34edb757ee9a2170.tar.bz2
toggleDecor fix - rather than static, use an extra member of decorations
(means that odd number of toggles don't cause the next window toggled to "ignore" it). I think this fixes bug [ 561602 ] Problem using ToggleDecor in terminals.
Diffstat (limited to 'src/Window.cc')
-rw-r--r--src/Window.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/Window.cc b/src/Window.cc
index 1a8106a..24e4e45 100644
--- a/src/Window.cc
+++ b/src/Window.cc
@@ -22,7 +22,7 @@
22// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 22// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
23// DEALINGS IN THE SOFTWARE. 23// DEALINGS IN THE SOFTWARE.
24 24
25// $Id: Window.cc,v 1.100 2002/11/17 12:50:20 fluxgen Exp $ 25// $Id: Window.cc,v 1.101 2002/11/23 16:07:19 rathnor Exp $
26 26
27#include "Window.hh" 27#include "Window.hh"
28 28
@@ -94,6 +94,7 @@ tab(0) {
94 blackbox_attrib.premax_w = blackbox_attrib.premax_h = 0; 94 blackbox_attrib.premax_w = blackbox_attrib.premax_h = 0;
95 //use tab as default 95 //use tab as default
96 decorations.tab = true; 96 decorations.tab = true;
97 decorations.enabled = true;
97 client.window = w; 98 client.window = w;
98 frame.window = frame.plate = frame.title = frame.handle = None; 99 frame.window = frame.plate = frame.title = frame.handle = None;
99 frame.right_grip = frame.left_grip = None; 100 frame.right_grip = frame.left_grip = None;
@@ -3175,17 +3176,16 @@ void FluxboxWindow::setDecoration(Decoration decoration) {
3175} 3176}
3176 3177
3177void FluxboxWindow::toggleDecoration() { 3178void FluxboxWindow::toggleDecoration() {
3178 static bool decor = false;
3179 //don't toggle decor if the window is shaded 3179 //don't toggle decor if the window is shaded
3180 if (isShaded()) 3180 if (isShaded())
3181 return; 3181 return;
3182 3182
3183 if (!decor) { //remove decorations 3183 if (decorations.enabled) { //remove decorations
3184 setDecoration(DECOR_NONE); 3184 setDecoration(DECOR_NONE);
3185 decor = true; 3185 decorations.enabled = false;
3186 } else { //revert back to old decoration 3186 } else { //revert back to old decoration
3187 setDecoration(old_decoration); 3187 setDecoration(old_decoration);
3188 decor = false; 3188 decorations.enabled = true;
3189 } 3189 }
3190} 3190}
3191 3191