From 51007f35a531c892b1ee2013cc7f180ff20c0744 Mon Sep 17 00:00:00 2001 From: rathnor Date: Wed, 9 Apr 2003 17:20:06 +0000 Subject: Little fixes to bugs highlighted by valgrind - Simon --- src/Ewmh.cc | 3 ++- src/FbWinFrame.cc | 3 ++- src/Gnome.cc | 5 +++-- src/IconBar.cc | 3 ++- src/Tab.hh | 6 +++--- src/Toolbar.cc | 6 ++++-- src/Window.cc | 3 ++- 7 files changed, 18 insertions(+), 11 deletions(-) diff --git a/src/Ewmh.cc b/src/Ewmh.cc index 5c88b77..f077932 100644 --- a/src/Ewmh.cc +++ b/src/Ewmh.cc @@ -19,7 +19,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: Ewmh.cc,v 1.13 2003/03/04 21:41:05 fluxgen Exp $ +// $Id: Ewmh.cc,v 1.14 2003/04/09 17:20:00 rathnor Exp $ #include "Ewmh.hh" @@ -33,6 +33,7 @@ using namespace std; Ewmh::Ewmh() { createAtoms(); + enableUpdate(); } Ewmh::~Ewmh() { diff --git a/src/FbWinFrame.cc b/src/FbWinFrame.cc index 2564263..3bd9bfa 100644 --- a/src/FbWinFrame.cc +++ b/src/FbWinFrame.cc @@ -19,7 +19,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: FbWinFrame.cc,v 1.15 2003/04/03 22:37:43 rathnor Exp $ +// $Id: FbWinFrame.cc,v 1.16 2003/04/09 17:20:01 rathnor Exp $ #include "FbWinFrame.hh" #include "ImageControl.hh" @@ -67,6 +67,7 @@ FbWinFrame::FbWinFrame(FbWinFrameTheme &theme, FbTk::ImageControl &imgctrl, m_bevel(1), m_use_titlebar(true), m_use_handle(true), + m_focused(false), m_button_pm(0), m_themelistener(*this) { // m_shape(new Shape(m_window, 0)) { //Shape::TOPLEFT | Shape::TOPRIGHT)) { diff --git a/src/Gnome.cc b/src/Gnome.cc index 44a593b..13484c4 100644 --- a/src/Gnome.cc +++ b/src/Gnome.cc @@ -19,7 +19,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: Gnome.cc,v 1.13 2003/03/04 11:13:42 fluxgen Exp $ +// $Id: Gnome.cc,v 1.14 2003/04/09 17:20:01 rathnor Exp $ #include "Gnome.hh" @@ -33,6 +33,7 @@ using namespace std; Gnome::Gnome() { createAtoms(); + enableUpdate(); } Gnome::~Gnome() { @@ -160,7 +161,7 @@ void Gnome::updateClientList(BScreen &screen) { XA_CARDINAL, 32, PropModeReplace, (unsigned char *)wl, num); - delete wl; + delete[] wl; } void Gnome::updateWorkspaceNames(BScreen &screen) { diff --git a/src/IconBar.cc b/src/IconBar.cc index cf3139e..e549e79 100644 --- a/src/IconBar.cc +++ b/src/IconBar.cc @@ -19,7 +19,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: IconBar.cc,v 1.27 2003/04/09 13:00:21 fluxgen Exp $ +// $Id: IconBar.cc,v 1.28 2003/04/09 17:20:02 rathnor Exp $ #include "IconBar.hh" @@ -80,6 +80,7 @@ unsigned int IconBarObj::height() const { IconBar::IconBar(BScreen *scrn, Window parent, FbTk::Font &font): m_screen(scrn), m_parent(parent), + m_focus_pm(None), m_vertical(false), m_font(font) { diff --git a/src/Tab.hh b/src/Tab.hh index ab50882..3681c09 100644 --- a/src/Tab.hh +++ b/src/Tab.hh @@ -19,15 +19,15 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: Tab.hh,v 1.17 2002/12/01 13:42:00 rathnor Exp $ +// $Id: Tab.hh,v 1.18 2003/04/09 17:20:03 rathnor Exp $ #ifndef TAB_HH #define TAB_HH #include #include -class FluxboxWindow; - +//class FluxboxWindow; +#include "Window.hh" /** Note: Tab is a friend of FluxboxWindow */ diff --git a/src/Toolbar.cc b/src/Toolbar.cc index 4bb877d..00a70e8 100644 --- a/src/Toolbar.cc +++ b/src/Toolbar.cc @@ -22,7 +22,7 @@ // FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER // DEALINGS IN THE SOFTWARE. -// $Id: Toolbar.cc,v 1.67 2003/03/23 04:18:59 rathnor Exp $ +// $Id: Toolbar.cc,v 1.68 2003/04/09 17:20:04 rathnor Exp $ #include "Toolbar.hh" @@ -194,7 +194,9 @@ Toolbar::Frame::Frame(FbTk::EventHandler &evh, int screen_num): nwbutton(ArrowButton::RIGHT, // arrow type window, // parent 0, 0, // pos - 1, 1) // size + 1, 1), // size + hour(-1), // start with invalid number to force update + minute(-1) { FbTk::EventManager &evm = *FbTk::EventManager::instance(); diff --git a/src/Window.cc b/src/Window.cc index 5692008..ab1f201 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.129 2003/03/22 05:13:08 rathnor Exp $ +// $Id: Window.cc,v 1.130 2003/04/09 17:20:06 rathnor Exp $ #include "Window.hh" @@ -202,6 +202,7 @@ FluxboxWindow::FluxboxWindow(Window w, BScreen *s, int screen_num, decorations.enabled = true; // set client window client.window = w; + client.window_group = None; // set default values for decoration decorations.menu = true; //override menu option -- cgit v0.11.2