6 #include "tdelistboxdialog.h" 11 TDEListBoxDialog::TDEListBoxDialog( TQString& _selectedString, 12 const TQString& caption, 13 const TQString& labelText, 17 : KDialogBase( parent, name, modal, caption, Ok|Cancel, Ok, true ), 18 selectedString( _selectedString ) 22 setName( "TDEListBoxDialog" ); 25 TQFrame *page = makeMainWidget(); 26 TQVBoxLayout *topLayout = new TQVBoxLayout( page, 0, spacingHint() ); 27 labelAboveLA = new TQLabel( page, "labelAboveLA" ); 28 labelAboveLA->setText( labelText ); 30 topLayout->addWidget( labelAboveLA ); 32 entriesLB = new TQListBox( page, "entriesLB" ); 34 topLayout->addWidget( entriesLB ); 36 commentBelowLA = new TQLabel( page, "commentBelowLA" ); 37 commentBelowLA->setText( "" ); 38 topLayout->addWidget( commentBelowLA ); 39 commentBelowLA->hide(); 42 connect( entriesLB, TQT_SIGNAL( highlighted( const TQString& ) ), 43 this, TQT_SLOT( highlighted( const TQString& ) ) ); 44 connect( entriesLB, TQT_SIGNAL( selected( int) ), 45 TQT_SLOT( slotOk() ) ); 47 labelAboveLA->setBuddy( entriesLB ); 53 TDEListBoxDialog::~TDEListBoxDialog() 58 void TDEListBoxDialog::setLabelAbove( const TQString& label) 60 labelAboveLA->setText( label ); 67 void TDEListBoxDialog::setCommentBelow( const TQString& comment) 69 commentBelowLA->setText( comment ); 70 if( comment.isEmpty() ) 71 commentBelowLA->hide(); 73 commentBelowLA->show(); 78 void TDEListBoxDialog::highlighted( const TQString& txt ) 83 #include "tdelistboxdialog.moc" The user rights/ACL have been fetched from the server sucessfully.
|