1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189
|
/****************************************************************************
** Form implementation generated from reading ui file 'ModuleBrowser_qt.ui'
**
** Created: Mon Aug 21 18:59:50 2000
** by: The User Interface Compiler (uic)
**
** WARNING! All changes made in this file will be lost!
****************************************************************************/
#include "modulebrowser_qt.h"
#include <qbuttongroup.h>
#include <qcheckbox.h>
#include <qgroupbox.h>
#include <qheader.h>
#include <qlistview.h>
#include <qpushbutton.h>
#include <qlayout.h>
#include <qvariant.h>
#include <qtooltip.h>
#include <qwhatsthis.h>
/*
* Constructs a ModuleBrowserWidget which is a child of 'parent', with the
* name 'name' and widget flags set to 'f'
*/
ModuleBrowserWidget::ModuleBrowserWidget( QWidget* parent, const char* name, WFlags fl )
: ModuleBrowser( parent, name, fl )
{
if ( !name )
setName( "ModuleBrowserWidget" );
resize( 600, 494 );
setCaption( tr( "ModuleBrowser" ) );
grid = new QGridLayout( this );
grid->setSpacing( 6 );
grid->setMargin( 11 );
closeButton = new QPushButton( this, "closeButton" );
closeButton->setText( tr( "&Close" ) );
grid->addWidget( closeButton, 5, 1 );
propertiesButton = new QPushButton( this, "propertiesButton" );
propertiesButton->setText( tr( "&Properties" ) );
propertiesButton->setEnabled( FALSE );
grid->addWidget( propertiesButton, 2, 1 );
unregisterButton = new QPushButton( this, "unregisterButton" );
unregisterButton->setText( tr( "&Unregister" ) );
unregisterButton->setFlat( FALSE );
unregisterButton->setEnabled( FALSE );
grid->addWidget( unregisterButton, 1, 1 );
refreshButton = new QPushButton( this, "refreshButton" );
refreshButton->setText( tr( "&Refresh List" ) );
grid->addWidget( refreshButton, 0, 1 );
showColumns = new QButtonGroup( this, "showColumns" );
showColumns->setTitle( tr( "&Show Columns" ) );
showColumns->setColumnLayout(0, Qt::Vertical );
showColumns->layout()->setSpacing( 0 );
showColumns->layout()->setMargin( 0 );
vbox = new QVBoxLayout( showColumns->layout() );
vbox->setAlignment( Qt::AlignTop );
vbox->setSpacing( 6 );
vbox->setMargin( 11 );
showID = new QCheckBox( showColumns, "showID" );
showID->setText( tr( "&ID" ) );
showID->setChecked( TRUE );
vbox->addWidget( showID );
showName = new QCheckBox( showColumns, "showName" );
showName->setText( tr( "&Name" ) );
showName->setChecked( TRUE );
vbox->addWidget( showName );
showType = new QCheckBox( showColumns, "showType" );
showType->setText( tr( "&Type" ) );
showType->setChecked( TRUE );
vbox->addWidget( showType );
showVersion = new QCheckBox( showColumns, "showVersion" );
showVersion->setText( tr( "&Version" ) );
showVersion->setChecked( TRUE );
vbox->addWidget( showVersion );
showAPIVersion = new QCheckBox( showColumns, "showAPIVersion" );
showAPIVersion->setText( tr( "&API Version" ) );
showAPIVersion->setChecked( TRUE );
vbox->addWidget( showAPIVersion );
showDescription = new QCheckBox( showColumns, "showDescription" );
showDescription->setText( tr( "&Description" ) );
showDescription->setChecked( TRUE );
vbox->addWidget( showDescription );
grid->addWidget( showColumns, 3, 1 );
QSpacerItem* spacer = new QSpacerItem( 20, 156, QSizePolicy::Fixed, QSizePolicy::Expanding );
grid->addItem( spacer, 4, 1 );
moduleGroup = new QGroupBox( this, "moduleGroup" );
moduleGroup->setTitle( tr( "&Module List" ) );
moduleGroup->setColumnLayout(0, Qt::Vertical );
moduleGroup->layout()->setSpacing( 0 );
moduleGroup->layout()->setMargin( 0 );
grid_2 = new QGridLayout( moduleGroup->layout() );
grid_2->setAlignment( Qt::AlignTop );
grid_2->setSpacing( 6 );
grid_2->setMargin( 11 );
moduleListView = new QListView( moduleGroup, "moduleListView" );
moduleListView->addColumn( tr( "ID" ) );
moduleListView->addColumn( tr( "Name" ) );
moduleListView->addColumn( tr( "Type" ) );
moduleListView->addColumn( tr( "Version" ) );
moduleListView->addColumn( tr( "API Version" ) );
moduleListView->addColumn( tr( "Description" ) );
moduleListView->setSelectionMode( QListView::Extended );
moduleListView->setShowSortIndicator( TRUE );
moduleListView->setAllColumnsShowFocus( TRUE );
grid_2->addWidget( moduleListView, 0, 0 );
grid->addMultiCellWidget( moduleGroup, 0, 5, 0, 0 );
// signals and slots connections
connect( refreshButton, SIGNAL( clicked() ), this, SLOT( slotRefreshModuleList() ) );
connect( unregisterButton, SIGNAL( clicked() ), this, SLOT( slotUnregisterModules() ) );
connect( propertiesButton, SIGNAL( clicked() ), this, SLOT( slotShowModuleProperties() ) );
connect( showColumns, SIGNAL( clicked(int) ), this, SLOT( slotRefreshColumns(int) ) );
connect( closeButton, SIGNAL( clicked() ), this, SLOT( slotClose() ) );
connect( moduleListView, SIGNAL( selectionChanged() ), this, SLOT( slotSelectionChanged() ) );
connect( moduleListView, SIGNAL( doubleClicked(QListViewItem*) ), this, SLOT( slotShowModuleProperties() ) );
connect( moduleListView, SIGNAL( returnPressed(QListViewItem*) ), this, SLOT( slotShowModuleProperties() ) );
// tab order
setTabOrder( moduleListView, refreshButton );
setTabOrder( refreshButton, unregisterButton );
setTabOrder( unregisterButton, propertiesButton );
setTabOrder( propertiesButton, showID );
setTabOrder( showID, showName );
setTabOrder( showName, showType );
setTabOrder( showType, showVersion );
setTabOrder( showVersion, showAPIVersion );
setTabOrder( showAPIVersion, showDescription );
setTabOrder( showDescription, closeButton );
}
/*
* Destroys the object and frees any allocated resources
*/
ModuleBrowserWidget::~ModuleBrowserWidget()
{
// no need to delete child widgets, Qt does it all for us
}
void ModuleBrowserWidget::slotRefreshModuleList()
{
qWarning( "ModuleBrowserWidget::slotRefreshModuleList(): Not implemented yet!" );
}
void ModuleBrowserWidget::slotShowModuleProperties()
{
qWarning( "ModuleBrowserWidget::slotShowModuleProperties(): Not implemented yet!" );
}
void ModuleBrowserWidget::slotUnregisterModules()
{
qWarning( "ModuleBrowserWidget::slotUnregisterModules(): Not implemented yet!" );
}
void ModuleBrowserWidget::slotClose()
{
qWarning( "ModuleBrowserWidget::slotClose(): Not implemented yet!" );
}
void ModuleBrowserWidget::slotRefreshColumns(int)
{
qWarning( "ModuleBrowserWidget::slotRefreshColumns(int): Not implemented yet!" );
}
void ModuleBrowserWidget::slotSelectionChanged()
{
qWarning( "ModuleBrowserWidget::slotSelectionChanged(): Not implemented yet!" );
}
|