From 69d6f756dd346e59e68f48357663e44730e361e1 Mon Sep 17 00:00:00 2001 From: fgerlits Date: Wed, 8 Jun 2005 18:01:56 +0000 Subject: [PATCH] fixed bug #966 --- .../include/LiveSupport/Widgets/WhiteWindow.h | 6 +++--- .../modules/widgets/src/WhiteWindow.cxx | 18 +++++++++--------- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/livesupport/modules/widgets/include/LiveSupport/Widgets/WhiteWindow.h b/livesupport/modules/widgets/include/LiveSupport/Widgets/WhiteWindow.h index 9c2cd4520..9071e2dc0 100644 --- a/livesupport/modules/widgets/include/LiveSupport/Widgets/WhiteWindow.h +++ b/livesupport/modules/widgets/include/LiveSupport/Widgets/WhiteWindow.h @@ -22,7 +22,7 @@ Author : $Author: fgerlits $ - Version : $Revision: 1.13 $ + Version : $Revision: 1.14 $ Location : $Source: /home/paul/cvs2svn-livesupport/newcvsrepo/livesupport/modules/widgets/include/LiveSupport/Widgets/WhiteWindow.h,v $ ------------------------------------------------------------------------------*/ @@ -94,7 +94,7 @@ using namespace LiveSupport::Core; * * * @author $Author: fgerlits $ - * @version $Revision: 1.13 $ + * @version $Revision: 1.14 $ * @see WidgetFactory * @see WidgetFactory#getWhiteWindowCorners */ @@ -124,7 +124,7 @@ class WhiteWindow : public Gtk::Window /** * The event box for the title, enabling capturing mouse events. */ - Gtk::EventBox * titleEventBox; + Gtk::HBox * titleBox; /** * The left alignment contaner for the title. diff --git a/livesupport/modules/widgets/src/WhiteWindow.cxx b/livesupport/modules/widgets/src/WhiteWindow.cxx index 8b4c4126d..c9f0ce4f7 100644 --- a/livesupport/modules/widgets/src/WhiteWindow.cxx +++ b/livesupport/modules/widgets/src/WhiteWindow.cxx @@ -22,7 +22,7 @@ Author : $Author: fgerlits $ - Version : $Revision: 1.16 $ + Version : $Revision: 1.17 $ Location : $Source: /home/paul/cvs2svn-livesupport/newcvsrepo/livesupport/modules/widgets/src/WhiteWindow.cxx,v $ ------------------------------------------------------------------------------*/ @@ -67,8 +67,8 @@ WhiteWindow :: WhiteWindow(WidgetFactory::ImageType title, titleLabel = 0; Ptr::Ref wf = WidgetFactory::getInstance(); Gtk::Image* titleImage = Gtk::manage(wf->createImage(title)); - titleEventBox = Gtk::manage(new Gtk::EventBox()); - titleEventBox->add(*titleImage); + titleBox = Gtk::manage(new Gtk::HBox()); + titleBox->add(*titleImage); constructWindow(backgroundColor, cornerImages, resizable); } @@ -90,8 +90,8 @@ WhiteWindow :: WhiteWindow(Glib::ustring title, titleLabel->modify_font(Pango::FontDescription( "Bitstream Vera Sans 10")); set_title(title); - titleEventBox = Gtk::manage(new Gtk::EventBox()); - titleEventBox->add(*titleLabel); + titleBox = Gtk::manage(new Gtk::HBox()); + titleBox->add(*titleLabel); constructWindow(backgroundColor, cornerImages, resizable); } @@ -119,11 +119,11 @@ WhiteWindow :: constructWindow(Colors::ColorName backgroundColor, Gdk::Color bgColor = Colors::getColor(backgroundColor); // create the title - titleEventBox->modify_bg(Gtk::STATE_NORMAL, bgColor); + titleBox->modify_bg(Gtk::STATE_NORMAL, bgColor); titleAlignment = Gtk::manage(new Gtk::Alignment(Gtk::ALIGN_LEFT, Gtk::ALIGN_CENTER, 0, 0)); - titleAlignment->add(*titleEventBox); + titleAlignment->add(*titleBox); layout->attach(*titleAlignment, 0, 1, 0, 1, Gtk::FILL, Gtk::SHRINK); // create the minimize, maximize and close buttons @@ -177,8 +177,8 @@ WhiteWindow :: constructWindow(Colors::ColorName backgroundColor, show_all(); // register signal handlers - titleEventBox->add_events(Gdk::BUTTON_PRESS_MASK); - titleEventBox->signal_button_press_event().connect(sigc::mem_fun(*this, + this->add_events(Gdk::BUTTON_PRESS_MASK); + this->signal_button_press_event().connect(sigc::mem_fun(*this, &WhiteWindow::onTitleClicked)); minimizeButton->signal_clicked().connect(sigc::mem_fun(*this,