aboutsummaryrefslogtreecommitdiffstats
path: root/client.c
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--client.c19
1 files changed, 5 insertions, 14 deletions
diff --git a/client.c b/client.c
index fc02996..e86ded2 100644
--- a/client.c
+++ b/client.c
@@ -15,7 +15,7 @@
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
- * $OpenBSD: client.c,v 1.251 2019/02/23 19:17:17 okan Exp $
+ * $OpenBSD: client.c,v 1.252 2019/02/28 13:11:53 okan Exp $
*/
#include <sys/types.h>
@@ -128,7 +128,7 @@ client_init(Window win, struct screen_ctx *sc, int active)
if (client_get_wm_state(cc) == IconicState)
client_hide(cc);
else
- client_unhide(cc);
+ client_show(cc);
if (mapped) {
if (cc->gc) {
@@ -527,10 +527,10 @@ client_hide(struct client_ctx *cc)
{
XUnmapWindow(X_Dpy, cc->win);
- if (cc->flags & CLIENT_ACTIVE)
+ if (cc->flags & CLIENT_ACTIVE) {
+ cc->flags &= ~CLIENT_ACTIVE;
xu_ewmh_net_active_window(cc->sc, None);
-
- cc->flags &= ~CLIENT_ACTIVE;
+ }
cc->flags |= CLIENT_HIDDEN;
client_set_wm_state(cc, IconicState);
}
@@ -538,15 +538,6 @@ client_hide(struct client_ctx *cc)
void
client_show(struct client_ctx *cc)
{
- if (cc->flags & CLIENT_HIDDEN)
- client_unhide(cc);
- else
- client_raise(cc);
-}
-
-void
-client_unhide(struct client_ctx *cc)
-{
XMapRaised(X_Dpy, cc->win);
cc->flags &= ~CLIENT_HIDDEN;