Skip to content
Snippets Groups Projects
Commit 6c13efbe authored by Jan Möbius's avatar Jan Möbius
Browse files

Added empty about widget

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@3528 383ad7c9-94d9-4d36-a494-682f7c89f535
parent ca1374e7
No related branches found
No related tags found
No related merge requests found
...@@ -13,7 +13,7 @@ glew() ...@@ -13,7 +13,7 @@ glew()
DIRECTORIES = ../ ../Core ../Logging \ DIRECTORIES = ../ ../Core ../Logging \
../Scripting ../Scripting/scriptPrototypes ../Scripting/scriptWrappers ../SimpleOpt \ ../Scripting ../Scripting/scriptPrototypes ../Scripting/scriptWrappers ../SimpleOpt \
../widgets/addEmptyWidget ../widgets/coreWidget ../widgets/helpBrowser \ ../widgets/aboutWidget ../widgets/addEmptyWidget ../widgets/coreWidget ../widgets/helpBrowser \
../widgets/loadWidget ../widgets/optionsWidget ../widgets/unloadPluginsWidget \ ../widgets/loadWidget ../widgets/optionsWidget ../widgets/unloadPluginsWidget \
../widgets/viewModeWidget ../widgets/viewModeWidget
......
#== SYSTEM PART -- DON'T TOUCH ==============================================
include $(ACGMAKE)/Config
#==============================================================================
SUBDIRS = $(call find-subdirs)
PACKAGES := qt4 glut opengl x11 math ACG2 openmesh2
PROJ_LIBS =
MODULES := uic4compat moc4 cxx
#== SYSTEM PART -- DON'T TOUCH ==============================================
include $(ACGMAKE)/Rules
#==============================================================================
#include "aboutWidget.hh"
#include <QtGui>
#include <OpenFlipper/common/GlobalOptions.hh>
AboutWidget::AboutWidget(QWidget *parent )
: QMainWindow(parent)
{
setupUi(this);
QIcon icon;
icon.addFile(OpenFlipper::Options::iconDirStr()+OpenFlipper::Options::dirSeparator()+"window-close.png");
actionClose->setIcon(icon);
connect( actionClose , SIGNAL(triggered() ) , this, SLOT(hide()) );
connect( closeButton , SIGNAL(clicked() ) , this, SLOT(hide()) );
}
#include "ui_aboutWidget.hh"
#include <QtGui>
class AboutWidget : public QMainWindow, public Ui::AboutWidget
{
Q_OBJECT
public:
AboutWidget(QWidget *parent = 0);
};
<ui version="4.0" >
<class>AboutWidget</class>
<widget class="QMainWindow" name="AboutWidget" >
<property name="geometry" >
<rect>
<x>0</x>
<y>0</y>
<width>517</width>
<height>567</height>
</rect>
</property>
<property name="windowTitle" >
<string>About OpenFlipper</string>
</property>
<widget class="QWidget" name="centralwidget" >
<property name="geometry" >
<rect>
<x>0</x>
<y>25</y>
<width>517</width>
<height>517</height>
</rect>
</property>
<layout class="QVBoxLayout" name="verticalLayout" >
<item>
<widget class="QTabWidget" name="About" >
<property name="currentIndex" >
<number>0</number>
</property>
<widget class="QWidget" name="tab" >
<property name="geometry" >
<rect>
<x>0</x>
<y>0</y>
<width>495</width>
<height>431</height>
</rect>
</property>
<attribute name="title" >
<string>OpenFlipper</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_2" >
<item>
<widget class="QTextEdit" name="OpenFlipperAbout" />
</item>
</layout>
</widget>
</widget>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout" >
<item>
<spacer name="horizontalSpacer" >
<property name="orientation" >
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0" >
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QPushButton" name="closeButton" >
<property name="text" >
<string>Close</string>
</property>
</widget>
</item>
</layout>
</item>
</layout>
</widget>
<widget class="QMenuBar" name="menubar" >
<property name="geometry" >
<rect>
<x>0</x>
<y>0</y>
<width>517</width>
<height>25</height>
</rect>
</property>
<widget class="QMenu" name="menuFile" >
<property name="title" >
<string>File</string>
</property>
<addaction name="actionClose" />
</widget>
<addaction name="menuFile" />
</widget>
<widget class="QStatusBar" name="statusbar" >
<property name="geometry" >
<rect>
<x>0</x>
<y>542</y>
<width>517</width>
<height>25</height>
</rect>
</property>
</widget>
<action name="actionClose" >
<property name="text" >
<string>Close</string>
</property>
</action>
</widget>
<resources/>
<connections/>
</ui>
//=============================================================================
//
// OpenFlipper
// Copyright (C) 2008 by Computer Graphics Group, RWTH Aachen
// www.openflipper.org
//
//-----------------------------------------------------------------------------
//
// License
//
// OpenFlipper is free software: you can redistribute it and/or modify
// it under the terms of the GNU Lesser General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// OpenFlipper is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public License
// along with OpenFlipper. If not, see <http://www.gnu.org/licenses/>.
//
//-----------------------------------------------------------------------------
//
// $Revision: 1720 $
// $Author: moebius $
// $Date: 2008-05-09 14:15:53 +0200 (Fri, 09 May 2008) $
//
//=============================================================================
//=============================================================================
//
// CLASS Core - IMPLEMENTATION
//
//=============================================================================
//== INCLUDES =================================================================
#include "CoreWidget.hh"
#include <OpenFlipper/common/GlobalOptions.hh>
//== IMPLEMENTATION ==========================================================
void CoreWidget::showAboutWidget( ) {
if ( OpenFlipper::Options::nogui() )
return;
if ( aboutWidget_ == 0 ) {
aboutWidget_ = new AboutWidget( this );
}
aboutWidget_->show();
}
//=============================================================================
...@@ -82,6 +82,7 @@ CoreWidget( QVector<ViewMode*>& _viewModes, ...@@ -82,6 +82,7 @@ CoreWidget( QVector<ViewMode*>& _viewModes,
stackedWidget_(0), stackedWidget_(0),
helpBrowserDeveloper_(0), helpBrowserDeveloper_(0),
helpBrowserUser_(0), helpBrowserUser_(0),
aboutWidget_(0),
optionsWidget_(0), optionsWidget_(0),
plugins_(_plugins) plugins_(_plugins)
......
...@@ -67,6 +67,7 @@ ...@@ -67,6 +67,7 @@
#include <QDockWidget> #include <QDockWidget>
#include <OpenFlipper/widgets/aboutWidget/aboutWidget.hh>
#include <OpenFlipper/widgets/optionsWidget/optionsWidget.hh> #include <OpenFlipper/widgets/optionsWidget/optionsWidget.hh>
#include <OpenFlipper/widgets/helpBrowser/helpWidget.hh> #include <OpenFlipper/widgets/helpBrowser/helpWidget.hh>
...@@ -433,6 +434,21 @@ public: ...@@ -433,6 +434,21 @@ public:
/** @} */ /** @} */
//===========================================================================
/** @name About System
* @{ */
//===========================================================================
public slots:
/// Display the about widget
void showAboutWidget();
private:
/// Pointer to the about widget
AboutWidget* aboutWidget_;
/** @} */
//=========================================================================== //===========================================================================
/** @name Options System /** @name Options System
* @{ */ * @{ */
......
...@@ -268,7 +268,7 @@ void CoreWidget::setupMenuBar() ...@@ -268,7 +268,7 @@ void CoreWidget::setupMenuBar()
icon.addFile(OpenFlipper::Options::iconDirStr()+OpenFlipper::Options::dirSeparator()+"help-about.png"); icon.addFile(OpenFlipper::Options::iconDirStr()+OpenFlipper::Options::dirSeparator()+"help-about.png");
AC_About->setIcon(icon); AC_About->setIcon(icon);
AC_About->setWhatsThis("This entry shows information about <b>OpenFlipper</b>"); AC_About->setWhatsThis("This entry shows information about <b>OpenFlipper</b>");
// connect(AC_HelpBrowser, SIGNAL(triggered()), this, SIGNAL(showHelpBrowser())); connect(AC_About, SIGNAL(triggered()), this, SLOT(showAboutWidget()));
helpMenu_->addAction(AC_About); helpMenu_->addAction(AC_About);
// Add Menu entries to the main Toolbar // Add Menu entries to the main Toolbar
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment