summaryrefslogtreecommitdiff
path: root/src/client.cc
diff options
context:
space:
mode:
authorDana Jansens <danakj@orodu.net>2003-01-29 21:48:46 +0000
committerDana Jansens <danakj@orodu.net>2003-01-29 21:48:46 +0000
commit44d653e3e8d042bf3f1d68108a8197a895888da8 (patch)
tree4260520e37122d167a5aeb87c7f6670bce7b5601 /src/client.cc
parent5f89f11dd3b69c0881273f32cfd4f113f744fae7 (diff)
make struts get added to the screen when mapping a window. let the user disable window decorations.
Diffstat (limited to 'src/client.cc')
-rw-r--r--src/client.cc26
1 files changed, 26 insertions, 0 deletions
diff --git a/src/client.cc b/src/client.cc
index 3939b0c6..e9136df4 100644
--- a/src/client.cc
+++ b/src/client.cc
@@ -288,6 +288,23 @@ void Client::setupDecorAndFunctions()
}
}
+ // finally, user specified disabled decorations are applied to subtract
+ // decorations
+ if (_disabled_decorations & Decor_Titlebar)
+ _decorations &= ~Decor_Titlebar;
+ if (_disabled_decorations & Decor_Handle)
+ _decorations &= ~Decor_Handle;
+ if (_disabled_decorations & Decor_Border)
+ _decorations &= ~Decor_Border;
+ if (_disabled_decorations & Decor_Iconify)
+ _decorations &= ~Decor_Iconify;
+ if (_disabled_decorations & Decor_Maximize)
+ _decorations &= ~Decor_Maximize;
+ if (_disabled_decorations & Decor_AllDesktops)
+ _decorations &= ~Decor_AllDesktops;
+ if (_disabled_decorations & Decor_Close)
+ _decorations &= ~Decor_Close;
+
changeAllowedActions();
}
@@ -1322,6 +1339,15 @@ void Client::fullscreen(bool fs)
}
+void Client::disableDecorations(DecorationFlags flags)
+{
+ _disabled_decorations = flags;
+ setupDecorAndFunctions();
+ if (frame)
+ frame->adjustSize(); // change the decors on the frame
+}
+
+
bool Client::focus()
{
// won't try focus if the client doesn't want it, or if the window isn't