bool ListViewEditor::qt_invoke( int _id, QUObject* _o ) { switch ( _id - staticMetaObject()->slotOffset() ) { case 0: applyClicked(); break; case 1: columnClickable((bool)static_QUType_bool.get(_o+1)); break; case 2: columnDownClicked(); break; case 3: columnPixmapChosen(); break; case 4: columnPixmapDeleted(); break; case 5: columnResizable((bool)static_QUType_bool.get(_o+1)); break; case 6: columnTextChanged((const QString&)static_QUType_QString.get(_o+1)); break; case 7: columnUpClicked(); break; case 8: currentColumnChanged((QListBoxItem*)static_QUType_ptr.get(_o+1)); break; case 9: currentItemChanged((QListViewItem*)static_QUType_ptr.get(_o+1)); break; case 10: deleteColumnClicked(); break; case 11: itemColChanged((int)static_QUType_int.get(_o+1)); break; case 12: itemDeleteClicked(); break; case 13: itemDownClicked(); break; case 14: itemNewClicked(); break; case 15: itemNewSubClicked(); break; case 16: itemPixmapChoosen(); break; case 17: itemPixmapDeleted(); break; case 18: itemTextChanged((const QString&)static_QUType_QString.get(_o+1)); break; case 19: itemUpClicked(); break; case 20: itemLeftClicked(); break; case 21: itemRightClicked(); break; case 22: newColumnClicked(); break; case 23: okClicked(); break; case 24: initTabPage((const QString&)static_QUType_QString.get(_o+1)); break; case 25: emitItemRenamed((QListViewItem*)static_QUType_ptr.get(_o+1),(int)static_QUType_int.get(_o+2),(const QString&)static_QUType_QString.get(_o+3)); break; default: return ListViewEditorBase::qt_invoke( _id, _o ); } return TRUE; }
/* * Constructs a ListViewEditorBase as a child of 'parent', with the * name 'name' and widget flags set to 'f'. * * The dialog will by default be modeless, unless you set 'modal' to * TRUE to construct a modal dialog. */ ListViewEditorBase::ListViewEditorBase( QWidget* parent, const char* name, bool modal, WFlags fl ) : QDialog( parent, name, modal, fl ) { if ( !name ) setName( "ListViewEditorBase" ); setSizeGripEnabled( TRUE ); ListViewEditorBaseLayout = new QVBoxLayout( this, 11, 6, "ListViewEditorBaseLayout"); tabWidget = new QTabWidget( this, "tabWidget" ); Widget10 = new QWidget( tabWidget, "Widget10" ); Widget10Layout = new QGridLayout( Widget10, 1, 1, 11, 6, "Widget10Layout"); itemDelete = new QPushButton( Widget10, "itemDelete" ); Widget10Layout->addWidget( itemDelete, 2, 1 ); GroupBox1 = new QGroupBox( Widget10, "GroupBox1" ); GroupBox1->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)0, (QSizePolicy::SizeType)5, 0, 0, GroupBox1->sizePolicy().hasHeightForWidth() ) ); GroupBox1->setColumnLayout(0, Qt::Vertical ); GroupBox1->layout()->setSpacing( 6 ); GroupBox1->layout()->setMargin( 11 ); GroupBox1Layout = new QGridLayout( GroupBox1->layout() ); GroupBox1Layout->setAlignment( Qt::AlignTop ); Label2 = new QLabel( GroupBox1, "Label2" ); GroupBox1Layout->addWidget( Label2, 2, 0 ); Label1 = new QLabel( GroupBox1, "Label1" ); GroupBox1Layout->addWidget( Label1, 1, 0 ); itemText = new QLineEdit( GroupBox1, "itemText" ); itemText->setMinimumSize( QSize( 0, 0 ) ); GroupBox1Layout->addWidget( itemText, 1, 1 ); itemColumn = new QSpinBox( GroupBox1, "itemColumn" ); GroupBox1Layout->addWidget( itemColumn, 0, 1 ); Label4 = new QLabel( GroupBox1, "Label4" ); GroupBox1Layout->addWidget( Label4, 0, 0 ); Layout2 = new QHBoxLayout( 0, 0, 6, "Layout2"); itemPixmap = new QLabel( GroupBox1, "itemPixmap" ); Layout2->addWidget( itemPixmap ); itemDeletePixmap = new QPushButton( GroupBox1, "itemDeletePixmap" ); itemDeletePixmap->setMaximumSize( QSize( 30, 22 ) ); itemDeletePixmap->setPixmap( QPixmap::fromMimeSource( "designer_s_editcut.png" ) ); Layout2->addWidget( itemDeletePixmap ); itemChoosePixmap = new QPushButton( GroupBox1, "itemChoosePixmap" ); itemChoosePixmap->setMaximumSize( QSize( 30, 22 ) ); Layout2->addWidget( itemChoosePixmap ); GroupBox1Layout->addLayout( Layout2, 2, 1 ); Widget10Layout->addMultiCellWidget( GroupBox1, 0, 7, 2, 2 ); itemNew = new QPushButton( Widget10, "itemNew" ); Widget10Layout->addWidget( itemNew, 0, 1 ); itemsPreview = new QListView( Widget10, "itemsPreview" ); Widget10Layout->addMultiCellWidget( itemsPreview, 0, 7, 0, 0 ); itemNewSub = new QPushButton( Widget10, "itemNewSub" ); Widget10Layout->addWidget( itemNewSub, 1, 1 ); Vertical_Spacing1 = new QSpacerItem( 20, 20, QSizePolicy::Minimum, QSizePolicy::Expanding ); Widget10Layout->addItem( Vertical_Spacing1, 3, 1 ); itemUp = new QPushButton( Widget10, "itemUp" ); itemUp->setPixmap( QPixmap::fromMimeSource( "designer_s_up.png" ) ); Widget10Layout->addWidget( itemUp, 4, 1 ); itemDown = new QPushButton( Widget10, "itemDown" ); itemDown->setPixmap( QPixmap::fromMimeSource( "designer_s_down.png" ) ); Widget10Layout->addWidget( itemDown, 5, 1 ); itemLeft = new QPushButton( Widget10, "itemLeft" ); itemLeft->setPixmap( QPixmap::fromMimeSource( "designer_s_left.png" ) ); Widget10Layout->addWidget( itemLeft, 6, 1 ); itemRight = new QPushButton( Widget10, "itemRight" ); itemRight->setPixmap( QPixmap::fromMimeSource( "designer_s_right.png" ) ); Widget10Layout->addWidget( itemRight, 7, 1 ); tabWidget->insertTab( Widget10, QString("") ); Widget11 = new QWidget( tabWidget, "Widget11" ); Widget11Layout = new QGridLayout( Widget11, 1, 1, 11, 6, "Widget11Layout"); GroupBox1_2 = new QGroupBox( Widget11, "GroupBox1_2" ); GroupBox1_2->setColumnLayout(0, Qt::Vertical ); GroupBox1_2->layout()->setSpacing( 6 ); GroupBox1_2->layout()->setMargin( 11 ); GroupBox1Layout_2 = new QGridLayout( GroupBox1_2->layout() ); GroupBox1Layout_2->setAlignment( Qt::AlignTop ); Label2_2 = new QLabel( GroupBox1_2, "Label2_2" ); GroupBox1Layout_2->addWidget( Label2_2, 1, 0 ); colPixmap = new QLabel( GroupBox1_2, "colPixmap" ); GroupBox1Layout_2->addWidget( colPixmap, 1, 1 ); colDeletePixmap = new QPushButton( GroupBox1_2, "colDeletePixmap" ); colDeletePixmap->setMaximumSize( QSize( 30, 22 ) ); colDeletePixmap->setPixmap( QPixmap::fromMimeSource( "designer_s_editcut.png" ) ); GroupBox1Layout_2->addWidget( colDeletePixmap, 1, 2 ); colChoosePixmap = new QPushButton( GroupBox1_2, "colChoosePixmap" ); colChoosePixmap->setMaximumSize( QSize( 30, 22 ) ); GroupBox1Layout_2->addWidget( colChoosePixmap, 1, 3 ); Label1_2 = new QLabel( GroupBox1_2, "Label1_2" ); GroupBox1Layout_2->addWidget( Label1_2, 0, 0 ); colText = new QLineEdit( GroupBox1_2, "colText" ); colText->setMinimumSize( QSize( 0, 0 ) ); GroupBox1Layout_2->addMultiCellWidget( colText, 0, 0, 1, 3 ); colClickable = new QCheckBox( GroupBox1_2, "colClickable" ); GroupBox1Layout_2->addMultiCellWidget( colClickable, 2, 2, 0, 1 ); colResizable = new QCheckBox( GroupBox1_2, "colResizable" ); GroupBox1Layout_2->addMultiCellWidget( colResizable, 3, 3, 0, 1 ); Widget11Layout->addMultiCellWidget( GroupBox1_2, 0, 4, 2, 2 ); colDelete = new QPushButton( Widget11, "colDelete" ); Widget11Layout->addWidget( colDelete, 1, 1 ); colDown = new QPushButton( Widget11, "colDown" ); colDown->setPixmap( QPixmap::fromMimeSource( "designer_s_down.png" ) ); Widget11Layout->addWidget( colDown, 4, 1 ); colNew = new QPushButton( Widget11, "colNew" ); Widget11Layout->addWidget( colNew, 0, 1 ); colUp = new QPushButton( Widget11, "colUp" ); colUp->setPixmap( QPixmap::fromMimeSource( "designer_s_up.png" ) ); Widget11Layout->addWidget( colUp, 3, 1 ); colPreview = new QListBox( Widget11, "colPreview" ); Widget11Layout->addMultiCellWidget( colPreview, 0, 4, 0, 0 ); Vertical_Spacing2 = new QSpacerItem( 20, 20, QSizePolicy::Minimum, QSizePolicy::Expanding ); Widget11Layout->addItem( Vertical_Spacing2, 2, 1 ); tabWidget->insertTab( Widget11, QString("") ); ListViewEditorBaseLayout->addWidget( tabWidget ); Layout1 = new QHBoxLayout( 0, 0, 6, "Layout1"); helpButton = new QPushButton( this, "helpButton" ); helpButton->setAutoDefault( TRUE ); Layout1->addWidget( helpButton ); Horizontal_Spacing2 = new QSpacerItem( 20, 20, QSizePolicy::Expanding, QSizePolicy::Minimum ); Layout1->addItem( Horizontal_Spacing2 ); applyButton = new QPushButton( this, "applyButton" ); applyButton->setAutoDefault( TRUE ); Layout1->addWidget( applyButton ); okButton = new QPushButton( this, "okButton" ); okButton->setAutoDefault( TRUE ); okButton->setDefault( TRUE ); Layout1->addWidget( okButton ); cancelButton = new QPushButton( this, "cancelButton" ); cancelButton->setAutoDefault( TRUE ); Layout1->addWidget( cancelButton ); ListViewEditorBaseLayout->addLayout( Layout1 ); languageChange(); resize( QSize(567, 398).expandedTo(minimumSizeHint()) ); clearWState( WState_Polished ); // signals and slots connections connect( cancelButton, SIGNAL( clicked() ), this, SLOT( reject() ) ); connect( itemNew, SIGNAL( clicked() ), this, SLOT( itemNewClicked() ) ); connect( itemDelete, SIGNAL( clicked() ), this, SLOT( itemDeleteClicked() ) ); connect( itemUp, SIGNAL( clicked() ), this, SLOT( itemUpClicked() ) ); connect( itemDown, SIGNAL( clicked() ), this, SLOT( itemDownClicked() ) ); connect( itemColumn, SIGNAL( valueChanged(int) ), this, SLOT( itemColChanged(int) ) ); connect( itemText, SIGNAL( textChanged(const QString&) ), this, SLOT( itemTextChanged(const QString&) ) ); connect( itemDeletePixmap, SIGNAL( clicked() ), this, SLOT( itemPixmapDeleted() ) ); connect( itemChoosePixmap, SIGNAL( clicked() ), this, SLOT( itemPixmapChoosen() ) ); connect( colNew, SIGNAL( clicked() ), this, SLOT( newColumnClicked() ) ); connect( colDelete, SIGNAL( clicked() ), this, SLOT( deleteColumnClicked() ) ); connect( colUp, SIGNAL( clicked() ), this, SLOT( columnUpClicked() ) ); connect( colDown, SIGNAL( clicked() ), this, SLOT( columnDownClicked() ) ); connect( colText, SIGNAL( textChanged(const QString&) ), this, SLOT( columnTextChanged(const QString&) ) ); connect( colDeletePixmap, SIGNAL( clicked() ), this, SLOT( columnPixmapDeleted() ) ); connect( colChoosePixmap, SIGNAL( clicked() ), this, SLOT( columnPixmapChosen() ) ); connect( colResizable, SIGNAL( toggled(bool) ), this, SLOT( columnResizable(bool) ) ); connect( colClickable, SIGNAL( toggled(bool) ), this, SLOT( columnClickable(bool) ) ); connect( tabWidget, SIGNAL( selected(const QString&) ), this, SLOT( initTabPage(const QString&) ) ); connect( okButton, SIGNAL( clicked() ), this, SLOT( okClicked() ) ); connect( applyButton, SIGNAL( clicked() ), this, SLOT( applyClicked() ) ); connect( colPreview, SIGNAL( currentChanged(QListBoxItem*) ), this, SLOT( currentColumnChanged(QListBoxItem*) ) ); connect( colPreview, SIGNAL( selectionChanged(QListBoxItem*) ), this, SLOT( currentColumnChanged(QListBoxItem*) ) ); connect( itemsPreview, SIGNAL( currentChanged(QListViewItem*) ), this, SLOT( currentItemChanged(QListViewItem*) ) ); connect( itemsPreview, SIGNAL( selectionChanged(QListViewItem*) ), this, SLOT( currentItemChanged(QListViewItem*) ) ); connect( itemNewSub, SIGNAL( clicked() ), this, SLOT( itemNewSubClicked() ) ); connect( itemLeft, SIGNAL( clicked() ), this, SLOT( itemLeftClicked() ) ); connect( itemRight, SIGNAL( clicked() ), this, SLOT( itemRightClicked() ) ); // tab order setTabOrder( okButton, cancelButton ); setTabOrder( cancelButton, tabWidget ); setTabOrder( tabWidget, itemsPreview ); setTabOrder( itemsPreview, itemNew ); setTabOrder( itemNew, itemNewSub ); setTabOrder( itemNewSub, itemDelete ); setTabOrder( itemDelete, itemUp ); setTabOrder( itemUp, itemDown ); setTabOrder( itemDown, itemLeft ); setTabOrder( itemLeft, itemRight ); setTabOrder( itemRight, itemColumn ); setTabOrder( itemColumn, itemText ); setTabOrder( itemText, itemDeletePixmap ); setTabOrder( itemDeletePixmap, itemChoosePixmap ); setTabOrder( itemChoosePixmap, helpButton ); setTabOrder( helpButton, applyButton ); setTabOrder( applyButton, colPreview ); setTabOrder( colPreview, colNew ); setTabOrder( colNew, colDelete ); setTabOrder( colDelete, colUp ); setTabOrder( colUp, colDown ); setTabOrder( colDown, colText ); setTabOrder( colText, colDeletePixmap ); setTabOrder( colDeletePixmap, colChoosePixmap ); setTabOrder( colChoosePixmap, colClickable ); setTabOrder( colClickable, colResizable ); // buddies Label2->setBuddy( itemChoosePixmap ); Label1->setBuddy( itemText ); Label4->setBuddy( itemColumn ); Label2_2->setBuddy( colChoosePixmap ); Label1_2->setBuddy( colText ); init(); }