• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdepimlibs API Reference
  • KDE Home
  • Contact Us
 

akonadi

  • Akonadi
  • ContactEditorDialog
Public Types | Public Slots | Signals | Public Member Functions | List of all members
Akonadi::ContactEditorDialog Class Reference

#include <contacteditordialog.h>

Inherits KDialog.

Public Types

enum  DisplayMode { FullMode, VCardMode }
 
enum  Mode { CreateMode, EditMode }
 

Public Slots

void accept ()
 

Signals

void contactStored (const Akonadi::Item &contact)
 
void error (const QString &errMsg)
 

Public Member Functions

 ContactEditorDialog (Mode mode, QWidget *parent=0)
 
 ContactEditorDialog (Mode mode, AbstractContactEditorWidget *editorWidget, QWidget *parent=0)
 
 ContactEditorDialog (Mode mode, DisplayMode displayMode, QWidget *parent=0)
 
 ~ContactEditorDialog ()
 
ContactEditor * editor () const
 
void setContact (const Akonadi::Item &contact)
 
void setDefaultAddressBook (const Akonadi::Collection &addressbook)
 

Detailed Description

A dialog for creating or editing a contact in Akonadi.

This dialog provides a way to create a new contact or edit an existing contact in Akonadi.

Example for creating a new contact:

using namespace Akonadi;
ContactEditorDialog *dlg = new ContactEditorDialog( ContactEditorDialog::CreateMode, this );
connect( dlg, SIGNAL( contactStored( const Akonadi::Item& ) ),
this, SLOT( contactStored( const Akonadi::Item& ) ) );
dlg->show();

Example for editing an existing contact:

using namespace Akonadi;
const Item contact = ...;
ContactEditorDialog *dlg = new ContactEditorDialog( ContactEditorDialog::EditMode, this );
connect( dlg, SIGNAL( contactStored( const Akonadi::Item& ) ),
this, SLOT( contactStored( const Akonadi::Item& ) ) );
dlg->setContact( contact );
dlg->show();
Author
Tobias Koenig tokoe.nosp@m.@kde.nosp@m..org
Since
4.4

Definition at line 77 of file contacteditordialog.h.

Member Enumeration Documentation

enum Akonadi::ContactEditorDialog::Mode

Describes the mode of the editor dialog.

Enumerator
CreateMode 

Creates a new contact.

EditMode 

Edits an existing contact.

Definition at line 85 of file contacteditordialog.h.

Constructor & Destructor Documentation

ContactEditorDialog::ContactEditorDialog ( Mode  mode,
QWidget *  parent = 0 
)
explicit

Creates a new contact editor dialog with the standard editor widget.

Parameters
modeThe mode of the dialog.
parentThe parent widget of the dialog.

Definition at line 131 of file contacteditordialog.cpp.

ContactEditorDialog::ContactEditorDialog ( Mode  mode,
AbstractContactEditorWidget *  editorWidget,
QWidget *  parent = 0 
)

Creates a new contact editor dialog with a custom editor widget.

Parameters
modeThe mode of the dialog.
editorWidgetThe contact editor widget that shall be used for editing.
parentThe parent widget of the dialog.

Definition at line 136 of file contacteditordialog.cpp.

ContactEditorDialog::ContactEditorDialog ( Mode  mode,
DisplayMode  displayMode,
QWidget *  parent = 0 
)

Creates a new contact editor dialog with a custom editor widget.

Parameters
modeThe mode of the dialog.
displayModeThe mode of displaying: full or vcard
parentThe parent widget of the dialog.
Since
4.10

Definition at line 141 of file contacteditordialog.cpp.

ContactEditorDialog::~ContactEditorDialog ( )

Destroys the contact editor dialog.

Definition at line 146 of file contacteditordialog.cpp.

Member Function Documentation

void Akonadi::ContactEditorDialog::contactStored ( const Akonadi::Item &  contact)
signal

This signal is emitted whenever a contact was updated or stored.

Parameters
contactThe data reference of the contact.
ContactEditor * ContactEditorDialog::editor ( ) const

Returns the ContactEditor that is used by this dialog.

Definition at line 166 of file contacteditordialog.cpp.

void Akonadi::ContactEditorDialog::error ( const QString &  errMsg)
signal

This signal is emitted whenever a contact is not updated or stored.

Parameters
errMsgThe error during updating or storing contact.
void ContactEditorDialog::setContact ( const Akonadi::Item &  contact)

Sets the contact to edit when in EditMode.

Parameters
contactthe contact to edit
Note
The contact item just must have a uid set, all other data are fetched by the dialog automatically.

Definition at line 152 of file contacteditordialog.cpp.

void ContactEditorDialog::setDefaultAddressBook ( const Akonadi::Collection &  addressbook)

Sets the addressbook that shall be selected as default in create mode.

Definition at line 157 of file contacteditordialog.cpp.


The documentation for this class was generated from the following files:
  • contacteditordialog.h
  • contacteditordialog.cpp
This file is part of the KDE documentation.
Documentation copyright © 1996-2014 The KDE developers.
Generated on Tue Oct 14 2014 23:00:28 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

akonadi

Skip menu "akonadi"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • Modules
  • Related Pages

kdepimlibs API Reference

Skip menu "kdepimlibs API Reference"
  • akonadi
  •   contact
  •   kmime
  •   socialutils
  • kabc
  • kalarmcal
  • kblog
  • kcal
  • kcalcore
  • kcalutils
  • kholidays
  • kimap
  • kldap
  • kmbox
  • kmime
  • kpimidentities
  • kpimtextedit
  • kresources
  • ktnef
  • kxmlrpcclient
  • microblog

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal