diff --git a/src/Window.cc b/src/Window.cc index b02cc792..e97a821a 100644 --- a/src/Window.cc +++ b/src/Window.cc @@ -22,7 +22,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: Window.cc,v 1.294 2004/08/10 12:05:47 fluxgen Exp $ +// $Id: Window.cc,v 1.295 2004/08/10 19:18:48 fluxgen Exp $ #include "Window.hh" @@ -575,7 +575,10 @@ void FluxboxWindow::init() { if (m_shaped) shape(); - FbTk::App::instance()->sync(false); + + setupWindow(); + + FbTk::App::instance()->sync(false); } /// apply shape to this window @@ -3410,7 +3413,7 @@ void FluxboxWindow::addExtraMenu(const char *label, FbTk::Menu *menu) { menu->disableTitle(); m_extramenus.push_back(std::make_pair(label, menu)); - setupWindow(); + setupMenu(); } void FluxboxWindow::removeExtraMenu(FbTk::Menu *menu) { @@ -3422,7 +3425,7 @@ void FluxboxWindow::removeExtraMenu(FbTk::Menu *menu) { break; } } - setupWindow(); + setupMenu(); } void FluxboxWindow::close() { @@ -3524,6 +3527,10 @@ void FluxboxWindow::setupWindow() { // end setup frame + setupMenu(); +} + +void FluxboxWindow::setupMenu() { // setup menu menu().removeAll(); // clear old items diff --git a/src/Window.hh b/src/Window.hh index a271fb51..1b45d826 100644 --- a/src/Window.hh +++ b/src/Window.hh @@ -22,7 +22,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: Window.hh,v 1.117 2004/08/10 12:05:47 fluxgen Exp $ +// $Id: Window.hh,v 1.118 2004/08/10 19:18:47 fluxgen Exp $ #ifndef WINDOW_HH #define WINDOW_HH @@ -384,6 +384,7 @@ private: static const int PropBlackboxAttributesElements = 8; void setupWindow(); + void setupMenu(); void init(); /// applies a shape mask to the window if it has one