Exemple #1
0
func (c *Client) cbEnterNotify() xevent.EnterNotifyFun {
	f := func(X *xgbutil.XUtil, ev xevent.EnterNotifyEvent) {
		if c.IsMapped() {
			if wm.Config.FfmFocus {
				c.Focus()
			}
			if wm.Config.FfmRaise {
				c.Raise()
			}
		}
	}
	return xevent.EnterNotifyFun(f)
}
Exemple #2
0
func (c *Client) cbEnterNotify() xevent.EnterNotifyFun {
	f := func(X *xgbutil.XUtil, ev xevent.EnterNotifyEvent) {
		// If the client is already active, then we don't want to do anything.
		// This is slightly a hack to fix issue #29.
		if c.IsActive() {
			return
		}
		if c.IsMapped() {
			if wm.Config.FfmFocus {
				c.Focus()
			}
			if wm.Config.FfmRaise {
				c.Raise()
			}
		}
	}
	return xevent.EnterNotifyFun(f)
}
Exemple #3
0
func (c *Client) cbEnterNotify() xevent.EnterNotifyFun {
	f := func(X *xgbutil.XUtil, ev xevent.EnterNotifyEvent) {
		c.Focus()
	}
	return xevent.EnterNotifyFun(f)
}