From 47aae9120db93e3120a35ce145ae7b7358890ae4 Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Thu, 31 May 2012 01:31:04 -0500 Subject: Initial import of skeleton for development --- src/Makefile.am | 19 +++++++++ src/ldapcontroller.cpp | 82 +++++++++++++++++++++++++++++++++++++++ src/ldapcontroller.desktop | 17 +++++++++ src/ldapcontroller.h | 54 ++++++++++++++++++++++++++ src/ldapcontrollerconfigbase.ui | 85 +++++++++++++++++++++++++++++++++++++++++ 5 files changed, 257 insertions(+) create mode 100644 src/Makefile.am create mode 100644 src/ldapcontroller.cpp create mode 100644 src/ldapcontroller.desktop create mode 100644 src/ldapcontroller.h create mode 100644 src/ldapcontrollerconfigbase.ui (limited to 'src') diff --git a/src/Makefile.am b/src/Makefile.am new file mode 100644 index 0000000..e78843e --- /dev/null +++ b/src/Makefile.am @@ -0,0 +1,19 @@ +INCLUDES = $(all_includes) +METASOURCES = AUTO + +# Install this plugin in the KDE modules directory +kde_module_LTLIBRARIES = kcm_ldapcontroller.la + +kcm_ldapcontroller_la_SOURCES = ldapcontroller.cpp ldapcontrollerconfigbase.ui +kcm_ldapcontroller_la_LIBADD = -lkio $(LIB_TDEUI) +kcm_ldapcontroller_la_LDFLAGS = -avoid-version -module -no-undefined \ + $(all_libraries) + + +xdg_apps_DATA = ldapcontroller.desktop + + +messages: rc.cpp + $(EXTRACTRC) `find -name \*.ui -o -name \*.rc` > rc.cpp + $(XGETTEXT) *.cpp -o $(podir)/kcmldapcontroller.pot + diff --git a/src/ldapcontroller.cpp b/src/ldapcontroller.cpp new file mode 100644 index 0000000..addb8ad --- /dev/null +++ b/src/ldapcontroller.cpp @@ -0,0 +1,82 @@ +/*************************************************************************** + * Copyright (C) 2012 by Timothy Pearson * + * kb9vqf@pearsoncomputing.net * + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * (at your option) any later version. * + * * + * This program is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * + * GNU General Public License for more details. * + * * + * You should have received a copy of the GNU General Public License * + * along with this program; if not, write to the * + * Free Software Foundation, Inc., * + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * + ***************************************************************************/ + +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include "ldapcontroller.h" + +typedef KGenericFactory ldapFactory; + +K_EXPORT_COMPONENT_FACTORY( kcm_ldapcontroller, ldapFactory("kcmldapcontroller")) + +LDAPController::LDAPController(TQWidget *parent, const char *name, const TQStringList&) + : KCModule(parent, name), myAboutData(0) +{ + // FIXME + // Add UI base widget to 'this' + + load(); + + KAboutData* about = new KAboutData("ldapcontroller", I18N_NOOP("TDE LDAP Controller"), "0.1", + I18N_NOOP("TDE LDAP Controller Control Panel Module"), + KAboutData::License_GPL, + I18N_NOOP("(c) 2012 Timothy Pearson"), 0, 0); + + about->addAuthor("Timothy Pearson", 0, "kb9vqf@pearsoncomputing.net"); + setAboutData( about ); +}; + +LDAPController::~LDAPController() { +} + +void LDAPController::load() { + // +} + +void LDAPController::defaults() { + // +} + +void LDAPController::save() { + // +} + +int LDAPController::buttons() { + return KCModule::Apply|KCModule::Help; +} + +TQString LDAPController::quickHelp() const +{ + return i18n("This module configures an LDAP Realm Controller."); +} diff --git a/src/ldapcontroller.desktop b/src/ldapcontroller.desktop new file mode 100644 index 0000000..006b8b5 --- /dev/null +++ b/src/ldapcontroller.desktop @@ -0,0 +1,17 @@ +[Desktop Entry] +Encoding=UTF-8 +Exec=kcmshell ldapcontroller +Icon=tdmconfig +Type=Application + +X-KDE-ModuleType=Library +X-KDE-Library=ldapcontroller +X-KDE-HasReadOnlyMode=false +X-KDE-ParentApp=kcontrol + +[Desktop Entry] +Encoding=UTF-8 +Comment=A KControl tool for configuring an LDAP Realm Controller +Keywords=ldap controller +Name=LDAP Realm Controller +Categories=Qt;KDE;X-KDE-settings-components; diff --git a/src/ldapcontroller.h b/src/ldapcontroller.h new file mode 100644 index 0000000..9fdac57 --- /dev/null +++ b/src/ldapcontroller.h @@ -0,0 +1,54 @@ +/*************************************************************************** + * Copyright (C) 2012 by Timothy Pearson * + * kb9vqf@pearsoncomputing.net * + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * (at your option) any later version. * + * * + * This program is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * + * GNU General Public License for more details. * + * * + * You should have received a copy of the GNU General Public License * + * along with this program; if not, write to the * + * Free Software Foundation, Inc., * + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * + ***************************************************************************/ + +#ifndef _LDAPCONTROLLER_H_ +#define _LDAPCONTROLLER_H_ + +#include +#include +#include +#include +#include +#include +#include +#include + +#include "ldapconfigbase.h" + +class LDAPController: public KCModule +{ + Q_OBJECT + + public: + LDAPController( TQWidget *parent=0, const char *name=0, const TQStringList& = TQStringList() ); + ~LDAPController(); + + virtual void load(); + virtual void save(); + virtual void defaults(); + virtual int buttons(); + virtual TQString quickHelp() const; + virtual const KAboutData *aboutData() const { return myAboutData; }; + + private: + KAboutData *myAboutData; +}; + +#endif // _LDAPCONTROLLER_H_ diff --git a/src/ldapcontrollerconfigbase.ui b/src/ldapcontrollerconfigbase.ui new file mode 100644 index 0000000..ecb0d87 --- /dev/null +++ b/src/ldapcontrollerconfigbase.ui @@ -0,0 +1,85 @@ + +LDAPControllerConfigBase + + + LDAPControllerConfigBase + + + + 0 + 0 + 519 + 356 + + + + + unnamed + + + + TabWidget2 + + + true + + + + tab + + + LDAP Realms + + + + unnamed + + + + groupGlobal + + + Global Settings + + + + unnamed + + + + systemRole + + + + + + + Spacer4 + + + Vertical + + + Expanding + + + + 20 + 20 + + + + + + + + + + LDAPControllerConfigBase.ui.h + + + kdialog.h + + + + -- cgit v1.2.3