all repos — fluxbox @ e90cbd35e0fa3deb864e7fcd8777de0ab56c6013

custom fork of the fluxbox windowmanager

slit as an observer
fluxgen fluxgen
commit

e90cbd35e0fa3deb864e7fcd8777de0ab56c6013

parent

359037659a46cc26e422a3eccfa25fe827075db4

2 files changed, 13 insertions(+), 5 deletions(-)

jump to
M src/Slit.ccsrc/Slit.cc

@@ -22,7 +22,7 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING

// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: Slit.cc,v 1.78 2003/08/15 13:50:42 fluxgen Exp $ +// $Id: Slit.cc,v 1.79 2003/08/29 10:30:46 fluxgen Exp $ #include "Slit.hh"

@@ -260,9 +260,8 @@ m_kwm2_dockwindow(XInternAtom(FbTk::App::instance()->display(),

"_KDE_NET_WM_SYSTEM_TRAY_WINDOW_FOR", False)), //KDE v2.x m_layeritem(0), - m_slit_theme(new SlitTheme(*this)), + m_slit_theme(new SlitTheme(scr.rootWindow().screenNumber())), m_strut(0), - // resources // lock in first resource m_rc_auto_hide(scr.resourceManager().lock(), false,

@@ -281,6 +280,9 @@ scr.name() + ".slit.onhead", scr.altName() + ".Slit.onHead"),

m_rc_layernum(scr.resourceManager(), Fluxbox::Layer(Fluxbox::instance()->getDockLayer()), scr.name() + ".slit.layer", scr.altName() + ".Slit.Layer") { + // attach to theme and root window change signal + m_slit_theme->reconfigSig().attach(this); + scr.resizeSig().attach(this); frame.pixmap = None; // setup timer

@@ -1080,6 +1082,10 @@ ev.x, ev.y,

ev.width, ev.height); } +} + +void Slit::update(FbTk::Subject *subj) { + reconfigure(); } void Slit::clearWindow() {
M src/Slit.hhsrc/Slit.hh

@@ -22,7 +22,7 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING

// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -/// $Id: Slit.hh,v 1.37 2003/08/11 16:02:38 fluxgen Exp $ +/// $Id: Slit.hh,v 1.38 2003/08/29 10:30:46 fluxgen Exp $ #ifndef SLIT_HH #define SLIT_HH

@@ -47,7 +47,7 @@ class FbMenu;

class Strut; /// Handles dock apps -class Slit: public FbTk::EventHandler { +class Slit: public FbTk::EventHandler, public FbTk::Observer { public: /**

@@ -88,6 +88,8 @@ void leaveNotifyEvent(XCrossingEvent &event);

void configureRequestEvent(XConfigureRequestEvent &event); void exposeEvent(XExposeEvent &event); //@} + + void update(FbTk::Subject *subj); void moveToLayer(int layernum); void toggleHidden();