author | alwin <alwin> | 2004-03-02 12:21:11 (UTC) |
---|---|---|
committer | alwin <alwin> | 2004-03-02 12:21:11 (UTC) |
commit | b6b1c97559c0ed9f2e33632272426bf98f289232 (patch) (side-by-side diff) | |
tree | d3a9987704770cdf5eb14e1136f6e3ecb2f36a04 /library | |
parent | 0d59c780513da78033f4d9040475dee9db0256d4 (diff) | |
download | opie-b6b1c97559c0ed9f2e33632272426bf98f289232.zip opie-b6b1c97559c0ed9f2e33632272426bf98f289232.tar.gz opie-b6b1c97559c0ed9f2e33632272426bf98f289232.tar.bz2 |
applied the patch generated by the optimize_connect script from
TT.
-rw-r--r-- | library/datebookmonth.cpp | 28 | ||||
-rw-r--r-- | library/fileselector.cpp | 16 | ||||
-rw-r--r-- | library/finddialog.cpp | 12 | ||||
-rw-r--r-- | library/findwidget_p.cpp | 4 | ||||
-rw-r--r-- | library/ir.cpp | 4 | ||||
-rw-r--r-- | library/network.cpp | 4 | ||||
-rw-r--r-- | library/qcopenvelope_qws.cpp | 4 | ||||
-rw-r--r-- | library/qpeapplication.cpp | 12 | ||||
-rw-r--r-- | library/qpedialog.cpp | 4 | ||||
-rw-r--r-- | library/storage.cpp | 4 | ||||
-rw-r--r-- | library/timestring.cpp | 2 | ||||
-rw-r--r-- | library/tzselect.cpp | 8 |
12 files changed, 49 insertions, 53 deletions
diff --git a/library/datebookmonth.cpp b/library/datebookmonth.cpp index 76e022f..421559e 100644 --- a/library/datebookmonth.cpp +++ b/library/datebookmonth.cpp @@ -60,27 +60,27 @@ DateBookMonthHeader::DateBookMonthHeader( QWidget *parent, const char *name ) next->setPixmap( Resource::loadPixmap( "forward" ) ); next->setAutoRaise( TRUE ); next->setFixedSize( next->sizeHint() ); QWhatsThis::add( next, tr("Show the next month") ); end = new QToolButton( this ); end->setFocusPolicy(NoFocus); end->setPixmap( Resource::loadPixmap( "finish" ) ); end->setAutoRaise( TRUE ); end->setFixedSize( end->sizeHint() ); QWhatsThis::add( end, tr("Show December in the selected year") ); - connect( month, SIGNAL( activated( int ) ), + connect( month, SIGNAL( activated(int) ), this, SLOT( updateDate() ) ); - connect( year, SIGNAL( valueChanged( int ) ), + connect( year, SIGNAL( valueChanged(int) ), this, SLOT( updateDate() ) ); connect( begin, SIGNAL( clicked() ), this, SLOT( firstMonth() ) ); connect( end, SIGNAL( clicked() ), this, SLOT( lastMonth() ) ); connect( back, SIGNAL( clicked() ), this, SLOT( monthBack() ) ); connect( next, SIGNAL( clicked() ), this, SLOT( monthForward() ) ); back->setAutoRepeat( TRUE ); next->setAutoRepeat( TRUE ); } @@ -178,28 +178,28 @@ DateBookMonthTable::DateBookMonthTable( QWidget *parent, const char *name, horizontalHeader()->resizeSection( i, 30 ); setColumnStretchable( i, TRUE ); } setupLabels(); verticalHeader()->hide(); setLeftMargin( 0 ); for ( int i = 0; i < 6; ++i ) setRowStretchable( i, TRUE ); setSelectionMode( NoSelection ); - connect( this, SIGNAL( clicked( int, int, int, const QPoint & ) ), - this, SLOT( dayClicked( int, int ) ) ); - connect( this, SIGNAL( currentChanged( int, int ) ), - this, SLOT( dragDay( int, int ) ) ); + connect( this, SIGNAL( clicked(int,int,int,const QPoint&) ), + this, SLOT( dayClicked(int,int) ) ); + connect( this, SIGNAL( currentChanged(int,int) ), + this, SLOT( dragDay(int,int) ) ); setVScrollBarMode( AlwaysOff ); setHScrollBarMode( AlwaysOff ); } DateBookMonthTable::~DateBookMonthTable() { monthsEvents.clear(); delete d; } void DateBookMonthTable::setDate(int y, int m, int d) { @@ -385,28 +385,28 @@ DateBookMonth::DateBookMonth( QWidget *parent, const char *name, bool ac, autoClose( ac ) { setFocusPolicy(StrongFocus); year = QDate::currentDate().year(); month = QDate::currentDate().month(); day = QDate::currentDate().day(); header = new DateBookMonthHeader( this, "DateBookMonthHeader" ); table = new DateBookMonthTable( this, "DateBookMonthTable", data ); header->setDate( year, month ); table->setDate( year, month, QDate::currentDate().day() ); header->setFocusPolicy(NoFocus); table->setFocusPolicy(NoFocus); - connect( header, SIGNAL( dateChanged( int, int ) ), - this, SLOT( setDate( int, int ) ) ); - connect( table, SIGNAL( dateClicked( int, int, int ) ), - this, SLOT( finalDate(int, int, int) ) ); + connect( header, SIGNAL( dateChanged(int,int) ), + this, SLOT( setDate(int,int) ) ); + connect( table, SIGNAL( dateClicked(int,int,int) ), + this, SLOT( finalDate(int,int,int) ) ); connect( qApp, SIGNAL(weekChanged(bool)), this, SLOT(slotWeekChange(bool)) ); table->setFocus(); } DateBookMonth::~DateBookMonth() { } void DateBookMonth::setDate( int y, int m ) { @@ -687,28 +687,28 @@ DateButton::DateButton( bool longDate, QWidget *parent, const char * name ) } void DateButton::pickDate() { static QPopupMenu *m1 = 0; static DateBookMonth *picker = 0; if ( !m1 ) { m1 = new QPopupMenu( this ); picker = new DateBookMonth( m1, 0, TRUE ); m1->insertItem( picker ); - connect( picker, SIGNAL( dateClicked( int, int, int ) ), - this, SLOT( setDate( int, int, int ) ) ); - connect( picker, SIGNAL( dateClicked( int, int, int ) ), - this, SIGNAL( dateSelected( int, int, int ) ) ); + connect( picker, SIGNAL( dateClicked(int,int,int) ), + this, SLOT( setDate(int,int,int) ) ); + connect( picker, SIGNAL( dateClicked(int,int,int) ), + this, SIGNAL( dateSelected(int,int,int) ) ); connect( m1, SIGNAL( aboutToHide() ), this, SLOT( gotHide() ) ); } picker->slotWeekChange( weekStartsMonday ); picker->setDate( currDate.year(), currDate.month(), currDate.day() ); m1->popup(mapToGlobal(QPoint(0,height()))); picker->setFocus(); } void DateButton::gotHide() { diff --git a/library/fileselector.cpp b/library/fileselector.cpp index 7c29aba..93fb429 100644 --- a/library/fileselector.cpp +++ b/library/fileselector.cpp @@ -299,53 +299,53 @@ FileSelector::FileSelector( const QString &f, QWidget *parent, const char *name, QToolButton *tb = new QToolButton( d->toolbar ); tb->setPixmap( Resource::loadPixmap( "close" ) ); connect( tb, SIGNAL( clicked() ), this, SIGNAL( closeMe() ) ); buttonClose = tb; tb->setFixedSize( 18, 20 ); // tb->sizeHint() ); tb->setAutoRaise( TRUE ); QToolTip::add( tb, tr( "Close the File Selector" ) ); QPEMenuToolFocusManager::manager()->addWidget( tb ); view = new FileSelectorView( this, "fileview" ); QPEApplication::setStylusOperation( view->viewport(), QPEApplication::RightOnHold ); - connect( view, SIGNAL( mouseButtonClicked( int, QListViewItem *, const QPoint &, int ) ), - this, SLOT( fileClicked( int, QListViewItem *, const QPoint &, int ) ) ); - connect( view, SIGNAL( mouseButtonPressed( int, QListViewItem *, const QPoint &, int ) ), - this, SLOT( filePressed( int, QListViewItem *, const QPoint &, int ) ) ); - connect( view, SIGNAL( returnPressed( QListViewItem * ) ), - this, SLOT( fileClicked( QListViewItem * ) ) ); + connect( view, SIGNAL( mouseButtonClicked(int,QListViewItem*,const QPoint&,int) ), + this, SLOT( fileClicked(int,QListViewItem*,const QPoint&,int) ) ); + connect( view, SIGNAL( mouseButtonPressed(int,QListViewItem*,const QPoint&,int) ), + this, SLOT( filePressed(int,QListViewItem*,const QPoint&,int) ) ); + connect( view, SIGNAL( returnPressed(QListViewItem*) ), + this, SLOT( fileClicked(QListViewItem*) ) ); QHBox *hb = new QHBox( this ); d->typeCombo = new TypeCombo( hb ); connect( d->typeCombo, SIGNAL(selected(const QString&)), this, SLOT(typeSelected(const QString&)) ); QWhatsThis::add( d->typeCombo, tr("Show documents of this type") ); Categories c; c.load(categoryFileName()); QArray<int> vl( 0 ); d->catSelect = new CategorySelect( hb ); d->catSelect->setRemoveCategoryEdit( TRUE ); d->catSelect->setCategories( vl, "Document View", tr("Document View") ); d->catSelect->setAllCategories( TRUE ); connect( d->catSelect, SIGNAL(signalSelected(int)), this, SLOT(catSelected(int)) ); QWhatsThis::add( d->catSelect, tr("Show documents in this category") ); setCloseVisible( closeVisible ); QCopChannel *channel = new QCopChannel( "QPE/Card", this ); - connect( channel, SIGNAL(received(const QCString &, const QByteArray &)), - this, SLOT(cardMessage( const QCString &, const QByteArray &)) ); + connect( channel, SIGNAL(received(const QCString&,const QByteArray&)), + this, SLOT(cardMessage(const QCString&,const QByteArray&)) ); reread(); updateWhatsThis(); } /*! Destroys the widget. */ FileSelector::~FileSelector() { delete d; } diff --git a/library/finddialog.cpp b/library/finddialog.cpp index 64487c9..9417179 100644 --- a/library/finddialog.cpp +++ b/library/finddialog.cpp @@ -34,32 +34,28 @@ A find dialog. FIXME!!!! */ FindDialog::FindDialog( const QString &appName, QWidget *parent, const char *name, bool modal ) : QDialog( parent, name, modal ) { setCaption( tr("Find") ); QVBoxLayout *vb; vb = new QVBoxLayout( this ); fw = new FindWidget( appName, this, "Find Widget" ); vb->addWidget( fw ); - QObject::connect( fw, SIGNAL(signalFindClicked(const QString&, - bool,bool,int)), - this, SIGNAL(signalFindClicked(const QString&, - bool,bool,int)) ); - QObject::connect( fw, SIGNAL(signalFindClicked(const QString&,const QDate&, - bool,bool,int)), - this, SIGNAL(signalFindClicked(const QString&, - const QDate&,bool,bool,int)) ); + QObject::connect( fw, SIGNAL(signalFindClicked(const QString&,bool,bool,int)), + this, SIGNAL(signalFindClicked(const QString&,bool,bool,int)) ); + QObject::connect( fw, SIGNAL(signalFindClicked(const QString&,const QDate&,bool,bool,int)), + this, SIGNAL(signalFindClicked(const QString&,const QDate&,bool,bool,int)) ); d = 0; } FindDialog::~FindDialog() { } QString FindDialog::findText() const { return fw->findText(); } diff --git a/library/findwidget_p.cpp b/library/findwidget_p.cpp index e91d789..0591f07 100644 --- a/library/findwidget_p.cpp +++ b/library/findwidget_p.cpp @@ -38,26 +38,26 @@ FindWidget::FindWidget( const QString &appName, QWidget *parent, cmbCat->setCategories( vl, mStrApp ); cmbCat->setRemoveCategoryEdit( TRUE ); cmbCat->setAllCategories( TRUE ); // hide junk for the moment... lblStartDate->hide(); cmdStartDate->hide(); QPopupMenu *m1 = new QPopupMenu( this ); dtPicker = new DateBookMonth( m1, 0, TRUE ); dtPicker->setDate( mDate.year(), mDate.month(), mDate.day() ); m1->insertItem( dtPicker ); cmdStartDate->setPopup( m1 ); cmdStartDate->setText( TimeString::shortDate(mDate) ); - QObject::connect( dtPicker, SIGNAL(dateClicked(int, int, int)), - this, SLOT(slotDateChanged(int, int, int)) ); + QObject::connect( dtPicker, SIGNAL(dateClicked(int,int,int)), + this, SLOT(slotDateChanged(int,int,int)) ); QObject::connect( cmdFind, SIGNAL(clicked()), this, SLOT(slotFindClicked()) ); } FindWidget::~FindWidget() { } QString FindWidget::findText() const { return txtFind->text(); diff --git a/library/ir.cpp b/library/ir.cpp index 32c0925..c581eb1 100644 --- a/library/ir.cpp +++ b/library/ir.cpp @@ -39,26 +39,26 @@ \ingroup qtopiaemb */ /*! Constructs an Ir object. The \a parent and \a name classes are the standard QObject parameters. */ Ir::Ir( QObject *parent, const char *name ) : QObject( parent, name ) { #ifndef QT_NO_COP ch = new QCopChannel( "QPE/Obex" ); - connect( ch, SIGNAL(received(const QCString &, const QByteArray &)), - this, SLOT(obexMessage( const QCString &, const QByteArray &)) ); + connect( ch, SIGNAL(received(const QCString&,const QByteArray&)), + this, SLOT(obexMessage(const QCString&,const QByteArray&)) ); #endif } /*! Returns TRUE if the system supports infrared communication; otherwise returns FALSE. */ bool Ir::supported() { #ifndef QT_NO_COP return QCopChannel::isRegistered( "QPE/Obex" ); #endif diff --git a/library/network.cpp b/library/network.cpp index 991e11a..df28857 100644 --- a/library/network.cpp +++ b/library/network.cpp @@ -152,26 +152,26 @@ QStringList Network::choices(QListBox* lb, const QString& dir) return list; } class NetworkServer : public QCopChannel { Q_OBJECT public: NetworkServer(QObject* parent) : QCopChannel("QPE/Network",parent), wait(0) { up = FALSE; examineNetworks( TRUE ); QCopChannel* card = new QCopChannel("QPE/Card",parent); - connect(card,SIGNAL(received(const QCString &, const QByteArray&)), - this,SLOT(cardMessage(const QCString &, const QByteArray&))); + connect(card,SIGNAL(received(const QCString&,const QByteArray&)), + this,SLOT(cardMessage(const QCString&,const QByteArray&))); } ~NetworkServer() { stop(); } bool networkOnline() const { return up; } diff --git a/library/qcopenvelope_qws.cpp b/library/qcopenvelope_qws.cpp index 8f58787..63efb13 100644 --- a/library/qcopenvelope_qws.cpp +++ b/library/qcopenvelope_qws.cpp @@ -59,26 +59,26 @@ The \c{channelname} of channels within Qtopia all start with "QPE/". The \c{messagename} is a function identifier followed by a list of types in parentheses. There is no whitespace in the message name. To receive a message, you will generally just use your application's predefined QPE/Application/\e{appname} channel (see QPEApplication::appMessage()), but you can make another channel and connect it to a slot like this: \code myChannel = new QCopChannel( "QPE/FooBar", this ); - connect( myChannel, SIGNAL(received(const QCString &, const QByteArray &)), - this, SLOT(fooBarMessage( const QCString &, const QByteArray &)) ); + connect( myChannel, SIGNAL(received(const QCString&,const QByteArray&)), + this, SLOT(fooBarMessage(const QCString&,const QByteArray&)) ); \endcode See also, the \link qcop.html list of Qtopia messages\endlink. */ /*! Constructs a QCopEnvelope that will write \a message to \a channel. If \a message has parameters, you must then use operator<<() to add these parameters to the envelope. */ QCopEnvelope::QCopEnvelope( const QCString& channel, const QCString& message ) : QDataStream(new QBuffer), diff --git a/library/qpeapplication.cpp b/library/qpeapplication.cpp index 262221e..c339a78 100644 --- a/library/qpeapplication.cpp +++ b/library/qpeapplication.cpp @@ -619,48 +619,48 @@ QPEApplication::QPEApplication( int & argc, char **argv, Type t ) else if ( dw > 200 ) { setFont( QFont( "vera", 10 ) ); AppLnk::setSmallIconSize( 14 ); AppLnk::setBigIconSize( 32 ); } QMimeSourceFactory::setDefaultFactory( new ResourceMimeFactory ); connect( this, SIGNAL( lastWindowClosed() ), this, SLOT( hideOrQuit() ) ); sysChannel = new QCopChannel( "QPE/System", this ); - connect( sysChannel, SIGNAL( received( const QCString &, const QByteArray & ) ), - this, SLOT( systemMessage( const QCString &, const QByteArray & ) ) ); + connect( sysChannel, SIGNAL( received(const QCString&,const QByteArray&) ), + this, SLOT( systemMessage(const QCString&,const QByteArray&) ) ); /* COde now in initapp */ #if 0 #if defined(Q_WS_QWS) && !defined(QT_NO_COP) QString qcopfn( "/tmp/qcop-msg-" ); qcopfn += QString( argv[ 0 ] ); // append command name QFile f( qcopfn ); if ( f.open( IO_ReadOnly ) ) { flock( f.handle(), LOCK_EX ); } QCString channel = QCString( argv[ 0 ] ); channel.replace( QRegExp( ".*/" ), "" ); d->appName = channel; channel = "QPE/Application/" + channel; pidChannel = new QCopChannel( channel, this ); - connect( pidChannel, SIGNAL( received( const QCString &, const QByteArray & ) ), - this, SLOT( pidMessage( const QCString &, const QByteArray & ) ) ); + connect( pidChannel, SIGNAL( received(const QCString&,const QByteArray&) ), + this, SLOT( pidMessage(const QCString&,const QByteArray&) ) ); if ( f.isOpen() ) { d->keep_running = FALSE; QDataStream ds( &f ); QCString channel, message; QByteArray data; while ( !ds.atEnd() ) { ds >> channel >> message >> data; d->enqueueQCop( channel, message, data ); } flock( f.handle(), LOCK_UN ); @@ -742,26 +742,26 @@ void QPEApplication::initApp( int argc, char **argv ) QCString channel = QCString(argv[0]); channel.replace(QRegExp(".*/"),""); d->appName = channel; #if QT_VERSION > 235 qt_fbdpy->setIdentity( channel ); // In Qt/E 2.3.6 #endif channel = "QPE/Application/" + channel; pidChannel = new QCopChannel( channel, this); - connect( pidChannel, SIGNAL(received(const QCString &, const QByteArray &)), - this, SLOT(pidMessage(const QCString &, const QByteArray &))); + connect( pidChannel, SIGNAL(received(const QCString&,const QByteArray&)), + this, SLOT(pidMessage(const QCString&,const QByteArray&))); processQCopFile(); d->keep_running = d->qcopq.isEmpty(); for (int a=0; a<argc; a++) { if ( qstrcmp(argv[a],"-preload")==0 ) { argv[a] = argv[a+1]; a++; d->preloaded = TRUE; argc-=1; diff --git a/library/qpedialog.cpp b/library/qpedialog.cpp index ac42972..da461b7 100644 --- a/library/qpedialog.cpp +++ b/library/qpedialog.cpp @@ -40,26 +40,26 @@ if( QPEApplication::execDialog(dialog) == QDialog::Accept ){ // do some stuff } delete dialog; * \endcode * * @param di The dialog to handle */ QPEDialogListener::QPEDialogListener(QDialog *di ) : QObject(di) { dialog = di; - connect(qApp, SIGNAL(appMessage(const QCString&, const QByteArray&)), - this, SLOT(appMessage(const QCString&, const QByteArray&)) ); + connect(qApp, SIGNAL(appMessage(const QCString&,const QByteArray&)), + this, SLOT(appMessage(const QCString&,const QByteArray&)) ); } /** * d'tor */ QPEDialogListener::~QPEDialogListener() {} /** * \internal */ void QPEDialogListener::appMessage( const QCString &msg, const QByteArray & ) diff --git a/library/storage.cpp b/library/storage.cpp index 0ea465b..fcee689 100644 --- a/library/storage.cpp +++ b/library/storage.cpp @@ -86,26 +86,26 @@ static bool isCF(const QString& m) \ingroup qtopiaemb */ /*! Constructor that determines the current mount points of the filesystem. The standard \a parent parameters is passed on to QObject. */ StorageInfo::StorageInfo( QObject *parent ) : QObject( parent ) { mFileSystems.setAutoDelete( TRUE ); channel = new QCopChannel( "QPE/Card", this ); - connect( channel, SIGNAL(received(const QCString &, const QByteArray &)), - this, SLOT(cardMessage( const QCString &, const QByteArray &)) ); + connect( channel, SIGNAL(received(const QCString&,const QByteArray&)), + this, SLOT(cardMessage(const QCString&,const QByteArray&)) ); update(); } /*! Returns the longest matching FileSystem that starts with the same prefix as \a filename as its mount point. */ const FileSystem *StorageInfo::fileSystemOf( const QString &filename ) { for (QListIterator<FileSystem> i(mFileSystems); i.current(); ++i) { if ( filename.startsWith( (*i)->path() ) ) return (*i); diff --git a/library/timestring.cpp b/library/timestring.cpp index 2fd0191..91c29ae 100644 --- a/library/timestring.cpp +++ b/library/timestring.cpp @@ -44,25 +44,25 @@ private: DateFormat format; TimeStringFormatKeeper() : QObject( qApp ) { Config config("qpe"); config.setGroup( "Date" ); format = DateFormat(QChar(config.readEntry("Separator", "/")[0]), (DateFormat::Order)config .readNumEntry("ShortOrder", DateFormat::DayMonthYear), (DateFormat::Order)config.readNumEntry("LongOrder", DateFormat::DayMonthYear)); connect( qApp, SIGNAL( dateFormatChanged(DateFormat) ), - this, SLOT( formatChanged( DateFormat ) ) ); + this, SLOT( formatChanged(DateFormat) ) ); } }; TimeStringFormatKeeper *TimeStringFormatKeeper::self = 0; QString DateFormat::toNumberString() const { QString buf = ""; // for each part of the order for (int i = 0; i < 3; i++) { // switch on the relavent 3 bits. switch((_shortOrder >> (i * 3)) & 0x0007) { diff --git a/library/tzselect.cpp b/library/tzselect.cpp index f28100b..848dfb7 100644 --- a/library/tzselect.cpp +++ b/library/tzselect.cpp @@ -68,26 +68,26 @@ TZCombo::TZCombo( QWidget *p, const char* n ) n++; } setCurrentItem(index); } else { setCurrentItem(0); } // listen on QPE/System #if !defined(QT_NO_COP) QCopChannel *channel = new QCopChannel( "QPE/System", this ); - connect( channel, SIGNAL(received(const QCString&, const QByteArray&)), - this, SLOT(handleSystemChannel(const QCString&, const QByteArray&)) ); + connect( channel, SIGNAL(received(const QCString&,const QByteArray&)), + this, SLOT(handleSystemChannel(const QCString&,const QByteArray&)) ); #endif } TZCombo::~TZCombo() { } void TZCombo::updateZones() { QString cur = currentText(); @@ -209,26 +209,26 @@ TimeZoneSelector::TimeZoneSelector(QWidget* p, const char* n) : QHBox(p,n) { d = new TimeZoneSelectorPrivate(); // build the combobox before we do any updates... cmbTz = new TZCombo( this, "timezone combo" ); cmdTz = new QToolButton( this, "timezone button" ); cmdTz->setIconSet( Resource::loadIconSet( "citytime_icon" ) ); cmdTz->setMaximumSize( cmdTz->sizeHint() ); // set up a connection to catch a newly selected item and throw our // signal - QObject::connect( cmbTz, SIGNAL( activated( int ) ), - this, SLOT( slotTzActive( int ) ) ); + QObject::connect( cmbTz, SIGNAL( activated(int) ), + this, SLOT( slotTzActive(int) ) ); QObject::connect( cmdTz, SIGNAL( clicked() ), this, SLOT( slotExecute() ) ); } /*! Destroys a TimeZoneSelector. */ TimeZoneSelector::~TimeZoneSelector() { } void TimeZoneSelector::setLocalIncluded(bool b) |