diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-05-31 07:49:08 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-05-31 07:49:08 +0000 |
commit | 7ef3b0e2a5e5bc9bf928e989e4f66932be096824 (patch) | |
tree | d1b924b843f78b9d9de26becb36bb8e12f7fef44 /kresources/carddav/config.h | |
parent | f4a40d0495ff26b8767cf321fa8039e5ac633c12 (diff) | |
download | tdepim-7ef3b0e2a5e5bc9bf928e989e4f66932be096824.tar.gz tdepim-7ef3b0e2a5e5bc9bf928e989e4f66932be096824.zip |
Added new carddav resource for kaddressbook
Lots of bugfixes for korganizer caldav resource
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1132701 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kresources/carddav/config.h')
-rw-r--r-- | kresources/carddav/config.h | 79 |
1 files changed, 79 insertions, 0 deletions
diff --git a/kresources/carddav/config.h b/kresources/carddav/config.h new file mode 100644 index 000000000..c71d55a55 --- /dev/null +++ b/kresources/carddav/config.h @@ -0,0 +1,79 @@ +/*========================================================================= +| KCardDAV +|-------------------------------------------------------------------------- +| (c) 2010 Timothy Pearson +| +| This project is released under the GNU General Public License. +| Please see the file COPYING for more details. +|-------------------------------------------------------------------------- +| Configuration and properties dialog + ========================================================================*/ + +#ifndef KABC_RESOURCECARDDAVCONFIG_H +#define KABC_RESOURCECARDDAVCONFIG_H + +/*========================================================================= +| INCLUDES + ========================================================================*/ + +#include "resource.h" + +#include <kdemacros.h> +#include <kresources/configwidget.h> + +class QLineEdit; +class QCheckBox; + +namespace KABC { + +class CardDavReloadConfig; +class CardDavSaveConfig; + +/*========================================================================= +| CLASS + ========================================================================*/ + +/** + * Configuration widget for CardDAV resource. + */ +class KDE_EXPORT ResourceCardDavConfig : public KRES::ConfigWidget +{ + Q_OBJECT + +public: + + ResourceCardDavConfig(QWidget *parent = 0); + +public slots: + + virtual void loadSettings(KRES::Resource *resource); + virtual void saveSettings(KRES::Resource *resource); + +protected: + + virtual void setupUI(); + +private: + + QLineEdit *mUrl; + QLineEdit *mUsername; + QLineEdit *mPassword; + QCheckBox *mRememberPassword; + CardDavReloadConfig* mReloadConfig; + CardDavSaveConfig* mSaveConfig; + + static ResourceCardDav* getCardDavResource(KRES::Resource* res); + + /** + * Returns preferences of the given ResourceCardDav object. + * @param res resource object. + * @return if preferences object is obtained successfully, it's returned. Otherwise, NULL is returned. + */ + static CardDavPrefs* getPrefs(ResourceCardDav* res); +}; + +} // namespace KABC + + +#endif // KABC_RESOURCECARDDAVCONFIG_H + |