author | zecke <zecke> | 2002-05-21 14:21:25 (UTC) |
---|---|---|
committer | zecke <zecke> | 2002-05-21 14:21:25 (UTC) |
commit | 3eb1e88e5915c9dbd521a150cc5dd7eb7dbb3663 (patch) (side-by-side diff) | |
tree | 59f3648e8a0848457f879058b1064017b9feca66 /core/pim/addressbook/addressbook.cpp | |
parent | 54955c2fd698b2a1cf3ba8a79f2612013c8eb2f0 (diff) | |
download | opie-3eb1e88e5915c9dbd521a150cc5dd7eb7dbb3663.zip opie-3eb1e88e5915c9dbd521a150cc5dd7eb7dbb3663.tar.gz opie-3eb1e88e5915c9dbd521a150cc5dd7eb7dbb3663.tar.bz2 |
usbaility updates
Diffstat (limited to 'core/pim/addressbook/addressbook.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/pim/addressbook/addressbook.cpp | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/core/pim/addressbook/addressbook.cpp b/core/pim/addressbook/addressbook.cpp index beb953a..8229212 100644 --- a/core/pim/addressbook/addressbook.cpp +++ b/core/pim/addressbook/addressbook.cpp @@ -187,15 +187,15 @@ AddressbookWindow::AddressbookWindow( QWidget *parent, const char *name, "neccessary startup files.\n" "\nFree up some space before\nentering data!") ); } listContainer = new QWidget( this ); - + QVBoxLayout *vb = new QVBoxLayout( listContainer ); - + abList = new AbTable( &orderedFields, listContainer, "table" ); vb->addWidget(abList); abList->setHScrollBarMode( QScrollView::AlwaysOff ); connect( abList, SIGNAL( empty( bool ) ), this, SLOT( listIsEmpty( bool ) ) ); connect( abList, SIGNAL( details() ), @@ -230,13 +230,13 @@ AddressbookWindow::AddressbookWindow( QWidget *parent, const char *name, fontMenu->insertItem(tr( "Normal" ), 1); fontMenu->insertItem(tr( "Large" ), 2); defaultFont = new QFont( abList->font() ); slotSetFont(startFontSize); - + mbList->insertItem( tr("Font"), fontMenu); setCentralWidget(listContainer); // qDebug("adressbook contrsuction: t=%d", t.elapsed() ); } void AddressbookWindow::slotSetFont( int size ) { @@ -244,13 +244,13 @@ void AddressbookWindow::slotSetFont( int size ) { if (size > 2 || size < 0) size = 1; startFontSize = size; QFont *currentFont; - + switch (size) { case 0: fontMenu->setItemChecked(0, true); fontMenu->setItemChecked(1, false); fontMenu->setItemChecked(2, false); abList->setFont( QFont( defaultFont->family(), defaultFont->pointSize() - 2 ) ); @@ -468,13 +468,13 @@ static void parseName( const QString& name, QString *first, QString *middle, if ( space <= 0 ) { *first = rest; } else { *first = rest.left( space ); *middle = rest.mid( space+1 ); } - + } void AddressbookWindow::appMessage(const QCString &msg, const QByteArray &data) { if (msg == "editPersonal()") { @@ -500,13 +500,13 @@ void AddressbookWindow::appMessage(const QCString &msg, const QByteArray &data) if ( bAbEditFirstTime ) { abEditor = new ContactEditor( cnt, &orderedFields, &slOrderedFields, this, "editor" ); bAbEditFirstTime = FALSE; } else { - abEditor->setEntry( cnt ); + abEditor->setEntry( cnt ); } abView()->init( cnt ); editEntry( NewEntry ); @@ -791,13 +791,13 @@ void AddressbookWindow::initFields() } slOrderedFields.append( zn ); zn = cfg.readEntry( "Category" + QString::number(++i), QString::null ); } cfg.setGroup( "Font" ); startFontSize = cfg.readNumEntry( "fontSize", 1 ); - + } else { QString str; str = getenv("HOME"); str += "/Settings/AddressBook.conf"; QFile::remove( str ); @@ -856,20 +856,20 @@ AbLabel *AddressbookWindow::abView() void AddressbookWindow::slotFind() { #ifndef MAKE_FOR_SHARP_ROM if ( centralWidget() == abView() ) showList(); - + FindDialog frmFind( "Contacts", this ); QObject::connect( &frmFind, SIGNAL(signalFindClicked(const QString &, bool, bool, int)), abList, SLOT(slotDoFind( const QString&,bool,bool,int))); QObject::connect( abList, SIGNAL(signalNotFound()), &frmFind, SLOT(slotNotFound()) ); QObject::connect( abList, SIGNAL(signalWrapAround()), &frmFind, SLOT(slotWrapAround()) ); - + frmFind.exec(); - + if ( abList->numSelections() ) abList->clearSelection(); abList->clearFindRow(); #endif } @@ -903,12 +903,13 @@ void AddressbookWindow::populateCategories() { catMenu->clear(); int id, rememberId; id = 1; + rememberId = 0; catMenu->insertItem( tr( "All" ), id++ ); QStringList categories = abList->categories(); categories.append( tr( "Unfiled" ) ); for ( QStringList::Iterator it = categories.begin(); it != categories.end(); ++it ) { catMenu->insertItem( *it, id ); |