Commit 28a35860 authored by Tobias Koenig's avatar Tobias Koenig
Browse files

Add WhatsThis information to most actions

BUG: 207130

svn path=/trunk/KDE/kdepim/kaddressbook/; revision=1023370
parent 82a9a1b0
......@@ -263,7 +263,7 @@ void MainWidget::setupActions( KActionCollection *collection )
KToggleAction *toggleAction = 0;
action = KStandardAction::print( this, SLOT( print() ), collection );
action->setWhatsThis( i18n( "Print a special number of contacts." ) );
action->setWhatsThis( i18n( "Print the complete address book or a selected number of contacts." ) );
action = collection->addAction( "quick_search" );
action->setText( i18n( "Quick search" ) );
......@@ -272,6 +272,7 @@ void MainWidget::setupActions( KActionCollection *collection )
action = collection->addAction( "select_all" );
action->setText( i18n( "Select All" ) );
action->setShortcut( QKeySequence( Qt::CTRL + Qt::Key_A ) );
action->setWhatsThis( i18n( "Select all contacts in the current address book view." ) );
connect( action, SIGNAL( triggered( bool ) ), mItemView, SLOT( selectAll() ) );
toggleAction = collection->add<KToggleAction>( "options_show_collectionview" );
......@@ -297,51 +298,61 @@ void MainWidget::setupActions( KActionCollection *collection )
toggleAction = collection->add<KToggleAction>( "options_show_simplegui" );
toggleAction->setText( i18n( "Show Simple View" ) );
action->setWhatsThis( i18n( "Show a simple mode of the address book view." ) );
connect( toggleAction, SIGNAL( toggled( bool ) ), SLOT( setSimpleGuiMode( bool ) ) );
// import actions
action = collection->addAction( "file_import_vcard" );
action->setText( i18n( "Import vCard..." ) );
action->setWhatsThis( i18n( "Import contacts from a vCard file." ) );
mXXPortManager->addImportAction( action, "vcard30" );
action = collection->addAction( "file_import_csv" );
action->setText( i18n( "Import CSV file..." ) );
action->setWhatsThis( i18n( "Import contacts from a file in comma separated value format." ) );
mXXPortManager->addImportAction( action, "csv" );
action = collection->addAction( "file_import_ldif" );
action->setText( i18n( "Import LDIF file..." ) );
action->setWhatsThis( i18n( "Import contacts from a LDIF file." ) );
mXXPortManager->addImportAction( action, "ldif" );
action = collection->addAction( "file_import_ldap" );
action->setText( i18n( "Import from LDAP server..." ) );
action->setWhatsThis( i18n( "Import contacts from a LDAP server." ) );
mXXPortManager->addImportAction( action, "ldap" );
action = collection->addAction( "file_import_gmx" );
action->setText( i18n( "Import GMX file..." ) );
action->setWhatsThis( i18n( "Import contacts from a GMX address book file." ) );
mXXPortManager->addImportAction( action, "gmx" );
// export actions
action = collection->addAction( "file_export_vcard30" );
action->setText( i18n( "Export vCard 3.0..." ) );
action->setWhatsThis( i18n( "Export contacts to a vCard 3.0 file." ) );
mXXPortManager->addExportAction( action, "vcard30" );
action = collection->addAction( "file_export_vcard21" );
action->setText( i18n( "Export vCard 2.1..." ) );
action->setWhatsThis( i18n( "Export contacts to a vCard 2.1 file." ) );
mXXPortManager->addExportAction( action, "vcard21" );
action = collection->addAction( "file_export_csv" );
action->setText( i18n( "Export CSV file..." ) );
action->setWhatsThis( i18n( "Export contacts to a file in comma separated value format." ) );
mXXPortManager->addExportAction( action, "csv" );
action = collection->addAction( "file_export_ldif" );
action->setText( i18n( "Export LDIF file..." ) );
action->setWhatsThis( i18n( "Export contacts to a LDIF file." ) );
mXXPortManager->addExportAction( action, "ldif" );
action = collection->addAction( "file_export_gmx" );
action->setText( i18n( "Export GMX file..." ) );
action->setWhatsThis( i18n( "Export contacts to a GMX address book file." ) );
mXXPortManager->addExportAction( action, "gmx" );
}
void MainWidget::print()
......
......@@ -49,12 +49,19 @@ class StandardContactActionManager::Private
mGenericManager->createAllActions();
mGenericManager->action( Akonadi::StandardActionManager::CreateCollection )->setText( i18n( "Add Address Book Folder..." ) );
mGenericManager->action( Akonadi::StandardActionManager::CreateCollection )->setWhatsThis( i18n( "Add a new address book folder to the currently selected address book folder." ) );
mGenericManager->setActionText( Akonadi::StandardActionManager::CopyCollections, ki18np( "Copy Address Book Folder", "Copy %1 Address Book Folders" ) );
mGenericManager->action( Akonadi::StandardActionManager::CopyCollections )->setWhatsThis( i18n( "Copy the selected address book folders to the clipboard." ) );
mGenericManager->action( Akonadi::StandardActionManager::DeleteCollections )->setText( i18n( "Delete Address Book Folder" ) );
mGenericManager->action( Akonadi::StandardActionManager::DeleteCollections )->setWhatsThis( i18n( "Delete the selected address book folders from the address book." ) );
mGenericManager->action( Akonadi::StandardActionManager::SynchronizeCollections )->setText( i18n( "Reload" ) );
mGenericManager->action( Akonadi::StandardActionManager::SynchronizeCollections)->setWhatsThis( i18n( "Reloads the contacts from Akonadi and updates the address book view." ) );
mGenericManager->action( Akonadi::StandardActionManager::CollectionProperties )->setText( i18n( "Properties..." ) );
mGenericManager->action( Akonadi::StandardActionManager::CollectionProperties)->setWhatsThis( i18n( "Open a dialog to edit the properties of the selected address book folder." ) );
mGenericManager->setActionText( Akonadi::StandardActionManager::CopyItems, ki18np( "Copy Contact", "Copy %1 Contacts" ) );
mGenericManager->action( Akonadi::StandardActionManager::CopyItems )->setWhatsThis( i18n( "Copy the selected contacts to the clipboard." ) );
mGenericManager->setActionText( Akonadi::StandardActionManager::DeleteItems, ki18np( "Delete Contact", "Delete %1 Contacts" ) );
mGenericManager->action( Akonadi::StandardActionManager::DeleteItems )->setWhatsThis( i18n( "Delete the selected contacts from the address book." ) );
}
~Private()
......@@ -265,6 +272,7 @@ KAction* StandardContactActionManager::createAction( Type type )
action = new KAction( d->mParentWidget );
action->setIcon( KIcon( "document-edit" ) );
action->setText( i18n( "Edit Contact..." ) );
action->setWhatsThis( i18n( "Edit the selected contact<p>You will be presented with a dialog where you can edit all data about a person, including addresses and phone numbers.</p>" ) );
action->setEnabled( false );
d->mActions.insert( EditItem, action );
d->mActionCollection->addAction( QString::fromLatin1( "akonadi_contact_item_edit" ), action );
......@@ -274,6 +282,7 @@ KAction* StandardContactActionManager::createAction( Type type )
action = new KAction( d->mParentWidget );
action->setIcon( KIcon( "folder-new" ) );
action->setText( i18n( "Add &Address Book..." ) );
action->setWhatsThis( i18n( "Add a new address book<p>You will be presented with a dialog where you can select the type of the address book that shall be added.</p>" ) );
d->mActions.insert( CreateAddressBook, action );
d->mActionCollection->addAction( QString::fromLatin1( "akonadi_addressbook_create" ), action );
connect( action, SIGNAL( triggered( bool ) ), this, SLOT( addAddressBookTriggered() ) );
......@@ -282,6 +291,7 @@ KAction* StandardContactActionManager::createAction( Type type )
action = new KAction( d->mParentWidget );
action->setIcon( KIcon( "edit-delete" ) );
action->setText( i18n( "&Delete Address Book" ) );
action->setWhatsThis( i18n( "Delete the selected address book<p>The currently selected address book and all contained contacts and contact groups will be deleted.</p>" ) );
action->setVisible( false );
d->mActions.insert( DeleteAddressBook, action );
d->mActionCollection->addAction( QString::fromLatin1( "akonadi_addressbook_delete" ), action );
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment