//This file is part of QtTicTac.
//
// QTicTac is free software; you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation; either version 3 of the License, or
// (at your option) any later version.
//
// QTicTac 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 General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
//
// Copyright 2007 Jesse E. H-K
#include <QApplication>
#include "uiSettings.hpp"
namespace ttt {
UISettings
::UISettings( QWidget *parent
) : startb_
( new QPushButton( tr
( "&Start Game" ), settingsGroup_
) ),
quitb_
( new QPushButton( tr
( "&Quit" ), settingsGroup_
) ) {
vbox_->addWidget( startb_ );
vbox_->addWidget( quitb_ );
settingsGroup_->setLayout( vbox_ );
topLayout->addWidget( settingsGroup_ );
connect( quitb_, SIGNAL( clicked() ), qApp, SLOT( quit() ) );
}
}
//This file is part of QtTicTac.
//
// QTicTac is free software; you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation; either version 3 of the License, or
// (at your option) any later version.
//
// QTicTac 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 General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
//
// Copyright 2007 Jesse E. H-K
#include <QApplication>
#include "uiSettings.hpp"
namespace ttt {
UISettings::UISettings( QWidget *parent ) :
QWidget ( parent ),
settingsGroup_( new QGroupBox( this ) ),
startb_( new QPushButton( tr( "&Start Game" ), settingsGroup_ ) ),
quitb_( new QPushButton( tr( "&Quit" ), settingsGroup_ ) ) {
QVBoxLayout *topLayout = new QVBoxLayout(this);
QVBoxLayout *vbox_ = new QVBoxLayout();
vbox_->addWidget( startb_ );
vbox_->addWidget( quitb_ );
settingsGroup_->setLayout( vbox_ );
topLayout->addWidget( settingsGroup_ );
topLayout->addItem(new QSpacerItem(1,1, QSizePolicy::Fixed, QSizePolicy::Expanding ));
connect( quitb_, SIGNAL( clicked() ), qApp, SLOT( quit() ) );
}
}
To copy to clipboard, switch view to plain text mode
Bookmarks