1 /***************************************************************************
2 * Copyright (C) 2004,2005 by Jakub Stachowski *
5 * This program is free software; you can redistribute it and/or modify *
6 * it under the terms of the GNU General Public License as published by *
7 * the Free Software Foundation; either version 2 of the License, or *
8 * (at your option) any later version. *
10 * This program is distributed in the hope that it will be useful, *
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13 * GNU General Public License for more details. *
15 * You should have received a copy of the GNU General Public License *
16 * along with this program; if not, write to the *
17 * Free Software Foundation, Inc., *
18 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
19 ***************************************************************************/
22 #include <config-runtime.h>
26 #include <QRadioButton>
30 #include <QTextStream>
33 #include <kaboutdata.h>
35 #include <kpluginfactory.h>
36 #include <kpluginloader.h>
37 #include <klineedit.h>
38 #include <kpassworddialog.h>
42 #include <dnssd/settings.h>
43 #include <dnssd/domainbrowser.h>
44 #include <QtDBus/QtDBus>
46 #define MDNSD_CONF "/etc/mdnsd.conf"
47 #define MDNSD_PID "/var/run/mdnsd.pid"
49 K_PLUGIN_FACTORY(KCMDnssdFactory
, registerPlugin
<KCMDnssd
>();)
50 K_EXPORT_PLUGIN(KCMDnssdFactory("kcmkdnssd"))
52 KCMDnssd::KCMDnssd(QWidget
*parent
, const QVariantList
&)
53 : KCModule( KCMDnssdFactory::componentData(), parent
)
56 widget
= new Ui_ConfigDialog();
57 widget
->setupUi(this);
58 setAboutData(new KAboutData("kcm_kdnssd", 0,
59 ki18n("ZeroConf configuration"),0,KLocalizedString(),KAboutData::License_GPL
,
60 ki18n("(C) 2004-2007 Jakub Stachowski")));
61 setQuickHelp(i18n("Setup services browsing with ZeroConf"));
62 addConfig(DNSSD::Configuration::self(),this);
63 setButtons( Default
|Apply
);
74 // Send signal to all kde applications which have a DNSSD::DomainBrowserPrivate instance
75 QDBusMessage message
=
76 QDBusMessage::createSignal("/libdnssd", "org.kde.DNSSD.DomainBrowser", "domainListChanged");
77 QDBusConnection::sessionBus().send(message
);
81 #include "kcmdnssd.moc"