Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/orxonox/trunk/gui/orxonox_gui_banner.cc @ 3157

Last change on this file since 3157 was 3154, checked in by bensch, 19 years ago

orxonox/trunk/gui: gtk-fix if window gets closed by windowManager

File size: 2.0 KB
RevLine 
[2581]1/*
2   orxonox - the future of 3D-vertical-scrollers
3
4   Copyright (C) 2004 orx
5
6   This program is free software; you can redistribute it and/or modify
7   it under the terms of the GNU General Public License as published by
8   the Free Software Foundation; either version 2, or (at your option)
9   any later version.
10
11   This program is distributed in the hope that it will be useful,
12   but WITHOUT ANY WARRANTY; without even the implied warranty of
13   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14   GNU General Public License for more details.
15
16   You should have received a copy of the GNU General Public License
17   along with this program; if not, write to the Free Software Foundation,
18   Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 
19
20
21   ### File Specific:
22   main-programmer: Benjamin Grauer
23
24*/
25
[2580]26#include "orxonox_gui_banner.h"
27
[2588]28/**
29   \brief Creates a new BannerEventBox and its content.
30*/
[2580]31OrxonoxGuiBanner::OrxonoxGuiBanner ()
32{
[3148]33  // Banner Itself //
[2581]34  bannerEventBox = new EventBox ("BannerEventBox");
[2580]35  bannerImage = new Image ("banner.xpm");
36  bannerEventBox->fill(bannerImage);
[3148]37
38  // Banner Window //
39  logoWindow = new Window("Logo");
[3153]40    bannerEventBox->connectSignal ("button_press_event", logoWindow, Window::windowOpen);
41
42  logoWindow->connectSignal("destroy", logoWindow, Window::windowClose);
43  logoWindow->connectSignal("delete_event", logoWindow, Window::windowClose);
[3148]44  logoEventBox = new EventBox();
45  logoBox = new Box('v');
46  logoLabel = new Label("OrxOnoX, " PACKAGE_VERSION);
47  logoImage = new Image("banner.xpm");
48  logoEventBox->fill(logoImage);
49 
50  logoBox->fill(logoLabel);
51  logoBox->fill(logoEventBox);
[3153]52  logoEventBox->connectSignal("button_press_event",logoWindow, Window::windowClose);
[3148]53 
54  logoWindow->fill (logoBox);
55 
56  Window::addWindow (logoWindow);
[2581]57}
[2580]58
[2588]59/**
60   \brief Destructs it.
61*/
[2581]62OrxonoxGuiBanner::~OrxonoxGuiBanner ()
63{
64}
[2580]65
[2588]66/**
67   \brief Returns an EventBox
68   \return The EventBox, that holds the Banner.
69*/
[2595]70Widget* OrxonoxGuiBanner::getWidget ()
[2580]71{
72  return bannerEventBox;
73}
74
75
Note: See TracBrowser for help on using the repository browser.