//
// QPerforce is a gui interface to the perforce revision control
// system. It is based on the qt library, and should be easily portable
// across any platform that has this toolkit available.
//
// Copyright (C) 2002 Jacob Gladish
//
// This program 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 2
// of the License, or (at your option) any later version.
//
// This program 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, write to the Free Software
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
//
#ifndef __Q_PERFORCE_WINDOW_H__
#define __Q_PERFORCE_WINDOW_H__
#include <qmainwindow.h>
#include "WidgetId.h"
class BranchSpecMenu;
class BranchSpecTable;
class ChangeListMenu;
class ClientSpecMenu;
class EditMenu;
class FileMenu;
class HelpMenu;
class JobMenu;
class JobTable;
class LabelMenu;
class SettingsMenu;
class StatusPane;
class SubmittedChangeListsTable;
class ToolsMenu;
class UserMenu;
class QLineEdit;
class QMenuBar;
class QSplitter;
class QStatusBar;
class QWidgetStack;
class QToolBar;
class UserTable;
class ViewMenu;
class qperforceWindow : public QMainWindow
{
Q_OBJECT
private:
qperforceWindow( QWidget* parent = 0,
const char* name = 0,
WFlags f = WType_TopLevel );
public slots:
void showWidget( WidgetId id );
public:
static qperforceWindow* getInstance();
//======================================================================
// winow system status bar.
//
void showStatusBar( bool b );
void setStatusMessage( const QString& m );
//======================================================================
// user message window
//
void appendUserMessage( const QString& s );
private:
static qperforceWindow* _instance;
QMenuBar* _menuBar;
QStatusBar* _statusBar;
QToolBar* _toolBar;
//===================================================================
// Top left and right title text boxes
//
QLineEdit* _leftPaneTitle;
QLineEdit* _rightPaneTitle;
//===================================================================
// Top Level Layout
QSplitter* _verticalSplitter;
QSplitter* _topHorizontalSplitter;
//===================================================================
// Top Horizontal Menus
//
FileMenu* _fileMenu;
EditMenu* _editMenu;
ViewMenu* _viewMenu;
SettingsMenu* _settingsMenu;
ChangeListMenu* _changelistMenu;
BranchSpecMenu* _branchSpecMenu;
ClientSpecMenu* _clientSpecMenu;
LabelMenu* _labelMenu;
UserMenu* _userMenu;
JobMenu* _jobMenu;
ToolsMenu* _toolsMenu;
HelpMenu* _helpMenu;
//======================================================================
// right panel widgets
//
QWidgetStack* _rightWidgetStack;
UserTable* _userTable;
SubmittedChangeListsTable* _submittedChangeListsTable;
BranchSpecTable* _branchSpecTable;
JobTable* _jobTable;
//======================================================================
//======================================================================
// bottom status pane
StatusPane* _statusPane;
private:
void buildMenuBar();
void buildToolBar();
void buildRightWidgetStack();
};
#endif