kdelibs update to Trinity v3.5.11

git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1061230 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
v3.5.13-sru
tpearson 15 years ago
parent ce4a32fe52
commit 865f314dd5

@ -18,7 +18,7 @@
# Boston, MA 02110-1301, USA. # Boston, MA 02110-1301, USA.
COMPILE_FIRST = dcop libltdl kdefx kdecore kunittest kdeui kdesu kjs kwallet kio COMPILE_FIRST = dcop libltdl kdefx kdecore kunittest kdeui kdesu kjs kwallet kio kded kded_post
COMPILE_BEFORE_doc = kdoctools COMPILE_BEFORE_doc = kdoctools
COMPILE_AFTER_kparts = kspell2 kmdi kdeprint kinit kate interfaces kcert khtml COMPILE_AFTER_kparts = kspell2 kmdi kdeprint kinit kate interfaces kcert khtml
COMPILE_AFTER_kdeprint = kate khtml COMPILE_AFTER_kdeprint = kate khtml

@ -8,7 +8,7 @@ libartskde_la_SOURCES = artskde.cc kioinputstream_impl.cpp kplayobject.cc \
kartsserver.cpp kdatarequest_impl.cpp kaudioconverter.cc \ kartsserver.cpp kdatarequest_impl.cpp kaudioconverter.cc \
kvideowidget.cpp kplayobjectcreator.cc \ kvideowidget.cpp kplayobjectcreator.cc \
kaudiomanagerplay.cpp kaudiomanagerplay.cpp
libartskde_la_LIBADD = $(LIB_KIO) -lqtmcop -lsoundserver_idl libartskde_la_LIBADD = $(LIB_KIO) -lqtmcop -lsoundserver_idl -lartsflow_idl -lmcop $(LIB_QT) $(LIB_KDECORE) -lkmedia2_idl -lartsflow $(LIB_KDEUI) $(LIB_X11)
libartskde_la_LDFLAGS = $(all_libraries) -no-undefined -version-info 3:0:2 libartskde_la_LDFLAGS = $(all_libraries) -no-undefined -version-info 3:0:2
libartskde_la_METASOURCES = AUTO libartskde_la_METASOURCES = AUTO
libartskde_la_COMPILE_FIRST = artskde.h libartskde_la_COMPILE_FIRST = artskde.h

@ -7,7 +7,7 @@ kde_module_LTLIBRARIES = knotify.la
knotify_la_SOURCES = knotify.cpp knotify.skel knotify_la_SOURCES = knotify.cpp knotify.skel
if include_ARTS if include_ARTS
knotify_la_LIBADD = -lsoundserver_idl -lqtmcop $(LIB_KDEUI) $(top_builddir)/arts/kde/libartskde.la knotify_la_LIBADD = -lsoundserver_idl $(LIB_KDEUI) $(top_builddir)/arts/kde/libartskde.la $(LIB_QT) $(top_builddir)/dcop/libDCOP.la $(LIB_KDECORE) -lartsflow_idl -lmcop
endif endif
knotify_la_LDFLAGS = $(all_libraries) -module -avoid-version knotify_la_LDFLAGS = $(all_libraries) -module -avoid-version
knotify_la_METASOURCES = AUTO knotify_la_METASOURCES = AUTO

@ -19,6 +19,8 @@ AC_ARG_PROGRAM
dnl Automake doc recommends to do this only here. (Janos) dnl Automake doc recommends to do this only here. (Janos)
AM_INIT_AUTOMAKE(@MODULENAME@, @VERSION@) dnl searches for some needed programs AM_INIT_AUTOMAKE(@MODULENAME@, @VERSION@) dnl searches for some needed programs
AM_MAINTAINER_MODE
AC_PROG_INSTALL AC_PROG_INSTALL
dnl generate the config header dnl generate the config header
@ -46,7 +48,7 @@ dnl Checks for header files.
KDE_CHECK_STL KDE_CHECK_STL
AC_HEADER_DIRENT AC_HEADER_DIRENT
AC_HEADER_STDC AC_HEADER_STDC
AC_CHECK_HEADERS(sys/param.h sys/mman.h sys/time.h sysent.h strings.h sys/stat.h sys/select.h paths.h malloc.h limits.h sys/soundcard.h dlfcn.h termios.h) AC_CHECK_HEADERS(sys/param.h sys/mman.h sys/time.h sysent.h strings.h sys/stat.h sys/select.h paths.h malloc.h limits.h sys/soundcard.h dlfcn.h termios.h sys/prctl.h)
AC_ARG_WITH(acl, AC_ARG_WITH(acl,
[AC_HELP_STRING(--with-acl, [AC_HELP_STRING(--with-acl,
@ -162,7 +164,7 @@ AC_CHECK_RANDOM
AC_CHECK_MKSTEMPS AC_CHECK_MKSTEMPS
AC_CHECK_MKSTEMP AC_CHECK_MKSTEMP
AC_CHECK_MKDTEMP AC_CHECK_MKDTEMP
AC_CHECK_FUNCS(strtoll socket seteuid setegid strfmon stpcpy gettimeofday readdir_r setpriority) AC_CHECK_FUNCS(strtoll socket seteuid setegid strfmon stpcpy gettimeofday readdir_r setpriority tcgetattr tcsetattr)
AH_BOTTOM([ AH_BOTTOM([
/* provide a definition for a 32 bit entity, usable as a typedef, possibly /* provide a definition for a 32 bit entity, usable as a typedef, possibly

@ -46,7 +46,7 @@ libDCOP_la_SOURCES = dcopstub.cpp dcopref.cpp dcopobject.cpp dcopclient.cpp
kdeinit_LTLIBRARIES = dcopserver.la kdeinit_LTLIBRARIES = dcopserver.la
dcopserver_la_LDFLAGS = -module -avoid-version $(all_libraries) dcopserver_la_LDFLAGS = -module -avoid-version $(all_libraries)
dcopserver_la_SOURCES = dcopserver.cpp dcopsignals.cpp dcopserver_la_SOURCES = dcopserver.cpp dcopsignals.cpp
dcopserver_la_LIBADD = libDCOP.la dcopserver_la_LIBADD = libDCOP.la $(LIB_QT)
dcopserver_shutdown_SOURCES = dcopserver_shutdown.c dcopserver_shutdown_SOURCES = dcopserver_shutdown.c

@ -1,15 +1,16 @@
#!/bin/sh #!/bin/sh
trap "rm -f dcopidlng.stderr.$$" 0 1 2 15 tmpfile=`mktemp -t dcopidlng.XXXXXX` || { echo "$0: Cannot create temporary file" >&2; exit 1; }
trap " [ -f \"$tmpfile\" ] && /bin/rm -f -- \"$tmpfile\"" 0 1 2 3 13 15
if test -z "$KDECONFIG"; then if test -z "$KDECONFIG"; then
KDECONFIG=kde-config KDECONFIG=kde-config
fi fi
LIBDIR="`$KDECONFIG --install data --expandvars`/dcopidlng" LIBDIR="`$KDECONFIG --install data --expandvars`/dcopidlng"
perl -I"$LIBDIR" "$LIBDIR/kalyptus" --allow_k_dcop_accessors -f dcopidl $1 2> dcopidlng.stderr.$$ perl -I"$LIBDIR" "$LIBDIR/kalyptus" --allow_k_dcop_accessors -f dcopidl $1 2> $tmpfile
RET=$? RET=$?
if [ $RET -ne 0 ] if [ $RET -ne 0 ]
then then
cat dcopidlng.stderr.$$ >&2 cat $tmpfile >&2
fi fi
exit $RET exit $RET

@ -1,5 +1,5 @@
# set the include path for X, qt and KDE # set the include path for X, qt and KDE
INCLUDES = -I$(top_srcdir) $(all_includes) INCLUDES = -I$(top_srcdir) $(all_includes) $(AVAHI_CFLAGS)
# these are the headers for your project # these are the headers for your project
noinst_HEADERS = sdevent.h noinst_HEADERS = sdevent.h
@ -14,7 +14,7 @@ libkdnssd_la_SOURCES = remoteservice.cpp responder.cpp servicebase.cpp \
dnssdincludedir = $(includedir)/dnssd dnssdincludedir = $(includedir)/dnssd
dnssdinclude_HEADERS = domainbrowser.h query.h remoteservice.h \ dnssdinclude_HEADERS = domainbrowser.h query.h remoteservice.h \
publicservice.h servicebase.h servicebrowser.h settings.h publicservice.h servicebase.h servicebrowser.h settings.h
libkdnssd_la_LIBADD = ../kdecore/libkdecore.la $(LIB_DNSSD) libkdnssd_la_LIBADD = ../kdecore/libkdecore.la $(AVAHI_LIBS) $(LIB_QT)
libkdnssd_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -version-info 1:0 libkdnssd_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -version-info 1:0
#kde_kcfg_DATA = kcm_kdnssd.kcfg #kde_kcfg_DATA = kcm_kdnssd.kcfg

@ -1,12 +1,11 @@
Checklist to ensure that zeroconf will work: Checklist to ensure that zeroconf will work:
1) Install Apple's mdnsd, at least version 85 1) Install Avahi, at least version 0.3
2) kdelibs (and kdebase for ksysguard) should be configured and compiled with dns_sd sdk (part 2) compile kdnssd-avahi and install it to replace 'stub' libkdnssd.so provided by kdelibs
of mdnsd installation) present - config.h should contain '#define HAVE_DNSSD 1'
3) check /etc/nsswitch.conf and ensure that there is 'mdns' before 'dns' in 3) check /etc/nsswitch.conf and ensure that there is 'mdns' before 'dns' in
line starting with 'host:'. It should be something like: line starting with 'host:'. It should be something like:
host: files mdns dns host: files mdns dns
4) ensure that mdnsd is being started in initscripts 4) ensure that avahi-daemon is being started in initscripts
5) for testing: use kpf kicker applet to publish a directory, then open 'zeroconf:/' 5) for testing: use kpf kicker applet to publish a directory, then open 'zeroconf:/'
URL in konqueror. You should be able to see a local webserver with that published dir. URL in konqueror. You should be able to see a local webserver with that published dir.

@ -1,38 +1,17 @@
#MIN_CONFIG #MIN_CONFIG
AC_ARG_ENABLE(dnssd, [ --disable-dnssd don't require libdns_sd (browsing and publishing DNS-SD services will not be possible) ], with_dnssd=$enableval, with_dnssd=yes) # Check for pkg-config manually first, as if its not installed the
if test "$with_dnssd" = "yes"; then # PKG_PROG_PKG_CONFIG macro won't be defined.
AC_MSG_CHECKING(for DNS-SD support) m4_pattern_allow(PKG_CONFIG_MIN_VERSION)
save_dnssdtest_LIBS="$LIBS" AC_CHECK_PROG(have_pkg_config, pkg-config, yes, no)
save_dnssdtest_LDFLAGS="$LDFLAGS"
save_dnssdtest_CPPFLAGS="$CPPFLAGS" if test x"$have_pkg_config" == xno; then
LDFLAGS="$all_libraries $LDFLAGS" AC_MSG_ERROR(pkg-config is required to install this program)
CPPFLAGS="$CPPFLAGS $all_includes"
case $host_os in
darwin*) LIBS="" ;;
*) LIBS="-ldns_sd" ;;
esac
have_libdns_sd="no"
AC_TRY_LINK( [
#include <dns_sd.h>
],[
DNSServiceRefDeallocate( (DNSServiceRef) 0);
TXTRecordDeallocate( (TXTRecordRef*) 0);
],[
AC_DEFINE(HAVE_DNSSD,1,[Define if dns-sd is available])
case $host_os in
darwin*) LIB_DNSSD="" ;;
*) LIB_DNSSD="-ldns_sd" ;;
esac
have_libdns_sd="yes"
AC_MSG_RESULT(yes)
],[
AC_MSG_RESULT(no)
LIB_DNSSD=""
])
CPPFLAGS=$save_dnssdtest_CPPFLAGS
LDFLAGS=$save_dnssdtest_LDFLAGS
LIBS=$save_dnssdtest_LIBS
fi fi
AC_SUBST(LIB_DNSSD)
AM_CONDITIONAL(HAVE_DNSSD, test "$have_libdns_sd" = "yes") PKG_PROG_PKG_CONFIG
PKG_CHECK_MODULES( AVAHI, [ avahi-qt3 >= 0.4 , avahi-client >= 0.4 ])
AC_SUBST(AVAHI_CFLAGS)
AC_SUBST(AVAHI_LIBS)
PKG_CHECK_EXISTS( [ avahi-client >= 0.6], AC_DEFINE(AVAHI_API_0_6,1,[Avahi API 0.6] ) )

@ -27,29 +27,38 @@
#include "query.h" #include "query.h"
#include "servicebrowser.h" #include "servicebrowser.h"
#include <kapplication.h> #include <kapplication.h>
#ifdef AVAHI_API_0_6
#include <avahi-client/lookup.h>
#endif
namespace DNSSD namespace DNSSD
{ {
#ifdef HAVE_DNSSD #ifdef AVAHI_API_0_6
void domain_callback(DNSServiceRef, DNSServiceFlags flags, uint32_t, DNSServiceErrorType errorCode, void domains_callback(AvahiDomainBrowser*, AvahiIfIndex, AvahiProtocol, AvahiBrowserEvent event, const char* replyDomain,
const char *replyDomain, void *context); AvahiLookupResultFlags, void* context);
#else
void domains_callback(AvahiDomainBrowser*, AvahiIfIndex, AvahiProtocol, AvahiBrowserEvent event, const char* replyDomain,
void* context);
#endif #endif
class DomainBrowserPrivate : public Responder
class DomainBrowserPrivate
{ {
public: public:
DomainBrowserPrivate(DomainBrowser* owner) : Responder(), m_browseLAN(false), m_started(false), m_owner(owner) {} DomainBrowserPrivate(DomainBrowser* owner) : m_browseLAN(false), m_started(false),
m_browser(0), m_owner(owner) {}
~DomainBrowserPrivate() { if (m_browser) avahi_domain_browser_free(m_browser); }
QStringList m_domains; QStringList m_domains;
virtual void customEvent(QCustomEvent* event); virtual void customEvent(QCustomEvent* event);
bool m_browseLAN; bool m_browseLAN;
bool m_started; bool m_started;
AvahiDomainBrowser* m_browser;
DomainBrowser* m_owner; DomainBrowser* m_owner;
}; };
void DomainBrowserPrivate::customEvent(QCustomEvent* event) void DomainBrowserPrivate::customEvent(QCustomEvent* event)
{ {
if (event->type()==QEvent::User+SD_ERROR) stop();
if (event->type()==QEvent::User+SD_ADDREMOVE) { if (event->type()==QEvent::User+SD_ADDREMOVE) {
AddRemoveEvent *aev = static_cast<AddRemoveEvent*>(event); AddRemoveEvent *aev = static_cast<AddRemoveEvent*>(event);
if (aev->m_op==AddRemoveEvent::Add) m_owner->gotNewDomain(aev->m_domain); if (aev->m_op==AddRemoveEvent::Add) m_owner->gotNewDomain(aev->m_domain);
@ -57,16 +66,17 @@ void DomainBrowserPrivate::customEvent(QCustomEvent* event)
} }
} }
DomainBrowser::DomainBrowser(QObject *parent) : QObject(parent) DomainBrowser::DomainBrowser(QObject *parent) : QObject(parent)
{ {
d = new DomainBrowserPrivate(this); d = new DomainBrowserPrivate(this);
d->m_domains = Configuration::domainList(); d->m_domains = Configuration::domainList();
if (Configuration::browseLocal()) { if (Configuration::browseLocal()) {
d->m_domains+="local."; d->m_domains+="local.";
d->m_browseLAN=true; d->m_browseLAN=true;
} }
connect(KApplication::kApplication(),SIGNAL(kipcMessage(int,int)),this, connect(KApplication::kApplication(),SIGNAL(kipcMessage(int,int)),this,
SLOT(domainListChanged(int,int))); SLOT(domainListChanged(int,int)));
} }
DomainBrowser::DomainBrowser(const QStringList& domains, bool recursive, QObject *parent) : QObject(parent) DomainBrowser::DomainBrowser(const QStringList& domains, bool recursive, QObject *parent) : QObject(parent)
@ -88,14 +98,15 @@ void DomainBrowser::startBrowse()
if (d->m_started) return; if (d->m_started) return;
d->m_started=true; d->m_started=true;
if (ServiceBrowser::isAvailable()!=ServiceBrowser::Working) return; if (ServiceBrowser::isAvailable()!=ServiceBrowser::Working) return;
QStringList::const_iterator itEnd = d->m_domains.end(); QStringList::const_iterator itEnd = d->m_domains.end();
for (QStringList::const_iterator it=d->m_domains.begin(); it!=itEnd; ++it ) emit domainAdded(*it); for (QStringList::const_iterator it=d->m_domains.begin(); it!=itEnd; ++it ) emit domainAdded(*it);
#ifdef HAVE_DNSSD if (d->m_browseLAN)
if (d->m_browseLAN) { #ifdef AVAHI_API_0_6
DNSServiceRef ref; d->m_browser = avahi_domain_browser_new(Responder::self().client(), AVAHI_IF_UNSPEC, AVAHI_PROTO_UNSPEC,
if (DNSServiceEnumerateDomains(&ref,kDNSServiceFlagsBrowseDomains,0,domain_callback, "local.", AVAHI_DOMAIN_BROWSER_BROWSE, (AvahiLookupFlags)0, domains_callback, this);
reinterpret_cast<void*>(d))==kDNSServiceErr_NoError) d->setRef(ref); #else
} d->m_browser = avahi_domain_browser_new(Responder::self().client(), AVAHI_IF_UNSPEC, AVAHI_PROTO_UNSPEC,
"local.", AVAHI_DOMAIN_BROWSER_BROWSE, domains_callback, this);
#endif #endif
} }
@ -115,9 +126,14 @@ void DomainBrowser::gotRemoveDomain(const QString& domain)
void DomainBrowser::domainListChanged(int message,int) void DomainBrowser::domainListChanged(int message,int)
{ {
if (message!=KIPCDomainsChanged) return; if (message!=KIPCDomainsChanged) return;
bool was_started = d->m_started; bool was_started = d->m_started;
if (d->isRunning()) d->stop(); // LAN query if (d->m_browser) {
avahi_domain_browser_free(d->m_browser); // LAN query
d->m_browser=0;
}
d->m_started = false; d->m_started = false;
// remove all domains and resolvers // remove all domains and resolvers
if (was_started) { if (was_started) {
QStringList::const_iterator itEnd = d->m_domains.end(); QStringList::const_iterator itEnd = d->m_domains.end();
@ -129,7 +145,7 @@ void DomainBrowser::domainListChanged(int message,int)
Configuration::self()->readConfig(); Configuration::self()->readConfig();
d->m_browseLAN = Configuration::browseLocal(); d->m_browseLAN = Configuration::browseLocal();
d->m_domains = Configuration::domainList(); d->m_domains = Configuration::domainList();
if (Configuration::browseLocal()) d->m_domains+="local."; if (Configuration::browseLocal()) d->m_domains+="local";
// this will emit domainAdded() for every domain if necessary // this will emit domainAdded() for every domain if necessary
if (was_started) startBrowse(); if (was_started) startBrowse();
} }
@ -147,22 +163,21 @@ bool DomainBrowser::isRunning() const
void DomainBrowser::virtual_hook(int, void*) void DomainBrowser::virtual_hook(int, void*)
{} {}
#ifdef HAVE_DNSSD #ifdef AVAHI_API_0_6
void domain_callback(DNSServiceRef, DNSServiceFlags flags, uint32_t, DNSServiceErrorType errorCode, void domains_callback(AvahiDomainBrowser*, AvahiIfIndex, AvahiProtocol, AvahiBrowserEvent event, const char* replyDomain,
const char *replyDomain, void *context) AvahiLookupResultFlags,void* context)
#else
void domains_callback(AvahiDomainBrowser*, AvahiIfIndex, AvahiProtocol, AvahiBrowserEvent event, const char* replyDomain,
void* context)
#endif
{ {
QObject *obj = reinterpret_cast<QObject*>(context); QObject *obj = reinterpret_cast<QObject*>(context);
if (errorCode != kDNSServiceErr_NoError) { AddRemoveEvent* arev=new AddRemoveEvent((event==AVAHI_BROWSER_NEW) ? AddRemoveEvent::Add :
ErrorEvent err;
QApplication::sendEvent(obj, &err);
} else {
AddRemoveEvent arev((flags & kDNSServiceFlagsAdd) ? AddRemoveEvent::Add :
AddRemoveEvent::Remove, QString::null, QString::null, AddRemoveEvent::Remove, QString::null, QString::null,
DNSToDomain(replyDomain), !(flags & kDNSServiceFlagsMoreComing)); DNSToDomain(replyDomain));
QApplication::sendEvent(obj, &arev); QApplication::postEvent(obj, arev);
}
} }
#endif
} }
#include "domainbrowser.moc" #include "domainbrowser.moc"

@ -30,6 +30,12 @@
#include <network/ksocketaddress.h> #include <network/ksocketaddress.h>
#include <kurl.h> #include <kurl.h>
#include <unistd.h> #include <unistd.h>
#include <avahi-client/client.h>
#ifdef AVAHI_API_0_6
#include <avahi-client/publish.h>
#endif
#include <avahi-common/alternative.h>
#include <avahi-common/strlst.h>
#include "sdevent.h" #include "sdevent.h"
#include "responder.h" #include "responder.h"
#include "servicebrowser.h" #include "servicebrowser.h"
@ -38,16 +44,23 @@
namespace DNSSD namespace DNSSD
{ {
static unsigned long publicIP(); static unsigned long publicIP();
#ifdef HAVE_DNSSD
void publish_callback (DNSServiceRef, DNSServiceFlags, DNSServiceErrorType errorCode, const char *name, void publish_callback (AvahiEntryGroup*, AvahiEntryGroupState s, void *context);
const char*, const char*, void *context);
#endif class PublicServicePrivate
class PublicServicePrivate : public Responder
{ {
public: public:
PublicServicePrivate() : m_published(false) PublicServicePrivate() : m_published(false), m_running(false), m_collision(false), m_group(false)
{} {}
bool m_published; bool m_published;
bool m_running;
bool m_collision;
AvahiEntryGroup* m_group;
void commit()
{
if (!m_collision) avahi_entry_group_commit(m_group);
}
}; };
PublicService::PublicService(const QString& name, const QString& type, unsigned int port, PublicService::PublicService(const QString& name, const QString& type, unsigned int port,
@ -55,6 +68,10 @@ PublicService::PublicService(const QString& name, const QString& type, unsigned
: QObject(), ServiceBase(name, type, QString::null, domain, port) : QObject(), ServiceBase(name, type, QString::null, domain, port)
{ {
d = new PublicServicePrivate; d = new PublicServicePrivate;
if (Responder::self().client()) {
d->m_group = avahi_entry_group_new(Responder::self().client(), publish_callback,this);
connect(&Responder::self(),SIGNAL(stateChanged(AvahiClientState)),this,SLOT(clientState(AvahiClientState)));
}
if (domain.isNull()) if (domain.isNull())
if (Configuration::publishType()==Configuration::EnumPublishType::LAN) m_domain="local."; if (Configuration::publishType()==Configuration::EnumPublishType::LAN) m_domain="local.";
else m_domain=Configuration::publishDomain(); else m_domain=Configuration::publishDomain();
@ -63,25 +80,34 @@ PublicService::PublicService(const QString& name, const QString& type, unsigned
PublicService::~PublicService() PublicService::~PublicService()
{ {
stop(); if (d->m_group) avahi_entry_group_free(d->m_group);
delete d; delete d;
} }
void PublicService::tryApply()
{
if (fillEntryGroup()) d->commit();
else {
stop();
emit published(false);
}
}
void PublicService::setServiceName(const QString& serviceName) void PublicService::setServiceName(const QString& serviceName)
{ {
m_serviceName = serviceName; m_serviceName = serviceName;
if (d->isRunning()) { if (d->m_running) {
stop(); avahi_entry_group_reset(d->m_group);
publishAsync(); tryApply();
} }
} }
void PublicService::setDomain(const QString& domain) void PublicService::setDomain(const QString& domain)
{ {
m_domain = domain; m_domain = domain;
if (d->isRunning()) { if (d->m_running) {
stop(); avahi_entry_group_reset(d->m_group);
publishAsync(); tryApply();
} }
} }
@ -89,88 +115,113 @@ void PublicService::setDomain(const QString& domain)
void PublicService::setType(const QString& type) void PublicService::setType(const QString& type)
{ {
m_type = type; m_type = type;
if (d->isRunning()) { if (d->m_running) {
stop(); avahi_entry_group_reset(d->m_group);
publishAsync(); tryApply();
} }
} }
void PublicService::setPort(unsigned short port) void PublicService::setPort(unsigned short port)
{ {
m_port = port; m_port = port;
if (d->isRunning()) { if (d->m_running) {
stop(); avahi_entry_group_reset(d->m_group);
publishAsync(); tryApply();
} }
}
bool PublicService::isPublished() const
{
return d->m_published;
} }
void PublicService::setTextData(const QMap<QString,QString>& textData) void PublicService::setTextData(const QMap<QString,QString>& textData)
{ {
m_textData = textData; m_textData = textData;
if (d->isRunning()) { if (d->m_running) {
stop(); avahi_entry_group_reset(d->m_group);
publishAsync(); tryApply();
} }
} }
bool PublicService::isPublished() const
{
return d->m_published;
}
bool PublicService::publish() bool PublicService::publish()
{ {
publishAsync(); publishAsync();
while (d->isRunning() && !d->m_published) d->process(); while (d->m_running && !d->m_published) Responder::self().process();
return d->m_published; return d->m_published;
} }
void PublicService::stop() void PublicService::stop()
{ {
d->stop(); if (d->m_group) avahi_entry_group_reset(d->m_group);
d->m_published = false; d->m_published = false;
}
bool PublicService::fillEntryGroup()
{
AvahiStringList *s=0;
QMap<QString,QString>::ConstIterator itEnd = m_textData.end();
for (QMap<QString,QString>::ConstIterator it = m_textData.begin(); it!=itEnd ; ++it)
s = avahi_string_list_add_pair(s, it.key().utf8(),it.data().utf8());
#ifdef AVAHI_API_0_6
bool res = (!avahi_entry_group_add_service_strlst(d->m_group, AVAHI_IF_UNSPEC, AVAHI_PROTO_UNSPEC, (AvahiPublishFlags)0,
m_serviceName.isNull() ? avahi_client_get_host_name(Responder::self().client()) : m_serviceName.utf8().data(),
m_type.ascii(),domainToDNS(m_domain),m_hostName.utf8(),m_port,s));
#else
bool res = (!avahi_entry_group_add_service_strlst(d->m_group, AVAHI_IF_UNSPEC, AVAHI_PROTO_UNSPEC,
m_serviceName.isNull() ? avahi_client_get_host_name(Responder::self().client()) : m_serviceName.utf8().data(),
m_type.ascii(),m_domain.utf8(),m_hostName.utf8(),m_port,s));
#endif
avahi_string_list_free(s);
return res;
}
void PublicService::clientState(AvahiClientState s)
{
if (!d->m_running) return;
switch (s) {
#ifdef AVAHI_API_0_6
case AVAHI_CLIENT_FAILURE:
#else
case AVAHI_CLIENT_S_INVALID:
case AVAHI_CLIENT_DISCONNECTED:
#endif
stop();
emit published(false);
break;
case AVAHI_CLIENT_S_REGISTERING:
case AVAHI_CLIENT_S_COLLISION:
avahi_entry_group_reset(d->m_group);
d->m_collision=true;
break;
case AVAHI_CLIENT_S_RUNNING:
if (d->m_collision) {
d->m_collision=false;
tryApply();
}
}
} }
void PublicService::publishAsync() void PublicService::publishAsync()
{ {
if (d->isRunning()) stop(); if (d->m_running) stop();
#ifdef HAVE_DNSSD
if (ServiceBrowser::isAvailable()==ServiceBrowser::Working) { if (!d->m_group) {
TXTRecordRef txt; emit published(false);
TXTRecordCreate(&txt,0,0); return;
QMap<QString,QString>::ConstIterator itEnd = m_textData.end();
for (QMap<QString,QString>::ConstIterator it = m_textData.begin(); it!=itEnd ; ++it) {
QCString value = it.data().utf8();
if (TXTRecordSetValue(&txt,it.key().utf8(),value.length(),value)!=kDNSServiceErr_NoError) {
TXTRecordDeallocate(&txt);
emit published(false);
return;
}
}
DNSServiceRef ref;
if (DNSServiceRegister(&ref,0,0,m_serviceName.utf8(),m_type.ascii(),domainToDNS(m_domain),NULL,
htons(m_port),TXTRecordGetLength(&txt),TXTRecordGetBytesPtr(&txt),publish_callback,
reinterpret_cast<void*>(this)) == kDNSServiceErr_NoError) d->setRef(ref);
TXTRecordDeallocate(&txt);
} }
#endif AvahiClientState s=Responder::self().state();
if (!d->isRunning()) emit published(false); d->m_running=true;
d->m_collision=true; // make it look like server is getting out of collision to force registering
clientState(s);
} }
#ifdef HAVE_DNSSD void publish_callback (AvahiEntryGroup*, AvahiEntryGroupState s, void *context)
void publish_callback (DNSServiceRef, DNSServiceFlags, DNSServiceErrorType errorCode, const char *name,
const char*, const char*, void *context)
{ {
QObject *obj = reinterpret_cast<QObject*>(context); QObject *obj = reinterpret_cast<QObject*>(context);
if (errorCode != kDNSServiceErr_NoError) { if (s!=AVAHI_ENTRY_GROUP_ESTABLISHED && s!=AVAHI_ENTRY_GROUP_COLLISION) return;
ErrorEvent err; PublishEvent* pev=new PublishEvent(s==AVAHI_ENTRY_GROUP_ESTABLISHED);
QApplication::sendEvent(obj, &err); QApplication::postEvent(obj, pev);
} else {
PublishEvent pev(QString::fromUtf8(name));
QApplication::sendEvent(obj, &pev);
}
} }
#endif
const KURL PublicService::toInvitation(const QString& host) const KURL PublicService::toInvitation(const QString& host)
{ {
@ -194,14 +245,13 @@ const KURL PublicService::toInvitation(const QString& host)
void PublicService::customEvent(QCustomEvent* event) void PublicService::customEvent(QCustomEvent* event)
{ {
if (event->type()==QEvent::User+SD_ERROR) {
stop();
emit published(false);
}
if (event->type()==QEvent::User+SD_PUBLISH) { if (event->type()==QEvent::User+SD_PUBLISH) {
if (!static_cast<PublishEvent*>(event)->m_ok) {
setServiceName(QString::fromUtf8(avahi_alternative_service_name(m_serviceName.utf8())));
return;
}
d->m_published=true; d->m_published=true;
emit published(true); emit published(true);
m_serviceName = static_cast<PublishEvent*>(event)->m_name;
} }
} }

@ -23,6 +23,7 @@
#include <qobject.h> #include <qobject.h>
#include <dnssd/servicebase.h> #include <dnssd/servicebase.h>
#include <avahi-client/client.h>
class KURL; class KURL;
namespace DNSSD namespace DNSSD
@ -137,6 +138,10 @@ signals:
void published(bool); void published(bool);
private: private:
PublicServicePrivate *d; PublicServicePrivate *d;
bool fillEntryGroup();
void tryApply();
private slots:
void clientState(AvahiClientState);
protected: protected:
virtual void customEvent(QCustomEvent* event); virtual void customEvent(QCustomEvent* event);

@ -22,26 +22,46 @@
#include "responder.h" #include "responder.h"
#include "remoteservice.h" #include "remoteservice.h"
#include "sdevent.h" #include "sdevent.h"
#include <kdebug.h> #include <qdatetime.h>
#include <qapplication.h> #include <qapplication.h>
#include <qtimer.h> #include <qtimer.h>
#define TIMEOUT_WAN 2000 #include <avahi-client/client.h>
#ifdef AVAHI_API_0_6
#include <avahi-client/lookup.h>
#endif
#define TIMEOUT_LAN 200 #define TIMEOUT_LAN 200
namespace DNSSD namespace DNSSD
{ {
#ifdef HAVE_DNSSD #ifdef AVAHI_API_0_6
void query_callback (DNSServiceRef, DNSServiceFlags flags, uint32_t, DNSServiceErrorType errorCode,
const char *serviceName, const char *regtype, const char *replyDomain, void *context); void services_callback(AvahiServiceBrowser*, AvahiIfIndex, AvahiProtocol, AvahiBrowserEvent event, const char* name,
const char* regtype, const char* domain, AvahiLookupResultFlags, void* context);
void types_callback(AvahiServiceTypeBrowser*, AvahiIfIndex, AvahiProtocol, AvahiBrowserEvent event, const char* regtype,
const char* replyDomain, AvahiLookupResultFlags, void* context);
#else
void services_callback(AvahiServiceBrowser*, AvahiIfIndex, AvahiProtocol, AvahiBrowserEvent event, const char* name,
const char* regtype, const char* domain, void* context);
void types_callback(AvahiServiceTypeBrowser*, AvahiIfIndex, AvahiProtocol, AvahiBrowserEvent event, const char* regtype,
const char* replyDomain, void* context);
void domains_callback(AvahiDomainBrowser*, AvahiIfIndex, AvahiProtocol, AvahiBrowserEvent event, const char* replyDomain,
void* context);
#endif #endif
class QueryPrivate : public Responder
enum BrowserType { Types, Services };
class QueryPrivate
{ {
public: public:
QueryPrivate(const QString& type, const QString& domain) : Responder(), m_finished(false), QueryPrivate(const QString& type, const QString& domain) : m_finished(false), m_browser(0),
m_domain(domain), m_type(type) m_running(false), m_domain(domain), m_type(type) {}
{};
bool m_finished; bool m_finished;
BrowserType m_browserType;
void* m_browser;
bool m_running;
QString m_domain; QString m_domain;
QTimer timeout; QTimer timeout;
QString m_type; QString m_type;
@ -56,12 +76,18 @@ Query::Query(const QString& type, const QString& domain)
Query::~Query() Query::~Query()
{ {
if (d->m_browser) {
switch (d->m_browserType) {
case Services: avahi_service_browser_free((AvahiServiceBrowser*)d->m_browser); break;
case Types: avahi_service_type_browser_free((AvahiServiceTypeBrowser*)d->m_browser); break;
}
}
delete d; delete d;
} }
bool Query::isRunning() const bool Query::isRunning() const
{ {
return d->isRunning(); return d->m_running;
} }
bool Query::isFinished() const bool Query::isFinished() const
@ -76,16 +102,31 @@ const QString& Query::domain() const
void Query::startQuery() void Query::startQuery()
{ {
if (d->isRunning()) return; if (d->m_running) return;
d->m_finished = false; d->m_finished = false;
#ifdef HAVE_DNSSD if (d->m_type=="_services._dns-sd._udp") {
DNSServiceRef ref; d->m_browserType = Types;
if (DNSServiceBrowse(&ref,0,0, d->m_type.ascii(), #ifdef AVAHI_API_0_6
domainToDNS(d->m_domain),query_callback,reinterpret_cast<void*>(this)) d->m_browser = avahi_service_type_browser_new(Responder::self().client(), AVAHI_IF_UNSPEC, AVAHI_PROTO_UNSPEC,
== kDNSServiceErr_NoError) d->setRef(ref); domainToDNS(d->m_domain), (AvahiLookupFlags)0, types_callback, this);
#else
d->m_browser = avahi_service_type_browser_new(Responder::self().client(), AVAHI_IF_UNSPEC, AVAHI_PROTO_UNSPEC,
d->m_domain.utf8(), types_callback, this);
#endif
} else {
d->m_browserType = Services;
#ifdef AVAHI_API_0_6
d->m_browser = avahi_service_browser_new(Responder::self().client(), AVAHI_IF_UNSPEC, AVAHI_PROTO_UNSPEC,
d->m_type.ascii(),domainToDNS(d->m_domain), (AvahiLookupFlags)0, services_callback,this);
#else
d->m_browser = avahi_service_browser_new(Responder::self().client(), AVAHI_IF_UNSPEC, AVAHI_PROTO_UNSPEC,
d->m_type.ascii(),d->m_domain.utf8(),services_callback,this);
#endif #endif
if (!d->isRunning()) emit finished(); }
else d->timeout.start(domainIsLocal(d->m_domain) ? TIMEOUT_LAN : TIMEOUT_WAN,true); if (d->m_browser) {
d->m_running=true;
d->timeout.start(TIMEOUT_LAN,true);
} else emit finished();
} }
void Query::virtual_hook(int, void*) void Query::virtual_hook(int, void*)
{ {
@ -93,24 +134,15 @@ void Query::virtual_hook(int, void*)
void Query::customEvent(QCustomEvent* event) void Query::customEvent(QCustomEvent* event)
{ {
if (event->type()==QEvent::User+SD_ERROR) {
d->stop();
d->m_finished=false;
emit finished();
}
if (event->type()==QEvent::User+SD_ADDREMOVE) { if (event->type()==QEvent::User+SD_ADDREMOVE) {
RemoteService* svr; d->timeout.start(TIMEOUT_LAN,true);
d->m_finished=false;
AddRemoveEvent *aev = static_cast<AddRemoveEvent*>(event); AddRemoveEvent *aev = static_cast<AddRemoveEvent*>(event);
// m_type has useless trailing dot // m_type has useless trailing dot
QString type=aev->m_type.left(aev->m_type.length()-1); RemoteService* svr = new RemoteService(aev->m_name,
// label is badly splitted here - _http _tcp.local. . - rely on decode() aev->m_type,aev->m_domain);
if (d->m_type=="_services._dns-sd._udp") svr = new RemoteService(aev->m_name+"."+
type+"."+aev->m_domain);
else svr = new RemoteService(aev->m_name, type, aev->m_domain);
if (aev->m_op==AddRemoveEvent::Add) emit serviceAdded(svr); if (aev->m_op==AddRemoveEvent::Add) emit serviceAdded(svr);
else emit serviceRemoved(svr); else emit serviceRemoved(svr);
d->m_finished = aev->m_last;
if (d->m_finished) emit finished();
} }
} }
@ -119,22 +151,36 @@ void Query::timeout()
d->m_finished=true; d->m_finished=true;
emit finished(); emit finished();
} }
#ifdef HAVE_DNSSD
void query_callback (DNSServiceRef, DNSServiceFlags flags, uint32_t, DNSServiceErrorType errorCode, #ifdef AVAHI_API_0_6
const char *serviceName, const char *regtype, const char *replyDomain, void services_callback (AvahiServiceBrowser*, AvahiIfIndex, AvahiProtocol, AvahiBrowserEvent event,
void *context) const char* serviceName, const char* regtype, const char* replyDomain, AvahiLookupResultFlags, void* context)
#else
void services_callback (AvahiServiceBrowser*, AvahiIfIndex, AvahiProtocol, AvahiBrowserEvent event,
const char* serviceName, const char* regtype, const char* replyDomain, void* context)
#endif
{ {
QObject *obj = reinterpret_cast<QObject*>(context); QObject *obj = reinterpret_cast<QObject*>(context);
if (errorCode != kDNSServiceErr_NoError) { AddRemoveEvent* arev = new AddRemoveEvent((event==AVAHI_BROWSER_NEW) ? AddRemoveEvent::Add :
ErrorEvent err;
QApplication::sendEvent(obj, &err);
} else {
AddRemoveEvent arev((flags & kDNSServiceFlagsAdd) ? AddRemoveEvent::Add :
AddRemoveEvent::Remove, QString::fromUtf8(serviceName), regtype, AddRemoveEvent::Remove, QString::fromUtf8(serviceName), regtype,
DNSToDomain(replyDomain), !(flags & kDNSServiceFlagsMoreComing)); DNSToDomain(replyDomain));
QApplication::sendEvent(obj, &arev); QApplication::postEvent(obj, arev);
}
} }
#ifdef AVAHI_API_0_6
void types_callback(AvahiServiceTypeBrowser*, AvahiIfIndex, AvahiProtocol, AvahiBrowserEvent event, const char* regtype,
const char* replyDomain, AvahiLookupResultFlags, void* context)
#else
void types_callback(AvahiServiceTypeBrowser*, AvahiIfIndex, AvahiProtocol, AvahiBrowserEvent event, const char* regtype,
const char* replyDomain, void* context)
#endif #endif
{
QObject *obj = reinterpret_cast<QObject*>(context);
AddRemoveEvent* arev = new AddRemoveEvent((event==AVAHI_BROWSER_NEW) ? AddRemoveEvent::Add :
AddRemoveEvent::Remove, QString::null, regtype,
DNSToDomain(replyDomain));
QApplication::postEvent(obj, arev);
}
} }
#include "query.moc" #include "query.moc"

@ -27,33 +27,39 @@
#include <sys/types.h> #include <sys/types.h>
#endif #endif
#include <netinet/in.h> #include <netinet/in.h>
#include <avahi-client/client.h>
#include <avahi-common/strlst.h>
#ifdef AVAHI_API_0_6
#include <avahi-client/lookup.h>
#endif
#include "remoteservice.h" #include "remoteservice.h"
#include "responder.h" #include "responder.h"
#include "sdevent.h" #include "sdevent.h"
#include <kdebug.h>
namespace DNSSD namespace DNSSD
{ {
#ifdef HAVE_DNSSD #ifdef AVAHI_API_0_6
void resolve_callback ( DNSServiceRef, void resolve_callback(AvahiServiceResolver*, AvahiIfIndex, AvahiProtocol proto, AvahiResolverEvent e,
DNSServiceFlags, const char* name, const char* type, const char* domain, const char* hostname, const AvahiAddress* a,
uint32_t, uint16_t port, AvahiStringList* txt, AvahiLookupResultFlags, void* context);
DNSServiceErrorType errorCode, #else
const char*, void resolve_callback(AvahiServiceResolver*, AvahiIfIndex, AvahiProtocol proto, AvahiResolverEvent e,
const char *hosttarget, const char* name, const char* type, const char* domain, const char* hostname, const AvahiAddress* a,
uint16_t port, uint16_t port, AvahiStringList* txt, void* context);
uint16_t txtLen,
const unsigned char *txtRecord,
void *context
);
#endif #endif
class RemoteServicePrivate : public Responder class RemoteServicePrivate : public Responder
{ {
public: public:
RemoteServicePrivate() : Responder(), m_resolved(false) RemoteServicePrivate() : m_resolved(false), m_running(false), m_resolver(0) {}
{};
bool m_resolved; bool m_resolved;
bool m_running;
AvahiServiceResolver* m_resolver;
void stop() {
m_running = false;
if (m_resolver) avahi_service_resolver_free(m_resolver);
m_resolver=0;
}
}; };
RemoteService::RemoteService(const QString& label) RemoteService::RemoteService(const QString& label)
@ -83,29 +89,33 @@ RemoteService::RemoteService(const KURL& url)
RemoteService::~RemoteService() RemoteService::~RemoteService()
{ {
if (d->m_resolver) avahi_service_resolver_free(d->m_resolver);
delete d; delete d;
} }
bool RemoteService::resolve() bool RemoteService::resolve()
{ {
resolveAsync(); resolveAsync();
while (d->isRunning() && !d->m_resolved) d->process(); while (d->m_running && !d->m_resolved) Responder::self().process();
d->stop(); d->stop();
return d->m_resolved; return d->m_resolved;
} }
void RemoteService::resolveAsync() void RemoteService::resolveAsync()
{ {
if (d->isRunning()) return; if (d->m_running) return;
d->m_resolved = false; d->m_resolved = false;
kdDebug() << this << ":Starting resolve of : " << m_serviceName << " " << m_type << " " << m_domain << "\n"; // FIXME: first protocol should be set?
#ifdef HAVE_DNSSD #ifdef AVAHI_API_0_6
DNSServiceRef ref; d->m_resolver = avahi_service_resolver_new(Responder::self().client(),AVAHI_IF_UNSPEC, AVAHI_PROTO_UNSPEC,
if (DNSServiceResolve(&ref,0,0,m_serviceName.utf8(), m_type.ascii(), m_serviceName.utf8(), m_type.ascii(), domainToDNS(m_domain), AVAHI_PROTO_UNSPEC, AVAHI_LOOKUP_NO_ADDRESS,
domainToDNS(m_domain),(DNSServiceResolveReply)resolve_callback,reinterpret_cast<void*>(this)) resolve_callback, this);
== kDNSServiceErr_NoError) d->setRef(ref); #else
d->m_resolver = avahi_service_resolver_new(Responder::self().client(),AVAHI_IF_UNSPEC, AVAHI_PROTO_UNSPEC,
m_serviceName.utf8(), m_type.ascii(), m_domain.utf8(), AVAHI_PROTO_UNSPEC, resolve_callback, this);
#endif #endif
if (!d->isRunning()) emit resolved(false); if (d->m_resolver) d->m_running=true;
else emit resolved(false);
} }
bool RemoteService::isResolved() const bool RemoteService::isResolved() const
@ -154,42 +164,33 @@ QDataStream & operator>> (QDataStream & s, RemoteService & a)
return s; return s;
} }
#ifdef AVAHI_API_0_6
#ifdef HAVE_DNSSD void resolve_callback(AvahiServiceResolver*, AvahiIfIndex, AvahiProtocol, AvahiResolverEvent e,
void resolve_callback ( DNSServiceRef, const char*, const char*, const char*, const char* hostname, const AvahiAddress*,
DNSServiceFlags, uint16_t port, AvahiStringList* txt, AvahiLookupResultFlags, void* context)
uint32_t, #else
DNSServiceErrorType errorCode, void resolve_callback(AvahiServiceResolver*, AvahiIfIndex, AvahiProtocol, AvahiResolverEvent e,
const char*, const char*, const char*, const char*, const char* hostname, const AvahiAddress*,
const char *hosttarget, uint16_t port, AvahiStringList* txt, void* context)
uint16_t port, #endif
uint16_t txtLen,
const unsigned char *txtRecord,
void *context
)
{ {
QObject *obj = reinterpret_cast<QObject*>(context); QObject *obj = reinterpret_cast<QObject*>(context);
if (errorCode != kDNSServiceErr_NoError) { if (e != AVAHI_RESOLVER_FOUND) {
ErrorEvent err; ErrorEvent err;
QApplication::sendEvent(obj, &err); QApplication::sendEvent(obj, &err);
return; return;
} }
char key[256];
int index=0;
unsigned char valueLen;
kdDebug() << "Resolve callback\n";
QMap<QString,QString> map; QMap<QString,QString> map;
const void *voidValue = 0; while (txt) {
while (TXTRecordGetItemAtIndex(txtLen,txtRecord,index++,256,key,&valueLen, char *key, *value;
&voidValue) == kDNSServiceErr_NoError) size_t size;
{ if (avahi_string_list_get_pair(txt,&key,&value,&size)) break;
if (voidValue) map[QString::fromUtf8(key)]=QString::fromUtf8((const char*)voidValue,valueLen); map[QString::fromUtf8(key)]=(value) ? QString::fromUtf8(value) : QString::null;
else map[QString::fromUtf8(key)]=QString::null; txt = txt->next;
} }
ResolveEvent rev(DNSToDomain(hosttarget),ntohs(port),map); ResolveEvent rev(DNSToDomain(hostname),port,map);
QApplication::sendEvent(obj, &rev); QApplication::sendEvent(obj, &rev);
} }
#endif
} }

@ -20,62 +20,61 @@
#include "responder.h" #include "responder.h"
#include <qapplication.h> #include <qapplication.h>
#include <qeventloop.h>
#include <kstaticdeleter.h>
#include <kidna.h> #include <kidna.h>
#include <kdebug.h>
#include <avahi-qt3/qt-watch.h>
// dns_sd.h API should care about proper encoding of non-latin1 characters
// but for now it does not
#define IDN_BROKEN_IN_MDNSRESPONDER
namespace DNSSD namespace DNSSD
{ {
Responder::Responder(DNSServiceRef ref,QObject *parent, const char *name) static KStaticDeleter<Responder> responder_sd;
: QObject(parent, name), m_ref(0), m_socket(0) Responder* Responder::m_self = 0;
void client_callback(AvahiClient *, AvahiClientState s, void* u)
{ {
setRef(ref); Responder *r = reinterpret_cast<Responder*>(u);
emit (r->stateChanged(s));
} }
void Responder::setRef(DNSServiceRef ref)
Responder::Responder()
{ {
if (m_socket || m_ref) stop(); int error;
m_running = false; const AvahiPoll* poll = avahi_qt_poll_get();
m_ref = ref; #ifdef AVAHI_API_0_6
if (m_ref == 0 ) return; m_client = avahi_client_new(poll, AVAHI_CLIENT_IGNORE_USER_CONFIG,client_callback, this, &error);
#ifdef HAVE_DNSSD #else
int fd = DNSServiceRefSockFD(ref); m_client = avahi_client_new(poll, client_callback, this, &error);
if (fd == -1) return;
m_socket = new QSocketNotifier(fd,QSocketNotifier::Read,this);
connect(m_socket,SIGNAL(activated(int)),this,SLOT(process()));
m_running = true;
#endif #endif
if (!m_client) kdWarning() << "Failed to create avahi client" << endl;
} }
Responder::~Responder() Responder::~Responder()
{ {
stop(); if (m_client) avahi_client_free(m_client);
} }
void Responder::stop() Responder& Responder::self()
{ {
if (m_socket) delete m_socket; if (!m_self) responder_sd.setObject(m_self, new Responder);
m_socket = 0; return *m_self;
#ifdef HAVE_DNSSD
if (m_ref) DNSServiceRefDeallocate(m_ref);
#endif
m_ref = 0;
m_running = false;
} }
void Responder::process() void Responder::process()
{ {
#ifdef HAVE_DNSSD qApp->eventLoop()->processEvents(QEventLoop::ExcludeUserInput);
if ( DNSServiceProcessResult(m_ref) != kDNSServiceErr_NoError) stop();
#endif
} }
bool Responder::isRunning() const AvahiClientState Responder::state() const
{ {
return m_running; #ifdef AVAHI_API_0_6
return (m_client) ? (avahi_client_get_state(m_client)) : AVAHI_CLIENT_FAILURE;
#else
return (m_client) ? (avahi_client_get_state(m_client)) : AVAHI_CLIENT_DISCONNECTED;
#endif
} }
bool domainIsLocal(const QString& domain) bool domainIsLocal(const QString& domain)
@ -85,22 +84,14 @@ bool domainIsLocal(const QString& domain)
QCString domainToDNS(const QString &domain) QCString domainToDNS(const QString &domain)
{ {
#ifdef IDN_BROKEN_IN_MDNSRESPONDER
if (domainIsLocal(domain)) return domain.utf8(); if (domainIsLocal(domain)) return domain.utf8();
else return KIDNA::toAsciiCString(domain); else return KIDNA::toAsciiCString(domain);
#else
return domain.utf8();
#endif
} }
QString DNSToDomain(const char* domain) QString DNSToDomain(const char* domain)
{ {
#ifdef IDN_BROKEN_IN_MDNSRESPONDER
if (domainIsLocal(domain)) return QString::fromUtf8(domain); if (domainIsLocal(domain)) return QString::fromUtf8(domain);
else return KIDNA::toUnicode(domain); else return KIDNA::toUnicode(domain);
#else
return QString::fromUtf8(domain);
#endif
} }

@ -25,12 +25,7 @@
#include <qsocketnotifier.h> #include <qsocketnotifier.h>
#include <qsignal.h> #include <qsignal.h>
#include <config.h> #include <config.h>
#ifdef HAVE_DNSSD #include <avahi-client/client.h>
#include <dns_sd.h>
#else
#define DNSServiceRef void*
#endif
namespace DNSSD namespace DNSSD
{ {
@ -38,30 +33,28 @@ namespace DNSSD
This class should not be used directly. This class should not be used directly.
@author Jakub Stachowski @author Jakub Stachowski
@short Internal class wrapping dns_sd.h interface @short Internal class wrapping avahi client
*/ */
class Responder : public QObject class Responder : public QObject
{ {
Q_OBJECT Q_OBJECT
public: public:
Responder(DNSServiceRef ref=0,QObject *parent = 0, const char *name = 0); Responder();
~Responder(); ~Responder();
/** static Responder& self();
Returns true if it is possible to use mDNS service publishing and discovery. AvahiClientState state() const;
It needs mDNSResponder running. AvahiClient* client() const { return m_client; }
*/
bool isRunning() const;
void setRef(DNSServiceRef ref);
void stop();
public slots:
void process(); void process();
protected: signals:
DNSServiceRef m_ref; void stateChanged(AvahiClientState);
bool m_running; private:
QSocketNotifier *m_socket; AvahiClient* m_client;
static Responder* m_self;
friend void client_callback(AvahiClient*, AvahiClientState, void*);
}; };
/* Utils functions */ /* Utils functions */
@ -71,6 +64,7 @@ bool domainIsLocal(const QString& domain);
QCString domainToDNS(const QString &domain); QCString domainToDNS(const QString &domain);
QString DNSToDomain(const char* domain); QString DNSToDomain(const char* domain);
} }
#endif #endif

@ -41,24 +41,23 @@ class AddRemoveEvent : public QCustomEvent
public: public:
enum Operation { Add, Remove }; enum Operation { Add, Remove };
AddRemoveEvent(Operation op,const QString& name,const QString& type, AddRemoveEvent(Operation op,const QString& name,const QString& type,
const QString& domain, bool last) : QCustomEvent(QEvent::User+SD_ADDREMOVE), const QString& domain) : QCustomEvent(QEvent::User+SD_ADDREMOVE),
m_op(op), m_name(name), m_type(type), m_domain(domain), m_last(last) m_op(op), m_name(name), m_type(type), m_domain(domain)
{} {}
const Operation m_op; const Operation m_op;
const QString m_name; const QString m_name;
const QString m_type; const QString m_type;
const QString m_domain; const QString m_domain;
const bool m_last;
}; };
class PublishEvent : public QCustomEvent class PublishEvent : public QCustomEvent
{ {
public: public:
PublishEvent(const QString& name) : QCustomEvent(QEvent::User+SD_PUBLISH), m_name(name) PublishEvent(bool ok) : QCustomEvent(QEvent::User+SD_PUBLISH), m_ok(ok)
{} {}
const QString m_name; bool m_ok;
}; };
class ResolveEvent : public QCustomEvent class ResolveEvent : public QCustomEvent

@ -34,7 +34,7 @@ ServiceBase::~ServiceBase()
QString ServiceBase::encode() QString ServiceBase::encode()
{ {
return m_serviceName.replace("\\","\\\\").replace(".","\\.") + QString(".") + m_type + return m_serviceName.replace(".","\\.").replace("\\","\\\\") + QString(".") + m_type +
QString(".") + m_domain; QString(".") + m_domain;
} }

@ -23,14 +23,11 @@
#include <qstringlist.h> #include <qstringlist.h>
#include <qfile.h> #include <qfile.h>
#include "domainbrowser.h" #include "domainbrowser.h"
#include "responder.h"
#include "query.h" #include "query.h"
#include "servicebrowser.h" #include "servicebrowser.h"
#include <avahi-client/client.h>
#include <config.h> #include <config.h>
#ifdef HAVE_DNSSD
#include <dns_sd.h>
#endif
#define MDNSD_PID "/var/run/mdnsd.pid"
namespace DNSSD namespace DNSSD
{ {
@ -85,19 +82,11 @@ ServiceBrowser::ServiceBrowser(const QString& type,const QString& domain,int fla
const ServiceBrowser::State ServiceBrowser::isAvailable() const ServiceBrowser::State ServiceBrowser::isAvailable()
{ {
#ifdef HAVE_DNSSD AvahiClientState s = Responder::self().state();
QFile f(MDNSD_PID); #ifdef AVAHI_API_0_6
if (!f.open(IO_ReadOnly)) return Stopped; // no pidfile return (s==AVAHI_CLIENT_FAILURE) ? Stopped : Working;
QString line;
if (f.readLine(line,16)<1) return Stopped;
unsigned int pid = line.toUInt();
if (pid==0) return Stopped; // not a pid
return (kill(pid,0)==0 || errno==EPERM) ? Working : Stopped;
// signal 0 only checks if process is running, mdnsd is probably owned by 'nobody' so we will
// get EPERM, if mdnsd is not running error will be ESRCH
#else #else
return Unsupported; return (s==AVAHI_CLIENT_S_INVALID || s==AVAHI_CLIENT_DISCONNECTED) ? Stopped : Working;
#endif #endif
} }
ServiceBrowser::~ ServiceBrowser() ServiceBrowser::~ ServiceBrowser()

@ -16,7 +16,7 @@ kimproxyinclude_HEADERS = kimproxy.h kimproxyiface.h
lib_LTLIBRARIES = libkimproxy.la lib_LTLIBRARIES = libkimproxy.la
libkimproxy_la_LDFLAGS = -no-undefined $(all_libraries) libkimproxy_la_LDFLAGS = -no-undefined $(all_libraries)
libkimproxy_la_LIBADD = $(LIB_KIO) libkimproxy_la_LIBADD = $(LIB_KIO) $(LIB_QT) $(LIB_KDECORE) $(top_builddir)/dcop/libDCOP.la $(LIB_KDEUI)
libkimproxy_la_SOURCES = kimproxy.cpp kimiface.stub kimproxyiface.skel libkimproxy_la_SOURCES = kimproxy.cpp kimiface.stub kimproxyiface.skel
kimiface_DIR = $(top_srcdir)/interfaces/kimproxy/interface kimiface_DIR = $(top_srcdir)/interfaces/kimproxy/interface

@ -9,7 +9,7 @@ lib_LTLIBRARIES = libkmediaplayer.la
libkmediaplayer_la_SOURCES = player.cpp playerdcopobject.skel view.cpp libkmediaplayer_la_SOURCES = player.cpp playerdcopobject.skel view.cpp
libkmediaplayer_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -no-undefined libkmediaplayer_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -no-undefined
libkmediaplayer_la_LIBADD = $(LIB_KPARTS) libkmediaplayer_la_LIBADD = $(LIB_KPARTS) $(LIB_QT) $(top_builddir)/dcop/libDCOP.la $(LIB_KDEUI) $(LIB_KDECORE)
libkmediaplayer_la_METASOURCES = AUTO libkmediaplayer_la_METASOURCES = AUTO
kmediaplayerinclude_HEADERS = player.h playerdcopobject.h view.h kmediaplayerinclude_HEADERS = player.h playerdcopobject.h view.h

@ -5,7 +5,7 @@ kde_module_LTLIBRARIES = kfileaudiopreview.la
kfileaudiopreview_la_SOURCES = kfileaudiopreview.cpp kfileaudiopreview_la_SOURCES = kfileaudiopreview.cpp
kfileaudiopreview_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -module -avoid-version -no-undefined kfileaudiopreview_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -module -avoid-version -no-undefined
kfileaudiopreview_la_LIBADD = $(top_builddir)/interfaces/kmediaplayer/libkmediaplayer.la $(top_builddir)/arts/kde/libartskde.la $(LIB_KIO) kfileaudiopreview_la_LIBADD = $(top_builddir)/interfaces/kmediaplayer/libkmediaplayer.la $(top_builddir)/arts/kde/libartskde.la $(LIB_KIO) $(LIB_QT) $(LIB_KDECORE)
noinst_HEADERS = kfileaudiopreview.h noinst_HEADERS = kfileaudiopreview.h

@ -10,7 +10,7 @@ lib_LTLIBRARIES = libkscript.la
libkscript_la_SOURCES = scriptmanager.cpp libkscript_la_SOURCES = scriptmanager.cpp
libkscript_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -no-undefined libkscript_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -no-undefined
libkscript_la_LIBADD = $(LIB_KIO) libkscript_la_LIBADD = $(LIB_KIO) $(LIB_QT) $(LIB_KDECORE) $(LIB_KDEUI)
kscriptinclude_HEADERS = scriptinterface.h scriptclientinterface.h scriptmanager.h kscriptinclude_HEADERS = scriptinterface.h scriptclientinterface.h scriptmanager.h
kscriptincludedir = $(includedir) kscriptincludedir = $(includedir)

@ -4,7 +4,7 @@ kde_module_LTLIBRARIES = libshellscript.la
libshellscript_la_SOURCES = shellscript.cpp libshellscript_la_SOURCES = shellscript.cpp
libshellscript_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN) -no-undefined -avoid-version libshellscript_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN) -no-undefined -avoid-version
libshellscript_la_LIBADD = ../libkscript.la libshellscript_la_LIBADD = ../libkscript.la $(LIB_QT) $(LIB_KDECORE) $(top_builddir)/dcop/libDCOP.la
METASOURCES = AUTO METASOURCES = AUTO

@ -23,7 +23,7 @@ libktexteditor_la_SOURCES = ktexteditor.cpp \
libktexteditor_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) libktexteditor_la_LDFLAGS = $(all_libraries) $(KDE_RPATH)
libktexteditor_la_LIBADD = $(LIB_KPARTS) $(top_builddir)/dcop/libDCOP.la $(top_builddir)/kabc/libkabc.la libktexteditor_la_LIBADD = $(LIB_KPARTS) $(top_builddir)/dcop/libDCOP.la $(LIB_KABC) $(LIB_KDECORE) $(LIB_QT) $(LIB_KFILE) $(LIB_KDEUI)
ktexteditorinclude_HEADERS = document.h view.h editor.h plugin.h editinterface.h undointerface.h \ ktexteditorinclude_HEADERS = document.h view.h editor.h plugin.h editinterface.h undointerface.h \
selectioninterface.h cursorinterface.h \ selectioninterface.h cursorinterface.h \

@ -163,6 +163,8 @@ public:
start another program instead or close it yourself. start another program instead or close it yourself.
*/ */
virtual void setAutoDestroy(bool enabled) = 0; virtual void setAutoDestroy(bool enabled) = 0;
virtual bool setPtyFd(int master_pty) = 0;
}; };
#endif #endif

@ -22,7 +22,7 @@ CLEANFILES = addressee.h addressee.cpp field.cpp
lib_LTLIBRARIES = libkabc.la lib_LTLIBRARIES = libkabc.la
libkabc_la_LDFLAGS = $(KDE_RPATH) $(all_libraries) -version-info 3:0:2 -no-undefined libkabc_la_LDFLAGS = $(KDE_RPATH) $(all_libraries) -version-info 3:0:2 -no-undefined
libkabc_la_LIBADD = vcard/libvcard.la vcardparser/libvcards.la $(LIB_KIO) \ libkabc_la_LIBADD = vcard/libvcard.la vcardparser/libvcards.la $(LIB_KIO) \
$(top_builddir)/kresources/libkresources.la $(top_builddir)/kresources/libkresources.la $(LIB_QT) $(top_builddir)/dcop/libDCOP.la $(LIB_KDEUI) $(LIB_KDECORE)
libkabc_la_COMPILE_FIRST = addressee.h libkabc_la_COMPILE_FIRST = addressee.h
libkabc_la_SOURCES = \ libkabc_la_SOURCES = \

@ -5,7 +5,7 @@ kde_module_LTLIBRARIES = kabcformat_binary.la
kabcformat_binary_la_SOURCES = binaryformat.cpp kabcformat_binary_la_SOURCES = binaryformat.cpp
kabcformat_binary_la_LDFLAGS = -module $(KDE_PLUGIN) $(KDE_RPATH) $(all_libraries) \ kabcformat_binary_la_LDFLAGS = -module $(KDE_PLUGIN) $(KDE_RPATH) $(all_libraries) \
-no-undefined -no-undefined
kabcformat_binary_la_LIBADD = $(top_builddir)/kabc/libkabc.la kabcformat_binary_la_LIBADD = $(LIB_KABC) $(LIB_QT) $(LIB_KDECORE)
kabcformat_binary_la_COMPILE_FIRST = $(top_builddir)/kabc/addressee.h kabcformat_binary_la_COMPILE_FIRST = $(top_builddir)/kabc/addressee.h
# these are the headers for your project # these are the headers for your project

@ -6,13 +6,13 @@ noinst_HEADERS = resourcedirconfig.h
lib_LTLIBRARIES = libkabc_dir.la lib_LTLIBRARIES = libkabc_dir.la
libkabc_dir_la_SOURCES = resourcedir.cpp resourcedirconfig.cpp libkabc_dir_la_SOURCES = resourcedir.cpp resourcedirconfig.cpp
libkabc_dir_la_LDFLAGS = $(KDE_RPATH) $(all_libraries) -version-info 1:0:0 -no-undefined libkabc_dir_la_LDFLAGS = $(KDE_RPATH) $(all_libraries) -version-info 1:0:0 -no-undefined
libkabc_dir_la_LIBADD = $(LIB_KABC) libkabc_dir_la_LIBADD = $(LIB_KABC) $(LIB_QT) $(top_builddir)/kresources/libkresources.la $(LIB_KDECORE) $(LIB_KFILE) $(LIB_KDEUI)
libkabc_dir_la_COMPILE_FIRST = $(top_builddir)/kabc/addressee.h libkabc_dir_la_COMPILE_FIRST = $(top_builddir)/kabc/addressee.h
kde_module_LTLIBRARIES = kabc_dir.la kde_module_LTLIBRARIES = kabc_dir.la
kabc_dir_la_SOURCES = resourcedirplugin.cpp kabc_dir_la_SOURCES = resourcedirplugin.cpp
kabc_dir_la_LDFLAGS = -module $(KDE_PLUGIN) $(KDE_RPATH) $(all_libraries) -no-undefined kabc_dir_la_LDFLAGS = -module $(KDE_PLUGIN) $(KDE_RPATH) $(all_libraries) -no-undefined
kabc_dir_la_LIBADD = libkabc_dir.la kabc_dir_la_LIBADD = libkabc_dir.la $(LIB_QT) $(LIB_KDECORE)
METASOURCES = AUTO METASOURCES = AUTO

@ -6,14 +6,14 @@ noinst_HEADERS = resourcefileconfig.h
lib_LTLIBRARIES = libkabc_file.la lib_LTLIBRARIES = libkabc_file.la
libkabc_file_la_SOURCES = resourcefile.cpp resourcefileconfig.cpp libkabc_file_la_SOURCES = resourcefile.cpp resourcefileconfig.cpp
libkabc_file_la_LDFLAGS = $(KDE_RPATH) $(all_libraries) -version-info 1:0:0 -no-undefined libkabc_file_la_LDFLAGS = $(KDE_RPATH) $(all_libraries) -version-info 1:0:0 -no-undefined
libkabc_file_la_LIBADD = $(LIB_KABC) libkabc_file_la_LIBADD = $(LIB_KABC) $(LIB_QT) $(top_builddir)/kresources/libkresources.la $(LIB_KFILE) $(LIB_KDECORE) $(LIB_KDEUI)
libkabc_file_la_COMPILE_FIRST = $(top_builddir)/kabc/addressee.h libkabc_file_la_COMPILE_FIRST = $(top_builddir)/kabc/addressee.h
kde_module_LTLIBRARIES = kabc_file.la kde_module_LTLIBRARIES = kabc_file.la
kabc_file_la_SOURCES = resourcefileplugin.cpp kabc_file_la_SOURCES = resourcefileplugin.cpp
kabc_file_la_LDFLAGS = -module $(KDE_PLUGIN) $(KDE_RPATH) $(all_libraries) -no-undefined kabc_file_la_LDFLAGS = -module $(KDE_PLUGIN) $(KDE_RPATH) $(all_libraries) -no-undefined
kabc_file_la_LIBADD = libkabc_file.la kabc_file_la_LIBADD = libkabc_file.la $(LIB_QT) $(LIB_KDECORE)
kabc_file_la_COMPILE_FIRST = $(top_builddir)/kabc/addressee.h kabc_file_la_COMPILE_FIRST = $(top_builddir)/kabc/addressee.h
METASOURCES = AUTO METASOURCES = AUTO

@ -6,13 +6,13 @@ noinst_HEADERS = resourceldapkioconfig.h
lib_LTLIBRARIES = libkabc_ldapkio.la lib_LTLIBRARIES = libkabc_ldapkio.la
libkabc_ldapkio_la_SOURCES = resourceldapkio.cpp resourceldapkioconfig.cpp libkabc_ldapkio_la_SOURCES = resourceldapkio.cpp resourceldapkioconfig.cpp
libkabc_ldapkio_la_LDFLAGS = $(KDE_RPATH) $(all_libraries) -version-info 1:0:0 -no-undefined libkabc_ldapkio_la_LDFLAGS = $(KDE_RPATH) $(all_libraries) -version-info 1:0:0 -no-undefined
libkabc_ldapkio_la_LIBADD = $(top_builddir)/kabc/libkabc.la $(LIB_KIO) libkabc_ldapkio_la_LIBADD = $(LIB_KABC) $(LIB_KIO) $(LIB_QT) $(top_builddir)/kresources/libkresources.la $(LIB_KDEUI) $(LIB_KDECORE)
libkabc_ldapkio_la_COMPILE_FIRST = $(top_builddir)/kabc/addressee.h libkabc_ldapkio_la_COMPILE_FIRST = $(top_builddir)/kabc/addressee.h
kde_module_LTLIBRARIES = kabc_ldapkio.la kde_module_LTLIBRARIES = kabc_ldapkio.la
kabc_ldapkio_la_SOURCES = resourceldapkioplugin.cpp kabc_ldapkio_la_SOURCES = resourceldapkioplugin.cpp
kabc_ldapkio_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN) kabc_ldapkio_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN)
kabc_ldapkio_la_LIBADD = libkabc_ldapkio.la kabc_ldapkio_la_LIBADD = libkabc_ldapkio.la $(LIB_QT) $(LIB_KDECORE)
METASOURCES = AUTO METASOURCES = AUTO

@ -8,7 +8,7 @@ lib_LTLIBRARIES = libvcard.la
libvcard_la_SOURCES = vCard-all.cpp libvcard_la_SOURCES = vCard-all.cpp
libvcard_la_LDFLAGS = $(all_libraries) libvcard_la_LDFLAGS = $(all_libraries)
libvcard_la_LIBADD = $(LIB_KDECORE) libvcard_la_LIBADD = $(LIB_KDECORE) $(LIB_QT)
check_PROGRAMS = testwrite testread check_PROGRAMS = testwrite testread

@ -19,7 +19,11 @@ syntaxkate_DATA = language.dtd syntax.template cpp.xml c.xml html.xml kbasic.xml
cg.xml html-php.xml css-php.xml javascript-php.xml ahdl.xml ansic89.xml tibasic.xml \ cg.xml html-php.xml css-php.xml javascript-php.xml ahdl.xml ansic89.xml tibasic.xml \
purebasic.xml mips.xml logtalk.xml txt2tags.xml xslt.xml stata.xml glsl.xml \ purebasic.xml mips.xml logtalk.xml txt2tags.xml xslt.xml stata.xml glsl.xml \
lilypond.xml abc.xml asp.xml asm-avr.xml rib.xml cmake.xml octave.xml javadoc.xml cgis.xml \ lilypond.xml abc.xml asp.xml asm-avr.xml rib.xml cmake.xml octave.xml javadoc.xml cgis.xml \
spice.xml nasm.xml mediawiki.xml apache.xml m3u.xml ini.xml fstab.xml actionscript.xml spice.xml nasm.xml mediawiki.xml apache.xml m3u.xml ini.xml fstab.xml actionscript.xml \
abap.xml ansys.xml asn1.xml asterisk.xml bmethod.xml ddoc.xml djangotemplate.xml \
doxygenlua.xml dtd.xml email.xml erlang.xml freebasic.xml gap.xml json.xml maxima.xml \
mergetagtext.xml modelica.xml monobasic.xml nemerle.xml noweb.xml objectivecpp.xml opal.xml \
pgn.xml rapidq.xml scala.xml sisu.xml systemc.xml texinfo.xml xorg.xml xul.xml yaml.xml zonnon.xml
partrcdir = $(kde_confdir) partrcdir = $(kde_confdir)
partrc_DATA = katesyntaxhighlightingrc katefiletyperc partrc_DATA = katesyntaxhighlightingrc katefiletyperc

@ -3,7 +3,7 @@ METASOURCES = document.moc view.moc
lib_LTLIBRARIES = libkatepartinterfaces.la lib_LTLIBRARIES = libkatepartinterfaces.la
libkatepartinterfaces_la_SOURCES = interfaces.cpp katecmd.cpp libkatepartinterfaces_la_SOURCES = interfaces.cpp katecmd.cpp
libkatepartinterfaces_la_LIBADD = $(top_builddir)/interfaces/ktexteditor/libktexteditor.la libkatepartinterfaces_la_LIBADD = $(top_builddir)/interfaces/ktexteditor/libktexteditor.la $(LIB_QT) $(LIB_KDEUI) $(LIB_KPARTS) $(LIB_KDECORE)
libkatepartinterfaces_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -no-undefined libkatepartinterfaces_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -no-undefined
kateinclude_HEADERS = document.h view.h kateinclude_HEADERS = document.h view.h

@ -16,7 +16,7 @@ libkate_la_SOURCES = katesearch.cpp katebuffer.cpp katecmds.cpp \
libkatepart_la_SOURCES = dummy.cpp libkatepart_la_SOURCES = dummy.cpp
libkatepart_la_LIBADD = libkate.la ../interfaces/libkatepartinterfaces.la $(top_builddir)/kdeprint/libkdeprint.la $(top_builddir)/kutils/libkutils.la $(top_builddir)/kjs/libkjs.la $(LUA_LIBS) libkatepart_la_LIBADD = libkate.la ../interfaces/libkatepartinterfaces.la $(LIB_KDEPRINT) $(top_builddir)/kutils/libkutils.la $(top_builddir)/kjs/libkjs.la $(LUA_LIBS) $(LIB_QT) $(LIB_KDEUI) $(LIB_KDECORE) $(LIB_KPARTS) $(top_builddir)/interfaces/ktexteditor/libktexteditor.la $(LIB_KFILE) $(top_builddir)/dcop/libDCOP.la
libkatepart_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) libkatepart_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN)

@ -377,23 +377,35 @@ void KateSearch::replaceOne()
{ {
QString replaceWith = m_replacement; QString replaceWith = m_replacement;
if ( s.flags.regExp && s.flags.useBackRefs ) { if ( s.flags.regExp && s.flags.useBackRefs ) {
// replace each "(?!\)\d+" with the corresponding capture // Replace each "\0"..."\9" with the corresponding capture,
QRegExp br("\\\\(\\d+)"); // "\n" and "\t" with newline and tab,
// "\\" with "\",
// and remove the "\" for any other sequence.
QRegExp br("\\\\(.)");
int pos = br.search( replaceWith ); int pos = br.search( replaceWith );
int ncaps = m_re.numCaptures(); int ncaps = m_re.numCaptures();
while ( pos >= 0 ) { while ( pos >= 0 ) {
QString sc; QString substitute;
if ( !pos || replaceWith.at( pos-1) != '\\' ) { QChar argument = br.cap(1).at(0);
int ccap = br.cap(1).toInt(); if ( argument.isDigit() ) {
// the second character is a digit, this is a backreference
int ccap = argument.digitValue();
if (ccap <= ncaps ) { if (ccap <= ncaps ) {
sc = m_re.cap( ccap ); substitute = m_re.cap( ccap );
replaceWith.replace( pos, br.matchedLength(), sc ); } else {
}
else {
kdDebug()<<"KateSearch::replaceOne(): you don't have "<<ccap<<" backreferences in regexp '"<<m_re.pattern()<<"'"<<endl; kdDebug()<<"KateSearch::replaceOne(): you don't have "<<ccap<<" backreferences in regexp '"<<m_re.pattern()<<"'"<<endl;
break;
} }
} else if ( argument == 'n' ) {
substitute = '\n';
} else if ( argument == 't' ) {
substitute = '\t';
} else {
// handle a validly escaped backslash, or an invalid escape.
substitute = argument;
} }
pos = br.search( replaceWith, pos + (int)sc.length() ); replaceWith.replace( pos, br.matchedLength(), substitute );
pos = br.search( replaceWith, pos + substitute.length() );
} }
} }

@ -5,7 +5,7 @@ METASOURCES = AUTO
kde_module_LTLIBRARIES = ktexteditor_insertfile.la kde_module_LTLIBRARIES = ktexteditor_insertfile.la
ktexteditor_insertfile_la_SOURCES = insertfileplugin.cpp ktexteditor_insertfile_la_SOURCES = insertfileplugin.cpp
ktexteditor_insertfile_la_LIBADD = $(top_builddir)/interfaces/ktexteditor/libktexteditor.la ktexteditor_insertfile_la_LIBADD = $(top_builddir)/interfaces/ktexteditor/libktexteditor.la $(LIB_QT) $(LIB_KDECORE) $(LIB_KFILE) $(LIB_KDEUI)
ktexteditor_insertfile_la_LDFLAGS = -module $(KDE_PLUGIN) $(all_libraries) ktexteditor_insertfile_la_LDFLAGS = -module $(KDE_PLUGIN) $(all_libraries)
insertfiledatadir = $(kde_datadir)/ktexteditor_insertfile insertfiledatadir = $(kde_datadir)/ktexteditor_insertfile

@ -5,7 +5,7 @@ METASOURCES = AUTO
kde_module_LTLIBRARIES = ktexteditor_isearch.la kde_module_LTLIBRARIES = ktexteditor_isearch.la
ktexteditor_isearch_la_SOURCES = ISearchPlugin.cpp ktexteditor_isearch_la_SOURCES = ISearchPlugin.cpp
ktexteditor_isearch_la_LIBADD = $(top_builddir)/interfaces/ktexteditor/libktexteditor.la ktexteditor_isearch_la_LIBADD = $(top_builddir)/interfaces/ktexteditor/libktexteditor.la $(LIB_QT) $(LIB_KDECORE) $(LIB_KDEUI)
ktexteditor_isearch_la_LDFLAGS = -module $(KDE_PLUGIN) $(all_libraries) ktexteditor_isearch_la_LDFLAGS = -module $(KDE_PLUGIN) $(all_libraries)
isearchdatadir = $(kde_datadir)/ktexteditor_isearch isearchdatadir = $(kde_datadir)/ktexteditor_isearch

@ -5,7 +5,7 @@ METASOURCES = AUTO
kde_module_LTLIBRARIES = ktexteditor_kdatatool.la kde_module_LTLIBRARIES = ktexteditor_kdatatool.la
ktexteditor_kdatatool_la_SOURCES = kate_kdatatool.cpp ktexteditor_kdatatool_la_SOURCES = kate_kdatatool.cpp
ktexteditor_kdatatool_la_LIBADD = $(top_builddir)/interfaces/ktexteditor/libktexteditor.la ktexteditor_kdatatool_la_LIBADD = $(top_builddir)/interfaces/ktexteditor/libktexteditor.la $(LIB_QT) $(LIB_KDECORE) $(LIB_KFILE) $(LIB_KDEUI)
ktexteditor_kdatatool_la_LDFLAGS = -module $(KDE_PLUGIN) $(all_libraries) ktexteditor_kdatatool_la_LDFLAGS = -module $(KDE_PLUGIN) $(all_libraries)
kdatatooldatadir = $(kde_datadir)/ktexteditor_kdatatool kdatatooldatadir = $(kde_datadir)/ktexteditor_kdatatool

@ -5,7 +5,7 @@ METASOURCES = AUTO
kde_module_LTLIBRARIES = ktexteditor_docwordcompletion.la kde_module_LTLIBRARIES = ktexteditor_docwordcompletion.la
ktexteditor_docwordcompletion_la_SOURCES = docwordcompletion.cpp ktexteditor_docwordcompletion_la_SOURCES = docwordcompletion.cpp
ktexteditor_docwordcompletion_la_LIBADD = $(top_builddir)/interfaces/ktexteditor/libktexteditor.la ktexteditor_docwordcompletion_la_LIBADD = $(top_builddir)/interfaces/ktexteditor/libktexteditor.la $(LIB_QT) $(LIB_KDECORE) $(LIB_KDEUI)
ktexteditor_docwordcompletion_la_LDFLAGS = -module $(KDE_PLUGIN) $(all_libraries) ktexteditor_docwordcompletion_la_LDFLAGS = -module $(KDE_PLUGIN) $(all_libraries)
docwordcompletiondatadir = $(kde_datadir)/ktexteditor_docwordcompletion docwordcompletiondatadir = $(kde_datadir)/ktexteditor_docwordcompletion

@ -5,7 +5,7 @@ kde_module_LTLIBRARIES = libkcertpart.la
libkcertpart_la_SOURCES = kcertpart.cc libkcertpart_la_SOURCES = kcertpart.cc
libkcertpart_la_LDFLAGS = $(KDE_PLUGIN) $(all_libraries) libkcertpart_la_LDFLAGS = $(KDE_PLUGIN) $(all_libraries)
libkcertpart_la_LIBADD = $(LIB_KPARTS) libkcertpart_la_LIBADD = $(LIB_KPARTS) $(LIB_QT) $(LIB_KDEUI) $(LIB_KFILE) $(LIB_KDECORE)
libkcertpart_la_DEPENDENCIES = $(LIB_KPARTS) libkcertpart_la_DEPENDENCIES = $(LIB_KPARTS)
libkcertpart_la_METASOURCES = AUTO libkcertpart_la_METASOURCES = AUTO

@ -26,7 +26,7 @@ bin_PROGRAMS =
kdeinit_LTLIBRARIES = kcmshell.la kdeinit_LTLIBRARIES = kcmshell.la
kcmshell_la_SOURCES = main.cpp main.skel kcmshell_la_SOURCES = main.cpp main.skel
kcmshell_la_LIBADD = ../kutils/libkutils.la kcmshell_la_LIBADD = ../kutils/libkutils.la $(LIB_QT) $(LIB_KDEUI) $(top_builddir)/dcop/libDCOP.la $(LIB_KDECORE) $(LIB_KFILE)
kcmshell_la_LDFLAGS = $(all_libraries) -module -avoid-version kcmshell_la_LDFLAGS = $(all_libraries) -module -avoid-version
noinst_HEADERS = main.h noinst_HEADERS = main.h

@ -23,7 +23,7 @@ lib_LTLIBRARIES =
kdeinit_LTLIBRARIES = kconf_update.la kdeinit_LTLIBRARIES = kconf_update.la
kconf_update_la_SOURCES = kconf_update.cpp kconf_update_la_SOURCES = kconf_update.cpp
kconf_update_la_LIBADD = $(LIB_KDECORE) kconf_update_la_LIBADD = $(LIB_KDECORE) $(LIB_QT)
kconf_update_la_LDFLAGS = $(all_libraries) -module -avoid-version kconf_update_la_LDFLAGS = $(all_libraries) -module -avoid-version
METASOURCES = AUTO METASOURCES = AUTO

@ -34,7 +34,7 @@ SUBDIRS = malloc network $(SVGICONS) . kconfig_compiler tests
AM_LDFLAGS = $(LDFLAGS_AS_NEEDED) $(LDFLAGS_NEW_DTAGS) AM_LDFLAGS = $(LDFLAGS_AS_NEEDED) $(LDFLAGS_NEW_DTAGS)
lib_LTLIBRARIES = libkdefakes.la libkdecore.la lib_LTLIBRARIES = libkdefakes.la libkdecore.la
lib_LIBRARIES = libkdefakes_nonpic.a lib_LIBRARIES = libkdefakes_nonpic.a libkdefakes_pic.a
include_HEADERS = kconfig.h kconfigskeleton.h \ include_HEADERS = kconfig.h kconfigskeleton.h \
kconfigdata.h ksimpleconfig.h kconfigdialogmanager.h \ kconfigdata.h ksimpleconfig.h kconfigdialogmanager.h \
@ -75,6 +75,12 @@ vsnprintf_nonpic.c: $(srcdir)/vsnprintf.c
-rm -f vsnprintf_nonpic.c -rm -f vsnprintf_nonpic.c
$(LN_S) $(srcdir)/vsnprintf.c vsnprintf_nonpic.c $(LN_S) $(srcdir)/vsnprintf.c vsnprintf_nonpic.c
libkdefakes_pic.a: libkdefakes.la
-rm -f libkdefakes_pic.a fakes_pic.o vsnprintf_pic.o
cp -f .libs/fakes.o fakes_pic.o; cp -f .libs/vsnprintf.o vsnprintf_pic.o
ar cru libkdefakes_pic.a fakes_pic.o vsnprintf_pic.o
ranlib libkdefakes_pic.a
noinst_HEADERS = kaccelaction.h kaccelbase.h kaccelprivate.h kckey.h \ noinst_HEADERS = kaccelaction.h kaccelbase.h kaccelprivate.h kckey.h \
kcompletion_private.h netwm_p.h \ kcompletion_private.h netwm_p.h \
kglobalaccel_x11.h kglobalaccel_win.h kkeyserver_x11.h kkeyserver.h \ kglobalaccel_x11.h kglobalaccel_win.h kkeyserver_x11.h kkeyserver.h \
@ -116,7 +122,8 @@ libkdecore_la_SOURCES = libintl.cpp kapplication.cpp \
kqiodevicegzip_p.cpp ktimezones.cpp kqiodevicegzip_p.cpp ktimezones.cpp
libkdecore_la_LDFLAGS = $(QT_LDFLAGS) $(KDE_RPATH) $(KDE_MT_LDFLAGS) $(X_LDFLAGS) $(USER_LDFLAGS) -version-info 6:0:2 -no-undefined libkdecore_la_LDFLAGS = $(QT_LDFLAGS) $(KDE_RPATH) $(KDE_MT_LDFLAGS) $(X_LDFLAGS) $(USER_LDFLAGS) -version-info 6:0:2 -no-undefined
libkdecore_la_LIBADD = malloc/libklmalloc.la network/libkdecorenetwork.la $(SVGICON_LIB) ../dcop/libDCOP.la ../libltdl/libltdlc.la $(LIB_XEXT) $(LIBRESOLV) $(LIBUTIL) $(LIBART_LIBS) $(LIB_IDN) ../kdefx/libkdefx.la libkdecore_la_LIBADD = malloc/libklmalloc.la network/libkdecorenetwork.la $(SVGICON_LIB) ../dcop/libDCOP.la ../libltdl/libltdlc.la \
$(LIBART_LIBS) $(LIB_IDN) $(top_builddir)/kdefx/libkdefx.la $(LIB_QT) $(LIBSM) $(LIB_X11) $(LIBZ) $(LIBDL)
libkdecore_la_NMCHECK = $(srcdir)/libkdecore.nmcheck libkdecore_la_NMCHECK = $(srcdir)/libkdecore.nmcheck
libkdecore_la_NMCHECKWEAK = $(srcdir)/libkdecore_weak.nmcheck $(srcdir)/libqt-mt_weak.nmcheck \ libkdecore_la_NMCHECKWEAK = $(srcdir)/libkdecore_weak.nmcheck $(srcdir)/libqt-mt_weak.nmcheck \
$(top_srcdir)/dcop/libDCOP_weak.nmcheck $(top_srcdir)/kdecore/standard_weak.nmcheck $(top_srcdir)/dcop/libDCOP_weak.nmcheck $(top_srcdir)/kdecore/standard_weak.nmcheck
@ -170,7 +177,6 @@ kde_config_LDFLAGS = $(KDE_RPATH) $(KDE_MT_LDFLAGS)
kgrantpty_SOURCES = kgrantpty.c kgrantpty_SOURCES = kgrantpty.c
kgrantpty_CFLAGS= $(KDE_USE_FPIE) kgrantpty_CFLAGS= $(KDE_USE_FPIE)
kgrantpty_LDFLAGS = $(KDE_USE_PIE) $(KDE_RPATH) $(all_libraries) kgrantpty_LDFLAGS = $(KDE_USE_PIE) $(KDE_RPATH) $(all_libraries)
kgrantpty_LDADD = ./libkdefakes.la
# kgrantpty needs to be installed setuid root # kgrantpty needs to be installed setuid root
install-exec-hook: install-exec-hook:

@ -127,7 +127,10 @@ bool KAccelEventHandler::x11Event( XEvent* pEvent )
return false; return false;
if( pEvent->type == XKeyPress ) { if( pEvent->type == XKeyPress ) {
unsigned int tmp = pEvent->xkey.state;
pEvent->xkey.state &= ~0x2000;
KKeyNative keyNative( pEvent ); KKeyNative keyNative( pEvent );
pEvent->xkey.state = tmp;
KKey key( keyNative ); KKey key( keyNative );
key.simplify(); key.simplify();
int keyCodeQt = key.keyCodeQt(); int keyCodeQt = key.keyCodeQt();

@ -505,6 +505,8 @@ qWarning("SIGBUS while reading %s", rFile.name().latin1());
bool fileOptionImmutable = false; bool fileOptionImmutable = false;
bool groupOptionImmutable = false; bool groupOptionImmutable = false;
bool groupSkip = false; bool groupSkip = false;
bool foundGettextDomain = false;
QCString gettextDomain;
int line = 0; int line = 0;
for(; s < eof; s++) for(; s < eof; s++)
@ -596,6 +598,7 @@ qWarning("SIGBUS while reading %s", rFile.name().latin1());
if (groupSkip && !bDefault) if (groupSkip && !bDefault)
goto sktoeol; // Skip entry goto sktoeol; // Skip entry
bool optionImmutable = groupOptionImmutable; bool optionImmutable = groupOptionImmutable;
bool optionDeleted = false; bool optionDeleted = false;
bool optionExpand = false; bool optionExpand = false;
@ -695,6 +698,11 @@ qWarning("SIGBUS while reading %s", rFile.name().latin1());
QCString val = printableToString(st, s - st); QCString val = printableToString(st, s - st);
//qDebug("found key '%s' with value '%s'", key.data(), val.data()); //qDebug("found key '%s' with value '%s'", key.data(), val.data());
if (QString(key.data()) == "X-Ubuntu-Gettext-Domain") {
gettextDomain = val.data();
foundGettextDomain = true;
}
KEntryKey aEntryKey(aCurrentGroup, decodeKey(key)); KEntryKey aEntryKey(aCurrentGroup, decodeKey(key));
aEntryKey.bLocal = (locale != 0); aEntryKey.bLocal = (locale != 0);
aEntryKey.bDefault = bDefault; aEntryKey.bDefault = bDefault;
@ -718,6 +726,34 @@ qWarning("SIGBUS while reading %s", rFile.name().latin1());
pConfig->putData(aEntryKey, aEntry, false); pConfig->putData(aEntryKey, aEntry, false);
} }
} }
// Look up translations using KLocale
// https://launchpad.net/distros/ubuntu/+spec/langpacks-desktopfiles-kde
// This calls KLocale up to 10 times for each config file (and each KConfig has up to 4 files)
// so I'll see how much of a performance hit it is
// it also only acts on the last group in a file
// Ideas: only translate most important fields, only translate "Desktop Entry" files,
// do translation per KConfig not per single file
if (!pWriteBackMap) {
QFile file("file.txt");
if (foundGettextDomain) {
KLocale locale(gettextDomain);
QString language = locale.language();
translateKey(locale, aCurrentGroup, QCString("Name"));
translateKey(locale, aCurrentGroup, QCString("Comment"));
translateKey(locale, aCurrentGroup, QCString("Language"));
translateKey(locale, aCurrentGroup, QCString("Keywords"));
translateKey(locale, aCurrentGroup, QCString("About"));
translateKey(locale, aCurrentGroup, QCString("Description"));
translateKey(locale, aCurrentGroup, QCString("GenericName"));
translateKey(locale, aCurrentGroup, QCString("Query"));
translateKey(locale, aCurrentGroup, QCString("ExtraNames"));
translateKey(locale, aCurrentGroup, QCString("X-KDE-Submenu"));
}
}
if (fileOptionImmutable) if (fileOptionImmutable)
bFileImmutable = true; bFileImmutable = true;
@ -732,6 +768,21 @@ qWarning("SIGBUS while reading %s", rFile.name().latin1());
#endif #endif
} }
void KConfigINIBackEnd::translateKey(KLocale& locale, QCString currentGroup, QCString key) {
KEntryKey entryKey = KEntryKey(currentGroup, key);
KEntry entry = pConfig->lookupData(entryKey);
if (QString(entry.mValue) != "") {
QString orig = key + "=" + entry.mValue;
QString translate = locale.translate(key + "=" + entry.mValue);
if (QString::compare(orig, translate) != 0) {
translate = translate.mid(key.length() + 1);
entry.mValue = translate.utf8();
entryKey.bLocal = true;
entry.bNLS = true;
pConfig->putData(entryKey, entry, false);
}
}
}
void KConfigINIBackEnd::sync(bool bMerge) void KConfigINIBackEnd::sync(bool bMerge)
{ {

@ -25,6 +25,7 @@
#include "kconfigdata.h" #include "kconfigdata.h"
#include <kconfigbase.h> #include <kconfigbase.h>
#include <klockfile.h> #include <klockfile.h>
#include <klocale.h>
#include "kdelibs_export.h" #include "kdelibs_export.h"
class QFile; class QFile;
@ -250,6 +251,11 @@ protected:
void parseSingleConfigFile(QFile& rFile, KEntryMap *pWriteBackMap = 0L, void parseSingleConfigFile(QFile& rFile, KEntryMap *pWriteBackMap = 0L,
bool bGlobal = false, bool bDefault = false); bool bGlobal = false, bool bDefault = false);
// Kubuntu patch, 2006-08-03
// looks up a key in with KLocale
// see https://launchpad.net/distros/ubuntu/+spec/langpacks-desktopfiles-kde
void translateKey(KLocale& locale, QCString currentGroup, QCString key);
/** /**
* Writes configuration file back. * Writes configuration file back.
* *

@ -441,7 +441,7 @@ static int openSocket()
if (!kde_home || !kde_home[0]) if (!kde_home || !kde_home[0])
{ {
kde_home = "~/.kde/"; kde_home = "~/.kde3/";
} }
if (kde_home[0] == '~') if (kde_home[0] == '~')

@ -238,7 +238,8 @@ static void kDebugBackend( unsigned short nLevel, unsigned int nArea, const char
break; break;
} }
short nOutput = kDebug_data->config ? kDebug_data->config->readNumEntry(key, 2) : 2; // if no output mode is specified default to no debug output
short nOutput = kDebug_data->config ? kDebug_data->config->readNumEntry(key, 4) : 4;
// If the application doesn't have a QApplication object it can't use // If the application doesn't have a QApplication object it can't use
// a messagebox. // a messagebox.

@ -86,7 +86,7 @@ InfoOutput=4
# KMail # KMail
[5006] [5006]
InfoOutput=2 InfoOutput=4
# KitchenSync (Syncing Algorithm) # KitchenSync (Syncing Algorithm)
[5250] [5250]

@ -22,10 +22,10 @@
#include "kdelibs_export.h" #include "kdelibs_export.h"
#define KDE_VERSION_STRING "3.5.10" #define KDE_VERSION_STRING "3.5.11 [Trinity]"
#define KDE_VERSION_MAJOR 3 #define KDE_VERSION_MAJOR 3
#define KDE_VERSION_MINOR 5 #define KDE_VERSION_MINOR 5
#define KDE_VERSION_RELEASE 10 #define KDE_VERSION_RELEASE 11
#define KDE_MAKE_VERSION( a,b,c ) (((a) << 16) | ((b) << 8) | (c)) #define KDE_MAKE_VERSION( a,b,c ) (((a) << 16) | ((b) << 8) | (c))
#define KDE_VERSION \ #define KDE_VERSION \

@ -50,6 +50,10 @@ static QRgb qt_colorref2qrgb(COLORREF col)
#include <stdlib.h> #include <stdlib.h>
#include <kprotocolinfo.h> #include <kprotocolinfo.h>
#include <qtextcodec.h>
#include <qtextstream.h>
#include <qfile.h>
#ifdef Q_WS_X11 #ifdef Q_WS_X11
#include <X11/Xlib.h> #include <X11/Xlib.h>
#endif #endif
@ -77,6 +81,31 @@ QColor *KGlobalSettings::alternateColor = 0;
KGlobalSettings::KMouseSettings *KGlobalSettings::s_mouseSettings = 0; KGlobalSettings::KMouseSettings *KGlobalSettings::s_mouseSettings = 0;
// helper function for reading xdg user dirs: it is required in order to take
// care of locale stuff
void readXdgUserDirs(QString *desktop, QString *documents)
{
QFile f( QDir::homeDirPath() + "/.config/user-dirs.dirs" );
if (!f.open(IO_ReadOnly))
return;
// set the codec for the current locale
QTextStream s(&f);
s.setCodec( QTextCodec::codecForLocale() );
QString line = s.readLine();
while (!line.isNull())
{
if (line.startsWith("XDG_DESKTOP_DIR="))
*desktop = line.remove("XDG_DESKTOP_DIR=").remove("\"").replace("$HOME", QDir::homeDirPath());
else if (line.startsWith("XDG_DOCUMENTS_DIR="))
*documents = line.remove("XDG_DOCUMENTS_DIR=").remove("\"").replace("$HOME", QDir::homeDirPath());
line = s.readLine();
}
}
int KGlobalSettings::dndEventDelay() int KGlobalSettings::dndEventDelay()
{ {
KConfigGroup g( KGlobal::config(), "General" ); KConfigGroup g( KGlobal::config(), "General" );
@ -483,13 +512,17 @@ void KGlobalSettings::initStatic() // should be called initPaths(). Don't put an
KConfigGroup g( KGlobal::config(), "Paths" ); KConfigGroup g( KGlobal::config(), "Paths" );
// Desktop Path // Read desktop and documents path using XDG_USER_DIRS
*s_desktopPath = QDir::homeDirPath() + "/Desktop/"; readXdgUserDirs(s_desktopPath, s_documentPath);
*s_desktopPath = g.readPathEntry( "Desktop", *s_desktopPath);
*s_desktopPath = QDir::cleanDirPath( *s_desktopPath ); *s_desktopPath = QDir::cleanDirPath( *s_desktopPath );
if ( !s_desktopPath->endsWith("/") ) if ( !s_desktopPath->endsWith("/") )
s_desktopPath->append('/'); s_desktopPath->append('/');
*s_documentPath = QDir::cleanDirPath( *s_documentPath );
if ( !s_documentPath->endsWith("/"))
s_documentPath->append('/');
// Trash Path - TODO remove in KDE4 (kio_trash can't use it for interoperability reasons) // Trash Path - TODO remove in KDE4 (kio_trash can't use it for interoperability reasons)
*s_trashPath = *s_desktopPath + i18n("Trash") + "/"; *s_trashPath = *s_desktopPath + i18n("Trash") + "/";
*s_trashPath = g.readPathEntry( "Trash" , *s_trashPath); *s_trashPath = g.readPathEntry( "Trash" , *s_trashPath);
@ -510,18 +543,6 @@ void KGlobalSettings::initStatic() // should be called initPaths(). Don't put an
if ( !s_autostartPath->endsWith("/") ) if ( !s_autostartPath->endsWith("/") )
s_autostartPath->append('/'); s_autostartPath->append('/');
// Document Path
*s_documentPath = g.readPathEntry( "Documents",
#ifdef Q_WS_WIN
getWin32ShellFoldersPath("Personal")
#else
QDir::homeDirPath()
#endif
);
*s_documentPath = QDir::cleanDirPath( *s_documentPath );
if ( !s_documentPath->endsWith("/"))
s_documentPath->append('/');
// Make sure this app gets the notifications about those paths // Make sure this app gets the notifications about those paths
if (kapp) if (kapp)
kapp->addKipcEventMask(KIPC::SettingsChanged); kapp->addKipcEventMask(KIPC::SettingsChanged);

@ -24,6 +24,9 @@
#include <qwidget.h> #include <qwidget.h>
#include <qpainter.h> #include <qpainter.h>
#include <qpen.h> #include <qpen.h>
#include <qapplication.h>
#include <qpoint.h>
#include <qrect.h>
#include <kdebug.h> #include <kdebug.h>
#include <kglobal.h> #include <kglobal.h>
@ -768,3 +771,148 @@ KIconEffect::visualActivate(QWidget * widget, QRect rect)
} }
} }
void
KIconEffect::visualActivate(QWidget * widget, QRect rect, QPixmap *pixmap)
{
if (!KGlobalSettings::visualActivate())
return;
// Image too big to display smoothly
if ((rect.width() > 160) || (rect.height() > 160)) {
visualActivate(widget, rect); // call old effect
return;
}
uint actSpeed = KGlobalSettings::visualActivateSpeed();
uint actCount = QMIN(rect.width(), rect.height()) / 4;
// Clip actCount to range 1..10.
if (actCount < 1)
actCount = 1;
else if (actCount > 10)
actCount = 10;
// Clip actSpeed to range 1..100.
if (actSpeed < 1)
actSpeed = 1;
else if (actSpeed > 100)
actSpeed = 100;
// actSpeed needs to be converted to actDelay.
// actDelay is inversely proportional to actSpeed and needs to be
// divided up into actCount portions.
// We also convert the us value to ms.
unsigned int actDelay = (1000 * (100 - actSpeed)) / actCount;
unsigned int deltaX = rect.width() / actCount * 1.5;
unsigned int deltaY = rect.height() / actCount * 1.5;
QPoint c = rect.center();
QRect maxRect(c.x() - (actCount * 2) * deltaX /2,
c.y() - (actCount * 2) * deltaY /2,
actCount * 2 * deltaX,
actCount * 2 * deltaY);
// convert rect to global coordinates if needed
if ((widget->rect().width() <= maxRect.width())
|| (widget->rect().height() <= maxRect.height()))
{
QPoint topLeft(rect.x(), rect.y());
rect.moveLeft(widget->mapToGlobal(topLeft).x());
rect.moveTop(widget->mapToGlobal(topLeft).y());
c = rect.center();
maxRect.setRect(c.x() - (actCount * 2) * deltaX /2,
c.y() - (actCount * 2) * deltaY /2,
actCount * 2 * deltaX,
actCount * 2 * deltaY);
}
QPainter *p;
QImage img = pixmap->convertToImage();
QPixmap pix;
QPixmap composite(maxRect.width(), maxRect.height(), -1, QPixmap::BestOptim);
QPainter cPainter(&composite);
QPoint cComposite = composite.rect().center();
// enable alpha blending
img.setAlphaBuffer(true);
// Ugly hack... Get "Screenshot" to blt into and even do that on the
// root window if the display area of <widget> is too small
if ((widget->rect().width() <= maxRect.width())
|| (widget->rect().height() <= maxRect.height()))
{
p = new QPainter(QApplication::desktop()->screen( -1 ), TRUE);
pix = QPixmap::grabWindow((QApplication::desktop()->screen( -1 ))->winId(),
maxRect.x(),
maxRect.y(),
maxRect.width(),
maxRect.height());
} else
{
// not as ugly as drawing directly to the screen
p = new QPainter(widget);
pix = QPixmap::grabWidget(widget,
maxRect.x(),
maxRect.y(),
maxRect.width(),
maxRect.height());
}
uchar deltaAlpha = 255 / (actCount * 1.2);
// Activate effect like MacOS X
for (unsigned int i = actCount; i < actCount * 2; i++) {
int w = i * deltaX;
int h = i * deltaY;
rect.setRect(cComposite.x() - w / 2, cComposite.y() - h / 2, w, h);
// draw offscreen
cPainter.drawPixmap(0, 0, pix, 0, 0, pix.width(), pix.height());
cPainter.drawImage(rect, img);
cPainter.flush();
// put onscreen
p->drawPixmap(maxRect, composite);
p->flush();
// Fade out Icon a bit more
int x, y;
if ((img.depth() == 32) && qt_use_xrender && qt_has_xft)
{
int width = img.width();
int height = img.height();
for (y=0; y<height; y++)
{
#ifdef WORDS_BIGENDIAN
uchar *line = (uchar*) img.scanLine(y);
#else
uchar *line = (uchar*) img.scanLine(y) + 3;
#endif
for (x=0; x<width; x++)
{
*line = (*line < deltaAlpha) ? 0 : *line - deltaAlpha;
line += 4;
}
}
}
usleep(actDelay*3);
}
// remove traces of the effect
if ((widget->rect().width() <= maxRect.width())
|| (widget->rect().height() <= maxRect.height()))
p->drawPixmap(maxRect, pix);
else {
p->drawPixmap(maxRect, pix);
widget->update(rect);
}
delete p;
}

@ -152,6 +152,7 @@ public:
* @param rect This rectangle defines the effect's borders * @param rect This rectangle defines the effect's borders
*/ */
static void visualActivate(QWidget *widget, QRect rect); static void visualActivate(QWidget *widget, QRect rect);
static void visualActivate(QWidget *widget, QRect rect, QPixmap *pixmap);
/** /**
* Tints an image gray. * Tints an image gray.

@ -408,7 +408,7 @@ KIcon KIconTheme::iconPath(const QString& name, int size, KIcon::MatchType match
it's a downscale, and we only had upscales befores. it's a downscale, and we only had upscales befores.
This is to avoid scaling up unless we have to, This is to avoid scaling up unless we have to,
since that looks very ugly */ since that looks very ugly */
if ((abs(dw) >= abs(delta)) || if (/*(abs(dw) >= abs(delta)) ||*/
(delta > 0 && dw < 0)) (delta > 0 && dw < 0))
continue; continue;
} }

@ -76,6 +76,7 @@ public:
#ifdef Q_WS_WIN #ifdef Q_WS_WIN
char win32SystemEncoding[3+7]; //"cp " + lang ID char win32SystemEncoding[3+7]; //"cp " + lang ID
#endif #endif
bool useMainCatalogue;
}; };
static KLocale *this_klocale = 0; static KLocale *this_klocale = 0;
@ -118,8 +119,13 @@ void KLocale::initMainCatalogues(const QString & catalog)
{ {
// Use the first non-null string. // Use the first non-null string.
QString mainCatalogue = catalog; QString mainCatalogue = catalog;
if (maincatalogue)
mainCatalogue = QString::fromLatin1(maincatalogue); // don't use main catalogue if we're looking up .desktop translations
if (mainCatalogue.contains("desktop") == 0 || mainCatalogue.contains("kdesktop") == 1) {
if (maincatalogue) {
mainCatalogue = QString::fromLatin1(maincatalogue);
}
}
if (mainCatalogue.isEmpty()) { if (mainCatalogue.isEmpty()) {
kdDebug(173) << "KLocale instance created called without valid " kdDebug(173) << "KLocale instance created called without valid "
@ -129,8 +135,11 @@ void KLocale::initMainCatalogues(const QString & catalog)
else { else {
// do not use insertCatalogue here, that would already trigger updateCatalogs // do not use insertCatalogue here, that would already trigger updateCatalogs
d->catalogNames.append( mainCatalogue ); // application catalog d->catalogNames.append( mainCatalogue ); // application catalog
d->catalogNames.append( SYSTEM_MESSAGES ); // always include kdelibs.mo if (mainCatalogue.contains("desktop") == 0 || mainCatalogue.contains("kdesktop") == 1) { //don't bother if we're looking up desktop translations
d->catalogNames.append( "kio" ); // always include kio.mo d->catalogNames.append( SYSTEM_MESSAGES ); // always include kdelibs.mo
d->catalogNames.append( "kio" ); // always include kio.mo
d->catalogNames.append( "xdg-user-dirs" );
}
updateCatalogues(); // evaluate this for all languages updateCatalogues(); // evaluate this for all languages
} }
} }

@ -95,24 +95,24 @@ extern "C" {
# endif # endif
#endif #endif
#if defined (__FreeBSD__) || defined (__NetBSD__) || defined (__OpenBSD__) || defined (__bsdi__) || defined(__APPLE__) || defined (__DragonFly__) #if defined(HAVE_TCGETATTR)
# define _tcgetattr(fd, ttmode) tcgetattr(fd, ttmode)
#elif defined(TIOCGETA)
# define _tcgetattr(fd, ttmode) ioctl(fd, TIOCGETA, (char *)ttmode) # define _tcgetattr(fd, ttmode) ioctl(fd, TIOCGETA, (char *)ttmode)
#elif defined(TCGETS)
# define _tcgetattr(fd, ttmode) ioctl(fd, TCGETS, (char *)ttmode)
#else #else
# if defined(_HPUX_SOURCE) || defined(__Lynx__) || defined (__CYGWIN__) # error
# define _tcgetattr(fd, ttmode) tcgetattr(fd, ttmode)
# else
# define _tcgetattr(fd, ttmode) ioctl(fd, TCGETS, (char *)ttmode)
# endif
#endif #endif
#if defined (__FreeBSD__) || defined (__NetBSD__) || defined (__OpenBSD__) || defined (__bsdi__) || defined(__APPLE__) || defined (__DragonFly__) #if defined(HAVE_TCSETATTR) && defined(TCSANOW)
# define _tcsetattr(fd, ttmode) tcsetattr(fd, TCSANOW, ttmode)
#elif defined(TIOCSETA)
# define _tcsetattr(fd, ttmode) ioctl(fd, TIOCSETA, (char *)ttmode) # define _tcsetattr(fd, ttmode) ioctl(fd, TIOCSETA, (char *)ttmode)
#elif defined(TCSETS)
# define _tcsetattr(fd, ttmode) ioctl(fd, TCSETS, (char *)ttmode)
#else #else
# if defined(_HPUX_SOURCE) || defined(__CYGWIN__) # error
# define _tcsetattr(fd, ttmode) tcsetattr(fd, TCSANOW, ttmode)
# else
# define _tcsetattr(fd, ttmode) ioctl(fd, TCSETS, (char *)ttmode)
# endif
#endif #endif
#if defined (_HPUX_SOURCE) #if defined (_HPUX_SOURCE)
@ -201,87 +201,37 @@ KPty::~KPty()
delete d; delete d;
} }
bool KPty::open() bool KPty::setPty(int pty_master)
{ {
if (d->masterFd >= 0) kdWarning(175)
return true; << "setPty()" << endl;
// a pty is already open
if(d->masterFd >= 0) {
kdWarning(175)
<< "d->masterFd >= 0" << endl;
return false;
}
d->masterFd = pty_master;
return _attachPty(pty_master);
}
bool KPty::_attachPty(int pty_master)
{
QCString ptyName; QCString ptyName;
// Find a master pty that we can open //////////////////////////////// kdWarning(175)
<< "_attachPty() " << pty_master << endl;
// Because not all the pty animals are created equal, they want to
// be opened by several different methods.
// We try, as we know them, one by one.
#if defined(HAVE_PTSNAME) && defined(HAVE_GRANTPT) #if defined(HAVE_PTSNAME) && defined(HAVE_GRANTPT)
#ifdef _AIX
d->masterFd = ::open("/dev/ptc",O_RDWR);
#else
d->masterFd = ::open("/dev/ptmx",O_RDWR);
#endif
if (d->masterFd >= 0)
{
char *ptsn = ptsname(d->masterFd); char *ptsn = ptsname(d->masterFd);
if (ptsn) { if (ptsn) {
grantpt(d->masterFd); grantpt(d->masterFd);
d->ttyName = ptsn; d->ttyName = ptsn;
goto gotpty;
} else { } else {
::close(d->masterFd); ::close(d->masterFd);
d->masterFd = -1; d->masterFd = -1;
} }
}
#endif #endif
// Linux device names, FIXME: Trouble on other systems?
for (const char* s3 = "pqrstuvwxyzabcdefghijklmno"; *s3; s3++)
{
for (const char* s4 = "0123456789abcdefghijklmnopqrstuvwxyz"; *s4; s4++)
{
ptyName.sprintf("/dev/pty%c%c", *s3, *s4);
d->ttyName.sprintf("/dev/tty%c%c", *s3, *s4);
d->masterFd = ::open(ptyName.data(), O_RDWR);
if (d->masterFd >= 0)
{
#ifdef __sun
/* Need to check the process group of the pty.
* If it exists, then the slave pty is in use,
* and we need to get another one.
*/
int pgrp_rtn;
if (ioctl(d->masterFd, TIOCGPGRP, &pgrp_rtn) == 0 || errno != EIO) {
::close(d->masterFd);
d->masterFd = -1;
continue;
}
#endif /* sun */
if (!access(d->ttyName.data(),R_OK|W_OK)) // checks availability based on permission bits
{
if (!geteuid())
{
struct group* p = getgrnam(TTY_GROUP);
if (!p)
p = getgrnam("wheel");
gid_t gid = p ? p->gr_gid : getgid ();
chown(d->ttyName.data(), getuid(), gid);
chmod(d->ttyName.data(), S_IRUSR|S_IWUSR|S_IWGRP);
}
goto gotpty;
}
::close(d->masterFd);
d->masterFd = -1;
}
}
}
kdWarning(175) << "Can't open a pseudo teletype" << endl;
return false;
gotpty:
struct stat st; struct stat st;
if (stat(d->ttyName.data(), &st)) if (stat(d->ttyName.data(), &st))
return false; // this just cannot happen ... *cough* Yeah right, I just return false; // this just cannot happen ... *cough* Yeah right, I just
@ -354,6 +304,92 @@ bool KPty::open()
return true; return true;
} }
bool KPty::open()
{
if (d->masterFd >= 0)
return true;
QCString ptyName;
// Find a master pty that we can open ////////////////////////////////
// Because not all the pty animals are created equal, they want to
// be opened by several different methods.
// We try, as we know them, one by one.
#if defined(HAVE_PTSNAME) && defined(HAVE_GRANTPT)
#ifdef _AIX
d->masterFd = ::open("/dev/ptc",O_RDWR);
#else
d->masterFd = ::open("/dev/ptmx",O_RDWR);
#endif
if (d->masterFd >= 0)
{
char *ptsn = ptsname(d->masterFd);
if (ptsn) {
grantpt(d->masterFd);
d->ttyName = ptsn;
goto gotpty;
} else {
::close(d->masterFd);
d->masterFd = -1;
}
}
#endif
// Linux device names, FIXME: Trouble on other systems?
for (const char* s3 = "pqrstuvwxyzabcdefghijklmno"; *s3; s3++)
{
for (const char* s4 = "0123456789abcdefghijklmnopqrstuvwxyz"; *s4; s4++)
{
ptyName.sprintf("/dev/pty%c%c", *s3, *s4);
d->ttyName.sprintf("/dev/tty%c%c", *s3, *s4);
d->masterFd = ::open(ptyName.data(), O_RDWR);
if (d->masterFd >= 0)
{
#ifdef __sun
/* Need to check the process group of the pty.
* If it exists, then the slave pty is in use,
* and we need to get another one.
*/
int pgrp_rtn;
if (ioctl(d->masterFd, TIOCGPGRP, &pgrp_rtn) == 0 || errno != EIO) {
::close(d->masterFd);
d->masterFd = -1;
continue;
}
#endif /* sun */
if (!access(d->ttyName.data(),R_OK|W_OK)) // checks availability based on permission bits
{
if (!geteuid())
{
struct group* p = getgrnam(TTY_GROUP);
if (!p)
p = getgrnam("wheel");
gid_t gid = p ? p->gr_gid : getgid ();
chown(d->ttyName.data(), getuid(), gid);
chmod(d->ttyName.data(), S_IRUSR|S_IWUSR|S_IWGRP);
}
goto gotpty;
}
::close(d->masterFd);
d->masterFd = -1;
}
}
}
kdWarning(175) << "Can't open a pseudo teletype" << endl;
return false;
gotpty:
return _attachPty(d->masterFd);
return true;
}
void KPty::close() void KPty::close()
{ {
if (d->masterFd < 0) if (d->masterFd < 0)

@ -61,6 +61,13 @@ public:
*/ */
bool open(); bool open();
/**
* Attach a existing pty master
*
* @return true if the pty was successfully added
*/
bool setPty(int pty_master);
/** /**
* Close the pty master/slave pair. * Close the pty master/slave pair.
*/ */
@ -138,6 +145,9 @@ public:
*/ */
int slaveFd() const; int slaveFd() const;
protected:
bool _attachPty(int pty_master);
private: private:
bool chownpty(bool grant); bool chownpty(bool grant);

@ -834,6 +834,10 @@ QStringList KStandardDirs::resourceDirs(const char *type) const
if ((local || testdir.exists()) && !candidates->contains(path)) if ((local || testdir.exists()) && !candidates->contains(path))
candidates->append(path); candidates->append(path);
} }
// UGLY HACK - Chris CHeney
if (local && (!strcmp("config", type)))
candidates->append("/etc/kde3/");
//
local = false; local = false;
} }
} }
@ -1021,7 +1025,7 @@ QString KStandardDirs::kde_default(const char *type) {
if (!strcmp(type, "data")) if (!strcmp(type, "data"))
return "share/apps/"; return "share/apps/";
if (!strcmp(type, "html")) if (!strcmp(type, "html"))
return "share/doc/HTML/"; return "share/doc/kde/HTML/";
if (!strcmp(type, "icon")) if (!strcmp(type, "icon"))
return "share/icons/"; return "share/icons/";
if (!strcmp(type, "config")) if (!strcmp(type, "config"))
@ -1041,7 +1045,7 @@ QString KStandardDirs::kde_default(const char *type) {
if (!strcmp(type, "mime")) if (!strcmp(type, "mime"))
return "share/mimelnk/"; return "share/mimelnk/";
if (!strcmp(type, "cgi")) if (!strcmp(type, "cgi"))
return "cgi-bin/"; return "lib/cgi-bin/";
if (!strcmp(type, "wallpaper")) if (!strcmp(type, "wallpaper"))
return "share/wallpapers/"; return "share/wallpapers/";
if (!strcmp(type, "templates")) if (!strcmp(type, "templates"))
@ -1315,7 +1319,7 @@ void KStandardDirs::addKDEDefaults()
} }
else else
{ {
localKdeDir = QDir::homeDirPath() + "/.kde/"; localKdeDir = QDir::homeDirPath() + "/.kde3/";
} }
if (localKdeDir != "-/") if (localKdeDir != "-/")
@ -1425,6 +1429,8 @@ void KStandardDirs::addKDEDefaults()
} }
addResourceDir("home", QDir::homeDirPath()); addResourceDir("home", QDir::homeDirPath());
addResourceDir("locale", "/usr/share/locale-langpack/", true);
} }
void KStandardDirs::checkConfig() const void KStandardDirs::checkConfig() const

@ -1109,7 +1109,7 @@ unsigned long KStartupInfoId::timestamp() const
struct KStartupInfoDataPrivate struct KStartupInfoDataPrivate
{ {
KStartupInfoDataPrivate() : desktop( 0 ), wmclass( "" ), hostname( "" ), KStartupInfoDataPrivate() : desktop( 0 ), wmclass( "" ), hostname( "" ),
silent( KStartupInfoData::Unknown ), timestamp( -1U ), screen( -1 ) {} silent( KStartupInfoData::Unknown ), timestamp( -1U ), screen( -1 ), xinerama( -1 ), launched_by( 0 ) {}
QString bin; QString bin;
QString name; QString name;
QString description; QString description;
@ -1121,6 +1121,8 @@ struct KStartupInfoDataPrivate
KStartupInfoData::TriState silent; KStartupInfoData::TriState silent;
unsigned long timestamp; unsigned long timestamp;
int screen; int screen;
int xinerama;
WId launched_by;
}; };
QString KStartupInfoData::to_text() const QString KStartupInfoData::to_text() const
@ -1151,6 +1153,10 @@ QString KStartupInfoData::to_text() const
ret += QString::fromLatin1( " TIMESTAMP=%1" ).arg( d->timestamp ); ret += QString::fromLatin1( " TIMESTAMP=%1" ).arg( d->timestamp );
if( d->screen != -1 ) if( d->screen != -1 )
ret += QString::fromLatin1( " SCREEN=%1" ).arg( d->screen ); ret += QString::fromLatin1( " SCREEN=%1" ).arg( d->screen );
if( d->xinerama != -1 )
ret += QString::fromLatin1( " XINERAMA=%1" ).arg( d->xinerama );
if( d->launched_by != 0 )
ret += QString::fromLatin1( " LAUNCHED_BY=%1" ).arg( d->launched_by );
return ret; return ret;
} }
@ -1169,6 +1175,8 @@ KStartupInfoData::KStartupInfoData( const QString& txt_P )
const QString silent_str = QString::fromLatin1( "SILENT=" ); const QString silent_str = QString::fromLatin1( "SILENT=" );
const QString timestamp_str = QString::fromLatin1( "TIMESTAMP=" ); const QString timestamp_str = QString::fromLatin1( "TIMESTAMP=" );
const QString screen_str = QString::fromLatin1( "SCREEN=" ); const QString screen_str = QString::fromLatin1( "SCREEN=" );
const QString xinerama_str = QString::fromLatin1( "XINERAMA=" );
const QString launched_by_str = QString::fromLatin1( "LAUNCHED_BY=" );
for( QStringList::Iterator it = items.begin(); for( QStringList::Iterator it = items.begin();
it != items.end(); it != items.end();
++it ) ++it )
@ -1199,6 +1207,10 @@ KStartupInfoData::KStartupInfoData( const QString& txt_P )
d->timestamp = get_unum( *it ); d->timestamp = get_unum( *it );
else if( ( *it ).startsWith( screen_str )) else if( ( *it ).startsWith( screen_str ))
d->screen = get_num( *it ); d->screen = get_num( *it );
else if( ( *it ).startsWith( xinerama_str ))
d->xinerama = get_num( *it );
else if( ( *it ).startsWith( launched_by_str ))
d->launched_by = get_num( *it );
} }
} }
@ -1242,6 +1254,10 @@ void KStartupInfoData::update( const KStartupInfoData& data_P )
d->timestamp = data_P.timestamp(); d->timestamp = data_P.timestamp();
if( data_P.screen() != -1 ) if( data_P.screen() != -1 )
d->screen = data_P.screen(); d->screen = data_P.screen();
if( data_P.xinerama() != -1 && xinerama() != -1 ) // don't overwrite
d->xinerama = data_P.xinerama();
if( data_P.launchedBy() != 0 && launchedBy() != 0 ) // don't overwrite
d->launched_by = data_P.launchedBy();
} }
KStartupInfoData::KStartupInfoData() KStartupInfoData::KStartupInfoData()
@ -1412,6 +1428,26 @@ int KStartupInfoData::screen() const
return d->screen; return d->screen;
} }
void KStartupInfoData::setXinerama( int xinerama )
{
d->xinerama = xinerama;
}
int KStartupInfoData::xinerama() const
{
return d->xinerama;
}
void KStartupInfoData::setLaunchedBy( WId window )
{
d->launched_by = window;
}
WId KStartupInfoData::launchedBy() const
{
return d->launched_by;
}
static static
long get_num( const QString& item_P ) long get_num( const QString& item_P )
{ {

@ -636,6 +636,30 @@ class KDECORE_EXPORT KStartupInfoData
*/ */
void setScreen( int screen ); void setScreen( int screen );
/**
* The Xinerama screen for the startup notification, -1 if unknown.
*/
int xinerama() const;
/**
* Sets the Xinerama screen for the startup notification ( i.e. the screeen on which
* the starting application should appear ).
* @param xinerama the Xinerama screen for the startup notification
*/
void setXinerama( int xinerama );
/**
* The toplevel window of the application that caused this startup notification,
* 0 if unknown.
*/
WId launchedBy() const;
/**
* Sets the toplevel window of the application that caused this startup notification.
* @param window window ID of the toplevel window that is responsible for this startup
*/
void setLaunchedBy( WId window );
/** /**
* Updates the notification data from the given data. Some data, such as the desktop * Updates the notification data from the given data. Some data, such as the desktop
* or the name, won't be rewritten if already set. * or the name, won't be rewritten if already set.

@ -145,6 +145,9 @@ static Atom net_wm_state_stays_on_top = 0;
// used to determine whether application window is managed or not // used to determine whether application window is managed or not
static Atom xa_wm_state = 0; static Atom xa_wm_state = 0;
// ability flags
static Atom net_wm_full_placement = 0;
static Bool netwm_atoms_created = False; static Bool netwm_atoms_created = False;
const unsigned long netwm_sendevent_mask = (SubstructureRedirectMask| const unsigned long netwm_sendevent_mask = (SubstructureRedirectMask|
SubstructureNotifyMask); SubstructureNotifyMask);
@ -236,7 +239,7 @@ static int wcmp(const void *a, const void *b) {
} }
static const int netAtomCount = 84; static const int netAtomCount = 85;
static void create_atoms(Display *d) { static void create_atoms(Display *d) {
static const char * const names[netAtomCount] = static const char * const names[netAtomCount] =
{ {
@ -330,7 +333,9 @@ static void create_atoms(Display *d) {
"_KDE_NET_WM_TEMPORARY_RULES", "_KDE_NET_WM_TEMPORARY_RULES",
"WM_STATE", "WM_STATE",
"WM_PROTOCOLS" "WM_PROTOCOLS",
"_NET_WM_FULL_PLACEMENT"
}; };
Atom atoms[netAtomCount], *atomsp[netAtomCount] = Atom atoms[netAtomCount], *atomsp[netAtomCount] =
@ -425,7 +430,9 @@ static void create_atoms(Display *d) {
&kde_net_wm_temporary_rules, &kde_net_wm_temporary_rules,
&xa_wm_state, &xa_wm_state,
&wm_protocols &wm_protocols,
&net_wm_full_placement
}; };
assert( !netwm_atoms_created ); assert( !netwm_atoms_created );
@ -1355,6 +1362,8 @@ void NETRootInfo::setSupported() {
if (p->properties[ PROTOCOLS2 ] & WM2KDETemporaryRules) if (p->properties[ PROTOCOLS2 ] & WM2KDETemporaryRules)
atoms[pnum++] = kde_net_wm_temporary_rules; atoms[pnum++] = kde_net_wm_temporary_rules;
if (p->properties[ PROTOCOLS2 ] & WM2FullPlacement)
atoms[pnum++] = net_wm_full_placement;
XChangeProperty(p->display, p->root, net_supported, XA_ATOM, 32, XChangeProperty(p->display, p->root, net_supported, XA_ATOM, 32,
PropModeReplace, (unsigned char *) atoms, pnum); PropModeReplace, (unsigned char *) atoms, pnum);
@ -1587,6 +1596,8 @@ void NETRootInfo::updateSupportedProperties( Atom atom )
else if( atom == kde_net_wm_temporary_rules ) else if( atom == kde_net_wm_temporary_rules )
p->properties[ PROTOCOLS2 ] |= WM2KDETemporaryRules; p->properties[ PROTOCOLS2 ] |= WM2KDETemporaryRules;
else if( atom == net_wm_full_placement )
p->properties[ PROTOCOLS2 ] |= WM2FullPlacement;
} }
extern Time qt_x_user_time; extern Time qt_x_user_time;

@ -610,6 +610,7 @@ public:
WM2WindowRole = 1<<11, ///< @since 3.3 WM2WindowRole = 1<<11, ///< @since 3.3
WM2ClientMachine = 1<<12, ///< @since 3.3 WM2ClientMachine = 1<<12, ///< @since 3.3
WM2ShowingDesktop = 1<<13, ///< @since 3.5 WM2ShowingDesktop = 1<<13, ///< @since 3.5
WM2FullPlacement = 1<<14,
WM2DesktopLayout = 1<<15 ///< @since 3.5.8 WM2DesktopLayout = 1<<15 ///< @since 3.5.8
}; };

@ -127,19 +127,16 @@ bool KResolverWorkerBase::enqueue(KResolverWorkerBase* worker)
bool KResolverWorkerBase::checkResolver() bool KResolverWorkerBase::checkResolver()
{ {
assert(th != 0L);
return th->checkResolver(); return th->checkResolver();
} }
void KResolverWorkerBase::acquireResolver() void KResolverWorkerBase::acquireResolver()
{ {
assert(th != 0L);
th->acquireResolver(); th->acquireResolver();
} }
void KResolverWorkerBase::releaseResolver() void KResolverWorkerBase::releaseResolver()
{ {
assert(th != 0L);
th->releaseResolver(); th->releaseResolver();
} }

@ -23,11 +23,11 @@ lib_LTLIBRARIES =
kdeinit_LTLIBRARIES = kded.la kbuildsycoca.la kdeinit_LTLIBRARIES = kded.la kbuildsycoca.la
kded_la_LDFLAGS = $(all_libraries) -module -avoid-version kded_la_LDFLAGS = $(all_libraries) -module -avoid-version
kded_la_LIBADD = $(LIB_KIO) kded_la_LIBADD = $(LIB_KIO) $(LIB_QT) $(LIB_KDECORE) $(top_builddir)/dcop/libDCOP.la $(LIB_X11)
kded_la_SOURCES = kded.cpp kdedmodule.cpp kded_la_SOURCES = kded.cpp kdedmodule.cpp
kbuildsycoca_la_LDFLAGS = $(all_libraries) -module -avoid-version kbuildsycoca_la_LDFLAGS = $(all_libraries) -module -avoid-version
kbuildsycoca_la_LIBADD = $(LIB_KIO) kbuildsycoca_la_LIBADD = $(LIB_KIO) $(LIB_QT) $(top_builddir)/dcop/libDCOP.la $(LIB_KDECORE)
kbuildsycoca_la_SOURCES = kbuildsycoca.cpp kbuildservicetypefactory.cpp \ kbuildsycoca_la_SOURCES = kbuildsycoca.cpp kbuildservicetypefactory.cpp \
kbuildservicefactory.cpp \ kbuildservicefactory.cpp \
kbuildservicegroupfactory.cpp \ kbuildservicegroupfactory.cpp \

@ -248,6 +248,7 @@
<And> <And>
<Category>Graphics</Category> <Category>Graphics</Category>
<Not><Category>X-KDE-More</Category></Not> <Not><Category>X-KDE-More</Category></Not>
<Not><Filename>ooo-draw.desktop</Filename></Not>
</And> </And>
</Include> </Include>
<Menu> <Menu>
@ -325,6 +326,7 @@
<Category>Office</Category> <Category>Office</Category>
<Not><Category>X-KDE-More</Category></Not> <Not><Category>X-KDE-More</Category></Not>
</And> </And>
<Filename>ooo-draw.desktop</Filename>
</Include> </Include>
<Menu> <Menu>
<Name>More</Name> <Name>More</Name>
@ -376,73 +378,19 @@
<Name>Utilities</Name> <Name>Utilities</Name>
<Directory>kde-utilities.directory</Directory> <Directory>kde-utilities.directory</Directory>
<Include> <Include>
<And> <And>
<Or>
<Category>Utility</Category> <Category>Utility</Category>
<Not><Category>Accessibility</Category></Not> <Category>TextEditor</Category>
<Not><Category>X-KDE-Utilities-Desktop</Category></Not> <Category>X-KDE-Utilities-File</Category>
<Not><Category>X-KDE-Utilities-File</Category></Not> <Category>X-KDE-Utilities-Desktop</Category>
<Not><Category>X-KDE-Utilities-Peripherals</Category></Not> <Category>X-KDE-Utilities-Peripherals</Category>
<Not><Category>X-KDE-Utilities-PIM</Category></Not> <Category>X-KDE-Utilities-PIM</Category>
<Category>Accessibility</Category>
</Or>
<Not><Category>X-KDE-More</Category></Not> <Not><Category>X-KDE-More</Category></Not>
</And> </And>
</Include> </Include>
<Menu>
<Name>Accessibility</Name>
<Directory>kde-utilities-accessibility.directory</Directory>
<Include>
<And>
<Category>Utility</Category>
<Category>Accessibility</Category>
</And>
</Include>
</Menu>
<Menu>
<Name>Desktop</Name>
<Directory>kde-utilities-desktop.directory</Directory>
<Include>
<And>
<Category>Utility</Category>
<Category>X-KDE-Utilities-Desktop</Category>
</And>
</Include>
</Menu>
<Menu>
<Name>Editors</Name>
<Directory>kde-editors.directory</Directory>
<Include>
<Category>TextEditor</Category>
</Include>
</Menu>
<Menu>
<Name>File</Name>
<Directory>kde-utilities-file.directory</Directory>
<Include>
<And>
<Category>Utility</Category>
<Category>X-KDE-Utilities-File</Category>
</And>
</Include>
</Menu>
<Menu>
<Name>Peripherals</Name>
<Directory>kde-utilities-peripherals.directory</Directory>
<Include>
<And>
<Category>Utility</Category>
<Category>X-KDE-Utilities-Peripherals</Category>
</And>
</Include>
</Menu>
<Menu>
<Name>PIM</Name>
<Directory>kde-utilities-pim.directory</Directory>
<Include>
<And>
<Category>Utility</Category>
<Category>X-KDE-Utilities-PIM</Category>
</And>
</Include>
</Menu>
<Menu> <Menu>
<Name>XUtilities</Name> <Name>XUtilities</Name>
<Directory>kde-utilities-xutils.directory</Directory> <Directory>kde-utilities-xutils.directory</Directory>
@ -465,5 +413,13 @@
</And> </And>
</Include> </Include>
<DefaultMergeDirs/> <DefaultMergeDirs/>
<Menu>
<Name>Debian</Name>
<Directory>debian.directory</Directory>
<MergeFile>debian-menu.menu</MergeFile>
</Menu>
<MergeDir>applications-merged</MergeDir>
<MergeFile>applications-kmenuedit.menu</MergeFile> <MergeFile>applications-kmenuedit.menu</MergeFile>
</Menu> </Menu>

@ -158,7 +158,7 @@ KBuildServiceFactory::saveOfferList(QDataStream &str)
KServiceType::Ptr serviceType = KServiceType::serviceType(*it); KServiceType::Ptr serviceType = KServiceType::serviceType(*it);
if (!serviceType) if (!serviceType)
{ {
kdWarning() << "'"<< service->desktopEntryPath() << "' specifies undefined mimetype/servicetype '"<< (*it) << "'" << endl; // kdWarning() << "'"<< service->desktopEntryPath() << "' specifies undefined mimetype/servicetype '"<< (*it) << "'" << endl;
continue; continue;
} }
serviceTypes.append(serviceType); serviceTypes.append(serviceType);

@ -162,12 +162,27 @@ void Kded::initModules()
kde_running = false; kde_running = false;
// Preload kded modules. // Preload kded modules.
KService::List kdedModules = KServiceType::offers("KDEDModule"); KService::List kdedModules = KServiceType::offers("KDEDModule");
QString version = getenv( "KDE_SESSION_VERSION" );
QStringList blacklist;
if ( version >= "4" )
{
kdDebug(7020) << "KDE4 is running." << endl;
blacklist << "mediamanager" << "medianotifier" << "kmilod" << "kwrited";
}
for(KService::List::ConstIterator it = kdedModules.begin(); it != kdedModules.end(); ++it) for(KService::List::ConstIterator it = kdedModules.begin(); it != kdedModules.end(); ++it)
{ {
KService::Ptr service = *it; KService::Ptr service = *it;
bool autoload = service->property("X-KDE-Kded-autoload", QVariant::Bool).toBool(); bool autoload = service->property("X-KDE-Kded-autoload", QVariant::Bool).toBool();
config->setGroup(QString("Module-%1").arg(service->desktopEntryName())); config->setGroup(QString("Module-%1").arg(service->desktopEntryName()));
autoload = config->readBoolEntry("autoload", autoload); autoload = config->readBoolEntry("autoload", autoload);
for (QStringList::Iterator module = blacklist.begin(); module != blacklist.end(); ++module)
{
if (service->desktopEntryName() == *module)
{
autoload = false;
break;
}
}
if( m_newStartup ) if( m_newStartup )
{ {
// see ksmserver's README for description of the phases // see ksmserver's README for description of the phases

@ -774,7 +774,9 @@ VFolderMenu::locateMenuFile(const QString &fileName)
QString result; QString result;
QString xdgMenuPrefix = QString::fromLocal8Bit(getenv("XDG_MENU_PREFIX")); //QString xdgMenuPrefix = QString::fromLocal8Bit(getenv("XDG_MENU_PREFIX"));
// hardcode xdgMenuPrefix to "kde-" string until proper upstream fix
QString xdgMenuPrefix = "kde-";
if (!xdgMenuPrefix.isEmpty()) if (!xdgMenuPrefix.isEmpty())
{ {
QFileInfo fileInfo(fileName); QFileInfo fileInfo(fileName);

@ -24,7 +24,7 @@ INCLUDES= $(all_includes)
lib_LTLIBRARIES = libkdefx.la lib_LTLIBRARIES = libkdefx.la
libkdefx_la_LDFLAGS = $(KDE_RPATH) $(KDE_MT_LDFLAGS) $(all_libraries) -no-undefined -version-info 6:0:2 libkdefx_la_LDFLAGS = $(KDE_RPATH) $(KDE_MT_LDFLAGS) $(all_libraries) -no-undefined -version-info 6:0:2
libkdefx_la_LIBADD = $(LIB_QT) $(LIB_XRENDER) libkdefx_la_LIBADD = $(LIB_QT) $(LIB_XRENDER) $(LIB_X11)
libkdefx_la_NMCHECK = $(srcdir)/libkdefx.nmcheck libkdefx_la_NMCHECK = $(srcdir)/libkdefx.nmcheck
libkdefx_la_NMCHECKWEAK = $(srcdir)/libkdefx_weak.nmcheck $(top_srcdir)/kdecore/libqt-mt_weak.nmcheck \ libkdefx_la_NMCHECKWEAK = $(srcdir)/libkdefx_weak.nmcheck $(top_srcdir)/kdecore/libqt-mt_weak.nmcheck \
$(top_srcdir)/kdecore/standard_weak.nmcheck $(top_srcdir)/kdecore/standard_weak.nmcheck

@ -154,6 +154,7 @@ struct KStylePrivate
bool menuAltKeyNavigation : 1; bool menuAltKeyNavigation : 1;
bool menuDropShadow : 1; bool menuDropShadow : 1;
bool sloppySubMenus : 1; bool sloppySubMenus : 1;
bool semiTransparentRubberband : 1;
int popupMenuDelay; int popupMenuDelay;
float menuOpacity; float menuOpacity;
@ -187,6 +188,7 @@ KStyle::KStyle( KStyleFlags flags, KStyleScrollBarType sbtype )
d->menuAltKeyNavigation = settings.readBoolEntry("/KStyle/Settings/MenuAltKeyNavigation", true); d->menuAltKeyNavigation = settings.readBoolEntry("/KStyle/Settings/MenuAltKeyNavigation", true);
d->scrollablePopupmenus = settings.readBoolEntry("/KStyle/Settings/ScrollablePopupMenus", false); d->scrollablePopupmenus = settings.readBoolEntry("/KStyle/Settings/ScrollablePopupMenus", false);
d->menuDropShadow = settings.readBoolEntry("/KStyle/Settings/MenuDropShadow", false); d->menuDropShadow = settings.readBoolEntry("/KStyle/Settings/MenuDropShadow", false);
d->semiTransparentRubberband = settings.readBoolEntry("/KStyle/Settings/SemiTransparentRubberband", false);
d->menuHandler = NULL; d->menuHandler = NULL;
if (useMenuTransparency) { if (useMenuTransparency) {
@ -553,7 +555,57 @@ void KStyle::drawPrimitive( PrimitiveElement pe,
else else
// General handle, probably a kicker applet handle. // General handle, probably a kicker applet handle.
drawKStylePrimitive( KPE_GeneralHandle, p, widget, r, cg, flags, opt ); drawKStylePrimitive( KPE_GeneralHandle, p, widget, r, cg, flags, opt );
#if QT_VERSION >= 0x030300
#ifdef HAVE_XRENDER
} else if ( d->semiTransparentRubberband && pe == QStyle::PE_RubberBand ) {
QRect rect = r.normalize();
QPoint point;
point = p->xForm( point );
static XRenderColor clr = { 0, 0, 0, 0 };
static unsigned long fillColor = 0;
if ( fillColor != cg.highlight().rgb() ) {
fillColor = cg.highlight().rgb();
unsigned long color = fillColor << 8 | 0x40;
int red = (color >> 24) & 0xff;
int green = (color >> 16) & 0xff;
int blue = (color >> 8) & 0xff;
int alpha = (color >> 0) & 0xff;
red = red * alpha / 255;
green = green * alpha / 255;
blue = blue * alpha / 255;
clr.red = (red << 8) + red;
clr.green = (green << 8) + green;
clr.blue = (blue << 8) + blue;
clr.alpha = (alpha << 8) + alpha;
}
XRenderFillRectangle(
p->device()->x11Display(),
PictOpOver,
p->device()->x11RenderHandle(),
&clr,
rect.x() + point.x(),
rect.y() + point.y(),
rect.width(),
rect.height() );
p->save();
p->setRasterOp( Qt::CopyROP );
p->setPen( QPen( cg.highlight().dark( 160 ), 1 ) );
p->setBrush( NoBrush );
p->drawRect(
rect.x() + point.x(),
rect.y() + point.y(),
rect.width(),
rect.height() );
p->restore();
#endif
#endif
} else } else
QCommonStyle::drawPrimitive( pe, p, r, cg, flags, opt ); QCommonStyle::drawPrimitive( pe, p, r, cg, flags, opt );
} }

@ -1,11 +1,11 @@
Begin4 Begin4
Title: kdelibs Title: kdelibs
Version: 3.5.10 Version: Trinity 3.5.11
Entered-date: 2008-08-26 Entered-date: 2008-08-26
Description: libraries for the K Desktop Environment (KDE) Description: libraries for the K Desktop Environment (KDE)
Keywords: KDE X11 desktop Qt Keywords: KDE X11 desktop Qt
Author: http://bugs.kde.org/ (KDE Bugtracking System) Author: http://bugs.pearsoncomputing.net/ (KDE Trinity Bugtracking System)
Primary-site: http://www.kde.org/download/ Primary-site: http://trinity.pearsoncomputing.net/
Platforms: Unix, Qt Platforms: Unix, Qt
Copying-policy: LGPL, Artistic Copying-policy: LGPL, Artistic
End End

@ -11,7 +11,7 @@ INCLUDES= -I$(top_srcdir)/kdefx -I$(top_srcdir)/kded -I$(top_srcdir) $(all_inclu
kde_module_LTLIBRARIES = kded_kdeprintd.la kde_module_LTLIBRARIES = kded_kdeprintd.la
kded_kdeprintd_la_SOURCES = kdeprintd.skel kdeprintd.cpp kprintprocess.cpp kded_kdeprintd_la_SOURCES = kdeprintd.skel kdeprintd.cpp kprintprocess.cpp
kded_kdeprintd_la_LIBADD = $(LIB_KIO) $(LIB_KDED) kded_kdeprintd_la_LIBADD = $(LIB_KIO) $(LIB_KDED) $(LIB_QT) $(LIB_KDEUI) $(top_builddir)/dcop/libDCOP.la $(LIB_KDECORE) $(top_builddir)/kded/libkdeinit_kded.la
kded_kdeprintd_la_LDFLAGS = $(all_libraries) -module -avoid-version kded_kdeprintd_la_LDFLAGS = $(all_libraries) -module -avoid-version
#kded_kdeprintd_la_METASOURCES = AUTO #kded_kdeprintd_la_METASOURCES = AUTO
@ -30,7 +30,7 @@ libkdeprint_la_SOURCES = kmfactory.cpp kmjob.cpp kmjobmanager.cpp kmmanager.cpp
fooparser.cpp fooscanner.cpp ppdparser.cpp ppdscanner.cpp ppdloader.cpp fooparser.cpp fooscanner.cpp ppdparser.cpp ppdscanner.cpp ppdloader.cpp
libkdeprint_la_LDFLAGS = $(all_libraries) -version-info 6:0:2 -no-undefined libkdeprint_la_LDFLAGS = $(all_libraries) -version-info 6:0:2 -no-undefined
libkdeprint_la_LIBADD = $(LIB_KPARTS) $(LIBZ) libkdeprint_la_LIBADD = $(LIBZ) $(LIB_QT) $(LIB_KDEUI) $(top_builddir)/dcop/libDCOP.la $(LIB_KDECORE) $(LIB_KFILE)
libkdeprint_la_DEPENDENCIES = $(LIB_KPARTS) libkdeprint_la_DEPENDENCIES = $(LIB_KPARTS)
libkdeprint_la_METASOURCES = AUTO libkdeprint_la_METASOURCES = AUTO

@ -51,10 +51,11 @@ if test "$ac_use_cups" = "yes"; then
ac_LDFLAGS_save="$LDFLAGS" ac_LDFLAGS_save="$LDFLAGS"
LDFLAGS="$LDFLAGS $all_libraries" LDFLAGS="$LDFLAGS $all_libraries"
kde_cups_config= kde_cups_config=
kde_cups_libs="-lcups $LIBDL $LIBSOCKET" kde_cups_libs="-lcups"
AC_PATH_PROG(kde_cups_config,cups-config) AC_PATH_PROG(kde_cups_config,cups-config)
if test -n "$kde_cups_config"; then if test -n "$kde_cups_config"; then
kde_cups_libs=`$kde_cups_config --libs` # kde_cups_libs=`$kde_cups_config --libs`
kde_cups_libs="$kde_cups_libs"
else else
AC_MSG_RESULT(cups-config not found, using default libraries: $kde_cups_libs. You should consider upgrading CUPS) AC_MSG_RESULT(cups-config not found, using default libraries: $kde_cups_libs. You should consider upgrading CUPS)
fi fi

@ -15,7 +15,7 @@ kdeprint_cups_la_SOURCES = cupsinfos.cpp ipprequest.cpp kmcupsfactory.cpp kmcups
kptextpage.cpp kphpgl2page.cpp cupsaddsmb2.cpp kmwother.cpp ippreportdlg.cpp \ kptextpage.cpp kphpgl2page.cpp cupsaddsmb2.cpp kmwother.cpp ippreportdlg.cpp \
kptagspage.cpp kptagspage.cpp
kdeprint_cups_la_LDFLAGS = $(all_libraries) -module -avoid-version -no-undefined kdeprint_cups_la_LDFLAGS = $(all_libraries) -module -avoid-version -no-undefined
kdeprint_cups_la_LIBADD = $(top_builddir)/kdeprint/management/libkdeprint_management.la $(LIB_KIO) $(LIB_CUPS) $(top_builddir)/kdecore/libkdefakes.la kdeprint_cups_la_LIBADD = $(top_builddir)/kdeprint/management/libkdeprint_management.la $(LIB_KIO) $(LIB_CUPS) $(LIB_QT) $(LIB_KDEPRINT) $(LIB_KDECORE) $(LIB_KDEUI)
kdeprint_cups_la_METASOURCES = AUTO kdeprint_cups_la_METASOURCES = AUTO
noinst_HEADERS = cupsinfos.h ipprequest.h kmcupsjobmanager.h kmcupsmanager.h kmcupsuimanager.h \ noinst_HEADERS = cupsinfos.h ipprequest.h kmcupsjobmanager.h kmcupsmanager.h kmcupsuimanager.h \

@ -15,7 +15,7 @@ cupsdconf_la_SOURCES = cupsdconf.cpp cupsddialog.cpp cupsdpage.cpp cupsdcomment.
qdirmultilineedit.cpp sizewidget.cpp main.cpp qdirmultilineedit.cpp sizewidget.cpp main.cpp
cupsdconf_la_METASOURCES = AUTO cupsdconf_la_METASOURCES = AUTO
cupsdconf_la_LDFLAGS = -avoid-version -module $(all_libraries) $(KDE_RPATH) cupsdconf_la_LDFLAGS = -avoid-version -module $(all_libraries) $(KDE_RPATH)
cupsdconf_la_LIBADD = $(LIB_KIO) $(LIB_CUPS) cupsdconf_la_LIBADD = $(LIB_KIO) $(LIB_CUPS) $(LIB_QT) $(LIB_KDEUI) $(LIB_KDECORE)
noinst_HEADERS = cupsdconf.h cupsdpage.h cupsddialog.h cupsdcomment.h cupsdsplash.h \ noinst_HEADERS = cupsdconf.h cupsdpage.h cupsddialog.h cupsdcomment.h cupsdsplash.h \
cupsdserverpage.h cupsdlogpage.h cupsdjobspage.h cupsdfilterpage.h \ cupsdserverpage.h cupsdlogpage.h cupsdjobspage.h cupsdfilterpage.h \

@ -100,9 +100,9 @@ $$
# The root directory for HTTP documents that are served. # The root directory for HTTP documents that are served.
# By default the compiled-in directory.</p> # By default the compiled-in directory.</p>
# <p> # <p>
# <i>ex</i>: /usr/share/cups/doc</p> # <i>ex</i>: /usr/share/cups/doc-root</p>
$$ $$
#DocumentRoot /usr/share/cups/doc #DocumentRoot /usr/share/cups/doc-root
@@ @@
%%errorlog %%errorlog
@ -272,12 +272,12 @@ $$
# <b>Group (Group)</b> # <b>Group (Group)</b>
# <p> # <p>
# The group the server runs under. Normally this # The group the server runs under. Normally this
# must be <b>sys</b>, however you can configure things for another # must be <b>lpadmin</b>, however you can configure things for another
# group as needed.</p> # group as needed.</p>
# <p> # <p>
# <i>ex</i>: sys</p> # <i>ex</i>: lpadmin</p>
$$ $$
#Group sys #Group lpadmin
@@ @@
%%ripcache %%ripcache
@ -592,9 +592,9 @@ $$
# access. The default varies depending on the operating system, but # access. The default varies depending on the operating system, but
# will be <b>sys</b>, <b>system</b>, or <b>root</b> (checked for in that order).</p> # will be <b>sys</b>, <b>system</b>, or <b>root</b> (checked for in that order).</p>
# <p> # <p>
# <i>ex</i>: sys</p> # <i>ex</i>: lpadmin</p>
$$ $$
#SystemGroup sys #SystemGroup lpadmin
@@ @@
%%servercertificate %%servercertificate

@ -66,7 +66,7 @@ CupsdConf::CupsdConf()
<< "/usr/local/share/cups" << "/usr/local/share/cups"
<< "/opt/share/cups" << "/opt/share/cups"
<< "/opt/local/share/cups"); << "/opt/local/share/cups");
documentdir_ = findDir(QStringList(datadir_+"/doc") documentdir_ = findDir(QStringList(datadir_+"/doc-root")
<< datadir_.left(datadir_.length()-5)+"/doc/cups"); << datadir_.left(datadir_.length()-5)+"/doc/cups");
//fontpath_ << (datadir_+"/fonts"); //fontpath_ << (datadir_+"/fonts");
requestdir_ = findDir(QStringList("/var/spool/cups") requestdir_ = findDir(QStringList("/var/spool/cups")
@ -90,7 +90,7 @@ CupsdConf::CupsdConf()
printcap_ = "/etc/printcap"; printcap_ = "/etc/printcap";
printcapformat_ = PRINTCAP_BSD; printcapformat_ = PRINTCAP_BSD;
remoteroot_ = "remroot"; remoteroot_ = "remroot";
systemgroup_ = "sys"; systemgroup_ = "lpadmin";
encryptcert_ = serverfiles_+"/ssl/server.crt"; encryptcert_ = serverfiles_+"/ssl/server.crt";
encryptkey_ = serverfiles_+"/ssl/server.key"; encryptkey_ = serverfiles_+"/ssl/server.key";
hostnamelookup_ = HOSTNAME_OFF; hostnamelookup_ = HOSTNAME_OFF;
@ -115,7 +115,7 @@ CupsdConf::CupsdConf()
maxjobsperprinter_ = 0; maxjobsperprinter_ = 0;
maxjobsperuser_ = 0; maxjobsperuser_ = 0;
user_ = "lp"; user_ = "lp";
group_ = "sys"; group_ = "lpadmin";
ripcache_ = "8m"; ripcache_ = "8m";
filterlimit_ = 0; filterlimit_ = 0;
browsing_ = true; browsing_ = true;

@ -206,14 +206,9 @@ bool CupsdDialog::restartServer(QString& msg)
else else
{ {
bool success = false; bool success = false;
if (getuid() == 0 ) KProcess proc;
success = (::kill(serverPid, SIGHUP) == 0); proc << "kdesu" << "-c" << "/etc/init.d/cupsys restart";
else success = proc.start( KProcess::Block ) && proc.normalExit();
{
KProcess proc;
proc << "kdesu" << "-c" << "kill -SIGHUP " + QString::number( serverPid );
success = proc.start( KProcess::Block ) && proc.normalExit();
}
if( !success ) if( !success )
msg = i18n("Unable to restart CUPS server (pid = %1)").arg(serverPid); msg = i18n("Unable to restart CUPS server (pid = %1)").arg(serverPid);
} }

@ -95,7 +95,7 @@ KMCupsManager::~KMCupsManager()
QString KMCupsManager::driverDbCreationProgram() QString KMCupsManager::driverDbCreationProgram()
{ {
return QString::fromLatin1("make_driver_db_cups"); return QString::fromLatin1("/opt/kde3/bin/make_driver_db_cups");
} }
QString KMCupsManager::driverDirectory() QString KMCupsManager::driverDirectory()

@ -6,7 +6,7 @@ kde_module_LTLIBRARIES = kdeprint_ext.la
kdeprint_ext_la_SOURCES = kmextfactory.cpp kmextmanager.cpp kextprinterimpl.cpp kmextuimanager.cpp kdeprint_ext_la_SOURCES = kmextfactory.cpp kmextmanager.cpp kextprinterimpl.cpp kmextuimanager.cpp
kdeprint_ext_la_LDFLAGS = $(all_libraries) -module -avoid-version -no-undefined kdeprint_ext_la_LDFLAGS = $(all_libraries) -module -avoid-version -no-undefined
kdeprint_ext_la_LIBADD = $(top_builddir)/kdeprint/libkdeprint.la kdeprint_ext_la_LIBADD = $(LIB_KDEPRINT) $(LIB_QT) $(LIB_KDECORE)
kdeprint_ext_la_METASOURCES = AUTO kdeprint_ext_la_METASOURCES = AUTO
noinst_HEADERS = kmextmanager.h kextprinterimpl.h kmextuimanager.h noinst_HEADERS = kmextmanager.h kextprinterimpl.h kmextuimanager.h

@ -11,6 +11,15 @@
</filterarg> </filterarg>
<filterarg name="box" description="Border line width" format="-d%value" type="int" min="0" max="20" default="0" /> <filterarg name="box" description="Border line width" format="-d%value" type="int" min="0" max="20" default="0" />
<filterarg name="margin" description="Additional margin" format="-b%value" type="int" min="0" max="100" default="0" /> <filterarg name="margin" description="Additional margin" format="-b%value" type="int" min="0" max="100" default="0" />
<filterarg name="orientation" description="Orientation" format="%value" type="list" default="">
<value name="" description="Normal" />
<value name="-l" description="Landscape" />
<value name="-r" description="Seascape" />
</filterarg>
<filterarg name="layout" description="Layout" format="%value" type="list" default="">
<value name="" description="Row-Major" />
<value name="-c" description="Column-Major" />
</filterarg>
</filterargs> </filterargs>
<filterinput> <filterinput>
<filterarg name="file" format="%in" /> <filterarg name="file" format="%in" />

@ -403,7 +403,7 @@ bool KPrinter::printFiles(const QStringList& l, bool flag, bool startviewer)
} }
else else
{ {
if (/* !outputToFile() && */ startviewer) if (/* !outputToFile() && */ startviewer && !QFile::exists("/etc/xdg/autostart/system-config-printer-applet-kde.desktop") )
{ {
QStringList args; QStringList args;
args << "-d"; args << "-d";

@ -6,7 +6,7 @@ kde_module_LTLIBRARIES = kdeprint_lpdunix.la
kdeprint_lpdunix_la_SOURCES = kmlpdunixfactory.cpp kmlpdunixmanager.cpp klpdunixprinterimpl.cpp kmlpdunixuimanager.cpp kdeprint_lpdunix_la_SOURCES = kmlpdunixfactory.cpp kmlpdunixmanager.cpp klpdunixprinterimpl.cpp kmlpdunixuimanager.cpp
kdeprint_lpdunix_la_LDFLAGS = $(all_libraries) -module -avoid-version -no-undefined kdeprint_lpdunix_la_LDFLAGS = $(all_libraries) -module -avoid-version -no-undefined
kdeprint_lpdunix_la_LIBADD = $(top_builddir)/kdeprint/management/libkdeprint_management.la kdeprint_lpdunix_la_LIBADD = $(LIB_QT) $(LIB_KDECORE) $(LIB_KDEPRINT)
kdeprint_lpdunix_la_METASOURCES = AUTO kdeprint_lpdunix_la_METASOURCES = AUTO
noinst_HEADERS = kmlpdunixmanager.h klpdunixprinterimpl.h kmlpdunixuimanager.h noinst_HEADERS = kmlpdunixmanager.h klpdunixprinterimpl.h kmlpdunixuimanager.h

@ -13,7 +13,8 @@ kdeprint_lpr_la_SOURCES = printcapreader.cpp lprhandler.cpp \
lprngtoolhandler.cpp \ lprngtoolhandler.cpp \
editentrydialog.cpp editentrydialog.cpp
kdeprint_lpr_la_LDFLAGS = $(all_libraries) -module -avoid-version -no-undefined kdeprint_lpr_la_LDFLAGS = $(all_libraries) -module -avoid-version -no-undefined
kdeprint_lpr_la_LIBADD = $(top_builddir)/kdeprint/management/libkdeprint_management.la $(top_builddir)/kdecore/libkdefakes.la kdeprint_lpr_la_LIBADD = $(top_builddir)/kdeprint/management/libkdeprint_management.la \
$(LIB_QT) $(LIB_KDEPRINT) $(LIB_KDEUI) $(LIB_KDECORE)
kdeprint_lpr_la_METASOURCES = AUTO kdeprint_lpr_la_METASOURCES = AUTO
noinst_HEADERS = printcapreader.h \ noinst_HEADERS = printcapreader.h \

@ -8,7 +8,7 @@ kdeinit_LTLIBRARIES = kaddprinterwizard.la
bin_PROGRAMS = bin_PROGRAMS =
kaddprinterwizard_la_SOURCES = kaddprinterwizard.cpp kaddprinterwizard_la_SOURCES = kaddprinterwizard.cpp
kaddprinterwizard_la_LIBADD = libkdeprint_management.la kaddprinterwizard_la_LIBADD = $(LIB_QT) $(LIB_KDECORE) $(LIB_KDEPRINT) $(LIB_KDEUI)
kaddprinterwizard_la_LDFLAGS = -module -avoid-version $(all_libraries) $(KDE_RPATH) kaddprinterwizard_la_LDFLAGS = -module -avoid-version $(all_libraries) $(KDE_RPATH)
libkdeprint_management_la_SOURCES = \ libkdeprint_management_la_SOURCES = \
@ -26,12 +26,12 @@ libkdeprint_management_la_SOURCES = \
pluginaction.cpp kxmlcommanddlg.cpp kxmlcommandselector.cpp kmconfigcommand.cpp \ pluginaction.cpp kxmlcommanddlg.cpp kxmlcommandselector.cpp kmconfigcommand.cpp \
kmconfigfilter.cpp kmconfigfonts.cpp kmconfigjobs.cpp networkscanner.cpp kmconfigfilter.cpp kmconfigfonts.cpp kmconfigjobs.cpp networkscanner.cpp
libkdeprint_management_la_LDFLAGS = $(all_libraries) -version-info 6:0:2 -no-undefined libkdeprint_management_la_LDFLAGS = $(all_libraries) -version-info 6:0:2 -no-undefined
libkdeprint_management_la_LIBADD = ../libkdeprint.la libkdeprint_management_la_LIBADD = ../libkdeprint.la $(LIB_QT) $(LIB_KDECORE) $(LIB_KDEUI) $(LIB_KFILE)
libkdeprint_management_la_METASOURCES = AUTO libkdeprint_management_la_METASOURCES = AUTO
libkdeprint_management_module_la_SOURCES = kdeprint_management_module.cpp libkdeprint_management_module_la_SOURCES = kdeprint_management_module.cpp
libkdeprint_management_module_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN) -no-undefined libkdeprint_management_module_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN) -no-undefined
libkdeprint_management_module_la_LIBADD = libkdeprint_management.la libkdeprint_management_module_la_LIBADD = libkdeprint_management.la $(LIB_QT) $(LIB_KDEUI) $(LIB_KDECORE)
kdeprint_HEADERS = kmmainview.h kmjobviewer.h kmprinterpage.h kiconselectaction.h kmtimer.h kdeprint_HEADERS = kmmainview.h kmjobviewer.h kmprinterpage.h kiconselectaction.h kmtimer.h
kdeprintdir = $(includedir)/kdeprint kdeprintdir = $(includedir)/kdeprint

@ -209,6 +209,7 @@ void KMMainView::initActions()
new KAction(i18n("R&estart Server"),"kdeprint_restartsrv",0,this,SLOT(slotServerRestart()),m_actions,"server_restart"); new KAction(i18n("R&estart Server"),"kdeprint_restartsrv",0,this,SLOT(slotServerRestart()),m_actions,"server_restart");
new KAction(i18n("Configure &Server..."),"kdeprint_configsrv",0,this,SLOT(slotServerConfigure()),m_actions,"server_configure"); new KAction(i18n("Configure &Server..."),"kdeprint_configsrv",0,this,SLOT(slotServerConfigure()),m_actions,"server_configure");
new KAction(i18n("Configure Server Access..."),"kdeprint_configsrv",0,this,SLOT(slotServerAccessConfigure()),m_actions,"server_access_configure");
KToggleAction *tact = new KToggleAction(i18n("Show &Toolbar"),0,m_actions,"view_toolbar"); KToggleAction *tact = new KToggleAction(i18n("Show &Toolbar"),0,m_actions,"view_toolbar");
tact->setCheckedState(i18n("Hide &Toolbar")); tact->setCheckedState(i18n("Hide &Toolbar"));
@ -691,6 +692,13 @@ void KMMainView::slotServerConfigure()
} }
} }
void KMMainView::slotServerConfigureAccess()
{
KProcess *proc = new KProcess;
*proc << "/usr/bin/system-config-printer-kde";
proc->start(KProcess::DontCare);
}
void KMMainView::slotToggleToolBar(bool on) void KMMainView::slotToggleToolBar(bool on)
{ {
if (on) m_toolbar->show(); if (on) m_toolbar->show();

@ -78,6 +78,7 @@ public slots:
void slotTest(); void slotTest();
void slotServerRestart(); void slotServerRestart();
void slotServerConfigure(); void slotServerConfigure();
void slotServerConfigureAccess();
void slotManagerConfigure(); void slotManagerConfigure();
void slotAddSpecial(); void slotAddSpecial();
void slotRefresh(); void slotRefresh();

@ -179,11 +179,8 @@ void SmbView::setOpen(QListViewItem *item, bool on)
m_current = item; m_current = item;
*m_proc << "nmblookup"+m_wins_server+"-M "; *m_proc << "nmblookup"+m_wins_server+"-M ";
*m_proc << KProcess::quote(item->text(0)); *m_proc << KProcess::quote(item->text(0));
*m_proc << " -S | grep '<20>' | sed -e 's/^[[:space:]]*//' -e 's/[[:space:]]*<20>.*//' | xargs -Iserv_name smbclient -N -L 'serv_name' -W "; *m_proc << " -S";
*m_proc << KProcess::quote(item->text(0)); startProcess(ServerListing);
*m_proc << " -A ";
*m_proc << KProcess::quote(m_passwdFile->name());
startProcess(ServerListing);
} }
else if (item->depth() == 1) else if (item->depth() == 1)
{ // opening server { // opening server
@ -192,8 +189,11 @@ void SmbView::setOpen(QListViewItem *item, bool on)
*m_proc << KProcess::quote(item->text(0)); *m_proc << KProcess::quote(item->text(0));
*m_proc << " -W "; *m_proc << " -W ";
*m_proc << KProcess::quote(item->parent()->text(0)); *m_proc << KProcess::quote(item->parent()->text(0));
*m_proc << " -A "; if (m_login != QString::null)
*m_proc << KProcess::quote(m_passwdFile->name()); {
*m_proc << " -A ";
*m_proc << KProcess::quote(m_passwdFile->name());
}
startProcess(ShareListing); startProcess(ShareListing);
} }
} }
@ -220,16 +220,14 @@ void SmbView::processServers()
QStringList lines = QStringList::split('\n',m_buffer,true); QStringList lines = QStringList::split('\n',m_buffer,true);
QString line; QString line;
uint index(0); uint index(0);
for (;index < lines.count();index++)
if (lines[index].stripWhiteSpace().startsWith("Server"))
break;
index += 2;
while (index < lines.count()) while (index < lines.count())
{ {
line = lines[index++].stripWhiteSpace(); line = lines[index++].stripWhiteSpace();
if (line.isEmpty()) if (line.isEmpty())
break; break;
QStringList words = QStringList::split(' ',line,false); QStringList words = QStringList::split(' ',line,false);
if (words[1] != "<00>" || words[3] == "<GROUP>")
continue;
QListViewItem *item = new QListViewItem(m_current,words[0]); QListViewItem *item = new QListViewItem(m_current,words[0]);
item->setExpandable(true); item->setExpandable(true);
item->setPixmap(0,SmallIcon("kdeprint_computer")); item->setPixmap(0,SmallIcon("kdeprint_computer"));

@ -7,7 +7,7 @@ kde_module_LTLIBRARIES = kdeprint_rlpr.la
kdeprint_rlpr_la_SOURCES = kmrlprfactory.cpp kmrlprmanager.cpp krlprprinterimpl.cpp kmrlpruimanager.cpp \ kdeprint_rlpr_la_SOURCES = kmrlprfactory.cpp kmrlprmanager.cpp krlprprinterimpl.cpp kmrlpruimanager.cpp \
kmwrlpr.cpp kmproprlpr.cpp kmproxywidget.cpp kmconfigproxy.cpp kmwrlpr.cpp kmproprlpr.cpp kmproxywidget.cpp kmconfigproxy.cpp
kdeprint_rlpr_la_LDFLAGS = $(all_libraries) -module -avoid-version -no-undefined kdeprint_rlpr_la_LDFLAGS = $(all_libraries) -module -avoid-version -no-undefined
kdeprint_rlpr_la_LIBADD = $(top_builddir)/kdeprint/management/libkdeprint_management.la kdeprint_rlpr_la_LIBADD = $(top_builddir)/kdeprint/management/libkdeprint_management.la $(LIB_QT) $(LIB_KDEPRINT) $(LIB_KDECORE) $(LIB_KDEUI)
kdeprint_rlpr_la_METASOURCES = AUTO kdeprint_rlpr_la_METASOURCES = AUTO
noinst_HEADERS = kmrlprmanager.h krlprprinterimpl.h kmrlpruimanager.h kmwrlpr.h kmproprlpr.h \ noinst_HEADERS = kmrlprmanager.h krlprprinterimpl.h kmrlpruimanager.h kmwrlpr.h kmproprlpr.h \

@ -4,7 +4,7 @@ kde_module_LTLIBRARIES = kdeprint_tool_escputil.la
kdeprint_tool_escputil_la_SOURCES = escpwidget.cpp kdeprint_tool_escputil_la_SOURCES = escpwidget.cpp
kdeprint_tool_escputil_la_METASOURCES = AUTO kdeprint_tool_escputil_la_METASOURCES = AUTO
kdeprint_tool_escputil_la_LDFLAGS = $(all_libraries) -module -avoid-version -no-undefined kdeprint_tool_escputil_la_LDFLAGS = $(all_libraries) -module -avoid-version -no-undefined
kdeprint_tool_escputil_la_LIBADD = $(LIB_KDEUI) kdeprint_tool_escputil_la_LIBADD = $(LIB_KDEUI) $(LIB_QT) $(LIB_KDECORE)
noinst_HEADERS = escpwidget.h noinst_HEADERS = escpwidget.h

@ -5,7 +5,7 @@ INCLUDES = -I$(top_srcdir)/kio/ $(all_includes)
lib_LTLIBRARIES = libkdesu.la lib_LTLIBRARIES = libkdesu.la
libkdesu_la_SOURCES = client.cpp process.cpp kcookie.cpp su.cpp ssh.cpp stub.cpp kdesu_pty.cpp libkdesu_la_SOURCES = client.cpp process.cpp kcookie.cpp su.cpp ssh.cpp stub.cpp kdesu_pty.cpp
libkdesu_la_LDFLAGS = -version-info 6:0:2 -no-undefined $(all_libraries) libkdesu_la_LDFLAGS = -version-info 6:0:2 -no-undefined $(all_libraries)
libkdesu_la_LIBADD = $(LIB_KDECORE) $(LIBUTIL) libkdesu_la_LIBADD = $(LIB_KDECORE) $(LIB_QT) $(top_builddir)/dcop/libDCOP.la
libkdesu_la_NMCHECK = $(srcdir)/libkdesu.nmcheck libkdesu_la_NMCHECK = $(srcdir)/libkdesu.nmcheck
libkdesu_la_NMCHECKWEAK = $(srcdir)/libkdesu_weak.nmcheck $(top_srcdir)/kdecore/libkdecore_weak.nmcheck \ libkdesu_la_NMCHECKWEAK = $(srcdir)/libkdesu_weak.nmcheck $(top_srcdir)/kdecore/libkdecore_weak.nmcheck \
$(top_srcdir)/dcop/libDCOP_weak.nmcheck $(top_srcdir)/kdecore/libqt-mt_weak.nmcheck $(top_srcdir)/dcop/libDCOP_weak.nmcheck $(top_srcdir)/kdecore/libqt-mt_weak.nmcheck
@ -24,7 +24,7 @@ uninstall-local:
bin_PROGRAMS = kdesu_stub bin_PROGRAMS = kdesu_stub
kdesu_stub_SOURCES = kdesu_stub.c kdesu_stub_SOURCES = kdesu_stub.c
kdesu_stub_LDFLAGS = $(all_libraries) kdesu_stub_LDFLAGS = $(all_libraries)
kdesu_stub_LDADD = ../kdecore/libkdefakes.la kdesu_stub_LDADD =
include $(top_srcdir)/admin/Doxyfile.am include $(top_srcdir)/admin/Doxyfile.am

@ -18,7 +18,8 @@
# the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, # the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
# Boston, MA 02110-1301, USA. # Boston, MA 02110-1301, USA.
SUBDIRS = . kdetrayproxy tests about SUBDIRS = . tests about
DIST_SUBDIRS = kdetrayproxy
INCLUDES= -I$(top_srcdir)/kdefx -I$(top_srcdir)/interfaces $(all_includes) INCLUDES= -I$(top_srcdir)/kdefx -I$(top_srcdir)/interfaces $(all_includes)
@ -28,10 +29,9 @@ AM_LDFLAGS = $(LDFLAGS_AS_NEEDED) $(LDFLAGS_NEW_DTAGS)
lib_LTLIBRARIES = libkdeui.la libkspell.la lib_LTLIBRARIES = libkdeui.la libkspell.la
libkdeui_la_LDFLAGS = $(KDE_MT_LDFLAGS) -no-undefined -version-info 6:0:2 libkdeui_la_LDFLAGS = $(KDE_MT_LDFLAGS) -no-undefined -version-info 6:0:2
libkdeui_la_LIBADD = ../kdecore/libkdecore.la libkdeui_la_LIBADD = ../kdecore/libkdecore.la $(LIB_QT) $(top_builddir)/dcop/libDCOP.la $(LIB_X11) $(top_builddir)/kdefx/libkdefx.la $(LIB_XEXT)
libkspell_la_LDFLAGS = $(KDE_MT_LDFLAGS) -version-info 6:0:2 -no-undefined libkspell_la_LDFLAGS = $(KDE_MT_LDFLAGS) -version-info 6:0:2 -no-undefined
libkspell_la_LIBADD = libkdeui.la
libkspell_la_SOURCES = dummy.cpp libkspell_la_SOURCES = dummy.cpp
picsdir = $(kde_datadir)/kdeui/pics picsdir = $(kde_datadir)/kdeui/pics

@ -113,8 +113,8 @@ void KAboutApplication::buildDialog( const KAboutData *aboutData )
KActiveLabel* activeLabel = new KActiveLabel( authorPage ); KActiveLabel* activeLabel = new KActiveLabel( authorPage );
if (!aboutData->customAuthorTextEnabled()) if (!aboutData->customAuthorTextEnabled())
{ {
if ( aboutData->bugAddress().isEmpty() || aboutData->bugAddress() == "submit@bugs.kde.org") if ( aboutData->bugAddress().isEmpty() || aboutData->bugAddress() == "submit@bugs.pearsoncomputing.net")
text = i18n( "Please use <a href=\"http://bugs.kde.org\">http://bugs.kde.org</a> to report bugs.\n" ); text = i18n( "Please use <a href=\"http://bugs.pearsoncomputing.net\">http://bugs.pearsoncomputing.net</a> to report bugs.\n" );
else { else {
if( aboutData->authors().count() == 1 && ( aboutData->authors().first().emailAddress() == aboutData->bugAddress() ) ) if( aboutData->authors().count() == 1 && ( aboutData->authors().first().emailAddress() == aboutData->bugAddress() ) )
{ {

@ -32,20 +32,22 @@ KAboutKDE::KAboutKDE( QWidget *parent, const char *name, bool modal )
parent, name, modal ) parent, name, modal )
{ {
const QString text1 = i18n("" const QString text1 = i18n(""
"The <b>K Desktop Environment</b> is written and maintained by the " "The <b>Trinity Desktop Environment</b> is a fork of the "
"KDE Team, a world-wide network of software engineers committed to " "K Desktop Environment version 3.5, which was originally written by the KDE Team, "
"<a href=\"http://www.gnu.org/philosophy/free-sw.html\">Free Software</a> development.<br><br>" "a world-wide network of software engineers committed to <a "
"No single group, company or organization controls the KDE source " "href=\"http://www.gnu.org/philosophy/free-sw.html\">Free Software</a> "
"code. Everyone is welcome to contribute to KDE.<br><br>" "development.<br><br>No single group, company or organization controls the "
"Visit <A HREF=\"http://www.kde.org/\">http://www.kde.org</A> for " "Trinity source code. Everyone is welcome to contribute to Trinity.<br><br>Visit <A "
"more information on the KDE project. "); "HREF=\"http://trinity.pearsoncomputing.net/\">http://trinity.pearsoncomputing.net</A> for more information "
"about Trinity, and <A HREF=\"http://www.kde.org/\">http://www.kde.org</A> "
"for more information on the KDE project. ");
const QString text2 = i18n("" const QString text2 = i18n(""
"Software can always be improved, and the KDE Team is ready to " "Software can always be improved, and the Trinity Team is ready to "
"do so. However, you - the user - must tell us when " "do so. However, you - the user - must tell us when "
"something does not work as expected or could be done better.<br><br>" "something does not work as expected or could be done better.<br><br>"
"The K Desktop Environment has a bug tracking system. Visit " "The Trinity Desktop Environment has a bug tracking system. Visit "
"<A HREF=\"http://bugs.kde.org/\">http://bugs.kde.org</A> or " "<A HREF=\"http://bugs.pearsoncomputing.net/\">http://bugs.pearsoncomputing.net</A> or "
"use the \"Report Bug...\" dialog from the \"Help\" menu to report bugs.<br><br>" "use the \"Report Bug...\" dialog from the \"Help\" menu to report bugs.<br><br>"
"If you have a suggestion for improvement then you are welcome to use " "If you have a suggestion for improvement then you are welcome to use "
"the bug tracking system to register your wish. Make sure you use the " "the bug tracking system to register your wish. Make sure you use the "
@ -53,37 +55,33 @@ KAboutKDE::KAboutKDE( QWidget *parent, const char *name, bool modal )
const QString text3 = i18n("" const QString text3 = i18n(""
"You do not have to be a software developer to be a member of the " "You do not have to be a software developer to be a member of the "
"KDE team. You can join the national teams that translate " "Trinity team. You can join the national teams that translate "
"program interfaces. You can provide graphics, themes, sounds, and " "program interfaces. You can provide graphics, themes, sounds, and "
"improved documentation. You decide!" "improved documentation. You decide!"
"<br><br>" "<br><br>"
"Visit " "Visit "
"<A HREF=\"http://www.kde.org/jobs/\">http://www.kde.org/jobs/</A> " "<A HREF=\"http://trinity.pearsoncomputing.net/jobs/\">http://trinity.pearsoncomputing.net/jobs/</A> "
"for information on some projects in which you can participate." "for information on some projects in which you can participate."
"<br><br>" "<br><br>"
"If you need more information or documentation, then a visit to " "If you need more information or documentation, then a visit to "
"<A HREF=\"http://developer.kde.org/\">http://developer.kde.org</A> " "<A HREF=\"http://trinity.pearsoncomputing.net/docs/\">http://trinity.pearsoncomputing.net/docs/</A> "
"will provide you with what you need."); "will provide you with what you need.");
const QString text4 = i18n("" const QString text4 = i18n(""
"KDE is available free of charge, but making it is not free.<br><br>" "Trinity is available free of charge, but making it is not free.<br><br>"
"Thus, the KDE team formed the KDE e.V., a non-profit organization" "<br><br>"
" legally founded in Tuebingen, Germany. The KDE e.V. represents" "The Trinity team does need financial support. Most of the money is used to "
" the KDE project in legal and financial matters."
" See <a href=\"http://www.kde-ev.org/\">http://www.kde-ev.org</a>"
" for information on the KDE e.V.<br><br>"
"The KDE team does need financial support. Most of the money is used to "
"reimburse members and others on expenses they experienced when " "reimburse members and others on expenses they experienced when "
"contributing to KDE. You are encouraged to support KDE through a financial " "contributing to Trinity. You are encouraged to support Trinity through a financial "
"donation, using one of the ways described at " "donation, using one of the ways described at "
"<a href=\"http://www.kde.org/support/\">http://www.kde.org/support/</a>." "<a href=\"http://trinity.pearsoncomputing.net/support/\">http://trinity.pearsoncomputing.net/support/</a>."
"<br><br>Thank you very much in advance for your support."); "<br><br>Thank you very much in advance for your support!");
setHelp( QString::fromLatin1("khelpcenter/main.html"), QString::null ); setHelp( QString::fromLatin1("khelpcenter/main.html"), QString::null );
setTitle(i18n("K Desktop Environment. Release %1"). setTitle(i18n("Trinity Desktop Environment. Release %1").
arg(QString::fromLatin1(KDE_VERSION_STRING)) ); arg(QString::fromLatin1(KDE_VERSION_STRING)) );
addTextPage( i18n("About KDE","&About"), text1, true ); addTextPage( i18n("About Trinity","&About"), text1, true );
addTextPage( i18n("&Report Bugs or Wishes"), text2, true ); addTextPage( i18n("&Report Bugs or Wishes"), text2, true );
addTextPage( i18n("&Join the KDE Team"), text3, true ); addTextPage( i18n("&Join the Trinity Team"), text3, true );
addTextPage( i18n("&Support KDE"), text4, true ); addTextPage( i18n("&Support Trinity"), text4, true );
setImage( locate( "data", QString::fromLatin1("kdeui/pics/aboutkde.png")) ); setImage( locate( "data", QString::fromLatin1("kdeui/pics/aboutkde.png")) );
setImageBackgroundColor( white ); setImageBackgroundColor( white );
} }

@ -88,12 +88,13 @@ KBugReport::KBugReport( QWidget * parentw, bool modal, const KAboutData *aboutDa
QWidget * parent = plainPage(); QWidget * parent = plainPage();
d->submitBugButton = 0; d->submitBugButton = 0;
if ( m_aboutData->bugAddress() == QString::fromLatin1("submit@bugs.kde.org") ) //if ( m_aboutData->bugAddress() == QString::fromLatin1("submit@bugs.pearsoncomputing.net") )
{ //{
// This is a core KDE application -> redirect to the web form // // This is a core KDE application -> redirect to the web form
// Always redirect to the Web form for Trinity
d->submitBugButton = new QPushButton( parent ); d->submitBugButton = new QPushButton( parent );
setButtonCancel( KStdGuiItem::close() ); setButtonCancel( KStdGuiItem::close() );
} //}
QLabel * tmpLabel; QLabel * tmpLabel;
QVBoxLayout * lay = new QVBoxLayout( parent, 0, spacingHint() ); QVBoxLayout * lay = new QVBoxLayout( parent, 0, spacingHint() );
@ -250,7 +251,7 @@ KBugReport::KBugReport( QWidget * parentw, bool modal, const KAboutData *aboutDa
lay->addSpacing(10); lay->addSpacing(10);
QString text = i18n("To submit a bug report, click on the button below.\n" QString text = i18n("To submit a bug report, click on the button below.\n"
"This will open a web browser window on http://bugs.kde.org where you will find a form to fill in.\n" "This will open a web browser window on http://bugs.pearsoncomputing.net where you will find a form to fill in.\n"
"The information displayed above will be transferred to that server."); "The information displayed above will be transferred to that server.");
QLabel * label = new QLabel( text, parent, "label"); QLabel * label = new QLabel( text, parent, "label");
lay->addWidget( label ); lay->addWidget( label );
@ -274,13 +275,14 @@ KBugReport::~KBugReport()
void KBugReport::updateURL() void KBugReport::updateURL()
{ {
KURL url ( "http://bugs.kde.org/wizard.cgi" ); KURL url ( "http://bugs.pearsoncomputing.net/enter_bug.cgi" );
url.addQueryItem( "os", d->os ); url.addQueryItem( "product", "KDE 3.5" );
url.addQueryItem( "compiler", KDE_COMPILER_VERSION ); url.addQueryItem( "op_sys", d->os );
url.addQueryItem( "kdeVersion", d->kde_version ); url.addQueryItem( "cf_kde_compiler", KDE_COMPILER_VERSION );
url.addQueryItem( "appVersion", m_strVersion ); url.addQueryItem( "cf_kde_version", d->kde_version );
url.addQueryItem( "package", d->appcombo->currentText() ); url.addQueryItem( "cf_kde_appversion", m_strVersion );
url.addQueryItem( "kbugreport", "1" ); url.addQueryItem( "cf_kde_package", d->appcombo->currentText() );
url.addQueryItem( "cf_kde_kbugreport", "1" );
d->url = url; d->url = url;
} }
@ -408,7 +410,7 @@ void KBugReport::slotOk( void )
{ {
QString msg = i18n("Unable to send the bug report.\n" QString msg = i18n("Unable to send the bug report.\n"
"Please submit a bug report manually...\n" "Please submit a bug report manually...\n"
"See http://bugs.kde.org/ for instructions."); "See http://bugs.pearsoncomputing.net/ for instructions.");
KMessageBox::error(this, msg + "\n\n" + d->lastError); KMessageBox::error(this, msg + "\n\n" + d->lastError);
return; return;
} }
@ -476,7 +478,7 @@ bool KBugReport::sendBugReport()
{ {
QString recipient ( m_aboutData ? QString recipient ( m_aboutData ?
m_aboutData->bugAddress() : m_aboutData->bugAddress() :
QString::fromLatin1("submit@bugs.kde.org") ); QString::fromLatin1("submit@bugs.pearsoncomputing.net") );
QString command; QString command;
command = locate("exe", "ksendbugmail"); command = locate("exe", "ksendbugmail");

@ -66,7 +66,7 @@ protected slots:
*/ */
virtual void slotSetFrom(); virtual void slotSetFrom();
/** /**
* The URL-Label "http://bugs.kde.org/" was clicked. * The URL-Label "http://bugs.pearsoncomputing.net/" was clicked.
* @deprecated remove in KDE4.0 * @deprecated remove in KDE4.0
*/ */
virtual void slotUrlClicked(const QString &); virtual void slotUrlClicked(const QString &);

@ -3,7 +3,7 @@ kde_module_LTLIBRARIES = kded_kdetrayproxy.la
INCLUDES= -I$(top_srcdir)/kded $(all_includes) INCLUDES= -I$(top_srcdir)/kded $(all_includes)
kded_kdetrayproxy_la_SOURCES = kdetrayproxy.cpp module.cpp module.skel kded_kdetrayproxy_la_SOURCES = kdetrayproxy.cpp module.cpp module.skel
kded_kdetrayproxy_la_LDFLAGS = $(all_libraries) -module -avoid-version kded_kdetrayproxy_la_LDFLAGS = $(all_libraries) -module -avoid-version
kded_kdetrayproxy_la_LIBADD = $(LIB_KDECORE) $(LIB_KDED) kded_kdetrayproxy_la_LIBADD = $(LIB_KDECORE) $(LIB_KDED) $(LIB_QT) $(top_builddir)/dcop/libDCOP.la $(LIB_X11) $(top_builddir)/kded/libkdeinit_kded.la
METASOURCES = AUTO METASOURCES = AUTO

@ -173,7 +173,7 @@ KPopupMenu* KHelpMenu::menu()
if (kapp->authorizeKAction("help_about_kde")) if (kapp->authorizeKAction("help_about_kde"))
{ {
mMenu->insertItem( SmallIcon("about_kde"), i18n( "About &KDE" ), menuAboutKDE ); mMenu->insertItem( SmallIcon("about_kde"), i18n( "About &Trinity" ), menuAboutKDE );
mMenu->connectItem( menuAboutKDE, this, SLOT( aboutKDE() ) ); mMenu->connectItem( menuAboutKDE, this, SLOT( aboutKDE() ) );
} }
} }

@ -548,7 +548,7 @@ void KIconViewItem::calcRect( const QString& text_ )
r = m_wordWrap->boundingRect(); r = m_wordWrap->boundingRect();
int realWidth = QMAX( QMIN( r.width() + 4, tw ), fm->width( "X" ) ); int realWidth = QMAX( QMIN( r.width() + 4, tw ), fm->width( "X" ) );
itemTextRect.setWidth( realWidth ); itemTextRect.setWidth( realWidth + 2);
itemTextRect.setHeight( r.height() ); itemTextRect.setHeight( r.height() );
int w = 0; int h = 0; int y = 0; int w = 0; int h = 0; int y = 0;
@ -699,11 +699,13 @@ void KIconViewItem::paintPixmap( QPainter *p, const QColorGroup &cg )
void KIconViewItem::paintText( QPainter *p, const QColorGroup &cg ) void KIconViewItem::paintText( QPainter *p, const QColorGroup &cg )
{ {
int textX = textRect( false ).x() + 2; int textX = textRect( false ).x() + 4;
int textY = textRect( false ).y(); int textY = textRect( false ).y();
if ( isSelected() ) { if ( isSelected() ) {
p->fillRect( textRect( false ), cg.highlight() ); p->setBrush(QBrush(cg.highlight()));
p->setPen(QPen(cg.highlight()));
p->drawRoundRect( textRect( false ) ,1000/textRect(false).width(),1000/textRect(false).height() );
p->setPen( QPen( cg.highlightedText() ) ); p->setPen( QPen( cg.highlightedText() ) );
} else { } else {
if ( iconView()->itemTextBackground() != NoBrush ) if ( iconView()->itemTextBackground() != NoBrush )

@ -111,7 +111,7 @@ static const KStdActionInfo g_rgActionInfo[] =
{ ReportBug, KStdAccel::AccelNone, "help_report_bug", I18N_NOOP("&Report Bug..."), 0, 0 }, { ReportBug, KStdAccel::AccelNone, "help_report_bug", I18N_NOOP("&Report Bug..."), 0, 0 },
{ SwitchApplicationLanguage, KStdAccel::AccelNone, "switch_application_language", I18N_NOOP("Switch application &language..."), 0, 0 }, { SwitchApplicationLanguage, KStdAccel::AccelNone, "switch_application_language", I18N_NOOP("Switch application &language..."), 0, 0 },
{ AboutApp, KStdAccel::AccelNone, "help_about_app", I18N_NOOP("&About %1"), 0, 0 }, { AboutApp, KStdAccel::AccelNone, "help_about_app", I18N_NOOP("&About %1"), 0, 0 },
{ AboutKDE, KStdAccel::AccelNone, "help_about_kde", I18N_NOOP("About &KDE"), 0,"about_kde" }, { AboutKDE, KStdAccel::AccelNone, "help_about_kde", I18N_NOOP("About &Trinity"), 0,"about_kde" },
{ ActionNone, KStdAccel::AccelNone, 0, 0, 0, 0 } { ActionNone, KStdAccel::AccelNone, 0, 0, 0, 0 }
}; };

@ -56,6 +56,8 @@ KTabWidget::KTabWidget( QWidget *parent, const char *name, WFlags f )
setTabBar( new KTabBar(this, "tabbar") ); setTabBar( new KTabBar(this, "tabbar") );
setAcceptDrops( true ); setAcceptDrops( true );
setHoverCloseButtonDelayed(false);
connect(tabBar(), SIGNAL(contextMenu( int, const QPoint & )), SLOT(contextMenu( int, const QPoint & ))); connect(tabBar(), SIGNAL(contextMenu( int, const QPoint & )), SLOT(contextMenu( int, const QPoint & )));
connect(tabBar(), SIGNAL(mouseDoubleClick( int )), SLOT(mouseDoubleClick( int ))); connect(tabBar(), SIGNAL(mouseDoubleClick( int )), SLOT(mouseDoubleClick( int )));
connect(tabBar(), SIGNAL(mouseMiddleClick( int )), SLOT(mouseMiddleClick( int ))); connect(tabBar(), SIGNAL(mouseMiddleClick( int )), SLOT(mouseMiddleClick( int )));

@ -30,7 +30,7 @@ makekdewidgets_LDADD = $(LIB_QT) ../kdecore/libkdecore.la
kde_widget_LTLIBRARIES = kdewidgets.la kde_widget_LTLIBRARIES = kdewidgets.la
kdewidgets_la_LDFLAGS = $(KDE_PLUGIN) -module $(all_libraries) kdewidgets_la_LDFLAGS = $(KDE_PLUGIN) -module $(all_libraries)
kdewidgets_la_LIBADD = $(LIB_KIO) $(LIB_KABC) kdewidgets_la_LIBADD = $(LIB_KIO) $(LIB_KABC) $(LIB_QT) $(LIB_KDEUI) $(LIB_KDECORE)
kdewidgets_la_SOURCES = classpreviews.cpp kdewidgets.cpp kdewidgets_la_SOURCES = classpreviews.cpp kdewidgets.cpp
kdewidgets.cpp: $(srcdir)/kde.widgets makekdewidgets kdewidgets.cpp: $(srcdir)/kde.widgets makekdewidgets

@ -5,18 +5,17 @@ AM_LDFLAGS = $(KDE_RPATH) $(LIBXML_RPATH) $(LIBXSLT_RPATH) $(all_libraries)
noinst_LTLIBRARIES = libkbzipfilter_dummy.la noinst_LTLIBRARIES = libkbzipfilter_dummy.la
libkbzipfilter_dummy_la_SOURCES = kbzip2filter.cpp libkbzipfilter_dummy_la_SOURCES = kbzip2filter.cpp
libkbzipfilter_dummy_la_LIBADD = $(LIB_KIO) $(LIBBZ2)
####### Files ####### Files
kde_module_LTLIBRARIES = kio_help.la kio_ghelp.la kde_module_LTLIBRARIES = kio_help.la kio_ghelp.la
kio_help_la_SOURCES = kio_help.cpp main.cpp xslt.cpp kio_help_la_SOURCES = kio_help.cpp main.cpp xslt.cpp
kio_help_la_LIBADD = $(LIBXSLT_LIBS) $(LIBXML_LIBS) libkbzipfilter_dummy.la kio_help_la_LIBADD = $(LIBXSLT_LIBS) $(LIBXML_LIBS) libkbzipfilter_dummy.la $(LIB_KIO) $(LIBBZ2) $(LIB_QT) $(LIB_KDECORE)
kio_help_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN) kio_help_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN)
kio_ghelp_la_SOURCES = kio_help.cpp main_ghelp.cpp xslt.cpp kio_ghelp_la_SOURCES = kio_help.cpp main_ghelp.cpp xslt.cpp
kio_ghelp_la_LIBADD = $(LIBXSLT_LIBS) $(LIBXML_LIBS) libkbzipfilter_dummy.la kio_ghelp_la_LIBADD = $(LIBXSLT_LIBS) $(LIBXML_LIBS) libkbzipfilter_dummy.la $(LIB_KIO) $(LIBBZ2) $(LIB_QT) $(LIB_KDECORE)
kio_ghelp_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN) kio_ghelp_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN)
noinst_HEADERS = kio_help.h noinst_HEADERS = kio_help.h
@ -25,7 +24,7 @@ kdelnk_DATA = help.protocol ghelp.protocol
kdelnkdir = $(kde_servicesdir) kdelnkdir = $(kde_servicesdir)
bin_PROGRAMS = meinproc bin_PROGRAMS = meinproc
meinproc_LDADD = xslt_pure.o libkbzipfilter_dummy.la $(LIBXSLT_LIBS) $(LIBXML_LIBS) meinproc_LDADD = xslt_pure.o libkbzipfilter_dummy.la $(LIBXSLT_LIBS) $(LIBXML_LIBS) $(LIB_KIO) $(LIBBZ2) $(LIB_KDECORE)
meinproc_SOURCES = meinproc.cpp meinproc_SOURCES = meinproc.cpp
xslt_pure.o: xslt.cpp xslt_pure.o: xslt.cpp

@ -136,9 +136,18 @@ int main(int argc, char **argv) {
} }
if ( args->isSet( "check" ) ) { if ( args->isSet( "check" ) ) {
#if !defined(PATH_MAX) && defined(__GLIBC__)
char *pwd_buffer;
#else
char pwd_buffer[PATH_MAX]; char pwd_buffer[PATH_MAX];
#endif
QFileInfo file( QFile::decodeName(args->arg( 0 )) ); QFileInfo file( QFile::decodeName(args->arg( 0 )) );
if ( !getcwd( pwd_buffer, sizeof(pwd_buffer) - 1 ) ) { #if !defined(PATH_MAX) && defined(__GLIBC__)
if ( !(pwd_buffer = getcwd( NULL, 0 ) ) )
#else
if ( !getcwd( pwd_buffer, sizeof(pwd_buffer) - 1 ) )
#endif
{
kdError() << "getcwd failed." << endl; kdError() << "getcwd failed." << endl;
return 2; return 2;
} }
@ -175,11 +184,18 @@ int main(int argc, char **argv) {
} }
pclose( xmllint ); pclose( xmllint );
chdir( pwd_buffer ); chdir( pwd_buffer );
if ( !noout ) if ( !noout ) {
#if !defined(PATH_MAX) && defined(__GLIBC__)
free( pwd_buffer );
#endif
return 1; return 1;
}
} else { } else {
kdWarning() << "couldn't find xmllint" << endl; kdWarning() << "couldn't find xmllint" << endl;
} }
#if !defined(PATH_MAX) && defined(__GLIBC__)
free( pwd_buffer );
#endif
} }
xmlSubstituteEntitiesDefault(1); xmlSubstituteEntitiesDefault(1);

@ -57,7 +57,7 @@ libkhtml_la_LIBADD = ./xml/libkhtmlxml.la ./html/libkhtmlhtml.la \
$(LIBTHAI) \ $(LIBTHAI) \
$(top_builddir)/kdeprint/libkdeprint.la \ $(top_builddir)/kdeprint/libkdeprint.la \
$(top_builddir)/kutils/libkutils.la \ $(top_builddir)/kutils/libkutils.la \
$(top_builddir)/kwallet/client/libkwalletclient.la $(top_builddir)/kwallet/client/libkwalletclient.la $(top_builddir)/kjs/libkjs.la $(LIB_KDEUI) $(LIB_QT) $(LIB_KDECORE) $(LIB_KFILE) $(top_builddir)/dcop/libDCOP.la $(LIBJPEG) $(LIB_X11)
# init_libkhtml is in libkhtml.so; init_libkhtmlpart needs to be in the part # init_libkhtml is in libkhtml.so; init_libkhtmlpart needs to be in the part
dummy.cpp: $(srcdir)/Makefile.am dummy.cpp: $(srcdir)/Makefile.am

@ -565,6 +565,13 @@ DocumentFragment HTMLElementImpl::createContextualFragment( const DOMString &htm
void HTMLElementImpl::setInnerHTML( const DOMString &html, int &exceptioncode ) void HTMLElementImpl::setInnerHTML( const DOMString &html, int &exceptioncode )
{ {
// Works line innerText in Gecko
// ### test if needed for ID_SCRIPT as well.
if ( id() == ID_STYLE ) {
setInnerText(html, exceptioncode);
return;
}
DocumentFragment fragment = createContextualFragment( html ); DocumentFragment fragment = createContextualFragment( html );
if ( fragment.isNull() ) { if ( fragment.isNull() ) {
exceptioncode = DOMException::NO_MODIFICATION_ALLOWED_ERR; exceptioncode = DOMException::NO_MODIFICATION_ALLOWED_ERR;

@ -614,17 +614,7 @@ void HTMLFormElementImpl::submit( )
bool checkboxResult = false; bool checkboxResult = false;
const int savePassword = KMessageBox::createKMessageBox(dialog, QMessageBox::Information, const int savePassword = KMessageBox::createKMessageBox(dialog, QMessageBox::Information,
formUrl.host().isEmpty() ? // e.g. local file i18n("Store passwords on this page?"),
i18n("Konqueror has the ability to store the password "
"in an encrypted wallet. When the wallet is unlocked, it "
"can then automatically restore the login information "
"next time you submit this form. Do you want to store "
"the information now?") :
i18n("Konqueror has the ability to store the password "
"in an encrypted wallet. When the wallet is unlocked, it "
"can then automatically restore the login information "
"next time you visit %1. Do you want to store "
"the information now?").arg(formUrl.host()),
QStringList(), QString::null, &checkboxResult, KMessageBox::Notify); QStringList(), QString::null, &checkboxResult, KMessageBox::Notify);
if ( savePassword == KDialogBase::Yes ) { if ( savePassword == KDialogBase::Yes ) {

@ -32,6 +32,6 @@ kjavaappletviewer_la_SOURCES= kjavaapplet.cpp kjavaappletcontext.cpp \
kjavadownloader.cpp kjavaappletviewer.cpp kjavadownloader.cpp kjavaappletviewer.cpp
kjavaappletviewer_la_LDFLAGS= $(all_libraries) -module $(KDE_PLUGIN) kjavaappletviewer_la_LDFLAGS= $(all_libraries) -module $(KDE_PLUGIN)
kjavaappletviewer_la_LIBADD= $(LIB_KPARTS) kjavaappletviewer_la_LIBADD= $(LIB_KPARTS) $(LIB_QT) $(LIB_KDEUI) $(LIB_KDECORE) $(LIB_KFILE) $(top_builddir)/dcop/libDCOP.la
kde_services_DATA= kjavaappletviewer.desktop kde_services_DATA= kjavaappletviewer.desktop

@ -5,7 +5,7 @@ INCLUDES = -I$(top_srcdir)/khtml -I$(top_srcdir)/kio/httpfilter -I$(top_srcdir)/
kde_module_LTLIBRARIES = libkmultipart.la kde_module_LTLIBRARIES = libkmultipart.la
libkmultipart_la_SOURCES = kmultipart.cpp libkmultipart_la_SOURCES = kmultipart.cpp
libkmultipart_la_LIBADD = $(LIB_KPARTS) $(top_builddir)/kio/httpfilter/libhttpfilter.la libkmultipart_la_LIBADD = $(LIB_KPARTS) $(top_builddir)/kio/httpfilter/libhttpfilter.la $(LIB_QT) $(LIB_KDECORE) $(LIB_KDEUI) $(LIB_KFILE) $(LIBZ)
libkmultipart_la_DEPENDENCIES = $(LIB_KPARTS) libkmultipart_la_DEPENDENCIES = $(LIB_KPARTS)
libkmultipart_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) libkmultipart_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN)

@ -22,14 +22,14 @@ KDE_CXXFLAGS = $(WOVERLOADED_VIRTUAL)
noinst_LTLIBRARIES = libkhtmlmisc.la noinst_LTLIBRARIES = libkhtmlmisc.la
libkhtmlmisc_la_SOURCES = \ libkhtmlmisc_la_SOURCES = \
decoder.cpp loader.cpp loader_jpeg.cpp guess_ja.cpp\ decoder.cpp loader.cpp loader_jpeg.cpp guess_ja.cpp\
htmlhashes.cpp helper.cpp arena.cpp stringit.cpp htmlhashes.cpp helper.cpp arena.cpp stringit.cpp knsplugininstaller.cpp
libkhtmlmisc_la_LIBADD = $(LIBJPEG) libkhtmlmisc_la_LIBADD = $(LIBJPEG)
libkhtmlmisc_la_LDFLAGS = $(USER_LDFLAGS) libkhtmlmisc_la_LDFLAGS = $(USER_LDFLAGS)
libkhtmlmisc_la_METASOURCES = AUTO libkhtmlmisc_la_METASOURCES = AUTO
noinst_HEADERS = \ noinst_HEADERS = \
decoder.h khtmllayout.h loader_jpeg.h loader.h guess_ja.h\ decoder.h khtmllayout.h loader_jpeg.h loader.h guess_ja.h\
stringit.h htmlhashes.h helper.h shared.h arena.h stringit.h htmlhashes.h helper.h shared.h arena.h knsplugininstaller.h
INCLUDES = -I$(top_srcdir) -I$(top_srcdir)/dcop -I$(top_srcdir)/kio -I$(top_srcdir)/libltdl \ INCLUDES = -I$(top_srcdir) -I$(top_srcdir)/dcop -I$(top_srcdir)/kio -I$(top_srcdir)/libltdl \
-I$(top_srcdir)/khtml -I$(top_srcdir)/kutils $(all_includes) -I$(top_srcdir)/khtml -I$(top_srcdir)/kutils $(all_includes)

@ -0,0 +1,672 @@
/*
* This file is part of the KDE project.
*
* Copyright (C) 2005 Benoit Canet <bcanet@dental-on-line.fr>
* with some advices from Aurelien Gateau <agateau@dental-on-line.fr>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library 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
* Library General Public License for more details.
*
* You should have received a copy of the GNU Library General Public License
* along with this library; see the file COPYING.LIB. If not, write to
* the Free Software Foundation, Inc., 51 Franklin Steet, Fifth Floor,
* Boston, MA 02110-1301, USA.
*
*/
#include "knsplugininstaller.moc"
#include <kdebug.h>
#include <kdiroperator.h>
#include <klistview.h>
#include <klocale.h>
#include <kstddirs.h>
#include <ktempfile.h>
#include <netaccess.h>
#include <qbuttongroup.h>
#include <qdir.h>
#include <qiodevice.h>
#include <qfile.h>
#include <qlabel.h>
#include <qlayout.h>
#include <qmap.h>
#include <qstringlist.h>
#include <qtextstream.h>
#include <sys/utsname.h>
// Use 6031 for debugging (render_frame)
#define DEBUG_NUMBER 6031
/*
* Utility class to associate a list item with a pluginInfo object
*/
class PluginListItem : public QListViewItem
{
public:
PluginListItem(KNSPluginInfo pluginInfo, QListView *parent)
: QListViewItem(parent, pluginInfo.pluginName())
, m_pluginInfo(pluginInfo) {}
KNSPluginInfo pluginInfo() const { return m_pluginInfo; }
private:
KNSPluginInfo m_pluginInfo;
};
// public methods
KNSPluginInstallEngine::KNSPluginInstallEngine(KMimeType::Ptr mime) : QObject()
{
m_mime = mime;
// Fill the architecture map
m_archMap["i386"] = "ia32";
m_archMap["i486"] = "ia32";
m_archMap["i586"] = "ia32";
m_archMap["i686"] = "ia32";
}
KNSPluginInstallEngine::~KNSPluginInstallEngine()
{
}
bool KNSPluginInstallEngine::pluginAvailable()
{
if(m_pluginList.count())
return true;
// check if pluginsListFile is present in kde config
if(!loadConfig())
return false;
// load the xml configuration file
if(!loadXmlConfig())
return false;
return findPlugin();
}
bool KNSPluginInstallEngine::isActive()
{
// check if we have a configuration key in the kde registry
QString pluginsListFile;
KConfig cfg("kcmnspluginrc", true);
cfg.setGroup("Misc");
pluginsListFile = cfg.readPathEntry("PluginsListFile");
return !pluginsListFile.isEmpty();
}
const QValueList<KNSPluginInfo>& KNSPluginInstallEngine::pluginList() const
{
return m_pluginList;
}
// private methods
bool KNSPluginInstallEngine::loadConfig()
{
QString pluginsListFile;
KConfig cfg("kcmnspluginrc", true);
cfg.setGroup("Misc");
pluginsListFile = cfg.readPathEntry("PluginsListFile");
if(!pluginsListFile.isEmpty())
{
m_pluginsListFileURL = KURL(pluginsListFile);
kdDebug(DEBUG_NUMBER) << "config loaded "<<endl;
return true;
}
return false;
}
bool KNSPluginInstallEngine::loadXmlConfig()
{
// load the Xml configuration file
if(m_pluginsXmlConfig.isEmpty())
{
QString tmpFile;
if(KIO::NetAccess::download(m_pluginsListFileURL, tmpFile, NULL)) {
QFile f(tmpFile);
if(!f.open(IO_ReadOnly))
return false;
QTextStream stream(&f);
stream.setEncoding(QTextStream::UnicodeUTF8);
m_pluginsXmlConfig = stream.read();
f.close();
KIO::NetAccess::removeTempFile(tmpFile);
} else
return false;
}
kdDebug(DEBUG_NUMBER) << "xml config loaded :" << endl;
return true;
}
bool KNSPluginInstallEngine::findPlugin()
{
// get system infos
// TODO/FIX : correct this to work with x86-64 machines
utsname sysinfo;
if(uname(&sysinfo))
return false;
QString sysname(sysinfo.sysname);
QString machine(sysinfo.machine);
QString arch = m_archMap[machine];
// Parse the document
QDomDocument doc("xmlConfig");
doc.setContent(m_pluginsXmlConfig);
QDomNodeList archList = doc.elementsByTagName(QString("arch"));
QDomNode archNode, osNode , pluginNode, node;
QDomElement e;
// look for the correct architecture
bool found = false;
unsigned int i;
for(i=0; i < archList.count() ; i++) {
archNode = archList.item(i);
e = archNode.toElement();
if( e.attribute("architecture") == arch) {
kdDebug(DEBUG_NUMBER) << "found correct architecture :" << arch << endl;
found = true;
break;
}
}
if(!found)
return false;
// look for the correct os
found = false;
osNode = archNode.firstChild();
while(!osNode.isNull()) {
e = osNode.toElement();
if( e.tagName() == "os" && e.attribute("name") == sysname) {
kdDebug(DEBUG_NUMBER) << "found correct os :" << sysname << endl;
found = true;
break;
}
osNode=osNode.nextSibling();
}
if(!found)
return false;
// Look for a plugin with the given mimetype
pluginNode = osNode.firstChild();
while(!pluginNode.isNull()) {
e = pluginNode.toElement();
if( e.tagName() == "plugin" && m_mime->is(e.attribute("mimetype")) ) {
kdDebug(DEBUG_NUMBER) << "found correct plugin :" << e.attribute("mimetype") << endl;
KNSPluginInfo pluginInfo(pluginNode);
if(pluginInfo.isValid())
m_pluginList.append(pluginInfo);
}
pluginNode=pluginNode.nextSibling();
}
if(m_pluginList.count())
return true;
else
return false;
}
void KNSPluginInstallEngine::startInstall(KNSPluginInfo info)
{
m_toInstallPluginInfo = info;
// create a temporary dowload file
KTempFile tempFile(locateLocal("tmp", "plugin") , QString(".tar.gz"));
m_tmpPluginFileName = tempFile.name();
tempFile.unlink();
tempFile.close();
// start the download job
m_downloadJob = KIO::copy(info.pluginURL(), "file://"+m_tmpPluginFileName, false );
// connect signals
connect(m_downloadJob, SIGNAL(percent (KIO::Job *, unsigned long)), this , SLOT(slotDownLoadProgress(KIO::Job *, unsigned long)));
connect(m_downloadJob, SIGNAL(result(KIO::Job *)), this, SLOT(slotDownloadResult(KIO::Job *)) );
kdDebug(DEBUG_NUMBER) << "download plugin " << m_tmpPluginFileName << endl;
}
void KNSPluginInstallEngine::slotDownLoadProgress(KIO::Job *, unsigned long percent)
{
// propagate the download progression
emit installProgress( ((int)percent)/3 );
}
void KNSPluginInstallEngine::slotDownloadResult(KIO::Job *job)
{
// test if the download job suceed
if(job->error()) {
kdDebug(DEBUG_NUMBER) << "download error" << m_tmpPluginFileName << endl;
emit installFailed();
}
else {
kdDebug(DEBUG_NUMBER) << "download completed" << m_tmpPluginFileName << endl;
// the download succeed copy the plugins files
// test the existance of the homedir
QDir dir(QDir::homeDirPath());
if(!dir.exists()) {
emit installFailed();
return;
}
// test and create firefox plugins directory
if(!dir.exists(".mozilla"))
dir.mkdir(".mozilla");
if(!dir.exists(".mozilla/plugins"))
dir.mkdir(".mozilla/plugins");
// destination kurl
KURL destURL("file://"+QDir::homeDirPath()+"/.mozilla/plugins");
// construct the source kurlList
KURL::List urlList;
QStringList pluginFileList = m_toInstallPluginInfo.pluginFileList();
QStringList::iterator it;
for( it = pluginFileList.begin(); it != pluginFileList.end(); ++it ) {
urlList.append( KURL("tar://"+m_tmpPluginFileName+"/"+(*it)) );
}
m_installFileJob = KIO::copy(urlList , destURL, false );
connect(m_installFileJob, SIGNAL(percent (KIO::Job *, unsigned long)), this , SLOT(slotCopyProgress(KIO::Job *, unsigned long)));
connect(m_installFileJob, SIGNAL(result(KIO::Job *)), this, SLOT(slotCopyResult(KIO::Job *)) );
}
kdDebug(DEBUG_NUMBER) << "COPY FILE " << m_tmpPluginFileName << endl;
// zero the download job pointer
m_downloadJob = NULL;
}
void KNSPluginInstallEngine::slotCopyProgress(KIO::Job *, unsigned long percent)
{
// propagate the download progression
emit installProgress( ((int)percent)/3 + 33 );
}
void KNSPluginInstallEngine::slotCopyResult(KIO::Job *job)
{
// test if the download job suceed
if(job->error()) {
kdDebug(DEBUG_NUMBER) << "download error" << m_tmpPluginFileName << endl;
emit installFailed();
}
else {
// start the plugins scan
m_scanProc = new QProcess( this );
m_scanProc->addArgument( "nspluginscan" );
m_scanProc->addArgument( "--verbose" );
connect( m_scanProc, SIGNAL(readyReadStdout()),
this, SLOT(readScanProcFromStdout()) );
connect( m_scanProc, SIGNAL(processExited()),
this, SLOT(endScanProc()) );
if ( !m_scanProc->start() ) {
emit installFailed();
}
}
}
void KNSPluginInstallEngine::readScanProcFromStdout()
{
// Monitor the scan progress
QString progress = m_scanProc->readLineStdout();
int percent;
bool ok;
percent = progress.toInt(&ok);
if(!ok)
emit installFailed();
emit installProgress( (percent)/3 + 66 );
}
void KNSPluginInstallEngine::endScanProc()
{
// end of scan
if(m_scanProc->normalExit()) {
emit installProgress( 100 );
emit installCompleted();
} else
emit installFailed();
}
KNSPluginWizard::KNSPluginWizard(QWidget *parent, const char *name, KMimeType::Ptr mime)
: KWizard(parent, name, true)
, m_installEngine(mime)
{
setCaption(i18n("KDE plugin wizard"));
setModal(true);
// read the plugin installer configuration
m_installEngine.pluginAvailable();
// init the wizzard Pages
initConfirmationPage();
initLicencePage();
initInstallationProgressPage();
initFinishPage();
initPagesButtonStates();
// connect signals and slots
connectSignals();
//set correct default installation status
m_installationComplete = false;
};
KNSPluginWizard::~KNSPluginWizard()
{
};
void KNSPluginWizard::initConfirmationPage()
{
m_confirmationVBox = new QVBox(this);
new QLabel(i18n("The following plugins are available."), m_confirmationVBox);
m_pluginListView = new KListView(m_confirmationVBox);
m_pluginListView->addColumn(i18n("Name"));
m_pluginListView->setSelectionMode(QListView::Single);
new QLabel(i18n("Click on next to install the selected plugin."), m_confirmationVBox);
addPage (m_confirmationVBox, i18n("Plugin installation confirmation"));
bool selected = false;
// Fill the plugin list
QValueList<KNSPluginInfo>::iterator it;
QValueList<KNSPluginInfo> pluginList = m_installEngine.pluginList();
for( it = pluginList.begin(); it != pluginList.end(); ++it ) {
PluginListItem *item = new PluginListItem((*it) , m_pluginListView);
if(!selected) {
selected = true;
m_pluginListView->setSelected(item, true);
}
kdDebug(DEBUG_NUMBER) << "New Plugin List item"<< endl;
setNextEnabled(m_confirmationVBox, true);
}
}
void KNSPluginWizard::initLicencePage()
{
m_licenceVBox = new QVBox(this);
m_licencePageLabel = new QLabel(m_licenceVBox);
m_licencePageText = new KTextEdit(m_licenceVBox);
m_licencePageText->setReadOnly(true);
// invisible buttonGroup
QButtonGroup *buttonGroup = new QButtonGroup(this);
m_agreementButtonGroup = buttonGroup;
buttonGroup->hide();
buttonGroup->setExclusive(true);
m_licencePageAgree = new QRadioButton ( i18n("I agree."), m_licenceVBox);
m_licencePageDisagree = new QRadioButton ( i18n("I do not agree (plugin will not be installed)."), m_licenceVBox);
buttonGroup->insert(m_licencePageAgree);
buttonGroup->insert(m_licencePageDisagree);
m_licencePageDisagree->setChecked(true);
addPage (m_licenceVBox, i18n("Plugin licence"));
connect(buttonGroup, SIGNAL(clicked(int)), this, SLOT(slotAgreementClicked(int)));
}
void KNSPluginWizard::initInstallationProgressPage() {
m_installationProgressWidget = new QWidget(this);
QVBoxLayout *layout = new QVBoxLayout(m_installationProgressWidget);
layout->addWidget(new QLabel(i18n("Installation in progress."), m_installationProgressWidget));
layout->addItem(new QSpacerItem(40,20,QSizePolicy::Expanding,QSizePolicy::Expanding ));
m_installationProgressBar = new KProgress(m_installationProgressWidget);
m_installationProgressBar->setTotalSteps(100);
layout->addWidget(m_installationProgressBar);
addPage( m_installationProgressWidget, i18n("Plugin installation"));
}
void KNSPluginWizard::initFinishPage()
{
m_finishWidget = new QWidget(this);
QVBoxLayout *layout = new QVBoxLayout(m_finishWidget);
layout->addItem(new QSpacerItem(40,20,QSizePolicy::Expanding,QSizePolicy::Expanding ));
m_finishLabel = new QLabel(m_finishWidget);
layout->addWidget(m_finishLabel);
layout->addItem(new QSpacerItem(40,20,QSizePolicy::Expanding,QSizePolicy::Expanding ));
addPage(m_finishWidget, i18n("Installation status"));
}
void KNSPluginWizard::initPagesButtonStates()
{
// set buttons states for the confirmation page
setNextEnabled(m_confirmationVBox, true);
setFinishEnabled(m_confirmationVBox, false);
setHelpEnabled(m_confirmationVBox, false);
// set buttons states for the licence page
setNextEnabled(m_licenceVBox , false);
setBackEnabled(m_licenceVBox , false);
setFinishEnabled(m_licenceVBox , false);
setHelpEnabled(m_licenceVBox , false);
// for the installation page
setNextEnabled(m_installationProgressWidget , false);
setBackEnabled(m_installationProgressWidget , false);
setFinishEnabled(m_installationProgressWidget , false);
setHelpEnabled(m_installationProgressWidget , false);
// for the finish page
setNextEnabled(m_finishWidget , false);
setBackEnabled(m_finishWidget , false);
setFinishEnabled(m_finishWidget , true);
setHelpEnabled(m_finishWidget , false);
}
void KNSPluginWizard::connectSignals() {
connect(&m_installEngine, SIGNAL(installProgress(int)), m_installationProgressBar, SLOT(setProgress(int)) );
connect(&m_installEngine, SIGNAL(installCompleted()), this, SLOT(slotInstallationCompleted()) );
connect(&m_installEngine, SIGNAL(installFailed()), this, SLOT(slotInstallationFailed()) );
}
void KNSPluginWizard::showPage(QWidget *page)
{
// if the licence page is shown set the label and the licence content
if(page == m_licenceVBox && m_licencePageLabel->text().isEmpty()) {
KNSPluginInfo info = static_cast<PluginListItem *>(m_pluginListView->selectedItem())->pluginInfo();
m_licencePageLabel->setText(i18n("To install ")+info.pluginName()+i18n(" you need to agree to the following"));
QString licence;
licence = info.licence();
QString tmpFile;
if(info.licenceURL().isValid())
// retrieve the licence if we have an url
if(KIO::NetAccess::download(info.licenceURL(), tmpFile, NULL)) {
QFile f(tmpFile);
if(f.open(IO_ReadOnly)) {
QTextStream stream(&f);
stream.setEncoding(QTextStream::UnicodeUTF8);
licence = stream.read();
f.close();
KIO::NetAccess::removeTempFile(tmpFile);
}
}
// else display the licence found in the xml config
m_licencePageText->setText(licence);
}
// if the installation page is shown start the download
if(page == m_installationProgressWidget) {
KNSPluginInfo info = static_cast<PluginListItem *>(m_pluginListView->selectedItem())->pluginInfo();
m_installEngine.startInstall(info);
}
// If we must display the finish page
if(page == m_finishWidget) {
if(m_installationComplete) {
m_finishLabel->setText(i18n("Installation completed. Reload the page."));
} else
m_finishLabel->setText(i18n("Installation failed"));
}
KWizard::showPage(page);
}
int KNSPluginWizard::exec()
{
if(!m_installEngine.pluginList().count())
return QDialog::Rejected;
return KWizard::exec();
}
bool KNSPluginWizard::pluginAvailable()
{
return m_installEngine.pluginAvailable();
}
void KNSPluginWizard::slotAgreementClicked(int id)
{
if( id == m_agreementButtonGroup->id(m_licencePageAgree) ) {
setNextEnabled(m_licenceVBox, true);
} else {
setNextEnabled(m_licenceVBox, false);
}
}
void KNSPluginWizard::slotInstallationCompleted()
{
m_installationComplete = true;
// enable next button
setNextEnabled(m_installationProgressWidget, true);
next();
}
void KNSPluginWizard::slotInstallationFailed()
{
m_installationComplete = false;
showPage(m_finishWidget);
}
// KNSPlugin info copy constructor
KNSPluginInfo::KNSPluginInfo()
{
}
// KNSPlugin info constructor par an xml dom fragment
KNSPluginInfo::KNSPluginInfo(QDomNode pluginNode)
{
QDomElement e;
QDomNode node;
// Read plugin informations
node = pluginNode.firstChild();
while(!node.isNull()) {
e = node.toElement();
if( e.tagName() == "pluginname") {
kdDebug(DEBUG_NUMBER) << "found name " << e.text() << endl;
m_pluginName = e.text();
}
if( e.tagName() == "pluginurl") {
kdDebug(DEBUG_NUMBER) << "found plugin url " << e.text() << endl;
m_pluginURL = KURL(e.text());
}
if( e.tagName() == "licence") {
kdDebug(DEBUG_NUMBER) << "found licence " << e.text() << endl;
m_licence = e.text();
}
if( e.tagName() == "licenceurl") {
kdDebug(DEBUG_NUMBER) << "found licenceurl " << e.text() << endl;
m_licenceURL = KURL(e.text());
}
if( e.tagName() == "pluginfile") {
kdDebug(DEBUG_NUMBER) << "found pluginfile " << e.text() << endl;
m_pluginFileList.append(e.text());
}
node = node.nextSibling();
}
}
KNSPluginInfo::~KNSPluginInfo()
{
}
bool KNSPluginInfo::isValid() const
{
// tell if the pluginInfo is a valid One
if( m_pluginName.isEmpty() || ( m_licence.isEmpty() && !m_licenceURL.isValid() ) || !m_pluginURL.isValid() || m_pluginFileList.empty() ) {
kdDebug(DEBUG_NUMBER) << "invalid plugin info" << endl;
return false;
}
else {
kdDebug(DEBUG_NUMBER) << "valid plugin info" << endl;
return true;
}
}
// Accesors
QString KNSPluginInfo::pluginName() const
{
return m_pluginName;
}
QString KNSPluginInfo::licence() const
{
return m_licence;
}
KURL KNSPluginInfo::licenceURL() const
{
return m_licenceURL;
}
KURL KNSPluginInfo::pluginURL() const
{
return m_pluginURL;
}
const QStringList& KNSPluginInfo::pluginFileList() const
{
return m_pluginFileList;
}

@ -0,0 +1,269 @@
/*
* This file is part of the KDE project.
*
* Copyright (C) 2005 Benoit Canet <bcanet@dental-on-line.fr>
* with some advices from Aurelien Gateau <agateau@dental-on-line.fr>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library 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
* Library General Public License for more details.
*
* You should have received a copy of the GNU Library General Public License
* along with this library; see the file COPYING.LIB. If not, write to
* the Free Software Foundation, Inc., 51 Franklin Steet, Fifth Floor,
* Boston, MA 02110-1301, USA.
*
*/
#ifndef KNSPLUGININSTALLER_H
#define KNSPLUGININSTALLER_H
#include <job.h>
#include <ktextedit.h>
#include <kmimetype.h>
#include <kprogress.h>
#include <kurl.h>
#include <kwizard.h>
#include <qbuttongroup.h>
#include <qdom.h>
#include <qlabel.h>
#include <qobject.h>
#include <qprocess.h>
#include <qradiobutton.h>
#include <qvaluelist.h>
#include <qvbox.h>
#include <qwidget.h>
class QStringList;
/*
* This class contains all the infos needed to install a given plugin
* Takes and parse a QDomNode in its constructor
*/
class KNSPluginInfo
{
public:
/*
* Construct the plugin info object
*/
KNSPluginInfo();
KNSPluginInfo(QDomNode pluginNode);
~KNSPluginInfo();
/*
* Check the validity of the plugin info object
*/
bool isValid() const;
//Accessor methods
QString pluginName() const;
QString licence() const;
KURL licenceURL() const;
KURL pluginURL() const;
const QStringList& pluginFileList() const;
private:
// plugin info
QString m_pluginName;
QString m_licence;
KURL m_licenceURL;
KURL m_pluginURL;
QStringList m_pluginFileList;
};
/*
* This class contain all the the methods used to perform a plugin installation
*
*/
class KNSPluginInstallEngine : public QObject
{
Q_OBJECT
public:
/*
* Construct the class
*/
KNSPluginInstallEngine(KMimeType::Ptr mime);
~KNSPluginInstallEngine();
/*
* Check if the installer engine and wizzard is activated
*/
static bool isActive();
/**
* Check the availability of a plugin
*/
bool pluginAvailable();
/*
* Return the list of plugins Available
*/
const QValueList<KNSPluginInfo>& pluginList() const;
void startInstall(KNSPluginInfo info);
private:
// methods used to check the kde config and detect if an adequate plugin is available
/*
* load kde KNSPluginInstaller config
*/
bool loadConfig();
/*
* retrieve the xml configuration file
*/
bool loadXmlConfig();
/*
* parse the xml configuration file
*/
bool findPlugin();
QMap<QString, QString> m_archMap;
QString m_pluginsXmlConfig;
QValueList<KNSPluginInfo> m_pluginList;
KMimeType::Ptr m_mime;
KURL m_pluginsListFileURL;
QString m_tmpPluginFileName;
KIO::CopyJob *m_downloadJob;
KIO::CopyJob *m_installFileJob;
KNSPluginInfo m_toInstallPluginInfo;
QProcess *m_scanProc;
signals:
// Signals used to communicate with the wizzard
void installProgress(int percent);
void installCompleted();
void installFailed();
private slots:
// Used to monitor the plugin downloading
void slotDownLoadProgress(KIO::Job *job, unsigned long percent);
void slotDownloadResult(KIO::Job *job);
// Used to monitor the plugin installation
void slotCopyProgress(KIO::Job *job, unsigned long percent);
void slotCopyResult(KIO::Job *job);
// Used to monitor the plugins scan
void readScanProcFromStdout();
void endScanProc();
};
/*
* This class is a wizzard used to install a plugin
*/
class KNSPluginWizard : public KWizard
{
Q_OBJECT
public:
/**
* Construct a KNSpluginInstaller
*/
KNSPluginWizard(QWidget *parent, const char *name, KMimeType::Ptr mime);
~KNSPluginWizard();
/**
* Lauch the wizzard
*/
int exec();
/*
* Check the availability of a plugin
*/
bool pluginAvailable();
private:
// methods used in the constructor to init the wizzard pages
void initConfirmationPage();
void initLicencePage();
void initInstallationProgressPage();
void initFinishPage();
// in this method we disable or enable the wizzard pages buttons
void initPagesButtonStates();
/*
* Connect signals
*/
void connectSignals();
/*
* Overiden method called when a page is shown
*/
void showPage(QWidget *page);
// Plugin installation engine
KNSPluginInstallEngine m_installEngine;
// pages widgets
QVBox *m_confirmationVBox;
QVBox *m_licenceVBox;
QWidget *m_installationProgressWidget;
QWidget *m_finishWidget;
// plugin list
KListView *m_pluginListView;
// licence stuff
QLabel *m_licencePageLabel;
KTextEdit *m_licencePageText;
QRadioButton *m_licencePageAgree;
QRadioButton *m_licencePageDisagree;
QButtonGroup *m_agreementButtonGroup;
// installation progress bar
KProgress *m_installationProgressBar;
// Finish Label
QLabel *m_finishLabel;
// installation status
bool m_installationComplete;
private slots:
/*
* Check if the user Agree or disagree with the licence
*/
void slotAgreementClicked(int id);
/*
* Called when the installation is completed
*/
void slotInstallationCompleted();
/*
* Called when the installation has failed
*/
void slotInstallationFailed();
signals:
/*
* Emited when the installation has complete - TODO connect this signal to reload the page
*/
void pluginInstallCompleted();
};
#endif

@ -36,6 +36,7 @@
#include "misc/htmltags.h" #include "misc/htmltags.h"
#include "khtmlview.h" #include "khtmlview.h"
#include "khtml_part.h" #include "khtml_part.h"
#include "misc/knsplugininstaller.h"
#include <kapplication.h> #include <kapplication.h>
#include <kmessagebox.h> #include <kmessagebox.h>
@ -937,17 +938,30 @@ void RenderPartObject::slotPartLoadingErrorNotify()
if (!mimeName.isEmpty() && part->docImpl() && !part->pluginPageQuestionAsked( serviceType ) ) if (!mimeName.isEmpty() && part->docImpl() && !part->pluginPageQuestionAsked( serviceType ) )
{ {
part->setPluginPageQuestionAsked( serviceType ); part->setPluginPageQuestionAsked( serviceType );
// Prepare the URL to show in the question (host only if http, to make it short) bool pluginAvailable;
KURL pluginPageURL( embed->pluginPage ); pluginAvailable = false;
QString shortURL = pluginPageURL.protocol() == "http" ? pluginPageURL.host() : pluginPageURL.prettyURL(); // check if a pluginList file is in the config
int res = KMessageBox::questionYesNo( m_view, if(KNSPluginInstallEngine::isActive())
i18n("No plugin found for '%1'.\nDo you want to download one from %2?").arg(mimeName).arg(shortURL),
i18n("Missing Plugin"), i18n("Download"), i18n("Do Not Download"), QString("plugin-")+serviceType);
if ( res == KMessageBox::Yes )
{ {
// Display vendor download page KNSPluginWizard pluginWizard(m_view, "pluginInstaller", mime);
ext->createNewWindow( pluginPageURL ); if(pluginWizard.pluginAvailable()) {
return; pluginAvailable = true;
pluginWizard.exec();
}
}
if(!pluginAvailable) {
// Prepare the URL to show in the question (host only if http, to make it short)
KURL pluginPageURL( embed->pluginPage );
QString shortURL = pluginPageURL.protocol() == "http" ? pluginPageURL.host() : pluginPageURL.prettyURL();
int res = KMessageBox::questionYesNo( m_view,
i18n("No plugin found for '%1'.\nDo you want to download one from %2?").arg(mimeName).arg(shortURL),
i18n("Missing Plugin"), i18n("Download"), i18n("Do Not Download"), QString("plugin-")+serviceType);
if ( res == KMessageBox::Yes )
{
// Display vendor download page
ext->createNewWindow( pluginPageURL );
return;
}
} }
} }
} }
@ -1007,4 +1021,5 @@ void RenderPartObject::slotViewCleared()
} }
} }
#include "render_frames.moc" #include "render_frames.moc"

@ -37,7 +37,7 @@ kimg_xview_la_LIBADD = $(LIB_QT)
kimg_eps_la_SOURCES = eps.cpp kimg_eps_la_SOURCES = eps.cpp
kimg_eps_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries) kimg_eps_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries)
kimg_eps_la_LIBADD = $(LIB_KDECORE) kimg_eps_la_LIBADD = $(LIB_KDECORE) $(LIB_QT)
kimg_ico_la_SOURCES = ico.cpp kimg_ico_la_SOURCES = ico.cpp
kimg_ico_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries) kimg_ico_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries)
@ -49,35 +49,35 @@ kimg_jp2_la_LIBADD = $(LIB_QT) $(LIB_JASPER) ../kdecore/libkdecore.la
kimg_pcx_la_SOURCES = pcx.cpp kimg_pcx_la_SOURCES = pcx.cpp
kimg_pcx_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries) kimg_pcx_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries)
kimg_pcx_la_LIBADD = $(LIB_QT) $(LIB_KDECORE) kimg_pcx_la_LIBADD = $(LIB_QT)
kimg_tga_la_SOURCES = tga.cpp kimg_tga_la_SOURCES = tga.cpp
kimg_tga_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries) kimg_tga_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries)
kimg_tga_la_LIBADD = $(LIB_QT) $(LIB_KDECORE) kimg_tga_la_LIBADD = $(LIB_QT)
kimg_rgb_la_SOURCES = rgb.cpp kimg_rgb_la_SOURCES = rgb.cpp
kimg_rgb_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries) kimg_rgb_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries)
kimg_rgb_la_LIBADD = $(LIB_QT) $(LIB_KDECORE) kimg_rgb_la_LIBADD = $(LIB_QT)
kimg_xcf_la_SOURCES = xcf.cpp kimg_xcf_la_SOURCES = xcf.cpp
kimg_xcf_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries) kimg_xcf_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries)
kimg_xcf_la_LIBADD = $(LIB_QT) $(LIB_KDECORE) kimg_xcf_la_LIBADD = $(LIB_QT)
kimg_exr_la_SOURCES = exr.cpp kimg_exr_la_SOURCES = exr.cpp
kimg_exr_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries) kimg_exr_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries)
kimg_exr_la_LIBADD = $(LIB_QT) $(LIB_KDECORE) $(LIB_EXR) kimg_exr_la_LIBADD = $(LIB_QT) $(LIB_EXR)
kimg_dds_la_SOURCES = dds.cpp kimg_dds_la_SOURCES = dds.cpp
kimg_dds_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries) kimg_dds_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries)
kimg_dds_la_LIBADD = $(LIB_QT) $(LIB_KDECORE) kimg_dds_la_LIBADD = $(LIB_QT)
kimg_psd_la_SOURCES = psd.cpp kimg_psd_la_SOURCES = psd.cpp
kimg_psd_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries) kimg_psd_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries)
kimg_psd_la_LIBADD = $(LIB_QT) $(LIB_KDECORE) kimg_psd_la_LIBADD = $(LIB_QT)
kimg_hdr_la_SOURCES = hdr.cpp kimg_hdr_la_SOURCES = hdr.cpp
kimg_hdr_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries) kimg_hdr_la_LDFLAGS = -module $(KIMGIO_PLUGIN) -no-undefined $(all_libraries)
kimg_hdr_la_LIBADD = $(LIB_QT) $(LIB_KDECORE) kimg_hdr_la_LIBADD = $(LIB_QT)
noinst_HEADERS= xview.h eps.h tiffr.h g3r.h ico.h jp2.h pcx.h tga.h rgb.h xcf.h gimp.h exr.h dds.h psd.h hdr.h noinst_HEADERS= xview.h eps.h tiffr.h g3r.h ico.h jp2.h pcx.h tga.h rgb.h xcf.h gimp.h exr.h dds.h psd.h hdr.h

@ -56,7 +56,7 @@ kwrapper_SOURCES = kwrapper.c
kwrapper_LDADD = $(LIBSOCKET) kwrapper_LDADD = $(LIBSOCKET)
klauncher_la_LDFLAGS = $(all_libraries) -module -avoid-version klauncher_la_LDFLAGS = $(all_libraries) -module -avoid-version
klauncher_la_LIBADD = $(LIB_KIO) klauncher_la_LIBADD = $(LIB_KIO) $(LIB_QT) $(LIB_KDECORE) $(top_builddir)/dcop/libDCOP.la $(LIB_X11)
klauncher_la_SOURCES = klauncher.cpp klauncher_main.cpp autostart.cpp klauncher_la_SOURCES = klauncher.cpp klauncher_main.cpp autostart.cpp
kstartupconfig_SOURCES = kstartupconfig.cpp kstartupconfig_SOURCES = kstartupconfig.cpp

@ -48,6 +48,14 @@ AutoStart::AutoStart( bool new_startup )
m_startList = new AutoStartList; m_startList = new AutoStartList;
m_startList->setAutoDelete(true); m_startList->setAutoDelete(true);
KGlobal::dirs()->addResourceType("autostart", "share/autostart"); KGlobal::dirs()->addResourceType("autostart", "share/autostart");
QString xdgdirs = getenv("XDG_CONFIG_DIRS");
if (xdgdirs.isEmpty())
xdgdirs = "/etc/xdg";
QStringList xdgdirslist = QStringList::split( ':', xdgdirs );
for ( QStringList::Iterator itr = xdgdirslist.begin(); itr != xdgdirslist.end(); ++itr ) {
KGlobal::dirs()->addResourceDir("autostart", (*itr) +"/autostart");
}
} }
AutoStart::~AutoStart() AutoStart::~AutoStart()

@ -60,7 +60,7 @@
#include <kapplication.h> #include <kapplication.h>
#include <klocale.h> #include <klocale.h>
#ifdef Q_OS_LINUX #ifdef HAVE_SYS_PRCTL_H
#include <sys/prctl.h> #include <sys/prctl.h>
#ifndef PR_SET_NAME #ifndef PR_SET_NAME
#define PR_SET_NAME 15 #define PR_SET_NAME 15
@ -256,18 +256,18 @@ static void setup_tty( const char* tty )
int fd = open( tty, O_WRONLY ); int fd = open( tty, O_WRONLY );
if( fd < 0 ) if( fd < 0 )
{ {
perror( "kdeinit: couldn't open() tty" ); fprintf(stderr, "kdeinit: couldn't open() %s: %s\n", tty, strerror (errno) );
return; return;
} }
if( dup2( fd, STDOUT_FILENO ) < 0 ) if( dup2( fd, STDOUT_FILENO ) < 0 )
{ {
perror( "kdeinit: couldn't dup2() tty" ); fprintf(stderr, "kdeinit: couldn't dup2() %s: %s\n", tty, strerror (errno) );
close( fd ); close( fd );
return; return;
} }
if( dup2( fd, STDERR_FILENO ) < 0 ) if( dup2( fd, STDERR_FILENO ) < 0 )
{ {
perror( "kdeinit: couldn't dup2() tty" ); fprintf(stderr, "kdeinit: couldn't dup2() %s: %s\n", tty, strerror (errno) );
close( fd ); close( fd );
return; return;
} }
@ -571,7 +571,7 @@ static pid_t launch(int argc, const char *_name, const char *args,
d.argv[argc] = 0; d.argv[argc] = 0;
/** Give the process a new name **/ /** Give the process a new name **/
#ifdef Q_OS_LINUX #ifdef HAVE_SYS_PRCTL_H
/* set the process name, so that killall works like intended */ /* set the process name, so that killall works like intended */
r = prctl(PR_SET_NAME, (unsigned long) name.data(), 0, 0, 0); r = prctl(PR_SET_NAME, (unsigned long) name.data(), 0, 0, 0);
if ( r == 0 ) if ( r == 0 )

@ -81,7 +81,7 @@ int main()
else if( getenv( "HOME" )) else if( getenv( "HOME" ))
{ {
strlcpy( kdehome, getenv( "HOME" ), 1024 ); strlcpy( kdehome, getenv( "HOME" ), 1024 );
strlcat( kdehome, "/.kde", 1024 ); strlcat( kdehome, "/.kde3", 1024 );
} }
else else
return 1; return 1;

@ -89,6 +89,9 @@ int create_link(const char *file, const char *tmp_dir)
} }
#ifndef PATH_MAX
#define PATH_MAX 4096
#endif
int build_link(const char *tmp_prefix, const char *kde_prefix) int build_link(const char *tmp_prefix, const char *kde_prefix)
{ {
struct passwd *pw_ent; struct passwd *pw_ent;
@ -116,7 +119,7 @@ int build_link(const char *tmp_prefix, const char *kde_prefix)
if (!kde_home || !kde_home[0]) if (!kde_home || !kde_home[0])
{ {
kde_home = "~/.kde/"; kde_home = "~/.kde3/";
} }
if (kde_home[0] == '~') if (kde_home[0] == '~')

@ -139,7 +139,7 @@ static int openSocket()
if (!kde_home || !kde_home[0]) if (!kde_home || !kde_home[0])
{ {
kde_home = "~/.kde/"; kde_home = "~/.kde3/";
} }
if (kde_home[0] == '~') if (kde_home[0] == '~')

@ -20,7 +20,8 @@ AM_CPPFLAGS = -D_LARGEFILE64_SOURCE
INCLUDES= -I$(srcdir)/.. $(all_includes) $(SSL_INCLUDES) INCLUDES= -I$(srcdir)/.. $(all_includes) $(SSL_INCLUDES)
SUBDIRS = kssl kio bookmarks kfile . kpasswdserver misc pics tests kioexec httpfilter SUBDIRS = kssl kio bookmarks kfile . pics tests kioexec httpfilter
DIST_SUBDIRS = kpasswdserver misc
lib_LTLIBRARIES = libkio.la lib_LTLIBRARIES = libkio.la
@ -32,7 +33,7 @@ libkio_la_LIBADD = kssl/libkssl.la kio/libkiocore.la \
kio/libksycoca.la bookmarks/libkbookmarks.la kfile/libkfile.la \ kio/libksycoca.la bookmarks/libkbookmarks.la kfile/libkfile.la \
../kdeui/libkdeui.la ../kdesu/libkdesu.la \ ../kdeui/libkdeui.la ../kdesu/libkdesu.la \
../kwallet/client/libkwalletclient.la \ ../kwallet/client/libkwalletclient.la \
$(LIBZ) $(LIBFAM) $(LIBVOLMGT) $(ACL_LIBS) $(LIBZ) $(LIBFAM) $(LIBVOLMGT) $(ACL_LIBS) $(LIB_QT) $(LIB_KDECORE) $(top_builddir)/dcop/libDCOP.la $(LIB_X11)
kde_mime_DATA = magic kde_mime_DATA = magic
kde_servicetypes_DATA = application.desktop kurifilterplugin.desktop \ kde_servicetypes_DATA = application.desktop kurifilterplugin.desktop \

@ -20,6 +20,9 @@
#include "config-kfile.h" #include "config-kfile.h"
#include <qdir.h> #include <qdir.h>
#include <qfile.h>
#include <qtextcodec.h>
#include <qtextstream.h>
#include <kconfig.h> #include <kconfig.h>
#include <kglobal.h> #include <kglobal.h>
@ -50,7 +53,7 @@ KFileSpeedBar::KFileSpeedBar( QWidget *parent, const char *name )
QDir(KGlobalSettings::documentPath()).exists()) QDir(KGlobalSettings::documentPath()).exists())
{ {
u.setPath( KGlobalSettings::documentPath() ); u.setPath( KGlobalSettings::documentPath() );
insertItem( u, i18n("Documents"), false, "document" ); insertItem( u, i18n("Documents"), false, "folder_txt" );
} }
u.setPath( QDir::homeDirPath() ); u.setPath( QDir::homeDirPath() );
@ -62,6 +65,51 @@ KFileSpeedBar::KFileSpeedBar( QWidget *parent, const char *name )
insertItem( u, i18n("Storage Media"), false, insertItem( u, i18n("Storage Media"), false,
KProtocolInfo::icon( "media" ) ); KProtocolInfo::icon( "media" ) );
if ( QFile::exists( QDir::homeDirPath()+"/.config/user-dirs.dirs" ) )
{
QString download, music, pictures, videos, templates, publicShares;
QFile f( QDir::homeDirPath()+"/.config/user-dirs.dirs" );
if (!f.open(IO_ReadOnly))
return;
QTextStream s( &f );
s.setCodec( QTextCodec::codecForLocale() );
// read the xdg user dirs
QString line = s.readLine();
while (!line.isNull())
{
if (line.startsWith("XDG_DOWNLOAD_DIR="))
download = line.remove("XDG_DOWNLOAD_DIR=").remove("\"").replace("$HOME", QDir::homeDirPath());
else if (line.startsWith("XDG_MUSIC_DIR="))
music = line.remove("XDG_MUSIC_DIR=").remove("\"").replace("$HOME", QDir::homeDirPath());
else if (line.startsWith("XDG_PICTURES_DIR="))
pictures = line.remove("XDG_PICTURES_DIR=").remove("\"").replace("$HOME", QDir::homeDirPath());
else if (line.startsWith("XDG_VIDEOS_DIR="))
videos = line.remove("XDG_VIDEOS_DIR=").remove("\"").replace("$HOME", QDir::homeDirPath());
else if (line.startsWith("XDG_TEMPLATES_DIR="))
templates = line.remove("XDG_TEMPLATES_DIR=").remove("\"").replace("$HOME", QDir::homeDirPath());
else if (line.startsWith("XDG_PUBLICSHARES_DIR="))
publicShares = line.remove("XDG_PUBLICSHARES_DIR=").remove("\"").replace("$HOME", QDir::homeDirPath());
line = s.readLine();
}
// now add in the speedbar
if (!download.isEmpty())
insertItem( download, i18n( "Download" ), false, "folder_html" );
if (!music.isEmpty())
insertItem( music, i18n( "Music" ), false, "folder_sound" );
if (!pictures.isEmpty())
insertItem( pictures, i18n( "Pictures" ), false, "folder_image" );
if (!videos.isEmpty())
insertItem( videos, i18n( "Videos" ), false, "folder_video" );
if (!templates.isEmpty())
insertItem( templates, i18n( "Templates" ), false, "folder_video" );
if (!publicShares.isEmpty())
insertItem( publicShares, i18n( "Public" ), false, "folder_video" );
}
u = "remote:/"; u = "remote:/";
if ( KProtocolInfo::isKnownProtocol( u ) ) if ( KProtocolInfo::isKnownProtocol( u ) )
insertItem( u, i18n("Network Folders"), false, insertItem( u, i18n("Network Folders"), false,

@ -1881,7 +1881,14 @@ static bool fileSystemSupportsACL( const QCString& pathCString )
fileSystemSupportsACLs = ( statfs( pathCString.data(), &buf ) == 0 ) && ( buf.f_flags & MNT_ACLS ); fileSystemSupportsACLs = ( statfs( pathCString.data(), &buf ) == 0 ) && ( buf.f_flags & MNT_ACLS );
#else #else
fileSystemSupportsACLs = fileSystemSupportsACLs =
getxattr( pathCString.data(), "system.posix_acl_access", NULL, 0 ) >= 0 || errno == ENODATA; getxattr( pathCString.data(), "system.posix_acl_access", NULL, 0 ) >= 0
#ifdef ENODATA
|| (errno == ENODATA)
#endif
#ifdef ENOATTR
|| (errno == ENOATTR)
#endif
;
#endif #endif
return fileSystemSupportsACLs; return fileSystemSupportsACLs;
} }

@ -64,34 +64,15 @@
// debug // debug
#include <sys/ioctl.h> #include <sys/ioctl.h>
#ifdef HAVE_SYS_INOTIFY #ifdef HAVE_INOTIFY
#include <sys/inotify.h>
#include <fcntl.h>
#elif HAVE_INOTIFY
#include <unistd.h> #include <unistd.h>
#include <fcntl.h> #include <fcntl.h>
#include <sys/syscall.h> #include <sys/syscall.h>
#include <linux/types.h>
// Linux kernel headers are documented to not compile // Linux kernel headers are documented to not compile
#define _S390_BITOPS_H #define _S390_BITOPS_H
#include <linux/inotify.h> #include <sys/inotify.h>
static inline int inotify_init (void)
{
return syscall (__NR_inotify_init);
}
static inline int inotify_add_watch (int fd, const char *name, __u32 mask)
{
return syscall (__NR_inotify_add_watch, fd, name, mask);
}
static inline int inotify_rm_watch (int fd, __u32 wd)
{
return syscall (__NR_inotify_rm_watch, fd, wd);
}
#endif
#ifdef HAVE_INOTIFY
#ifndef IN_ONLYDIR #ifndef IN_ONLYDIR
#define IN_ONLYDIR 0x01000000 #define IN_ONLYDIR 0x01000000
#endif #endif
@ -103,6 +84,7 @@ static inline int inotify_rm_watch (int fd, __u32 wd)
#ifndef IN_MOVE_SELF #ifndef IN_MOVE_SELF
#define IN_MOVE_SELF 0x00000800 #define IN_MOVE_SELF 0x00000800
#endif #endif
#endif #endif
#include <sys/utsname.h> #include <sys/utsname.h>

File diff suppressed because it is too large Load Diff

@ -77,6 +77,7 @@ public:
QString m_localPath; QString m_localPath;
QString m_suggestedFileName; QString m_suggestedFileName;
QGuardedPtr <QWidget> m_window; QGuardedPtr <QWidget> m_window;
QCString m_asn;
}; };
pid_t KRun::runURL( const KURL& u, const QString& _mimetype ) pid_t KRun::runURL( const KURL& u, const QString& _mimetype )
@ -109,14 +110,20 @@ bool KRun::isExecutableFile( const KURL& url, const QString &mimetype )
return false; return false;
} }
// This is called by foundMimeType, since it knows the mimetype of the URL
pid_t KRun::runURL( const KURL& u, const QString& _mimetype, bool tempFile, bool runExecutables, const QString& suggestedFileName ) pid_t KRun::runURL( const KURL& u, const QString& _mimetype, bool tempFile, bool runExecutables, const QString& suggestedFileName )
{
return runURL( u, _mimetype, NULL, "", tempFile, runExecutables, suggestedFileName );
}
// This is called by foundMimeType, since it knows the mimetype of the URL
pid_t KRun::runURL( const KURL& u, const QString& _mimetype, QWidget* window, const QCString& asn,
bool tempFile, bool runExecutables, const QString& suggestedFileName )
{ {
bool noRun = false; bool noRun = false;
bool noAuth = false; bool noAuth = false;
if ( _mimetype == "inode/directory-locked" ) if ( _mimetype == "inode/directory-locked" )
{ {
KMessageBoxWrapper::error( 0L, KMessageBoxWrapper::error( window,
i18n("<qt>Unable to enter <b>%1</b>.\nYou do not have access rights to this location.</qt>").arg(u.htmlURL()) ); i18n("<qt>Unable to enter <b>%1</b>.\nYou do not have access rights to this location.</qt>").arg(u.htmlURL()) );
return 0; return 0;
} }
@ -133,7 +140,7 @@ pid_t KRun::runURL( const KURL& u, const QString& _mimetype, bool tempFile, bool
{ {
QString path = u.path(); QString path = u.path();
shellQuote( path ); shellQuote( path );
return (KRun::runCommand(path)); // just execute the url as a command return (KRun::runCommand(path, QString::null, QString::null, window, asn)); // just execute the url as a command
// ## TODO implement deleting the file if tempFile==true // ## TODO implement deleting the file if tempFile==true
} }
else else
@ -155,14 +162,14 @@ pid_t KRun::runURL( const KURL& u, const QString& _mimetype, bool tempFile, bool
if ( noRun ) if ( noRun )
{ {
KMessageBox::sorry( 0L, KMessageBox::sorry( window,
i18n("<qt>The file <b>%1</b> is an executable program. " i18n("<qt>The file <b>%1</b> is an executable program. "
"For safety it will not be started.</qt>").arg(u.htmlURL())); "For safety it will not be started.</qt>").arg(u.htmlURL()));
return 0; return 0;
} }
if ( noAuth ) if ( noAuth )
{ {
KMessageBoxWrapper::error( 0L, KMessageBoxWrapper::error( window,
i18n("<qt>You do not have permission to run <b>%1</b>.</qt>").arg(u.htmlURL()) ); i18n("<qt>You do not have permission to run <b>%1</b>.</qt>").arg(u.htmlURL()) );
return 0; return 0;
} }
@ -182,7 +189,7 @@ pid_t KRun::runURL( const KURL& u, const QString& _mimetype, bool tempFile, bool
return displayOpenWithDialog( lst, tempFile, suggestedFileName ); return displayOpenWithDialog( lst, tempFile, suggestedFileName );
} }
return KRun::run( *offer, lst, 0 /*window*/, tempFile, suggestedFileName ); return KRun::run( *offer, lst, window, asn, tempFile, suggestedFileName );
} }
bool KRun::displayOpenWithDialog( const KURL::List& lst ) bool KRun::displayOpenWithDialog( const KURL::List& lst )
@ -536,13 +543,13 @@ QString KRun::binaryName( const QString & execLine, bool removePath )
} }
static pid_t runCommandInternal( KProcess* proc, const KService* service, const QString& binName, static pid_t runCommandInternal( KProcess* proc, const KService* service, const QString& binName,
const QString &execName, const QString & iconName ) const QString &execName, const QString & iconName, QWidget* window, QCString asn )
{ {
if (service && !service->desktopEntryPath().isEmpty() if (service && !service->desktopEntryPath().isEmpty()
&& !KDesktopFile::isAuthorizedDesktopFile( service->desktopEntryPath() )) && !KDesktopFile::isAuthorizedDesktopFile( service->desktopEntryPath() ))
{ {
kdWarning() << "No authorization to execute " << service->desktopEntryPath() << endl; kdWarning() << "No authorization to execute " << service->desktopEntryPath() << endl;
KMessageBox::sorry(0, i18n("You are not authorized to execute this file.")); KMessageBox::sorry(window, i18n("You are not authorized to execute this file."));
return 0; return 0;
} }
QString bin = KRun::binaryName( binName, true ); QString bin = KRun::binaryName( binName, true );
@ -550,10 +557,10 @@ static pid_t runCommandInternal( KProcess* proc, const KService* service, const
bool silent; bool silent;
QCString wmclass; QCString wmclass;
KStartupInfoId id; KStartupInfoId id;
bool startup_notify = KRun::checkStartupNotify( binName, service, &silent, &wmclass ); bool startup_notify = ( asn != "0" && KRun::checkStartupNotify( binName, service, &silent, &wmclass ));
if( startup_notify ) if( startup_notify )
{ {
id.initId(); id.initId( asn );
id.setupStartupEnv(); id.setupStartupEnv();
KStartupInfoData data; KStartupInfoData data;
data.setHostname(); data.setHostname();
@ -572,6 +579,8 @@ static pid_t runCommandInternal( KProcess* proc, const KService* service, const
if( silent ) if( silent )
data.setSilent( KStartupInfoData::Yes ); data.setSilent( KStartupInfoData::Yes );
data.setDesktop( KWin::currentDesktop()); data.setDesktop( KWin::currentDesktop());
if( window )
data.setLaunchedBy( window->winId());
KStartupInfo::sendStartup( id, data ); KStartupInfo::sendStartup( id, data );
} }
pid_t pid = KProcessRunner::run( proc, binName, id ); pid_t pid = KProcessRunner::run( proc, binName, id );
@ -635,7 +644,8 @@ bool KRun::checkStartupNotify( const QString& /*binName*/, const KService* servi
return true; return true;
} }
static pid_t runTempService( const KService& _service, const KURL::List& _urls, bool tempFiles, const QString& suggestedFileName ) static pid_t runTempService( const KService& _service, const KURL::List& _urls, QWidget* window,
const QCString& asn, bool tempFiles, const QString& suggestedFileName )
{ {
if (!_urls.isEmpty()) { if (!_urls.isEmpty()) {
kdDebug(7010) << "runTempService: first url " << _urls.first().url() << endl; kdDebug(7010) << "runTempService: first url " << _urls.first().url() << endl;
@ -654,7 +664,7 @@ static pid_t runTempService( const KService& _service, const KURL::List& _urls,
{ {
KURL::List singleUrl; KURL::List singleUrl;
singleUrl.append(*it); singleUrl.append(*it);
runTempService( _service, singleUrl, tempFiles, suggestedFileName ); runTempService( _service, singleUrl, window, "", tempFiles, suggestedFileName );
} }
KURL::List singleUrl; KURL::List singleUrl;
singleUrl.append(_urls.first()); singleUrl.append(_urls.first());
@ -673,7 +683,7 @@ static pid_t runTempService( const KService& _service, const KURL::List& _urls,
proc->setWorkingDirectory(_service.path()); proc->setWorkingDirectory(_service.path());
return runCommandInternal( proc, &_service, KRun::binaryName( _service.exec(), false ), return runCommandInternal( proc, &_service, KRun::binaryName( _service.exec(), false ),
_service.name(), _service.icon() ); _service.name(), _service.icon(), window, asn );
} }
// WARNING: don't call this from processDesktopExec, since klauncher uses that too... // WARNING: don't call this from processDesktopExec, since klauncher uses that too...
@ -734,10 +744,21 @@ pid_t KRun::run( const KService& _service, const KURL::List& _urls, bool tempFil
pid_t KRun::run( const KService& _service, const KURL::List& _urls, QWidget* window, bool tempFiles ) pid_t KRun::run( const KService& _service, const KURL::List& _urls, QWidget* window, bool tempFiles )
{ {
return run( _service, _urls, window, tempFiles, QString::null ); return run( _service, _urls, window, "", tempFiles, QString::null );
}
pid_t KRun::run( const KService& _service, const KURL::List& _urls, QWidget* window, const QCString& asn, bool tempFiles )
{
return run( _service, _urls, window, asn, tempFiles, QString::null );
} }
pid_t KRun::run( const KService& _service, const KURL::List& _urls, QWidget* window, bool tempFiles, const QString& suggestedFileName ) pid_t KRun::run( const KService& _service, const KURL::List& _urls, QWidget* window, bool tempFiles, const QString& suggestedFileName )
{
return run( _service, _urls, window, "", tempFiles, suggestedFileName );
}
pid_t KRun::run( const KService& _service, const KURL::List& _urls, QWidget* window, const QCString& asn,
bool tempFiles, const QString& suggestedFileName )
{ {
if (!_service.desktopEntryPath().isEmpty() && if (!_service.desktopEntryPath().isEmpty() &&
!KDesktopFile::isAuthorizedDesktopFile( _service.desktopEntryPath())) !KDesktopFile::isAuthorizedDesktopFile( _service.desktopEntryPath()))
@ -759,7 +780,7 @@ pid_t KRun::run( const KService& _service, const KURL::List& _urls, QWidget* win
if ( tempFiles || _service.desktopEntryPath().isEmpty() || !suggestedFileName.isEmpty() ) if ( tempFiles || _service.desktopEntryPath().isEmpty() || !suggestedFileName.isEmpty() )
{ {
return runTempService(_service, _urls, tempFiles, suggestedFileName); return runTempService(_service, _urls, window, asn, tempFiles, suggestedFileName);
} }
kdDebug(7010) << "KRun::run " << _service.desktopEntryPath() << endl; kdDebug(7010) << "KRun::run " << _service.desktopEntryPath() << endl;
@ -774,8 +795,24 @@ pid_t KRun::run( const KService& _service, const KURL::List& _urls, QWidget* win
QString error; QString error;
int pid = 0; int pid = 0;
QCString myasn = asn;
// startServiceByDesktopPath() doesn't take QWidget*, add it to the startup info now
if( window != NULL )
{
if( myasn.isEmpty())
myasn = KStartupInfo::createNewStartupId();
if( myasn != "0" )
{
KStartupInfoId id;
id.initId( myasn );
KStartupInfoData data;
data.setLaunchedBy( window->winId());
KStartupInfo::sendChange( id, data );
}
}
int i = KApplication::startServiceByDesktopPath( int i = KApplication::startServiceByDesktopPath(
_service.desktopEntryPath(), urls.toStringList(), &error, 0L, &pid _service.desktopEntryPath(), urls.toStringList(), &error, 0L, &pid, myasn
); );
if (i != 0) if (i != 0)
@ -800,33 +837,47 @@ pid_t KRun::run( const QString& _exec, const KURL::List& _urls, const QString& _
pid_t KRun::runCommand( QString cmd ) pid_t KRun::runCommand( QString cmd )
{ {
return KRun::runCommand( cmd, QString::null, QString::null ); return KRun::runCommand( cmd, QString::null, QString::null, NULL, "" );
} }
pid_t KRun::runCommand( const QString& cmd, const QString &execName, const QString & iconName ) pid_t KRun::runCommand( const QString& cmd, const QString &execName, const QString & iconName )
{
return KRun::runCommand( cmd, execName, iconName, NULL, "" );
}
pid_t KRun::runCommand( const QString& cmd, const QString &execName, const QString & iconName,
QWidget* window, const QCString& asn )
{ {
kdDebug(7010) << "runCommand " << cmd << "," << execName << endl; kdDebug(7010) << "runCommand " << cmd << "," << execName << endl;
KProcess * proc = new KProcess; KProcess * proc = new KProcess;
proc->setUseShell(true); proc->setUseShell(true);
*proc << cmd; *proc << cmd;
KService::Ptr service = KService::serviceByDesktopName( binaryName( execName, true ) ); KService::Ptr service = KService::serviceByDesktopName( binaryName( execName, true ) );
return runCommandInternal( proc, service.data(), binaryName( execName, false ), execName, iconName ); return runCommandInternal( proc, service.data(), binaryName( execName, false ), execName, iconName,
window, asn );
} }
KRun::KRun( const KURL& url, mode_t mode, bool isLocalFile, bool showProgressInfo ) KRun::KRun( const KURL& url, mode_t mode, bool isLocalFile, bool showProgressInfo )
:m_timer(0,"KRun::timer") :m_timer(0,"KRun::timer")
{ {
init (url, 0, mode, isLocalFile, showProgressInfo); init (url, 0, "", mode, isLocalFile, showProgressInfo);
} }
KRun::KRun( const KURL& url, QWidget* window, mode_t mode, bool isLocalFile, KRun::KRun( const KURL& url, QWidget* window, mode_t mode, bool isLocalFile,
bool showProgressInfo ) bool showProgressInfo )
:m_timer(0,"KRun::timer") :m_timer(0,"KRun::timer")
{ {
init (url, window, mode, isLocalFile, showProgressInfo); init (url, window, "", mode, isLocalFile, showProgressInfo);
}
KRun::KRun( const KURL& url, QWidget* window, const QCString& asn, mode_t mode, bool isLocalFile,
bool showProgressInfo )
:m_timer(0,"KRun::timer")
{
init (url, window, asn, mode, isLocalFile, showProgressInfo);
} }
void KRun::init ( const KURL& url, QWidget* window, mode_t mode, bool isLocalFile, void KRun::init ( const KURL& url, QWidget* window, const QCString& asn, mode_t mode, bool isLocalFile,
bool showProgressInfo ) bool showProgressInfo )
{ {
m_bFault = false; m_bFault = false;
@ -842,6 +893,7 @@ void KRun::init ( const KURL& url, QWidget* window, mode_t mode, bool isLocalFil
d = new KRunPrivate; d = new KRunPrivate;
d->m_runExecutables = true; d->m_runExecutables = true;
d->m_window = window; d->m_window = window;
d->m_asn = asn;
setEnableExternalBrowser(true); setEnableExternalBrowser(true);
// Start the timer. This means we will return to the event // Start the timer. This means we will return to the event
@ -942,7 +994,7 @@ void KRun::init()
KService::Ptr service = KService::serviceByStorageId( exec ); KService::Ptr service = KService::serviceByStorageId( exec );
if (service) if (service)
{ {
run( *service, urls ); run( *service, urls, d->m_window, d->m_asn );
ok = true; ok = true;
} }
} }
@ -1235,7 +1287,7 @@ void KRun::foundMimeType( const QString& type )
{ {
KURL::List lst; KURL::List lst;
lst.append( m_strURL ); lst.append( m_strURL );
m_bFinished = KRun::run( *serv, lst ); m_bFinished = KRun::run( *serv, lst, d->m_window, d->m_asn );
/// Note: the line above means that if that service failed, we'll /// Note: the line above means that if that service failed, we'll
/// go to runURL to maybe find another service, even though a dialog /// go to runURL to maybe find another service, even though a dialog
/// box was displayed. That's good if runURL tries another service, /// box was displayed. That's good if runURL tries another service,
@ -1250,7 +1302,7 @@ void KRun::foundMimeType( const QString& type )
m_strURL.setPath( d->m_localPath ); m_strURL.setPath( d->m_localPath );
} }
if (!m_bFinished && KRun::runURL( m_strURL, type, false, d->m_runExecutables, d->m_suggestedFileName )){ if (!m_bFinished && KRun::runURL( m_strURL, type, d->m_window, d->m_asn, false, d->m_runExecutables, d->m_suggestedFileName )){
m_bFinished = true; m_bFinished = true;
} }
else{ else{

@ -111,6 +111,8 @@ public:
*/ */
KRun( const KURL& url, QWidget* window, mode_t mode = 0, KRun( const KURL& url, QWidget* window, mode_t mode = 0,
bool isLocalFile = false, bool showProgressInfo = true ); bool isLocalFile = false, bool showProgressInfo = true );
KRun( const KURL& url, QWidget* window, const QCString& asn, mode_t mode = 0,
bool isLocalFile = false, bool showProgressInfo = true );
/** /**
* Destructor. Don't call it yourself, since a KRun object auto-deletes * Destructor. Don't call it yourself, since a KRun object auto-deletes
@ -210,6 +212,8 @@ public:
* @since 3.5.2 * @since 3.5.2
*/ */
static pid_t run( const KService& _service, const KURL::List& _urls, QWidget* window, bool tempFiles = false ); static pid_t run( const KService& _service, const KURL::List& _urls, QWidget* window, bool tempFiles = false );
static pid_t run( const KService& _service, const KURL::List& _urls, QWidget* window,
const QCString& asn, bool tempFiles = false );
/** /**
* Open a list of URLs with a certain service (application). * Open a list of URLs with a certain service (application).
* *
@ -226,6 +230,8 @@ public:
/// @since 3.5.3 /// @since 3.5.3
/// @internal /// @internal
static pid_t run( const KService& _service, const KURL::List& _urls, QWidget* window, bool tempFiles, const QString& suggestedFileName ); static pid_t run( const KService& _service, const KURL::List& _urls, QWidget* window, bool tempFiles, const QString& suggestedFileName );
static pid_t run( const KService& _service, const KURL::List& _urls, QWidget* window,
const QCString& asn, bool tempFiles, const QString& suggestedFileName );
/** /**
* Open a list of URLs with. * Open a list of URLs with.
@ -269,6 +275,7 @@ public:
static pid_t runURL( const KURL& _url, const QString& _mimetype ); static pid_t runURL( const KURL& _url, const QString& _mimetype );
/// @since 3.5.3 /// @since 3.5.3
/// @internal /// @internal
static pid_t runURL( const KURL& _url, const QString& _mimetype, QWidget* window, const QCString& asn, bool tempFile, bool runExecutables, const QString& suggestedFileName );
static pid_t runURL( const KURL& _url, const QString& _mimetype, bool tempFile, bool runExecutables, const QString& suggestedFileName ); static pid_t runURL( const KURL& _url, const QString& _mimetype, bool tempFile, bool runExecutables, const QString& suggestedFileName );
/** /**
@ -299,6 +306,8 @@ public:
* of running command) if command was unsafe for map notification. * of running command) if command was unsafe for map notification.
*/ */
static pid_t runCommand( const QString& cmd, const QString & execName, const QString & icon ); static pid_t runCommand( const QString& cmd, const QString & execName, const QString & icon );
static pid_t runCommand( const QString& cmd, const QString & execName, const QString & icon,
QWidget* window, const QCString& asn );
/** /**
* Display the Open-With dialog for those URLs, and run the chosen application. * Display the Open-With dialog for those URLs, and run the chosen application.
@ -438,7 +447,7 @@ protected:
virtual void virtual_hook( int id, void* data ); virtual void virtual_hook( int id, void* data );
private: private:
void init (const KURL& url, QWidget* window, mode_t mode, void init (const KURL& url, QWidget* window, const QCString& asn, mode_t mode,
bool isLocalFile, bool showProgressInfo); bool isLocalFile, bool showProgressInfo);
private: private:
class KRunPrivate; class KRunPrivate;

@ -97,6 +97,7 @@ KService::init( KDesktopFile *config )
m_bValid = true; m_bValid = true;
bool absPath = !QDir::isRelativePath(entryPath()); bool absPath = !QDir::isRelativePath(entryPath());
bool kde4application = config->fileName().startsWith("/usr/share/applications/kde4/");
config->setDesktopGroup(); config->setDesktopGroup();
@ -196,9 +197,28 @@ KService::init( KDesktopFile *config )
name = name.left(pos); name = name.left(pos);
m_strExec = config->readPathEntry( "Exec" ); m_strExec = config->readPathEntry( "Exec" );
if (kde4application && !m_strExec.startsWith("/")) {
m_strExec = "KDEHOME=$HOME/.kde XDG_DATA_DIRS=/usr/share KDEDIRS=/usr/ XDG_CONFIG_DIRS=/etc/xdg/ PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:$PATH "+m_strExec;
} else if (config->readBoolEntry("X-KDE-SubstituteUID")) {
int space = m_strExec.find(" ");
if (space==-1)
m_strExec = KStandardDirs::findExe(m_strExec);
else {
const QString command = m_strExec.left(space);
m_strExec.replace(command,KStandardDirs::findExe(command));
}
}
entryMap.remove("Exec"); entryMap.remove("Exec");
m_strIcon = config->readEntry( "Icon", "unknown" ); m_strIcon = config->readEntry( "Icon", "unknown" );
if (kde4application) {
if (QFile::exists("/usr/share/icons/oxygen/22x22/apps/" + m_strIcon + ".png")) {
m_strIcon = "/usr/share/icons/oxygen/22x22/apps/" + m_strIcon + ".png";
} else if (QFile::exists("/usr/share/icons/hicolor/22x22/apps/" + m_strIcon + ".png")) {
m_strIcon = "/usr/share/icons/hicolor/22x22/apps/" + m_strIcon + ".png";
}
}
entryMap.remove("Icon"); entryMap.remove("Icon");
m_bTerminal = (config->readBoolEntry( "Terminal" )); // should be a property IMHO m_bTerminal = (config->readBoolEntry( "Terminal" )); // should be a property IMHO
entryMap.remove("Terminal"); entryMap.remove("Terminal");
@ -209,6 +229,9 @@ KService::init( KDesktopFile *config )
m_strComment = config->readEntry( "Comment" ); m_strComment = config->readEntry( "Comment" );
entryMap.remove("Comment"); entryMap.remove("Comment");
m_strGenName = config->readEntry( "GenericName" ); m_strGenName = config->readEntry( "GenericName" );
if (kde4application) {
m_strGenName += " [KDE4]";
}
entryMap.remove("GenericName"); entryMap.remove("GenericName");
QString untranslatedGenericName = config->readEntryUntranslated( "GenericName" ); QString untranslatedGenericName = config->readEntryUntranslated( "GenericName" );
if (!untranslatedGenericName.isEmpty()) if (!untranslatedGenericName.isEmpty())
@ -226,7 +249,8 @@ KService::init( KDesktopFile *config )
m_lstServiceTypes = config->readListEntry( "ServiceTypes" ); m_lstServiceTypes = config->readListEntry( "ServiceTypes" );
entryMap.remove("ServiceTypes"); entryMap.remove("ServiceTypes");
// For compatibility with KDE 1.x // For compatibility with KDE 1.x
m_lstServiceTypes += config->readListEntry( "MimeType", ';' ); if (!kde4application)
m_lstServiceTypes += config->readListEntry( "MimeType", ';' );
entryMap.remove("MimeType"); entryMap.remove("MimeType");
if ( m_strType == "Application" && !m_lstServiceTypes.contains("Application") ) if ( m_strType == "Application" && !m_lstServiceTypes.contains("Application") )
@ -245,6 +269,8 @@ KService::init( KDesktopFile *config )
m_DCOPServiceType = DCOP_None; m_DCOPServiceType = DCOP_None;
m_strDesktopEntryName = name.lower(); m_strDesktopEntryName = name.lower();
if (kde4application)
m_strDesktopEntryName = "kde4-" + m_strDesktopEntryName;
m_bAllowAsDefault = config->readBoolEntry( "AllowDefault", true ); m_bAllowAsDefault = config->readBoolEntry( "AllowDefault", true );
entryMap.remove("AllowDefault"); entryMap.remove("AllowDefault");
@ -260,7 +286,10 @@ KService::init( KDesktopFile *config )
for( ; it != entryMap.end();++it) for( ; it != entryMap.end();++it)
{ {
//qDebug(" Key = %s Data = %s", it.key().latin1(), it.data().latin1()); //qDebug(" Key = %s Data = %s", it.key().latin1(), it.data().latin1());
m_mapProps.insert( it.key(), QVariant( it.data())); QString key = it.key();
if (kde4application && key=="OnlyShowIn" && it.data()=="KDE;")
key = "NotShowIn";
m_mapProps.insert( key, QVariant( it.data()));
} }
} }

@ -231,6 +231,9 @@ void DirectoryListThread::run()
while ( !terminationRequested() && while ( !terminationRequested() &&
(dirEntry = ::readdir( dir))) (dirEntry = ::readdir( dir)))
#else #else
#if !defined(MAXPATHLEN) && defined(__GNU__)
#define MAXPATHLEN UCHAR_MAX
#endif
struct dirent *dirPosition = (struct dirent *) malloc( sizeof( struct dirent ) + MAXPATHLEN + 1 ); struct dirent *dirPosition = (struct dirent *) malloc( sizeof( struct dirent ) + MAXPATHLEN + 1 );
struct dirent *dirEntry = 0; struct dirent *dirEntry = 0;
while ( !terminationRequested() && while ( !terminationRequested() &&

@ -10,6 +10,6 @@ kde_module_LTLIBRARIES = kded_kpasswdserver.la
kded_kpasswdserver_la_SOURCES = kpasswdserver.cpp kpasswdserver.skel kded_kpasswdserver_la_SOURCES = kpasswdserver.cpp kpasswdserver.skel
kded_kpasswdserver_la_METASOURCES = AUTO kded_kpasswdserver_la_METASOURCES = AUTO
kded_kpasswdserver_la_LDFLAGS = $(all_libraries) -module -avoid-version kded_kpasswdserver_la_LDFLAGS = $(all_libraries) -module -avoid-version
kded_kpasswdserver_la_LIBADD = $(top_builddir)/kwallet/client/libkwalletclient.la $(LIB_KIO) $(LIB_KDED) kded_kpasswdserver_la_LIBADD = $(top_builddir)/kwallet/client/libkwalletclient.la $(LIB_KIO) $(LIB_KDED) $(LIB_QT) $(LIB_KDEUI) $(LIB_KDECORE) $(top_builddir)/dcop/libDCOP.la $(LIB_X11) $(top_builddir)/kded/libkdeinit_kded.la
include $(top_srcdir)/admin/Doxyfile.am include $(top_srcdir)/admin/Doxyfile.am

@ -29,7 +29,7 @@ bin_PROGRAMS = kmailservice ktelnetservice
observer_DIR = $(top_srcdir)/kio/kio observer_DIR = $(top_srcdir)/kio/kio
kio_uiserver_la_SOURCES = uiserver.cpp uiserver.skel observer.stub kio_uiserver_la_SOURCES = uiserver.cpp uiserver.skel observer.stub
kio_uiserver_la_LIBADD = $(LIB_KIO) kio_uiserver_la_LIBADD = $(LIB_KIO) $(LIB_KDEUI) $(LIB_QT) $(top_builddir)/dcop/libDCOP.la $(LIB_KDECORE)
kio_uiserver_la_LDFLAGS = $(all_libraries) -module -avoid-version kio_uiserver_la_LDFLAGS = $(all_libraries) -module -avoid-version
METASOURCES = AUTO METASOURCES = AUTO

@ -285,7 +285,12 @@ sub update_server {
system('PATH=/bin:/sbin pidof nfsd >/dev/null') != 0) { system('PATH=/bin:/sbin pidof nfsd >/dev/null') != 0) {
# trying to start the server... # trying to start the server...
system('/etc/init.d/portmap start') if system('/etc/init.d/portmap status') != 0; system('/etc/init.d/portmap start') if system('/etc/init.d/portmap status') != 0;
system('/etc/init.d/nfs', $_) foreach 'stop', 'start'; if ( -f '/etc/init.d/nfs' ) {
system('/etc/init.d/nfs', $_) foreach 'stop', 'start';
}
elsif ( -f '/etc/init.d/nfs-kernel-server' ) {
system('/etc/init.d/nfs-kernel-server', $_) foreach 'stop', 'start';
}
} }
exit 0; exit 0;
} }

@ -8,5 +8,5 @@ kdesaslinclude_HEADERS = kdesasl.h
libkdesasl_la_SOURCES = kdesasl.cpp libkdesasl_la_SOURCES = kdesasl.cpp
libkdesasl_la_LDFLAGS = $(all_libraries) -version-info 3:0:2 -no-undefined libkdesasl_la_LDFLAGS = $(all_libraries) -version-info 3:0:2 -no-undefined
libkdesasl_la_LIBADD = $(LIB_KDECORE) libkdesasl_la_LIBADD = $(LIB_KDECORE) $(LIB_QT)

@ -8,5 +8,5 @@ kntlminclude_HEADERS = kntlm.h
libkntlm_la_SOURCES = kntlm.cpp des.cpp libkntlm_la_SOURCES = kntlm.cpp des.cpp
libkntlm_la_LDFLAGS = $(all_libraries) -version-info 0:0:0 -no-undefined libkntlm_la_LDFLAGS = $(all_libraries) -version-info 0:0:0 -no-undefined
libkntlm_la_LIBADD = $(LIB_KDECORE) libkntlm_la_LIBADD = $(LIB_KDECORE) $(LIB_QT)

@ -10,7 +10,9 @@ KDE_CXXFLAGS = $(USE_EXCEPTIONS)
kded_proxyscout_la_SOURCES = proxyscout.skel proxyscout.cpp script.cpp \ kded_proxyscout_la_SOURCES = proxyscout.skel proxyscout.cpp script.cpp \
downloader.cpp discovery.cpp downloader.cpp discovery.cpp
kded_proxyscout_la_LDFLAGS = $(all_libraries) -module -avoid-version kded_proxyscout_la_LDFLAGS = $(all_libraries) -module -avoid-version
kded_proxyscout_la_LIBADD = $(LIB_KIO) $(top_builddir)/kjs/libkjs.la $(LIB_KDED) kded_proxyscout_la_LIBADD = $(LIB_KIO) $(top_builddir)/kjs/libkjs.la $(LIB_KDED) $(LIB_QT) \
$(top_builddir)/dcop/libDCOP.la $(top_builddir)/kded/libkdeinit_kded.la \
$(LIB_KDECORE) $(LIBRESOLV)
kpac_dhcp_helper_SOURCES = kpac_dhcp_helper.c kpac_dhcp_helper_SOURCES = kpac_dhcp_helper.c
kpac_dhcp_helper_CFLAGS = $(KDE_USE_FPIE) kpac_dhcp_helper_CFLAGS = $(KDE_USE_FPIE)

@ -21,7 +21,7 @@ INCLUDES= -I$(srcdir)/.. -I$(top_srcdir) $(SSL_INCLUDES) -I$(top_srcdir)/kio/kss
kde_module_LTLIBRARIES = kded_kssld.la kde_module_LTLIBRARIES = kded_kssld.la
kded_kssld_la_LDFLAGS = $(all_libraries) -module -avoid-version kded_kssld_la_LDFLAGS = $(all_libraries) -module -avoid-version
kded_kssld_la_LIBADD = $(LIB_KIO) $(LIB_KDED) kded_kssld_la_LIBADD = $(LIB_KIO) $(LIB_KDED) $(LIB_QT) $(top_builddir)/dcop/libDCOP.la $(top_builddir)/kded/libkdeinit_kded.la $(LIB_KDECORE)
kded_kssld_la_SOURCES = kssld.cpp kssld.skel kded_kssld_la_SOURCES = kssld.cpp kssld.skel
METASOURCES = AUTO METASOURCES = AUTO

@ -21,7 +21,7 @@ INCLUDES= -I$(srcdir)/.. -I$(top_srcdir) -I$(top_srcdir)/kwallet/backend -I$(top
kde_module_LTLIBRARIES = kded_kwalletd.la kde_module_LTLIBRARIES = kded_kwalletd.la
kded_kwalletd_la_LDFLAGS = $(all_libraries) -module -avoid-version kded_kwalletd_la_LDFLAGS = $(all_libraries) -module -avoid-version
kded_kwalletd_la_LIBADD = $(LIB_KIO) ../../../kwallet/backend/libkwalletbackend.la ../../../kwallet/client/libkwalletclient.la $(LIB_KDED) kded_kwalletd_la_LIBADD = $(LIB_KIO) ../../../kwallet/backend/libkwalletbackend.la ../../../kwallet/client/libkwalletclient.la $(LIB_KDED) $(LIB_QT) $(top_builddir)/dcop/libDCOP.la $(LIB_KDECORE) $(LIB_KDEUI) $(top_builddir)/kded/libkdeinit_kded.la
kded_kwalletd_la_SOURCES = kwalletd.cpp kwalletd.skel ktimeout.cpp kwalletwizard.ui kbetterthankdialogbase.ui kded_kwalletd_la_SOURCES = kwalletd.cpp kwalletd.skel ktimeout.cpp kwalletwizard.ui kbetterthankdialogbase.ui
METASOURCES = AUTO METASOURCES = AUTO

@ -829,6 +829,12 @@ bool KWalletD::removeFolder(int handle, const QString& f) {
if ((b = getWallet(friendlyDCOPPeerName(), handle))) { if ((b = getWallet(friendlyDCOPPeerName(), handle))) {
bool rc = b->removeFolder(f); bool rc = b->removeFolder(f);
// write changes to disk immediately
QByteArray p;
QString wallet = b->walletName();
p.duplicate(_passwords[wallet].data(), _passwords[wallet].length());
b->sync(p);
p.fill(0);
QByteArray data; QByteArray data;
QDataStream ds(data, IO_WriteOnly); QDataStream ds(data, IO_WriteOnly);
ds << b->walletName(); ds << b->walletName();
@ -845,6 +851,12 @@ bool KWalletD::createFolder(int handle, const QString& f) {
if ((b = getWallet(friendlyDCOPPeerName(), handle))) { if ((b = getWallet(friendlyDCOPPeerName(), handle))) {
bool rc = b->createFolder(f); bool rc = b->createFolder(f);
// write changes to disk immediately
QByteArray p;
QString wallet = b->walletName();
p.duplicate(_passwords[wallet].data(), _passwords[wallet].length());
b->sync(p);
p.fill(0);
QByteArray data; QByteArray data;
QDataStream ds(data, IO_WriteOnly); QDataStream ds(data, IO_WriteOnly);
ds << b->walletName(); ds << b->walletName();
@ -987,6 +999,12 @@ int KWalletD::writeMap(int handle, const QString& folder, const QString& key, co
e.setValue(value); e.setValue(value);
e.setType(KWallet::Wallet::Map); e.setType(KWallet::Wallet::Map);
b->writeEntry(&e); b->writeEntry(&e);
// write changes to disk immediately
QByteArray p;
QString wallet = b->walletName();
p.duplicate(_passwords[wallet].data(), _passwords[wallet].length());
b->sync(p);
p.fill(0);
emitFolderUpdated(b->walletName(), folder); emitFolderUpdated(b->walletName(), folder);
return 0; return 0;
} }
@ -1005,6 +1023,12 @@ int KWalletD::writeEntry(int handle, const QString& folder, const QString& key,
e.setValue(value); e.setValue(value);
e.setType(KWallet::Wallet::EntryType(entryType)); e.setType(KWallet::Wallet::EntryType(entryType));
b->writeEntry(&e); b->writeEntry(&e);
// write changes to disk immediately
QByteArray p;
QString wallet = b->walletName();
p.duplicate(_passwords[wallet].data(), _passwords[wallet].length());
b->sync(p);
p.fill(0);
emitFolderUpdated(b->walletName(), folder); emitFolderUpdated(b->walletName(), folder);
return 0; return 0;
} }
@ -1023,6 +1047,12 @@ int KWalletD::writeEntry(int handle, const QString& folder, const QString& key,
e.setValue(value); e.setValue(value);
e.setType(KWallet::Wallet::Stream); e.setType(KWallet::Wallet::Stream);
b->writeEntry(&e); b->writeEntry(&e);
// write changes to disk immediately
QByteArray p;
QString wallet = b->walletName();
p.duplicate(_passwords[wallet].data(), _passwords[wallet].length());
b->sync(p);
p.fill(0);
emitFolderUpdated(b->walletName(), folder); emitFolderUpdated(b->walletName(), folder);
return 0; return 0;
} }
@ -1041,6 +1071,12 @@ int KWalletD::writePassword(int handle, const QString& folder, const QString& ke
e.setValue(value); e.setValue(value);
e.setType(KWallet::Wallet::Password); e.setType(KWallet::Wallet::Password);
b->writeEntry(&e); b->writeEntry(&e);
// write changes to disk immediately
QByteArray p;
QString wallet = b->walletName();
p.duplicate(_passwords[wallet].data(), _passwords[wallet].length());
b->sync(p);
p.fill(0);
emitFolderUpdated(b->walletName(), folder); emitFolderUpdated(b->walletName(), folder);
return 0; return 0;
} }
@ -1090,6 +1126,12 @@ int KWalletD::removeEntry(int handle, const QString& folder, const QString& key)
} }
b->setFolder(folder); b->setFolder(folder);
bool rc = b->removeEntry(key); bool rc = b->removeEntry(key);
// write changes to disk immediately
QByteArray p;
QString wallet = b->walletName();
p.duplicate(_passwords[wallet].data(), _passwords[wallet].length());
b->sync(p);
p.fill(0);
emitFolderUpdated(b->walletName(), folder); emitFolderUpdated(b->walletName(), folder);
return rc ? 0 : -3; return rc ? 0 : -3;
} }
@ -1183,6 +1225,12 @@ int KWalletD::renameEntry(int handle, const QString& folder, const QString& oldN
if ((b = getWallet(friendlyDCOPPeerName(), handle))) { if ((b = getWallet(friendlyDCOPPeerName(), handle))) {
b->setFolder(folder); b->setFolder(folder);
int rc = b->renameEntry(oldName, newName); int rc = b->renameEntry(oldName, newName);
// write changes to disk immediately
QByteArray p;
QString wallet = b->walletName();
p.duplicate(_passwords[wallet].data(), _passwords[wallet].length());
b->sync(p);
p.fill(0);
emitFolderUpdated(b->walletName(), folder); emitFolderUpdated(b->walletName(), folder);
return rc; return rc;
} }

@ -4,7 +4,7 @@ METASOURCES = AUTO
kde_module_LTLIBRARIES = kbzip2filter.la kde_module_LTLIBRARIES = kbzip2filter.la
kbzip2filter_la_SOURCES = kbzip2filter.cpp kbzip2filter_la_SOURCES = kbzip2filter.cpp
kbzip2filter_la_LIBADD = $(LIB_KIO) $(LIBBZ2) kbzip2filter_la_LIBADD = $(LIB_KIO) $(LIBBZ2) $(LIB_QT) $(LIB_KDECORE)
kbzip2filter_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN) kbzip2filter_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN)
kde_services_DATA = kbzip2filter.desktop kde_services_DATA = kbzip2filter.desktop

@ -9,7 +9,7 @@ INCLUDES = $(all_includes)
kde_module_LTLIBRARIES = kio_file.la kde_module_LTLIBRARIES = kio_file.la
kio_file_la_SOURCES = file.cc kio_file_la_SOURCES = file.cc
kio_file_la_LIBADD = $(LIB_KIO) kio_file_la_LIBADD = $(LIB_KIO) $(LIB_QT) $(LIB_KDECORE) $(ACL_LIBS)
kio_file_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN) kio_file_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN)
noinst_HEADERS = file.h noinst_HEADERS = file.h

@ -1234,8 +1234,13 @@ void FileProtocol::listDir( const KURL& url)
directories we keep as active directory. And directories we keep as active directory. And
as the slave runs in the background, it's hard as the slave runs in the background, it's hard
to see for the user what the problem would be */ to see for the user what the problem would be */
#if !defined(PATH_MAX) && defined(__GLIBC__)
char *path_buffer;
path_buffer = getcwd(NULL, 0);
#else
char path_buffer[PATH_MAX]; char path_buffer[PATH_MAX];
(void) getcwd(path_buffer, PATH_MAX - 1); (void) getcwd(path_buffer, PATH_MAX - 1);
#endif
if ( chdir( _path.data() ) ) { if ( chdir( _path.data() ) ) {
if (errno == EACCES) if (errno == EACCES)
error(ERR_ACCESS_DENIED, _path); error(ERR_ACCESS_DENIED, _path);
@ -1261,6 +1266,9 @@ void FileProtocol::listDir( const KURL& url)
kdDebug(7101) << "============= COMPLETED LIST ============" << endl; kdDebug(7101) << "============= COMPLETED LIST ============" << endl;
chdir(path_buffer); chdir(path_buffer);
#if !defined(PATH_MAX) && defined(__GLIBC__)
free(path_buffer);
#endif
finished(); finished();
} }

@ -5,7 +5,7 @@ INCLUDES= $(all_includes)
kde_module_LTLIBRARIES = kio_ftp.la kde_module_LTLIBRARIES = kio_ftp.la
kio_ftp_la_SOURCES = ftp.cc kio_ftp_la_SOURCES = ftp.cc
kio_ftp_la_LIBADD = $(LIB_KIO) kio_ftp_la_LIBADD = $(LIB_KIO) $(LIB_QT) $(LIB_KDECORE)
kio_ftp_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN) kio_ftp_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN)
noinst_HEADERS = ftp.h noinst_HEADERS = ftp.h

@ -5,7 +5,7 @@ METASOURCES = AUTO
kde_module_LTLIBRARIES = kgzipfilter.la kde_module_LTLIBRARIES = kgzipfilter.la
kgzipfilter_la_SOURCES = kgzipfilter.cpp kgzipfilter_la_SOURCES = kgzipfilter.cpp
kgzipfilter_la_LIBADD = $(LIB_KIO) $(LIBZ) kgzipfilter_la_LIBADD = $(LIB_KIO) $(LIBZ) $(LIB_QT) $(LIB_KDECORE)
kgzipfilter_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN) kgzipfilter_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN)
kde_services_DATA = kgzipfilter.desktop kde_services_DATA = kgzipfilter.desktop

@ -15,11 +15,11 @@ kde_module_LTLIBRARIES = kio_http.la
kio_http_la_SOURCES = http.cc kio_http_la_SOURCES = http.cc
kio_http_la_METASOURCES = AUTO kio_http_la_METASOURCES = AUTO
kio_http_la_LIBADD = $(LIB_KIO) $(top_builddir)/kio/httpfilter/libhttpfilter.la $(top_builddir)/kio/misc/kntlm/libkntlm.la kio_http_la_LIBADD = $(LIB_KIO) $(top_builddir)/kio/httpfilter/libhttpfilter.la $(top_builddir)/kio/misc/kntlm/libkntlm.la $(LIB_QT) $(LIB_KDECORE) $(LIBZ) $(top_builddir)/dcop/libDCOP.la
kio_http_la_LDFLAGS = $(all_libraries) $(GSSAPI_RPATH) -module $(KDE_PLUGIN) $(GSSAPI_LIBS) kio_http_la_LDFLAGS = $(all_libraries) $(GSSAPI_RPATH) -module $(KDE_PLUGIN) -lgssapi_krb5
kio_http_cache_cleaner_la_SOURCES = http_cache_cleaner.cpp kio_http_cache_cleaner_la_SOURCES = http_cache_cleaner.cpp
kio_http_cache_cleaner_la_LIBADD = $(LIB_KIO) kio_http_cache_cleaner_la_LIBADD = $(LIB_KIO) $(LIB_QT) $(LIB_KDECORE) $(top_builddir)/dcop/libDCOP.la
kio_http_cache_cleaner_la_LDFLAGS = -module -avoid-version kio_http_cache_cleaner_la_LDFLAGS = -module -avoid-version
noinst_HEADERS = http.h noinst_HEADERS = http.h

@ -13,12 +13,12 @@ kde_module_LTLIBRARIES = kded_kcookiejar.la
kcookiejar_la_SOURCES = main.cpp kcookiejar_la_SOURCES = main.cpp
METASOURCES = AUTO METASOURCES = AUTO
kcookiejar_la_LDFLAGS = $(all_libraries) -module -avoid-version kcookiejar_la_LDFLAGS = $(all_libraries) -module -avoid-version
kcookiejar_la_LIBADD = $(LIB_KDECORE) kcookiejar_la_LIBADD = $(LIB_KDECORE) $(LIB_QT) $(top_builddir)/dcop/libDCOP.la
kded_kcookiejar_la_SOURCES = kcookiejar.cpp kcookieserver.cpp \ kded_kcookiejar_la_SOURCES = kcookiejar.cpp kcookieserver.cpp \
kcookieserver.skel kcookiewin.cpp kcookieserver.skel kcookiewin.cpp
kded_kcookiejar_la_LDFLAGS = $(all_libraries) -module -avoid-version kded_kcookiejar_la_LDFLAGS = $(all_libraries) -module -avoid-version
kded_kcookiejar_la_LIBADD = $(LIB_KIO) $(LIB_KDED) kded_kcookiejar_la_LIBADD = $(LIB_KDED) $(LIB_QT) $(top_builddir)/dcop/libDCOP.la $(LIB_KDECORE) $(LIB_X11) $(LIB_KDEUI) $(top_builddir)/kded/libkdeinit_kded.la
kded_DATA = kcookiejar.desktop kded_DATA = kcookiejar.desktop
kdeddir = $(kde_servicesdir)/kded kdeddir = $(kde_servicesdir)/kded

@ -8,7 +8,7 @@ METASOURCES = AUTO
kde_module_LTLIBRARIES = kio_metainfo.la kde_module_LTLIBRARIES = kio_metainfo.la
kio_metainfo_la_SOURCES = metainfo.cpp kio_metainfo_la_SOURCES = metainfo.cpp
kio_metainfo_la_LIBADD = $(LIB_KIO) kio_metainfo_la_LIBADD = $(LIB_KIO) $(LIB_QT) $(LIB_KDECORE)
kio_metainfo_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN) kio_metainfo_la_LDFLAGS = $(all_libraries) -module $(KDE_PLUGIN)
noinst_HEADERS = metainfo.h noinst_HEADERS = metainfo.h

@ -52,10 +52,10 @@ AC_DEFUN([AC_CHECK_PCREPOSIX],
KDE_FIND_PATH(pcre-config, PCRE_CONFIG, [${exec_prefix}/bin ${prefix}/bin], [PCRE_CONFIG="" ]) KDE_FIND_PATH(pcre-config, PCRE_CONFIG, [${exec_prefix}/bin ${prefix}/bin], [PCRE_CONFIG="" ])
if test -n "$PCRE_CONFIG" && $PCRE_CONFIG --libs >/dev/null 2>&1; then if test -n "$PCRE_CONFIG" && $PCRE_CONFIG --libs >/dev/null 2>&1; then
LIBPCRE=`$PCRE_CONFIG --libs-posix | sed -e "s,-L/usr/lib ,,"` LIBPCRE=`$PCRE_CONFIG --libs-posix | sed -e "s,-L/usr/lib ,," -e "s,[\b-].\+pcreposix[^[:space:]]*\b,,"`
PCRECFLAGS=`$PCRE_CONFIG --cflags` PCRECFLAGS=`$PCRE_CONFIG --cflags`
else else
LIBPCRE="-lpcre -lpcreposix" LIBPCRE="-lpcre"
PCRECFLAGS= PCRECFLAGS=
fi fi
AC_CACHE_VAL(ac_cv_have_pcreposix, [ AC_CACHE_VAL(ac_cv_have_pcreposix, [

@ -169,22 +169,17 @@
* the result overflows to +-Infinity or underflows to 0. * the result overflows to +-Infinity or underflows to 0.
*/ */
// Put this before anything else that may import a definition of CONST. CONST from grammar.cpp conflicts with this. #include "dtoa.h"
#ifdef KDE_USE_FINAL
#undef CONST
#endif
#include <config.h> #include <config.h>
#include "stdlib.h" #include "global.h"
#ifdef WORDS_BIGENDIAN // #if PLATFORM(BIG_ENDIAN)
#define IEEE_MC68k // #define IEEE_MC68k
#else // #else
#define IEEE_8087 #define IEEE_8087
#endif // #endif
#define INFNAN_CHECK #define INFNAN_CHECK
#include "dtoa.h"
@ -196,22 +191,19 @@ typedef unsigned Long ULong;
#endif #endif
#ifdef DEBUG #ifdef DEBUG
#include "stdio.h" #include <stdio.h>
#define Bug(x) {fprintf(stderr, "%s\n", x); exit(1);} #define Bug(x) {fprintf(stderr, "%s\n", x); exit(1);}
#endif #endif
#include "string.h" #include <stdlib.h>
#include <string.h>
#ifdef USE_LOCALE #ifdef USE_LOCALE
#include "locale.h" #include <locale.h>
#endif #endif
#ifdef MALLOC #ifdef MALLOC
#ifdef KR_headers
extern char *MALLOC();
#else
extern void *MALLOC(size_t); extern void *MALLOC(size_t);
#endif
#else #else
#define MALLOC malloc #define MALLOC malloc
#endif #endif
@ -233,7 +225,7 @@ static double private_mem[PRIVATE_mem], *pmem_next = private_mem;
#define IEEE_Arith #define IEEE_Arith
#endif #endif
#include "errno.h" #include <errno.h>
#ifdef Bad_float_h #ifdef Bad_float_h
@ -260,25 +252,29 @@ static double private_mem[PRIVATE_mem], *pmem_next = private_mem;
#define DBL_MAX 1.7014118346046923e+38 #define DBL_MAX 1.7014118346046923e+38
#endif #endif
#ifndef LONG_MAX
#define LONG_MAX 2147483647
#endif
#else /* ifndef Bad_float_h */ #else /* ifndef Bad_float_h */
#include "float.h" #include <float.h>
#endif /* Bad_float_h */ #endif /* Bad_float_h */
#ifndef __MATH_H__ #ifndef __MATH_H__
#include "math.h" #include <math.h>
#endif #endif
#define strtod kjs_strtod
#define dtoa kjs_dtoa
#define freedtoa kjs_freedtoa
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif
#ifndef CONST // #ifndef CONST
#ifdef KR_headers
#define CONST /* blank */
#else
#define CONST const #define CONST const
#endif // #endif
#endif
#if defined(IEEE_8087) + defined(IEEE_MC68k) + defined(VAX) + defined(IBM) != 1 #if defined(IEEE_8087) + defined(IEEE_MC68k) + defined(VAX) + defined(IBM) != 1
Exactly one of IEEE_8087, IEEE_MC68k, VAX, or IBM should be defined. Exactly one of IEEE_8087, IEEE_MC68k, VAX, or IBM should be defined.
@ -286,37 +282,19 @@ Exactly one of IEEE_8087, IEEE_MC68k, VAX, or IBM should be defined.
typedef union { double d; ULong L[2]; } U; typedef union { double d; ULong L[2]; } U;
#ifdef YES_ALIAS #define dval(x) (x).d
#define dval(x) x
#ifdef IEEE_8087 #ifdef IEEE_8087
#define word0(x) ((ULong *)&x)[1] #define word0(x) (x).L[1]
#define word1(x) ((ULong *)&x)[0] #define word1(x) (x).L[0]
#else #else
#define word0(x) ((ULong *)&x)[0] #define word0(x) (x).L[0]
#define word1(x) ((ULong *)&x)[1] #define word1(x) (x).L[1]
#endif
#else
#ifdef IEEE_8087
#define word0(x) ((U*)&x)->L[1]
#define word1(x) ((U*)&x)->L[0]
#else
#define word0(x) ((U*)&x)->L[0]
#define word1(x) ((U*)&x)->L[1]
#endif
#define dval(x) ((U*)&x)->d
#endif #endif
/* The following definition of Storeinc is appropriate for MIPS processors. /* The following definition of Storeinc is appropriate for MIPS processors.
* An alternative that might be better on some machines is * An alternative that might be better on some machines is
* #define Storeinc(a,b,c) (*a++ = b << 16 | c & 0xffff)
*/ */
#if defined(IEEE_8087) + defined(VAX) #define Storeinc(a,b,c) (*a++ = b << 16 | c & 0xffff)
#define Storeinc(a,b,c) (((unsigned short *)a)[1] = (unsigned short)b, \
((unsigned short *)a)[0] = (unsigned short)c, a++)
#else
#define Storeinc(a,b,c) (((unsigned short *)a)[0] = (unsigned short)b, \
((unsigned short *)a)[1] = (unsigned short)c, a++)
#endif
/* #define P DBL_MANT_DIG */ /* #define P DBL_MANT_DIG */
/* Ten_pmax = floor(P*log(2)/log(5)) */ /* Ten_pmax = floor(P*log(2)/log(5)) */
@ -440,11 +418,7 @@ typedef union { double d; ULong L[2]; } U;
#ifdef RND_PRODQUOT #ifdef RND_PRODQUOT
#define rounded_product(a,b) a = rnd_prod(a, b) #define rounded_product(a,b) a = rnd_prod(a, b)
#define rounded_quotient(a,b) a = rnd_quot(a, b) #define rounded_quotient(a,b) a = rnd_quot(a, b)
#ifdef KR_headers
extern double rnd_prod(), rnd_quot();
#else
extern double rnd_prod(double, double), rnd_quot(double, double); extern double rnd_prod(double, double), rnd_quot(double, double);
#endif
#else #else
#define rounded_product(a,b) a *= b #define rounded_product(a,b) a *= b
#define rounded_quotient(a,b) a /= b #define rounded_quotient(a,b) a /= b
@ -457,11 +431,7 @@ extern double rnd_prod(double, double), rnd_quot(double, double);
#define Pack_32 #define Pack_32
#endif #endif
#ifdef KR_headers
#define FFFFFFFF ((((unsigned long)0xffff)<<16)|(unsigned long)0xffff)
#else
#define FFFFFFFF 0xffffffffUL #define FFFFFFFF 0xffffffffUL
#endif
#ifdef NO_LONG_LONG #ifdef NO_LONG_LONG
#undef ULLong #undef ULLong
@ -502,11 +472,7 @@ Bigint {
static Bigint * static Bigint *
Balloc Balloc
#ifdef KR_headers
(k) int k;
#else
(int k) (int k)
#endif
{ {
int x; int x;
Bigint *rv; Bigint *rv;
@ -525,7 +491,7 @@ Balloc
#else #else
len = (sizeof(Bigint) + (x-1)*sizeof(ULong) + sizeof(double) - 1) len = (sizeof(Bigint) + (x-1)*sizeof(ULong) + sizeof(double) - 1)
/sizeof(double); /sizeof(double);
if (pmem_next - private_mem + len <= PRIVATE_mem) { if (pmem_next - private_mem + len <= (unsigned)PRIVATE_mem) {
rv = (Bigint*)pmem_next; rv = (Bigint*)pmem_next;
pmem_next += len; pmem_next += len;
} }
@ -542,11 +508,7 @@ Balloc
static void static void
Bfree Bfree
#ifdef KR_headers
(v) Bigint *v;
#else
(Bigint *v) (Bigint *v)
#endif
{ {
if (v) { if (v) {
ACQUIRE_DTOA_LOCK(0); ACQUIRE_DTOA_LOCK(0);
@ -561,11 +523,7 @@ y->wds*sizeof(Long) + 2*sizeof(int))
static Bigint * static Bigint *
multadd multadd
#ifdef KR_headers
(b, m, a) Bigint *b; int m, a;
#else
(Bigint *b, int m, int a) /* multiply by m and add a */ (Bigint *b, int m, int a) /* multiply by m and add a */
#endif
{ {
int i, wds; int i, wds;
#ifdef ULLong #ifdef ULLong
@ -587,7 +545,7 @@ multadd
#ifdef ULLong #ifdef ULLong
y = *x * (ULLong)m + carry; y = *x * (ULLong)m + carry;
carry = y >> 32; carry = y >> 32;
*x++ = y & FFFFFFFF; *x++ = (ULong)y & FFFFFFFF;
#else #else
#ifdef Pack_32 #ifdef Pack_32
xi = *x; xi = *x;
@ -610,7 +568,7 @@ multadd
Bfree(b); Bfree(b);
b = b1; b = b1;
} }
b->x[wds++] = carry; b->x[wds++] = (ULong)carry;
b->wds = wds; b->wds = wds;
} }
return b; return b;
@ -618,11 +576,7 @@ multadd
static Bigint * static Bigint *
s2b s2b
#ifdef KR_headers
(s, nd0, nd, y9) CONST char *s; int nd0, nd; ULong y9;
#else
(CONST char *s, int nd0, int nd, ULong y9) (CONST char *s, int nd0, int nd, ULong y9)
#endif
{ {
Bigint *b; Bigint *b;
int i, k; int i, k;
@ -656,11 +610,7 @@ s2b
static int static int
hi0bits hi0bits
#ifdef KR_headers
(x) register ULong x;
#else
(register ULong x) (register ULong x)
#endif
{ {
register int k = 0; register int k = 0;
@ -690,11 +640,7 @@ hi0bits
static int static int
lo0bits lo0bits
#ifdef KR_headers
(y) ULong *y;
#else
(ULong *y) (ULong *y)
#endif
{ {
register int k; register int k;
register ULong x = *y; register ULong x = *y;
@ -738,11 +684,7 @@ lo0bits
static Bigint * static Bigint *
i2b i2b
#ifdef KR_headers
(i) int i;
#else
(int i) (int i)
#endif
{ {
Bigint *b; Bigint *b;
@ -754,11 +696,7 @@ i2b
static Bigint * static Bigint *
mult mult
#ifdef KR_headers
(a, b) Bigint *a, *b;
#else
(Bigint *a, Bigint *b) (Bigint *a, Bigint *b)
#endif
{ {
Bigint *c; Bigint *c;
int k, wa, wb, wc; int k, wa, wb, wc;
@ -801,10 +739,10 @@ mult
do { do {
z = *x++ * (ULLong)y + *xc + carry; z = *x++ * (ULLong)y + *xc + carry;
carry = z >> 32; carry = z >> 32;
*xc++ = z & FFFFFFFF; *xc++ = (ULong)z & FFFFFFFF;
} }
while(x < xae); while(x < xae);
*xc = carry; *xc = (ULong)carry;
} }
} }
#else #else
@ -866,11 +804,7 @@ mult
static Bigint * static Bigint *
pow5mult pow5mult
#ifdef KR_headers
(b, k) Bigint *b; int k;
#else
(Bigint *b, int k) (Bigint *b, int k)
#endif
{ {
Bigint *b1, *p5, *p51; Bigint *b1, *p5, *p51;
int i; int i;
@ -923,11 +857,7 @@ pow5mult
static Bigint * static Bigint *
lshift lshift
#ifdef KR_headers
(b, k) Bigint *b; int k;
#else
(Bigint *b, int k) (Bigint *b, int k)
#endif
{ {
int i, k1, n, n1; int i, k1, n, n1;
Bigint *b1; Bigint *b1;
@ -983,11 +913,7 @@ lshift
static int static int
cmp cmp
#ifdef KR_headers
(a, b) Bigint *a, *b;
#else
(Bigint *a, Bigint *b) (Bigint *a, Bigint *b)
#endif
{ {
ULong *xa, *xa0, *xb, *xb0; ULong *xa, *xa0, *xb, *xb0;
int i, j; int i, j;
@ -1017,11 +943,7 @@ cmp
static Bigint * static Bigint *
diff diff
#ifdef KR_headers
(a, b) Bigint *a, *b;
#else
(Bigint *a, Bigint *b) (Bigint *a, Bigint *b)
#endif
{ {
Bigint *c; Bigint *c;
int i, wa, wb; int i, wa, wb;
@ -1064,13 +986,13 @@ diff
do { do {
y = (ULLong)*xa++ - *xb++ - borrow; y = (ULLong)*xa++ - *xb++ - borrow;
borrow = y >> 32 & (ULong)1; borrow = y >> 32 & (ULong)1;
*xc++ = y & FFFFFFFF; *xc++ = (ULong)y & FFFFFFFF;
} }
while(xb < xbe); while(xb < xbe);
while(xa < xae) { while(xa < xae) {
y = *xa++ - borrow; y = *xa++ - borrow;
borrow = y >> 32 & (ULong)1; borrow = y >> 32 & (ULong)1;
*xc++ = y & FFFFFFFF; *xc++ = (ULong)y & FFFFFFFF;
} }
#else #else
#ifdef Pack_32 #ifdef Pack_32
@ -1111,15 +1033,12 @@ diff
static double static double
ulp ulp
#ifdef KR_headers (double dx)
(x) double x;
#else
(double x)
#endif
{ {
register Long L; register Long L;
double a; U x, a;
dval(x) = dx;
L = (word0(x) & Exp_mask) - (P-1)*Exp_msk1; L = (word0(x) & Exp_mask) - (P-1)*Exp_msk1;
#ifndef Avoid_Underflow #ifndef Avoid_Underflow
#ifndef Sudden_Underflow #ifndef Sudden_Underflow
@ -1153,15 +1072,11 @@ ulp
static double static double
b2d b2d
#ifdef KR_headers
(a, e) Bigint *a; int *e;
#else
(Bigint *a, int *e) (Bigint *a, int *e)
#endif
{ {
ULong *xa, *xa0, w, y, z; ULong *xa, *xa0, w, y, z;
int k; int k;
double d; U d;
#ifdef VAX #ifdef VAX
ULong d0, d1; ULong d0, d1;
#else #else
@ -1223,12 +1138,9 @@ b2d
static Bigint * static Bigint *
d2b d2b
#ifdef KR_headers (double dd, int *e, int *bits)
(d, e, bits) double d; int *e, *bits;
#else
(double d, int *e, int *bits)
#endif
{ {
U d;
Bigint *b; Bigint *b;
int de, k; int de, k;
ULong *x, y, z; ULong *x, y, z;
@ -1237,6 +1149,9 @@ d2b
#endif #endif
#ifdef VAX #ifdef VAX
ULong d0, d1; ULong d0, d1;
#endif
dval(d) = dd;
#ifdef VAX
d0 = word0(d) >> 16 | word0(d) << 16; d0 = word0(d) >> 16 | word0(d) << 16;
d1 = word1(d) >> 16 | word1(d) << 16; d1 = word1(d) >> 16 | word1(d) << 16;
#else #else
@ -1361,13 +1276,9 @@ d2b
static double static double
ratio ratio
#ifdef KR_headers
(a, b) Bigint *a, *b;
#else
(Bigint *a, Bigint *b) (Bigint *a, Bigint *b)
#endif
{ {
double da, db; U da, db;
int k, ka, kb; int k, ka, kb;
dval(da) = b2d(a, &ka); dval(da) = b2d(a, &ka);
@ -1453,11 +1364,7 @@ static CONST double tinytens[] = { 1e-16, 1e-32 };
static int static int
match match
#ifdef KR_headers
(sp, t) char **sp, *t;
#else
(CONST char **sp, CONST char *t) (CONST char **sp, CONST char *t)
#endif
{ {
int c, d; int c, d;
CONST char *s = *sp; CONST char *s = *sp;
@ -1475,11 +1382,7 @@ match
#ifndef No_Hex_NaN #ifndef No_Hex_NaN
static void static void
hexnan hexnan
#ifdef KR_headers (U *rvp, CONST char **sp)
(rvp, sp) double *rvp; CONST char **sp;
#else
(double *rvp, CONST char **sp)
#endif
{ {
ULong c, x[2]; ULong c, x[2];
CONST char *s; CONST char *s;
@ -1528,12 +1431,8 @@ hexnan
#endif /* INFNAN_CHECK */ #endif /* INFNAN_CHECK */
double double
kjs_strtod strtod
#ifdef KR_headers
(s00, se) CONST char *s00; char **se;
#else
(CONST char *s00, char **se) (CONST char *s00, char **se)
#endif
{ {
#ifdef Avoid_Underflow #ifdef Avoid_Underflow
int scale; int scale;
@ -1541,7 +1440,8 @@ kjs_strtod
int bb2, bb5, bbe, bd2, bd5, bbbits, bs2, c, dsign, int bb2, bb5, bbe, bd2, bd5, bbbits, bs2, c, dsign,
e, e1, esign, i, j, k, nd, nd0, nf, nz, nz0, sign; e, e1, esign, i, j, k, nd, nd0, nf, nz, nz0, sign;
CONST char *s, *s0, *s1; CONST char *s, *s0, *s1;
double aadj, aadj1, adj, rv, rv0; double aadj, aadj1, adj;
U aadj2, rv, rv0;
Long L; Long L;
ULong y, z; ULong y, z;
Bigint *bb = NULL, *bb1 = NULL, *bd = NULL, *bd0 = NULL, *bs = NULL, *delta = NULL; Bigint *bb = NULL, *bb1 = NULL, *bd = NULL, *bd0 = NULL, *bs = NULL, *delta = NULL;
@ -2302,7 +2202,9 @@ kjs_strtod
aadj = z; aadj = z;
aadj1 = dsign ? aadj : -aadj; aadj1 = dsign ? aadj : -aadj;
} }
word0(aadj1) += (2*P+1)*Exp_msk1 - y; dval(aadj2) = aadj1;
word0(aadj2) += (2*P+1)*Exp_msk1 - y;
aadj1 = dval(aadj2);
} }
adj = aadj1 * ulp(dval(rv)); adj = aadj1 * ulp(dval(rv));
dval(rv) += adj; dval(rv) += adj;
@ -2419,11 +2321,7 @@ kjs_strtod
static int static int
quorem quorem
#ifdef KR_headers
(b, S) Bigint *b, *S;
#else
(Bigint *b, Bigint *S) (Bigint *b, Bigint *S)
#endif
{ {
int n; int n;
ULong *bx, *bxe, q, *sx, *sxe; ULong *bx, *bxe, q, *sx, *sxe;
@ -2461,7 +2359,7 @@ quorem
carry = ys >> 32; carry = ys >> 32;
y = *bx - (ys & FFFFFFFF) - borrow; y = *bx - (ys & FFFFFFFF) - borrow;
borrow = y >> 32 & (ULong)1; borrow = y >> 32 & (ULong)1;
*bx++ = y & FFFFFFFF; *bx++ = (ULong)y & FFFFFFFF;
#else #else
#ifdef Pack_32 #ifdef Pack_32
si = *sx++; si = *sx++;
@ -2502,7 +2400,7 @@ quorem
carry = ys >> 32; carry = ys >> 32;
y = *bx - (ys & FFFFFFFF) - borrow; y = *bx - (ys & FFFFFFFF) - borrow;
borrow = y >> 32 & (ULong)1; borrow = y >> 32 & (ULong)1;
*bx++ = y & FFFFFFFF; *bx++ = (ULong)y & FFFFFFFF;
#else #else
#ifdef Pack_32 #ifdef Pack_32
si = *sx++; si = *sx++;
@ -2540,11 +2438,7 @@ quorem
#endif #endif
static char * static char *
#ifdef KR_headers
rv_alloc(i) int i;
#else
rv_alloc(int i) rv_alloc(int i)
#endif
{ {
int j, k, *r; int j, k, *r;
@ -2563,11 +2457,7 @@ rv_alloc(int i)
} }
static char * static char *
#ifdef KR_headers
nrv_alloc(s, rve, n) char *s, **rve; int n;
#else
nrv_alloc(CONST char *s, char **rve, int n) nrv_alloc(CONST char *s, char **rve, int n)
#endif
{ {
char *rv, *t; char *rv, *t;
@ -2585,11 +2475,7 @@ nrv_alloc(CONST char *s, char **rve, int n)
*/ */
void void
#ifdef KR_headers freedtoa(char *s)
kjs_freedtoa(s) char *s;
#else
kjs_freedtoa(char *s)
#endif
{ {
Bigint *b = (Bigint *)((int *)s - 1); Bigint *b = (Bigint *)((int *)s - 1);
b->maxwds = 1 << (b->k = *(int*)b); b->maxwds = 1 << (b->k = *(int*)b);
@ -2635,13 +2521,8 @@ kjs_freedtoa(char *s)
*/ */
char * char *
kjs_dtoa dtoa
#ifdef KR_headers (double dd, int mode, int ndigits, int *decpt, int *sign, char **rve)
(d, mode, ndigits, decpt, sign, rve)
double d; int mode, ndigits, *decpt, *sign; char **rve;
#else
(double d, int mode, int ndigits, int *decpt, int *sign, char **rve)
#endif
{ {
/* Arguments ndigits, decpt, sign are similar to those /* Arguments ndigits, decpt, sign are similar to those
of ecvt and fcvt; trailing zeros are suppressed from of ecvt and fcvt; trailing zeros are suppressed from
@ -2686,7 +2567,8 @@ kjs_dtoa
ULong x; ULong x;
#endif #endif
Bigint *b, *b1, *delta, *mlo = NULL, *mhi, *S; Bigint *b, *b1, *delta, *mlo = NULL, *mhi, *S;
double d2, ds, eps; U d, d2, eps;
double ds;
char *s, *s0; char *s, *s0;
#ifdef Honor_FLT_ROUNDS #ifdef Honor_FLT_ROUNDS
int rounding; int rounding;
@ -2697,11 +2579,12 @@ kjs_dtoa
#ifndef MULTIPLE_THREADS #ifndef MULTIPLE_THREADS
if (dtoa_result) { if (dtoa_result) {
kjs_freedtoa(dtoa_result); freedtoa(dtoa_result);
dtoa_result = 0; dtoa_result = 0;
} }
#endif #endif
dval(d) = dd;
if (word0(d) & Sign_bit) { if (word0(d) & Sign_bit) {
/* set sign for everything, including 0's and NaNs */ /* set sign for everything, including 0's and NaNs */
*sign = 1; *sign = 1;
@ -2966,7 +2849,8 @@ kjs_dtoa
if (dval(d) > 0.5 + dval(eps)) if (dval(d) > 0.5 + dval(eps))
goto bump_up; goto bump_up;
else if (dval(d) < 0.5 - dval(eps)) { else if (dval(d) < 0.5 - dval(eps)) {
while(*--s == '0'); while(*--s == '0')
;
s++; s++;
goto ret1; goto ret1;
} }
@ -3285,7 +3169,8 @@ kjs_dtoa
#ifdef Honor_FLT_ROUNDS #ifdef Honor_FLT_ROUNDS
trimzeros: trimzeros:
#endif #endif
while(*--s == '0'); while(*--s == '0')
;
s++; s++;
} }
ret: ret:

@ -4,7 +4,7 @@ INCLUDES = -I$(top_srcdir)/kmdi/res -I$(top_srcdir)/kutils -I$(top_srcdir) -I$(t
lib_LTLIBRARIES = libkmdi.la lib_LTLIBRARIES = libkmdi.la
libkmdi_la_LDFLAGS = $(all_libraries) -version-info 1:0 libkmdi_la_LDFLAGS = $(all_libraries) -version-info 1:0
libkmdi_la_LIBADD = $(LIB_KPARTS) $(top_builddir)/kutils/libkutils.la libkmdi_la_LIBADD = $(LIB_KPARTS) $(top_builddir)/kutils/libkutils.la $(LIB_KDEUI) $(LIB_QT) $(LIB_KDECORE) $(LIB_X11)
libkmdi_la_SOURCES = kmdichildarea.cpp kmdichildfrm.cpp kmdichildfrmcaption.cpp \ libkmdi_la_SOURCES = kmdichildarea.cpp kmdichildfrm.cpp kmdichildfrmcaption.cpp \
kmdichildview.cpp kmdimainfrm.cpp kmditaskbar.cpp kmdidockcontainer.cpp \ kmdichildview.cpp kmdimainfrm.cpp kmditaskbar.cpp kmdidockcontainer.cpp \

@ -2,7 +2,7 @@ INCLUDES = -I$(top_srcdir)/kutils -I$(top_srcdir) -I$(top_srcdir)/kmdi $(all_inc
lib_LTLIBRARIES = libkmdi2.la lib_LTLIBRARIES = libkmdi2.la
libkmdi2_la_LDFLAGS = $(all_libraries) -version-info 1:0 libkmdi2_la_LDFLAGS = $(all_libraries) -version-info 1:0
libkmdi2_la_LIBADD = $(LIB_KPARTS) $(top_builddir)/kutils/libkutils.la libkmdi2_la_LIBADD = $(LIB_KPARTS) $(top_builddir)/kutils/libkutils.la $(LIB_KDEUI) $(LIB_QT) $(LIB_KDECORE)
libkmdi2_la_SOURCES = mainwindow.cpp dockcontainer.cpp toolviewaccessor.cpp guiclient.cpp tabwidget.cpp libkmdi2_la_SOURCES = mainwindow.cpp dockcontainer.cpp toolviewaccessor.cpp guiclient.cpp tabwidget.cpp

@ -5,7 +5,7 @@ METASOURCES = AUTO
lib_LTLIBRARIES = libknewstuff.la lib_LTLIBRARIES = libknewstuff.la
libknewstuff_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -version-info 1:0 libknewstuff_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -version-info 1:0
libknewstuff_la_LIBADD = $(LIB_KIO) libknewstuff_la_LIBADD = $(LIB_KIO) $(LIB_QT) $(LIB_KDECORE) $(LIB_KDEUI)
libknewstuff_la_SOURCES = engine.cpp entry.cpp downloaddialog.cpp \ libknewstuff_la_SOURCES = engine.cpp entry.cpp downloaddialog.cpp \
uploaddialog.cpp providerdialog.cpp provider.cpp knewstuff.cpp \ uploaddialog.cpp providerdialog.cpp provider.cpp knewstuff.cpp \
knewstuffgeneric.cpp knewstuffbutton.cpp knewstuffsecure.cpp security.cpp knewstuffgeneric.cpp knewstuffbutton.cpp knewstuffsecure.cpp security.cpp

@ -5,7 +5,7 @@ AM_LDFLAGS = $(LDFLAGS_AS_NEEDED)
INCLUDES= -I$(srcdir)/../ -I$(top_srcdir)/kio/ -I$(top_srcdir)/libltdl \ INCLUDES= -I$(srcdir)/../ -I$(top_srcdir)/kio/ -I$(top_srcdir)/libltdl \
-I$(top_srcdir)/kfile $(all_includes) -I$(top_srcdir)/kfile $(all_includes)
libkparts_la_LDFLAGS = $(KDE_MT_LDFLAGS) -version-info 3:0:1 -no-undefined libkparts_la_LDFLAGS = $(KDE_MT_LDFLAGS) -version-info 3:0:1 -no-undefined
libkparts_la_LIBADD = $(LIB_KIO) libkparts_la_LIBADD = $(LIB_KIO) $(LIB_QT) $(LIB_KDEUI) $(LIB_KDECORE) $(top_builddir)/dcop/libDCOP.la
check-local: check-local:
(cd tests && $(MAKE) check ) (cd tests && $(MAKE) check )

@ -15,7 +15,7 @@ libkresources_la_SOURCES = resource.cpp \
configpage.cpp configpage.cpp
libkresources_la_LDFLAGS = $(all_libraries) -no-undefined -version-info 3:0:2 libkresources_la_LDFLAGS = $(all_libraries) -no-undefined -version-info 3:0:2
libkresources_la_LIBADD = $(LIB_KDEUI) $(LIB_KIO) libkresources_la_LIBADD = $(LIB_KDEUI) $(LIB_KIO) $(LIB_QT) $(top_builddir)/dcop/libDCOP.la $(LIB_KDECORE)
kresincludedir = $(includedir)/kresources kresincludedir = $(includedir)/kresources
kresinclude_HEADERS = resource.h \ kresinclude_HEADERS = resource.h \
@ -32,7 +32,7 @@ kde_module_LTLIBRARIES = kcm_kresources.la
kcm_kresources_la_SOURCES = kcmkresources.cpp kcm_kresources_la_SOURCES = kcmkresources.cpp
kcm_kresources_la_LDFLAGS = $(all_libraries) -module -avoid-version -no-undefined kcm_kresources_la_LDFLAGS = $(all_libraries) -module -avoid-version -no-undefined
kcm_kresources_la_LIBADD = libkresources.la kcm_kresources_la_LIBADD = libkresources.la $(LIB_QT) $(LIB_KDEUI) $(LIB_KDECORE)
check_PROGRAMS = testresources check_PROGRAMS = testresources

@ -17,7 +17,6 @@ libkspell2base_la_SOURCES = settings.cpp broker.cpp \
defaultdictionary.cpp defaultdictionary.cpp
libkspell2base_la_LDFLAGS = -no-undefined $(all_libraries) libkspell2base_la_LDFLAGS = -no-undefined $(all_libraries)
libkspell2base_la_LIBADD = $(LIB_KPARTS) ../kutils/libkutils.la
servicetype_DATA = kspellclient.desktop servicetype_DATA = kspellclient.desktop
servicetypedir = $(kde_servicetypesdir) servicetypedir = $(kde_servicetypesdir)

@ -11,7 +11,7 @@ kde_module_LTLIBRARIES = kspell_aspell.la
kspell_aspell_la_SOURCES = kspell_aspellclient.cpp kspell_aspelldict.cpp kspell_aspell_la_SOURCES = kspell_aspellclient.cpp kspell_aspelldict.cpp
kspell_aspell_la_LDFLAGS = -module -no-undefined $(KDE_PLUGIN) kspell_aspell_la_LDFLAGS = -module -no-undefined $(KDE_PLUGIN)
kspell_aspell_la_LIBADD = ../../ui/libkspell2.la -laspell kspell_aspell_la_LIBADD = ../../ui/libkspell2.la -laspell $(LIB_QT) $(LIB_KDECORE)
service_DATA = kspell_aspell.desktop service_DATA = kspell_aspell.desktop
servicedir = $(kde_servicesdir) servicedir = $(kde_servicesdir)

@ -11,7 +11,7 @@ kde_module_LTLIBRARIES = kspell_hspell.la
kspell_hspell_la_SOURCES = kspell_hspellclient.cpp kspell_hspelldict.cpp kspell_hspell_la_SOURCES = kspell_hspellclient.cpp kspell_hspelldict.cpp
kspell_hspell_la_LDFLAGS = -module -no-undefined $(KDE_PLUGIN) kspell_hspell_la_LDFLAGS = -module -no-undefined $(KDE_PLUGIN)
kspell_hspell_la_LIBADD = ../../ui/libkspell2.la -lhspell -lz kspell_hspell_la_LIBADD = ../../ui/libkspell2.la -lhspell -lz $(LIB_QT) $(LIB_KDECORE)
service_DATA = kspell_hspell.desktop service_DATA = kspell_hspell.desktop
servicedir = $(kde_servicesdir) servicedir = $(kde_servicesdir)

@ -18,7 +18,7 @@ kspell_ispell_la_SOURCES = kspell_ispellclient.cpp kspell_ispelldict.cpp \
ispell_checker.cpp ispell_checker.cpp
kspell_ispell_la_LDFLAGS = -module -no-undefined $(KDE_PLUGIN) kspell_ispell_la_LDFLAGS = -module -no-undefined $(KDE_PLUGIN)
kspell_ispell_la_LIBADD = ../../ui/libkspell2.la kspell_ispell_la_LIBADD = ../../ui/libkspell2.la $(LIB_QT) $(LIB_KDECORE)
service_DATA = kspell_ispell.desktop service_DATA = kspell_ispell.desktop
servicedir = $(kde_servicesdir) servicedir = $(kde_servicesdir)

@ -18,7 +18,7 @@ test_dialog_SOURCES = test_dialog.cpp
test_dialog_LDADD = ../ui/libkspell2.la $(LIB_KDECORE) test_dialog_LDADD = ../ui/libkspell2.la $(LIB_KDECORE)
test_highlighter_SOURCES = test_highlighter.cpp test_highlighter_SOURCES = test_highlighter.cpp
test_highlighter_LDADD = ../ui/libkspell2_noinst.la ../libkspell2base.la $(LIB_KDECORE) test_highlighter_LDADD = ../ui/libkspell2_noinst.la ../libkspell2base.la $(LIB_KDECORE) $(LIB_KPARTS) ../../kutils/libkutils.la
test_configdialog_SOURCES = test_configdialog.cpp test_configdialog_SOURCES = test_configdialog.cpp
test_configdialog_LDADD = ../ui/libkspell2_noinst.la ../libkspell2base.la $(LIB_KDECORE) test_configdialog_LDADD = ../ui/libkspell2_noinst.la ../libkspell2base.la $(LIB_KDECORE) $(LIB_KPARTS) ../../kutils/libkutils.la

@ -18,4 +18,4 @@ dialog.lo: kspell2ui.h
libkspell2_la_SOURCES = dialog.cpp libkspell2_la_SOURCES = dialog.cpp
libkspell2_la_LDFLAGS = -no-undefined -version-info 1:0:0 $(all_libraries) libkspell2_la_LDFLAGS = -no-undefined -version-info 1:0:0 $(all_libraries)
libkspell2_la_LIBADD = libkspell2_noinst.la ../libkspell2base.la libkspell2_la_LIBADD = libkspell2_noinst.la ../libkspell2base.la ../../kutils/libkutils.la $(LIB_QT) $(LIB_KDEUI) $(LIB_KDECORE) $(LIB_KFILE)

@ -24,6 +24,6 @@ INCLUDES = -I$(top_srcdir)/kdefx $(all_includes)
noinst_HEADERS = highcolor.h bitmaps.h noinst_HEADERS = highcolor.h bitmaps.h
kde_style_LTLIBRARIES = highcolor.la kde_style_LTLIBRARIES = highcolor.la
highcolor_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module highcolor_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module
highcolor_la_LIBADD = ../../kdefx/libkdefx.la highcolor_la_LIBADD = ../../kdefx/libkdefx.la $(LIB_QT)
highcolor_la_SOURCES = highcolor.cpp highcolor_la_SOURCES = highcolor.cpp
highcolor_la_METASOURCES = AUTO highcolor_la_METASOURCES = AUTO

@ -35,7 +35,7 @@ noinst_HEADERS = highcontrast.h
kde_style_LTLIBRARIES = highcontrast.la kde_style_LTLIBRARIES = highcontrast.la
highcontrast_la_SOURCES = highcontrast.cpp highcontrast_la_SOURCES = highcontrast.cpp
highcontrast_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module highcontrast_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module
highcontrast_la_LIBADD = ../../kdefx/libkdefx.la highcontrast_la_LIBADD = ../../kdefx/libkdefx.la $(LIB_QT)
highcontrast_la_METASOURCES = AUTO highcontrast_la_METASOURCES = AUTO
DISTCLEANFILES = $(highcontrast_la_METASOURCES) DISTCLEANFILES = $(highcontrast_la_METASOURCES)

@ -3,7 +3,7 @@ INCLUDES = $(all_includes)
noinst_HEADERS = highcontrastconfig.h noinst_HEADERS = highcontrastconfig.h
kde_module_LTLIBRARIES = kstyle_highcontrast_config.la kde_module_LTLIBRARIES = kstyle_highcontrast_config.la
kstyle_highcontrast_config_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module kstyle_highcontrast_config_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module
kstyle_highcontrast_config_la_LIBADD = $(LIB_KDEUI) kstyle_highcontrast_config_la_LIBADD = $(LIB_QT) $(LIB_KDECORE)
kstyle_highcontrast_config_la_SOURCES = highcontrastconfig.cpp kstyle_highcontrast_config_la_SOURCES = highcontrastconfig.cpp
kstyle_highcontrast_config_la_METASOURCES = AUTO kstyle_highcontrast_config_la_METASOURCES = AUTO

@ -6,7 +6,7 @@ KDE_CXXFLAGS = -UQT_NO_ASCII_CAST
noinst_HEADERS = keramik.h pixmaploader.h keramikimage.h bitmaps.h gradients.h colorutil.h noinst_HEADERS = keramik.h pixmaploader.h keramikimage.h bitmaps.h gradients.h colorutil.h
kde_style_LTLIBRARIES = keramik.la kde_style_LTLIBRARIES = keramik.la
keramik_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module keramik_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module
keramik_la_LIBADD = ../../kdefx/libkdefx.la keramik_la_LIBADD = ../../kdefx/libkdefx.la $(LIB_QT) $(LIB_XEXT)
keramik_la_SOURCES = keramik.cpp pixmaploader.cpp gradients.cpp colorutil.cpp keramik_la_SOURCES = keramik.cpp pixmaploader.cpp gradients.cpp colorutil.cpp
keramik_la_COMPILE_FIRST = keramikrc.h keramik_la_COMPILE_FIRST = keramikrc.h
keramik_la_METASOURCES = AUTO keramik_la_METASOURCES = AUTO

@ -24,6 +24,6 @@ INCLUDES = -I$(top_srcdir)/kdefx $(all_includes)
noinst_HEADERS = kthemestyle.h kthemebase.h kstyledirs.h noinst_HEADERS = kthemestyle.h kthemebase.h kstyledirs.h
kde_style_LTLIBRARIES = kthemestyle.la kde_style_LTLIBRARIES = kthemestyle.la
kthemestyle_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module kthemestyle_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module
kthemestyle_la_LIBADD = ../../kdefx/libkdefx.la ../../kdecore/libkdecore.la kthemestyle_la_LIBADD = ../../kdefx/libkdefx.la ../../kdecore/libkdecore.la -ldl $(LIB_QT)
kthemestyle_la_SOURCES = kthemebase.cpp kthemestyle.cpp kstyledirs.cpp kthemestyle_la_SOURCES = kthemebase.cpp kthemestyle.cpp kstyledirs.cpp
kthemestyle_la_METASOURCES = AUTO kthemestyle_la_METASOURCES = AUTO

@ -16,7 +16,7 @@ noinst_HEADERS = plastik.h misc.h
kde_style_LTLIBRARIES = plastik.la kde_style_LTLIBRARIES = plastik.la
plastik_la_SOURCES = plastik.cpp misc.cpp plastik_la_SOURCES = plastik.cpp misc.cpp
plastik_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module plastik_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module
plastik_la_LIBADD = ../../kdefx/libkdefx.la plastik_la_LIBADD = ../../kdefx/libkdefx.la $(LIB_QT)
plastik_la_METASOURCES = AUTO plastik_la_METASOURCES = AUTO
DISTCLEANFILES = $(plastik_la_METASOURCES) DISTCLEANFILES = $(plastik_la_METASOURCES)

@ -3,7 +3,7 @@ INCLUDES = $(all_includes)
noinst_HEADERS = plastikconf.h noinst_HEADERS = plastikconf.h
kde_module_LTLIBRARIES = kstyle_plastik_config.la kde_module_LTLIBRARIES = kstyle_plastik_config.la
kstyle_plastik_config_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module kstyle_plastik_config_la_LDFLAGS = $(all_libraries) $(KDE_PLUGIN) -module
kstyle_plastik_config_la_LIBADD = $(LIB_KDEUI) kstyle_plastik_config_la_LIBADD = $(LIB_KDEUI) $(LIB_QT) $(LIB_KDECORE)
kstyle_plastik_config_la_SOURCES = plastikconf.cpp kstyle_plastik_config_la_SOURCES = plastikconf.cpp
kstyle_plastik_config_la_METASOURCES = AUTO kstyle_plastik_config_la_METASOURCES = AUTO

@ -14,5 +14,5 @@ kinstalltheme_LDFLAGS = $(all_libraries) $(KDE_RPATH)
# the libraries to link against. Be aware of the order. First the libraries, # the libraries to link against. Be aware of the order. First the libraries,
# that depend on the following ones. # that depend on the following ones.
kinstalltheme_LDADD = $(LIB_KDEUI) kinstalltheme_LDADD = $(LIB_QT) $(LIB_KDECORE)

@ -4,7 +4,7 @@ METASOURCES = AUTO
lib_LTLIBRARIES = libkunittest.la lib_LTLIBRARIES = libkunittest.la
libkunittest_la_SOURCES = runner.cpp tester.cpp libkunittest_la_SOURCES = runner.cpp tester.cpp
libkunittest_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -version-info 1:0:0 libkunittest_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -version-info 1:0:0
libkunittest_la_LIBADD = $(LIB_KDECORE) libkunittest_la_LIBADD = $(LIB_KDECORE) $(LIB_QT)
libkunittestinclude_HEADERS = runner.h tester.h module.h libkunittestinclude_HEADERS = runner.h tester.h module.h
libkunittestincludedir = $(includedir)/kunittest libkunittestincludedir = $(includedir)/kunittest

@ -4,7 +4,7 @@ INCLUDES = -I$(top_srcdir)/interfaces/kregexpeditor $(all_includes)
lib_LTLIBRARIES = libkutils.la lib_LTLIBRARIES = libkutils.la
libkutils_la_LDFLAGS = $(all_libraries) -no-undefined -version-info 3:0:2 libkutils_la_LDFLAGS = $(all_libraries) -no-undefined -version-info 3:0:2
# Needs KTrader # Needs KTrader
libkutils_la_LIBADD = ../kio/libkio.la ksettings/libksettings.la libkutils_la_LIBADD = ../kio/libkio.la ksettings/libksettings.la $(LIB_QT) $(top_builddir)/dcop/libDCOP.la $(LIB_KDEUI) $(LIB_KDECORE) $(LIB_X11)
libkutils_la_SOURCES = kfind.cpp kfinddialog.cpp kreplace.cpp \ libkutils_la_SOURCES = kfind.cpp kfinddialog.cpp kreplace.cpp \
kreplacedialog.cpp kcmoduleinfo.cpp kcmoduleloader.cpp \ kreplacedialog.cpp kcmoduleinfo.cpp kcmoduleloader.cpp \

@ -53,7 +53,9 @@ KCModuleInfo::KCModuleInfo()
KCModuleInfo::KCModuleInfo(const QString& desktopFile) KCModuleInfo::KCModuleInfo(const QString& desktopFile)
{ {
init( KService::serviceByStorageId(desktopFile) ); KService::Ptr service = KService::serviceByStorageId(desktopFile);
if(!service) setName(desktopFile);
init(service);
} }
KCModuleInfo::KCModuleInfo( KService::Ptr moduleInfo ) KCModuleInfo::KCModuleInfo( KService::Ptr moduleInfo )

@ -128,9 +128,23 @@ KCModule* KCModuleLoader::loadModule(const KCModuleInfo &mod, ErrorReporting rep
if ( !mod.service() ) if ( !mod.service() )
{ {
return reportError( report, if ( mod.moduleName() == "kcmlisa" || mod.moduleName() == "kcmkiolan" )
i18n("The module %1 could not be found.") {
.arg( mod.moduleName() ), i18n("<qt><p>The diagnostics is:<br>The desktop file %1 could not be found.</qt>").arg(mod.fileName()), parent ); return reportError( report,
i18n("The module %1 could not be found.")
.arg( mod.moduleName() ),
i18n("<qt><p>The Lisa and lan:/ ioslave modules "
"are not installed by default in Kubuntu, because they are obsolete "
"and replaced by zeroconf.<br> If you still wish to use them, you "
"should install the lisa package from the Universe repository.</p></qt>"),
parent );
} else {
return reportError( report,
i18n("The module %1 could not be found.")
.arg( mod.moduleName() ),
i18n("<qt><p>The diagnostics is:<br>The desktop file %1 could not be found.</p></qt>").arg(mod.fileName()),
parent );
}
} }
if (!mod.library().isEmpty()) if (!mod.library().isEmpty())

@ -4,7 +4,7 @@ INCLUDES= -I$(srcdir) $(all_includes)
lib_LTLIBRARIES = libkwalletclient.la lib_LTLIBRARIES = libkwalletclient.la
libkwalletclient_la_LDFLAGS = $(KDE_RPATH) $(all_libraries) -version-info 1:1 -no-undefined libkwalletclient_la_LDFLAGS = $(KDE_RPATH) $(all_libraries) -version-info 1:1 -no-undefined
libkwalletclient_la_LIBADD = $(LIB_KDECORE) libkwalletclient_la_LIBADD = $(LIB_KDECORE) $(LIB_QT) $(top_builddir)/dcop/libDCOP.la
libkwalletclient_la_SOURCES = kwallet.skel \ libkwalletclient_la_SOURCES = kwallet.skel \
kwallet.cc kwallet.cc

@ -18,7 +18,7 @@ libkmid_la_SOURCES = midiout.cc player.cc track.cc midimapper.cc \
libkmid.cc libkmid.cc
libkmid_la_LDFLAGS = $(KDE_MT_LDFLAGS) -version-info 0:95 -no-undefined libkmid_la_LDFLAGS = $(KDE_MT_LDFLAGS) -version-info 0:95 -no-undefined
libkmid_la_LIBADD = $(LIBASOUND) ../kdecore/libkdecore.la libkmid_la_LIBADD = $(LIBASOUND) ../kdecore/libkdecore.la $(LIB_QT)
DOXYGEN_REFERENCES = kdecore DOXYGEN_REFERENCES = kdecore
include ../admin/Doxyfile.am include ../admin/Doxyfile.am

@ -127,8 +127,8 @@ void FMOut::initDev (void)
void FMOut::loadFMPatches(void) void FMOut::loadFMPatches(void)
{ {
#ifdef HAVE_OSS_SUPPORT #ifdef HAVE_OSS_SUPPORT
char patchesfile[PATH_MAX]; char patchesfile[strlen(FMPatchesDirectory)+7+1];
char drumsfile[PATH_MAX]; char drumsfile[strlen(FMPatchesDirectory)+9+1];
int size; int size;
struct sbi_instrument instr; struct sbi_instrument instr;
char tmp[60]; char tmp[60];
@ -141,12 +141,12 @@ void FMOut::loadFMPatches(void)
if (opl==3) if (opl==3)
{ {
snprintf(patchesfile, PATH_MAX, "%s/std.o3",FMPatchesDirectory); snprintf(patchesfile, sizeof(patchesfile), "%s/std.o3",FMPatchesDirectory);
size=60; size=60;
} }
else else
{ {
snprintf(patchesfile, PATH_MAX, "%s/std.sb",FMPatchesDirectory); snprintf(patchesfile, sizeof(patchesfile), "%s/std.sb",FMPatchesDirectory);
size=52; size=52;
} }
fh=fopen(patchesfile,"rb"); fh=fopen(patchesfile,"rb");
@ -171,11 +171,11 @@ void FMOut::loadFMPatches(void)
if (opl==3) if (opl==3)
{ {
snprintf(drumsfile, PATH_MAX, "%s/drums.o3",FMPatchesDirectory); snprintf(drumsfile, sizeof(drumsfile), "%s/drums.o3",FMPatchesDirectory);
} }
else else
{ {
snprintf(drumsfile, PATH_MAX, "%s/drums.sb",FMPatchesDirectory); snprintf(drumsfile, sizeof(drumsfile), "%s/drums.sb",FMPatchesDirectory);
} }
fh=fopen(drumsfile,"rb"); fh=fopen(drumsfile,"rb");

@ -1,6 +1,6 @@
lib_LTLIBRARIES = libkscreensaver.la lib_LTLIBRARIES = libkscreensaver.la
libkscreensaver_la_SOURCES = main.cpp kscreensaver.cpp libkscreensaver_la_SOURCES = main.cpp kscreensaver.cpp
libkscreensaver_la_LIBADD = $(LIB_KIO) libkscreensaver_la_LIBADD = $(LIB_QT) $(LIB_KDECORE) $(LIB_X11)
if undefined_symbols_allowed if undefined_symbols_allowed
libkscreensaver_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -version-info 6:0:2 libkscreensaver_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -version-info 6:0:2
else else

@ -184,6 +184,7 @@ struct lt_dlhandle_struct {
#define LT_DLSTRERROR(name) lt_dlerror_strings[LT_CONC(LT_ERROR_,name)] #define LT_DLSTRERROR(name) lt_dlerror_strings[LT_CONC(LT_ERROR_,name)]
static const char objdir[] = LTDL_OBJDIR; static const char objdir[] = LTDL_OBJDIR;
#define LTDL_SHLIB_EXT ".so"
#ifdef LTDL_SHLIB_EXT #ifdef LTDL_SHLIB_EXT
static const char shlib_ext[] = LTDL_SHLIB_EXT; static const char shlib_ext[] = LTDL_SHLIB_EXT;
#endif #endif

@ -67,7 +67,25 @@ mimetypeapplicationdata_DATA = x-dvi.desktop x-gzdvi.desktop x-bz2dvi.desktop \
x-java-jnlp-file.desktop xml-dtd.desktop fits.desktop \ x-java-jnlp-file.desktop xml-dtd.desktop fits.desktop \
x-rar-compressed.desktop \ x-rar-compressed.desktop \
x-sqlite2.desktop x-sqlite3.desktop chm.desktop \ x-sqlite2.desktop x-sqlite3.desktop chm.desktop \
x-mplayer2.desktop x-mplayer2.desktop \
x-nzb.desktop \
vnd.openxmlformats-officedocument.wordprocessingml.document.desktop \
vnd.openxmlformats-officedocument.wordprocessingml.template.desktop \
vnd.ms-word.document.macroEnabled.12.desktop \
vnd.ms-word.template.macroEnabled.12.desktop \
vnd.openxmlformats-officedocument.spreadsheetml.sheet.desktop \
vnd.openxmlformats-officedocument.spreadsheetml.template.desktop \
vnd.ms-excel.sheet.macroEnabled.12.desktop \
vnd.ms-excel.template.macroEnabled.12.desktop \
vnd.ms-excel.addin.macroEnabled.12.desktop \
vnd.ms-excel.sheet.binary.macroEnabled.12.desktop \
vnd.openxmlformats-officedocument.presentationml.presentation.desktop \
vnd.openxmlformats-officedocument.presentationml.template.desktop \
vnd.openxmlformats-officedocument.presentationml.slideshow.desktop \
vnd.ms-powerpoint.addin.macroEnabled.12.desktop \
vnd.ms-powerpoint.presentation.macroEnabled.12.desktop \
vnd.ms-powerpoint.template.macroEnabled.12.desktop \
vnd.ms-powerpoint.slideshow.macroEnabled.12.desktop
mimetypeapplicationdatadir = $(kde_mimedir)/application mimetypeapplicationdatadir = $(kde_mimedir)/application

@ -0,0 +1,9 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.ms-access
Icon=database
Comment=Microsoft Access Database
[Property::X-KDE-NativeExtension]
Type=QString
Value=.mdb

@ -0,0 +1,89 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.ms-excel.addin.macroEnabled.12
Patterns=*.xlam;*.XLAM
Icon=spreadsheet
Comment=Microsoft Excel Spreadsheet Add-In Macro Enabled
Comment[af]=Microsoft Excel Spreiblad
Comment[ar]=ورقة عمل مايكروسوفت اكسل
Comment[az]=Microsoft Excel Sənədi
Comment[be]=Разліковы аркуш Microsoft Excel
Comment[bg]=Документ на Microsoft Excel
Comment[bn]=মাইক্রোসফট এক্সসেল নথী
Comment[br]=Loger Microsoft Excel
Comment[bs]=Microsoft Excel proračunska tablica
Comment[ca]=Full de càlcul de Microsoft Excel
Comment[cs]=Tabulka programu Microsoft Excel
Comment[csb]=Bòga Microsoft Excela
Comment[cy]=Taenlen Microsoft Excel
Comment[da]=Microsoft Excel-regneark
Comment[de]=MS-Excel-Arbeitsblatt
Comment[el]=Φύλλο εργασίας Microsoft Excel
Comment[eo]=Mikrosoft-Excel-dokumento
Comment[es]=Hoja de cálculo de Microsoft Excel
Comment[et]=Microsoft Exceli tabel
Comment[eu]=Microsoft Excel kalkulu-orria
Comment[fa]=صفحۀ گستردۀ میکروسافت اکسل
Comment[fi]=Microsoft Excel -taulukko
Comment[fr]=Feuille de calcul Microsoft Excel
Comment[fy]=Microsoft Excel-Rekkenboerd
Comment[ga]=Scarbhileog Microsoft Excel
Comment[gl]=Folla de cálculo Microsoft Excel
Comment[he]=גיליון אלקטרוני של Microsoft Excel
Comment[hi]=माइक्रोसॉफ्ट एक्सेल स्प्रेडशीट
Comment[hr]=Microsoft Excel proračunska tablica
Comment[hu]=Microsoft Excel dokumentum
Comment[id]=Lembar Kerja Microsoft Excel
Comment[is]=Microsoft Excel tafla
Comment[it]=Foglio di calcolo Microsoft Excel
Comment[ja]=Microsoft Excel スプレッドシート
Comment[ka]=Microsoft Excelის ცხრილი
Comment[kk]=Microsoft Excel эл.кестесі
Comment[km]=សៀវភៅ​បញ្ជី Microsoft Excel
Comment[ko]=마이크로소프트 엑셀 스프레드시트
Comment[lb]=Microsoft-Excel-Tabellëblat
Comment[lt]=Microsoft Excel elektroninė lentelė
Comment[lv]=Microsoft Excel izklājlapa
Comment[mk]=Microsoft Excel-табеларна пресметка
Comment[mn]=MS-Excel-Хүснэгт
Comment[ms]=Hamparan helaian Microsoft Excel
Comment[mt]=Spreadsheet Microsoft Excel
Comment[nb]=Microsoft Excel-regneark
Comment[nds]="Microsoft Excel"-Arbeitblatt
Comment[ne]=माइक्रोसफ्ट एक्सेल स्प्रेडसिट
Comment[nl]=Microsoft Excel-spreadsheet
Comment[nn]=Microsoft Excel-rekneark
Comment[nso]=Letlakala la Phatlalatso la Bokgoni bja Microsoft
Comment[pa]=Microsoft Excel ਸਾਰਣੀਕਾਰ
Comment[pl]=Arkusz Microsoft Excela
Comment[pt]=Folha de cálculo do Microsoft Excel
Comment[pt_BR]=Planilha do Microsoft Excel
Comment[ro]=Foaie de calcul tabelar Microsoft Excel
Comment[ru]=Таблица Microsoft Excel
Comment[rw]=Urupapurorusesuye Microsoft Excel
Comment[se]=Microsoft Excel-tabealla
Comment[sk]=Dokument Microsoft Excel
Comment[sl]=Preglednica za Microsoft Excel
Comment[sq]=Tabak nga Microsoft Excel
Comment[sr]=Унакрсна табела Microsoft-овог Excel-а
Comment[sr@Latn]=Unakrsna tabela Microsoft-ovog Excel-a
Comment[sv]=Microsoft Excel-kalkylark
Comment[ta]=மைக்ரோசாப்ட் எக்செல் விரிதாள்
Comment[te]=మైక్రొసాఫ్ట్ ఎక్సెల్ స్ప్రెడ్ షీట్
Comment[tg]=Ҷадвалҳои электронӣ Microsoft Excel
Comment[th]=ตารางคำนวณไมโครซอฟต์เอ็กเซล
Comment[tr]=Microsoft Excel Hesap Çizelgesi
Comment[tt]=Microsoft Excel İsäpcäymäse
Comment[uk]=Таблиця MS Excel
Comment[uz]=Microsoft Excel elektron jadvali
Comment[uz@cyrillic]=Microsoft Excel электрон жадвали
Comment[ven]=Bammbiri lo navhaho la microsoft Excel
Comment[vi]=Bảng tính Excel của Microsoft™.
Comment[wa]=Fitchî tåvleu Microsoft Excel
Comment[zh_CN]=Microsoft Excel 电子表格
Comment[zh_HK]=微軟 Excel 表格
Comment[zh_TW]=微軟 Excel 表格
Comment[zu]= Ipheshana lesitayela le-Microsoft Excel
[Property::X-KDE-NativeExtension]
Type=QString
Value=.xls

@ -1,6 +1,7 @@
[Desktop Entry] [Desktop Entry]
Type=MimeType Type=MimeType
MimeType=application/vnd.ms-excel MimeType=application/vnd.ms-excel
Patterns=*.xls;*.XLS
Icon=spreadsheet Icon=spreadsheet
Comment=Microsoft Excel Spreadsheet Comment=Microsoft Excel Spreadsheet
Comment[af]=Microsoft Excel Spreiblad Comment[af]=Microsoft Excel Spreiblad

@ -0,0 +1,89 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.ms-excel.sheet.binary.macroEnabled.12
Patterns=*.xlsb;*.XLSB
Icon=spreadsheet
Comment=Microsoft Excel Spreadsheet Macro Enabled
Comment[af]=Microsoft Excel Spreiblad
Comment[ar]=ورقة عمل مايكروسوفت اكسل
Comment[az]=Microsoft Excel Sənədi
Comment[be]=Разліковы аркуш Microsoft Excel
Comment[bg]=Документ на Microsoft Excel
Comment[bn]=মাইক্রোসফট এক্সসেল নথী
Comment[br]=Loger Microsoft Excel
Comment[bs]=Microsoft Excel proračunska tablica
Comment[ca]=Full de càlcul de Microsoft Excel
Comment[cs]=Tabulka programu Microsoft Excel
Comment[csb]=Bòga Microsoft Excela
Comment[cy]=Taenlen Microsoft Excel
Comment[da]=Microsoft Excel-regneark
Comment[de]=MS-Excel-Arbeitsblatt
Comment[el]=Φύλλο εργασίας Microsoft Excel
Comment[eo]=Mikrosoft-Excel-dokumento
Comment[es]=Hoja de cálculo de Microsoft Excel
Comment[et]=Microsoft Exceli tabel
Comment[eu]=Microsoft Excel kalkulu-orria
Comment[fa]=صفحۀ گستردۀ میکروسافت اکسل
Comment[fi]=Microsoft Excel -taulukko
Comment[fr]=Feuille de calcul Microsoft Excel
Comment[fy]=Microsoft Excel-Rekkenboerd
Comment[ga]=Scarbhileog Microsoft Excel
Comment[gl]=Folla de cálculo Microsoft Excel
Comment[he]=גיליון אלקטרוני של Microsoft Excel
Comment[hi]=माइक्रोसॉफ्ट एक्सेल स्प्रेडशीट
Comment[hr]=Microsoft Excel proračunska tablica
Comment[hu]=Microsoft Excel dokumentum
Comment[id]=Lembar Kerja Microsoft Excel
Comment[is]=Microsoft Excel tafla
Comment[it]=Foglio di calcolo Microsoft Excel
Comment[ja]=Microsoft Excel スプレッドシート
Comment[ka]=Microsoft Excelის ცხრილი
Comment[kk]=Microsoft Excel эл.кестесі
Comment[km]=សៀវភៅ​បញ្ជី Microsoft Excel
Comment[ko]=마이크로소프트 엑셀 스프레드시트
Comment[lb]=Microsoft-Excel-Tabellëblat
Comment[lt]=Microsoft Excel elektroninė lentelė
Comment[lv]=Microsoft Excel izklājlapa
Comment[mk]=Microsoft Excel-табеларна пресметка
Comment[mn]=MS-Excel-Хүснэгт
Comment[ms]=Hamparan helaian Microsoft Excel
Comment[mt]=Spreadsheet Microsoft Excel
Comment[nb]=Microsoft Excel-regneark
Comment[nds]="Microsoft Excel"-Arbeitblatt
Comment[ne]=माइक्रोसफ्ट एक्सेल स्प्रेडसिट
Comment[nl]=Microsoft Excel-spreadsheet
Comment[nn]=Microsoft Excel-rekneark
Comment[nso]=Letlakala la Phatlalatso la Bokgoni bja Microsoft
Comment[pa]=Microsoft Excel ਸਾਰਣੀਕਾਰ
Comment[pl]=Arkusz Microsoft Excela
Comment[pt]=Folha de cálculo do Microsoft Excel
Comment[pt_BR]=Planilha do Microsoft Excel
Comment[ro]=Foaie de calcul tabelar Microsoft Excel
Comment[ru]=Таблица Microsoft Excel
Comment[rw]=Urupapurorusesuye Microsoft Excel
Comment[se]=Microsoft Excel-tabealla
Comment[sk]=Dokument Microsoft Excel
Comment[sl]=Preglednica za Microsoft Excel
Comment[sq]=Tabak nga Microsoft Excel
Comment[sr]=Унакрсна табела Microsoft-овог Excel-а
Comment[sr@Latn]=Unakrsna tabela Microsoft-ovog Excel-a
Comment[sv]=Microsoft Excel-kalkylark
Comment[ta]=மைக்ரோசாப்ட் எக்செல் விரிதாள்
Comment[te]=మైక్రొసాఫ్ట్ ఎక్సెల్ స్ప్రెడ్ షీట్
Comment[tg]=Ҷадвалҳои электронӣ Microsoft Excel
Comment[th]=ตารางคำนวณไมโครซอฟต์เอ็กเซล
Comment[tr]=Microsoft Excel Hesap Çizelgesi
Comment[tt]=Microsoft Excel İsäpcäymäse
Comment[uk]=Таблиця MS Excel
Comment[uz]=Microsoft Excel elektron jadvali
Comment[uz@cyrillic]=Microsoft Excel электрон жадвали
Comment[ven]=Bammbiri lo navhaho la microsoft Excel
Comment[vi]=Bảng tính Excel của Microsoft™.
Comment[wa]=Fitchî tåvleu Microsoft Excel
Comment[zh_CN]=Microsoft Excel 电子表格
Comment[zh_HK]=微軟 Excel 表格
Comment[zh_TW]=微軟 Excel 表格
Comment[zu]= Ipheshana lesitayela le-Microsoft Excel
[Property::X-KDE-NativeExtension]
Type=QString
Value=.xls

@ -0,0 +1,89 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.ms-excel.sheet.macroEnabled.12
Patterns=*.xlsm;*.XLSM
Icon=spreadsheet
Comment=Microsoft Excel Spreadsheet Macro Enabled
Comment[af]=Microsoft Excel Spreiblad
Comment[ar]=ورقة عمل مايكروسوفت اكسل
Comment[az]=Microsoft Excel Sənədi
Comment[be]=Разліковы аркуш Microsoft Excel
Comment[bg]=Документ на Microsoft Excel
Comment[bn]=মাইক্রোসফট এক্সসেল নথী
Comment[br]=Loger Microsoft Excel
Comment[bs]=Microsoft Excel proračunska tablica
Comment[ca]=Full de càlcul de Microsoft Excel
Comment[cs]=Tabulka programu Microsoft Excel
Comment[csb]=Bòga Microsoft Excela
Comment[cy]=Taenlen Microsoft Excel
Comment[da]=Microsoft Excel-regneark
Comment[de]=MS-Excel-Arbeitsblatt
Comment[el]=Φύλλο εργασίας Microsoft Excel
Comment[eo]=Mikrosoft-Excel-dokumento
Comment[es]=Hoja de cálculo de Microsoft Excel
Comment[et]=Microsoft Exceli tabel
Comment[eu]=Microsoft Excel kalkulu-orria
Comment[fa]=صفحۀ گستردۀ میکروسافت اکسل
Comment[fi]=Microsoft Excel -taulukko
Comment[fr]=Feuille de calcul Microsoft Excel
Comment[fy]=Microsoft Excel-Rekkenboerd
Comment[ga]=Scarbhileog Microsoft Excel
Comment[gl]=Folla de cálculo Microsoft Excel
Comment[he]=גיליון אלקטרוני של Microsoft Excel
Comment[hi]=माइक्रोसॉफ्ट एक्सेल स्प्रेडशीट
Comment[hr]=Microsoft Excel proračunska tablica
Comment[hu]=Microsoft Excel dokumentum
Comment[id]=Lembar Kerja Microsoft Excel
Comment[is]=Microsoft Excel tafla
Comment[it]=Foglio di calcolo Microsoft Excel
Comment[ja]=Microsoft Excel スプレッドシート
Comment[ka]=Microsoft Excelის ცხრილი
Comment[kk]=Microsoft Excel эл.кестесі
Comment[km]=សៀវភៅ​បញ្ជី Microsoft Excel
Comment[ko]=마이크로소프트 엑셀 스프레드시트
Comment[lb]=Microsoft-Excel-Tabellëblat
Comment[lt]=Microsoft Excel elektroninė lentelė
Comment[lv]=Microsoft Excel izklājlapa
Comment[mk]=Microsoft Excel-табеларна пресметка
Comment[mn]=MS-Excel-Хүснэгт
Comment[ms]=Hamparan helaian Microsoft Excel
Comment[mt]=Spreadsheet Microsoft Excel
Comment[nb]=Microsoft Excel-regneark
Comment[nds]="Microsoft Excel"-Arbeitblatt
Comment[ne]=माइक्रोसफ्ट एक्सेल स्प्रेडसिट
Comment[nl]=Microsoft Excel-spreadsheet
Comment[nn]=Microsoft Excel-rekneark
Comment[nso]=Letlakala la Phatlalatso la Bokgoni bja Microsoft
Comment[pa]=Microsoft Excel ਸਾਰਣੀਕਾਰ
Comment[pl]=Arkusz Microsoft Excela
Comment[pt]=Folha de cálculo do Microsoft Excel
Comment[pt_BR]=Planilha do Microsoft Excel
Comment[ro]=Foaie de calcul tabelar Microsoft Excel
Comment[ru]=Таблица Microsoft Excel
Comment[rw]=Urupapurorusesuye Microsoft Excel
Comment[se]=Microsoft Excel-tabealla
Comment[sk]=Dokument Microsoft Excel
Comment[sl]=Preglednica za Microsoft Excel
Comment[sq]=Tabak nga Microsoft Excel
Comment[sr]=Унакрсна табела Microsoft-овог Excel-а
Comment[sr@Latn]=Unakrsna tabela Microsoft-ovog Excel-a
Comment[sv]=Microsoft Excel-kalkylark
Comment[ta]=மைக்ரோசாப்ட் எக்செல் விரிதாள்
Comment[te]=మైక్రొసాఫ్ట్ ఎక్సెల్ స్ప్రెడ్ షీట్
Comment[tg]=Ҷадвалҳои электронӣ Microsoft Excel
Comment[th]=ตารางคำนวณไมโครซอฟต์เอ็กเซล
Comment[tr]=Microsoft Excel Hesap Çizelgesi
Comment[tt]=Microsoft Excel İsäpcäymäse
Comment[uk]=Таблиця MS Excel
Comment[uz]=Microsoft Excel elektron jadvali
Comment[uz@cyrillic]=Microsoft Excel электрон жадвали
Comment[ven]=Bammbiri lo navhaho la microsoft Excel
Comment[vi]=Bảng tính Excel của Microsoft™.
Comment[wa]=Fitchî tåvleu Microsoft Excel
Comment[zh_CN]=Microsoft Excel 电子表格
Comment[zh_HK]=微軟 Excel 表格
Comment[zh_TW]=微軟 Excel 表格
Comment[zu]= Ipheshana lesitayela le-Microsoft Excel
[Property::X-KDE-NativeExtension]
Type=QString
Value=.xls

@ -0,0 +1,89 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.ms-excel.template.macroEnabled.12
Patterns=*.xltm;*.XLTM
Icon=spreadsheet
Comment=Microsoft Excel Spreadsheet Template Macro Enabled
Comment[af]=Microsoft Excel Spreiblad
Comment[ar]=ورقة عمل مايكروسوفت اكسل
Comment[az]=Microsoft Excel Sənədi
Comment[be]=Разліковы аркуш Microsoft Excel
Comment[bg]=Документ на Microsoft Excel
Comment[bn]=মাইক্রোসফট এক্সসেল নথী
Comment[br]=Loger Microsoft Excel
Comment[bs]=Microsoft Excel proračunska tablica
Comment[ca]=Full de càlcul de Microsoft Excel
Comment[cs]=Tabulka programu Microsoft Excel
Comment[csb]=Bòga Microsoft Excela
Comment[cy]=Taenlen Microsoft Excel
Comment[da]=Microsoft Excel-regneark
Comment[de]=MS-Excel-Arbeitsblatt
Comment[el]=Φύλλο εργασίας Microsoft Excel
Comment[eo]=Mikrosoft-Excel-dokumento
Comment[es]=Hoja de cálculo de Microsoft Excel
Comment[et]=Microsoft Exceli tabel
Comment[eu]=Microsoft Excel kalkulu-orria
Comment[fa]=صفحۀ گستردۀ میکروسافت اکسل
Comment[fi]=Microsoft Excel -taulukko
Comment[fr]=Feuille de calcul Microsoft Excel
Comment[fy]=Microsoft Excel-Rekkenboerd
Comment[ga]=Scarbhileog Microsoft Excel
Comment[gl]=Folla de cálculo Microsoft Excel
Comment[he]=גיליון אלקטרוני של Microsoft Excel
Comment[hi]=माइक्रोसॉफ्ट एक्सेल स्प्रेडशीट
Comment[hr]=Microsoft Excel proračunska tablica
Comment[hu]=Microsoft Excel dokumentum
Comment[id]=Lembar Kerja Microsoft Excel
Comment[is]=Microsoft Excel tafla
Comment[it]=Foglio di calcolo Microsoft Excel
Comment[ja]=Microsoft Excel スプレッドシート
Comment[ka]=Microsoft Excelის ცხრილი
Comment[kk]=Microsoft Excel эл.кестесі
Comment[km]=សៀវភៅ​បញ្ជី Microsoft Excel
Comment[ko]=마이크로소프트 엑셀 스프레드시트
Comment[lb]=Microsoft-Excel-Tabellëblat
Comment[lt]=Microsoft Excel elektroninė lentelė
Comment[lv]=Microsoft Excel izklājlapa
Comment[mk]=Microsoft Excel-табеларна пресметка
Comment[mn]=MS-Excel-Хүснэгт
Comment[ms]=Hamparan helaian Microsoft Excel
Comment[mt]=Spreadsheet Microsoft Excel
Comment[nb]=Microsoft Excel-regneark
Comment[nds]="Microsoft Excel"-Arbeitblatt
Comment[ne]=माइक्रोसफ्ट एक्सेल स्प्रेडसिट
Comment[nl]=Microsoft Excel-spreadsheet
Comment[nn]=Microsoft Excel-rekneark
Comment[nso]=Letlakala la Phatlalatso la Bokgoni bja Microsoft
Comment[pa]=Microsoft Excel ਸਾਰਣੀਕਾਰ
Comment[pl]=Arkusz Microsoft Excela
Comment[pt]=Folha de cálculo do Microsoft Excel
Comment[pt_BR]=Planilha do Microsoft Excel
Comment[ro]=Foaie de calcul tabelar Microsoft Excel
Comment[ru]=Таблица Microsoft Excel
Comment[rw]=Urupapurorusesuye Microsoft Excel
Comment[se]=Microsoft Excel-tabealla
Comment[sk]=Dokument Microsoft Excel
Comment[sl]=Preglednica za Microsoft Excel
Comment[sq]=Tabak nga Microsoft Excel
Comment[sr]=Унакрсна табела Microsoft-овог Excel-а
Comment[sr@Latn]=Unakrsna tabela Microsoft-ovog Excel-a
Comment[sv]=Microsoft Excel-kalkylark
Comment[ta]=மைக்ரோசாப்ட் எக்செல் விரிதாள்
Comment[te]=మైక్రొసాఫ్ట్ ఎక్సెల్ స్ప్రెడ్ షీట్
Comment[tg]=Ҷадвалҳои электронӣ Microsoft Excel
Comment[th]=ตารางคำนวณไมโครซอฟต์เอ็กเซล
Comment[tr]=Microsoft Excel Hesap Çizelgesi
Comment[tt]=Microsoft Excel İsäpcäymäse
Comment[uk]=Таблиця MS Excel
Comment[uz]=Microsoft Excel elektron jadvali
Comment[uz@cyrillic]=Microsoft Excel электрон жадвали
Comment[ven]=Bammbiri lo navhaho la microsoft Excel
Comment[vi]=Bảng tính Excel của Microsoft™.
Comment[wa]=Fitchî tåvleu Microsoft Excel
Comment[zh_CN]=Microsoft Excel 电子表格
Comment[zh_HK]=微軟 Excel 表格
Comment[zh_TW]=微軟 Excel 表格
Comment[zu]= Ipheshana lesitayela le-Microsoft Excel
[Property::X-KDE-NativeExtension]
Type=QString
Value=.xls

@ -0,0 +1,86 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.ms-powerpoint.addin.macroEnabled.12.desktop
Patterns=*.ppam
Icon=presentation
Comment=Microsoft PowerPoint Presentation Add-In Macro Enabled
Comment[af]=Microsoft Powerpoint Voorlegging
Comment[ar]=مستند مايكروسوفت باوربوينت
Comment[az]=Microsoft PowerPoint Sənədi
Comment[be]=Прэзентацыя Microsoft PowerPoint
Comment[bg]=Документ на Microsoft PowerPoint
Comment[bn]=মাইক্রোসফট পাওয়ার-পয়েন্ট নথী
Comment[br]=Emginnig Microsoft PowerPoint
Comment[bs]=Microsoft PowerPoint prezentacija
Comment[ca]=Presentació de Microsoft PowerPoint
Comment[cs]=Prezentace Microsoft Powerpoint
Comment[csb]=Prezentacëjô Microsoft PowerPointa
Comment[cy]=Cyflwyniad Microsoft PowerPoint
Comment[da]=Microsoft PowerPoint-præsentation
Comment[de]=MS-PowerPoint-Präsentation
Comment[el]=Παρουσίαση Microsoft PowerPoint
Comment[eo]=Mikrosoft-PowerPoint-dokumento
Comment[es]=Presentación de Microsoft PowerPoint
Comment[et]=Microsoft PowerPointi esitlus
Comment[eu]=Microsoft PowerPoint aurkezpena
Comment[fa]=میکروسافت پاورپوینت
Comment[fi]=Microsoft PowerPoint -esitys
Comment[fr]=Présentation Microsoft PowerPoint
Comment[fy]=Microsoft PowerPoint Presintaasje
Comment[ga]=Cáipéis Microsoft PowerPoint
Comment[gl]=Apresentación de Microsoft PowerPoint
Comment[he]=מצגת Microsoft PowerPoint
Comment[hi]=माइक्रोसाफ्ट पावरपाइंट प्रेजेंटेशन
Comment[hr]=Microsoft PowerPointa prezentacija
Comment[hu]=Microsoft PowerPoint dokumentum
Comment[id]=Presentasi Microsoft PowerPoint
Comment[is]=Microsoft PowerPoint kynning
Comment[it]=Presentazione Microsoft PowerPoint
Comment[ja]=Microsoft PowerPoint プレゼンテーション
Comment[ka]=Microsoft PowerPointის დოკუმენტი
Comment[kk]=Microsoft PowerPoint презентациясы
Comment[km]=ការ​បង្ហាញ Microsoft PowerPoint
Comment[ko]=마이크로소프트 파워포인트 프리젠테이션
Comment[lb]=Microsoft-PowerPoint-Präsentatioun
Comment[lt]=Microsoft PowerPoint pristatymas
Comment[lv]=Microsoft PowerPoint prezentācija
Comment[mk]=Microsoft PowerPoint-презентација
Comment[mn]=MS-PowerPoint-Үзүүлэн
Comment[ms]=Persembahan Microsoft PowerPoint
Comment[nb]=Microsoft PowerPoint-dokument
Comment[nds]="Microsoft PowerPoint"-Presentatschoon
Comment[ne]=माइक्रोसफ्ट पावरप्वाइन्ट प्रस्तुतिकरण
Comment[nl]=Microsoft PowerPoint-presentatie
Comment[nn]=Microsoft PowerPoint-presentasjon
Comment[pa]=Microsoft PowerPoint ਪੇਸ਼ਕਾਰੀ
Comment[pl]=Prezentacja Microsoft PowerPointa
Comment[pt]=Apresentação do Microsoft PowerPoint
Comment[pt_BR]=Documento do Microsoft PowerPoint
Comment[ro]=Prezentare Microsoft PowerPoint
Comment[ru]=Презентация Microsoft PowerPoint
Comment[rw]=Iyerekana Microsoft PowerPoint
Comment[se]=Microsoft PowerPoint-dokumeanta
Comment[sk]=Prezentácia Microsoft PowerPoint
Comment[sl]=Predstavitev za Microsoft PowerPoint
Comment[sq]=Prezentim nga Microsoft PowerPoint
Comment[sr]=Microsoft PowerPoint-ова презентација
Comment[sr@Latn]=Microsoft PowerPoint-ova prezentacija
Comment[sv]=Microsoft PowerPoint-presentation
Comment[ta]=மைக்ரோசாப்ட் பவர்பாயின்ட் வழங்கல்
Comment[te]=మైక్రొసాఫ్ట్ పవర్ పాయింట్ పత్రం
Comment[tg]=Презинтатсия Microsoft PowerPoint
Comment[th]=เอกสารนำเสนอไมโครซอฟต์เพาเวอร์พอยนต์
Comment[tr]=Microsoft PowerPoint Sunumu
Comment[tt]=Microsoft PowerPoint Täqbire
Comment[uk]=Презентація MS PowerPoint
Comment[uz]=Microsoft PowerPoint namunasi
Comment[uz@cyrillic]=Microsoft PowerPoint намунаси
Comment[vi]=Trình diễn PowerPoint của Microsoft™.
Comment[wa]=Prezintaedje Microsoft PowerPoint
Comment[zh_CN]=Microsoft PowerPoint 演示文稿
Comment[zh_HK]=微軟 PowerPoint 文件
Comment[zh_TW]=微軟 PowerPoint 文件
[Property::X-KDE-NativeExtension]
Type=QString
Value=.ppt

@ -1,6 +1,7 @@
[Desktop Entry] [Desktop Entry]
Type=MimeType Type=MimeType
MimeType=application/vnd.ms-powerpoint MimeType=application/vnd.ms-powerpoint
Patterns=*.ppt;*.PPT
Icon=presentation Icon=presentation
Comment=Microsoft PowerPoint Presentation Comment=Microsoft PowerPoint Presentation
Comment[af]=Microsoft Powerpoint Voorlegging Comment[af]=Microsoft Powerpoint Voorlegging

@ -0,0 +1,86 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.ms-powerpoint.presentation.macroEnabled.12
Patterns=*.pptm;*.PPTM
Icon=presentation
Comment=Microsoft PowerPoint Presentation Macro Enabled
Comment[af]=Microsoft Powerpoint Voorlegging
Comment[ar]=مستند مايكروسوفت باوربوينت
Comment[az]=Microsoft PowerPoint Sənədi
Comment[be]=Прэзентацыя Microsoft PowerPoint
Comment[bg]=Документ на Microsoft PowerPoint
Comment[bn]=মাইক্রোসফট পাওয়ার-পয়েন্ট নথী
Comment[br]=Emginnig Microsoft PowerPoint
Comment[bs]=Microsoft PowerPoint prezentacija
Comment[ca]=Presentació de Microsoft PowerPoint
Comment[cs]=Prezentace Microsoft Powerpoint
Comment[csb]=Prezentacëjô Microsoft PowerPointa
Comment[cy]=Cyflwyniad Microsoft PowerPoint
Comment[da]=Microsoft PowerPoint-præsentation
Comment[de]=MS-PowerPoint-Präsentation
Comment[el]=Παρουσίαση Microsoft PowerPoint
Comment[eo]=Mikrosoft-PowerPoint-dokumento
Comment[es]=Presentación de Microsoft PowerPoint
Comment[et]=Microsoft PowerPointi esitlus
Comment[eu]=Microsoft PowerPoint aurkezpena
Comment[fa]=میکروسافت پاورپوینت
Comment[fi]=Microsoft PowerPoint -esitys
Comment[fr]=Présentation Microsoft PowerPoint
Comment[fy]=Microsoft PowerPoint Presintaasje
Comment[ga]=Cáipéis Microsoft PowerPoint
Comment[gl]=Apresentación de Microsoft PowerPoint
Comment[he]=מצגת Microsoft PowerPoint
Comment[hi]=माइक्रोसाफ्ट पावरपाइंट प्रेजेंटेशन
Comment[hr]=Microsoft PowerPointa prezentacija
Comment[hu]=Microsoft PowerPoint dokumentum
Comment[id]=Presentasi Microsoft PowerPoint
Comment[is]=Microsoft PowerPoint kynning
Comment[it]=Presentazione Microsoft PowerPoint
Comment[ja]=Microsoft PowerPoint プレゼンテーション
Comment[ka]=Microsoft PowerPointის დოკუმენტი
Comment[kk]=Microsoft PowerPoint презентациясы
Comment[km]=ការ​បង្ហាញ Microsoft PowerPoint
Comment[ko]=마이크로소프트 파워포인트 프리젠테이션
Comment[lb]=Microsoft-PowerPoint-Präsentatioun
Comment[lt]=Microsoft PowerPoint pristatymas
Comment[lv]=Microsoft PowerPoint prezentācija
Comment[mk]=Microsoft PowerPoint-презентација
Comment[mn]=MS-PowerPoint-Үзүүлэн
Comment[ms]=Persembahan Microsoft PowerPoint
Comment[nb]=Microsoft PowerPoint-dokument
Comment[nds]="Microsoft PowerPoint"-Presentatschoon
Comment[ne]=माइक्रोसफ्ट पावरप्वाइन्ट प्रस्तुतिकरण
Comment[nl]=Microsoft PowerPoint-presentatie
Comment[nn]=Microsoft PowerPoint-presentasjon
Comment[pa]=Microsoft PowerPoint ਪੇਸ਼ਕਾਰੀ
Comment[pl]=Prezentacja Microsoft PowerPointa
Comment[pt]=Apresentação do Microsoft PowerPoint
Comment[pt_BR]=Documento do Microsoft PowerPoint
Comment[ro]=Prezentare Microsoft PowerPoint
Comment[ru]=Презентация Microsoft PowerPoint
Comment[rw]=Iyerekana Microsoft PowerPoint
Comment[se]=Microsoft PowerPoint-dokumeanta
Comment[sk]=Prezentácia Microsoft PowerPoint
Comment[sl]=Predstavitev za Microsoft PowerPoint
Comment[sq]=Prezentim nga Microsoft PowerPoint
Comment[sr]=Microsoft PowerPoint-ова презентација
Comment[sr@Latn]=Microsoft PowerPoint-ova prezentacija
Comment[sv]=Microsoft PowerPoint-presentation
Comment[ta]=மைக்ரோசாப்ட் பவர்பாயின்ட் வழங்கல்
Comment[te]=మైక్రొసాఫ్ట్ పవర్ పాయింట్ పత్రం
Comment[tg]=Презинтатсия Microsoft PowerPoint
Comment[th]=เอกสารนำเสนอไมโครซอฟต์เพาเวอร์พอยนต์
Comment[tr]=Microsoft PowerPoint Sunumu
Comment[tt]=Microsoft PowerPoint Täqbire
Comment[uk]=Презентація MS PowerPoint
Comment[uz]=Microsoft PowerPoint namunasi
Comment[uz@cyrillic]=Microsoft PowerPoint намунаси
Comment[vi]=Trình diễn PowerPoint của Microsoft™.
Comment[wa]=Prezintaedje Microsoft PowerPoint
Comment[zh_CN]=Microsoft PowerPoint 演示文稿
Comment[zh_HK]=微軟 PowerPoint 文件
Comment[zh_TW]=微軟 PowerPoint 文件
[Property::X-KDE-NativeExtension]
Type=QString
Value=.ppt

@ -0,0 +1,86 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.ms-powerpoint.slideshow.macroEnabled.12
Patterns=*.ppsm;*.PPSM
Icon=presentation
Comment=Microsoft PowerPoint Presentation SlideShow Macro Enabled
Comment[af]=Microsoft Powerpoint Voorlegging
Comment[ar]=مستند مايكروسوفت باوربوينت
Comment[az]=Microsoft PowerPoint Sənədi
Comment[be]=Прэзентацыя Microsoft PowerPoint
Comment[bg]=Документ на Microsoft PowerPoint
Comment[bn]=মাইক্রোসফট পাওয়ার-পয়েন্ট নথী
Comment[br]=Emginnig Microsoft PowerPoint
Comment[bs]=Microsoft PowerPoint prezentacija
Comment[ca]=Presentació de Microsoft PowerPoint
Comment[cs]=Prezentace Microsoft Powerpoint
Comment[csb]=Prezentacëjô Microsoft PowerPointa
Comment[cy]=Cyflwyniad Microsoft PowerPoint
Comment[da]=Microsoft PowerPoint-præsentation
Comment[de]=MS-PowerPoint-Präsentation
Comment[el]=Παρουσίαση Microsoft PowerPoint
Comment[eo]=Mikrosoft-PowerPoint-dokumento
Comment[es]=Presentación de Microsoft PowerPoint
Comment[et]=Microsoft PowerPointi esitlus
Comment[eu]=Microsoft PowerPoint aurkezpena
Comment[fa]=میکروسافت پاورپوینت
Comment[fi]=Microsoft PowerPoint -esitys
Comment[fr]=Présentation Microsoft PowerPoint
Comment[fy]=Microsoft PowerPoint Presintaasje
Comment[ga]=Cáipéis Microsoft PowerPoint
Comment[gl]=Apresentación de Microsoft PowerPoint
Comment[he]=מצגת Microsoft PowerPoint
Comment[hi]=माइक्रोसाफ्ट पावरपाइंट प्रेजेंटेशन
Comment[hr]=Microsoft PowerPointa prezentacija
Comment[hu]=Microsoft PowerPoint dokumentum
Comment[id]=Presentasi Microsoft PowerPoint
Comment[is]=Microsoft PowerPoint kynning
Comment[it]=Presentazione Microsoft PowerPoint
Comment[ja]=Microsoft PowerPoint プレゼンテーション
Comment[ka]=Microsoft PowerPointის დოკუმენტი
Comment[kk]=Microsoft PowerPoint презентациясы
Comment[km]=ការ​បង្ហាញ Microsoft PowerPoint
Comment[ko]=마이크로소프트 파워포인트 프리젠테이션
Comment[lb]=Microsoft-PowerPoint-Präsentatioun
Comment[lt]=Microsoft PowerPoint pristatymas
Comment[lv]=Microsoft PowerPoint prezentācija
Comment[mk]=Microsoft PowerPoint-презентација
Comment[mn]=MS-PowerPoint-Үзүүлэн
Comment[ms]=Persembahan Microsoft PowerPoint
Comment[nb]=Microsoft PowerPoint-dokument
Comment[nds]="Microsoft PowerPoint"-Presentatschoon
Comment[ne]=माइक्रोसफ्ट पावरप्वाइन्ट प्रस्तुतिकरण
Comment[nl]=Microsoft PowerPoint-presentatie
Comment[nn]=Microsoft PowerPoint-presentasjon
Comment[pa]=Microsoft PowerPoint ਪੇਸ਼ਕਾਰੀ
Comment[pl]=Prezentacja Microsoft PowerPointa
Comment[pt]=Apresentação do Microsoft PowerPoint
Comment[pt_BR]=Documento do Microsoft PowerPoint
Comment[ro]=Prezentare Microsoft PowerPoint
Comment[ru]=Презентация Microsoft PowerPoint
Comment[rw]=Iyerekana Microsoft PowerPoint
Comment[se]=Microsoft PowerPoint-dokumeanta
Comment[sk]=Prezentácia Microsoft PowerPoint
Comment[sl]=Predstavitev za Microsoft PowerPoint
Comment[sq]=Prezentim nga Microsoft PowerPoint
Comment[sr]=Microsoft PowerPoint-ова презентација
Comment[sr@Latn]=Microsoft PowerPoint-ova prezentacija
Comment[sv]=Microsoft PowerPoint-presentation
Comment[ta]=மைக்ரோசாப்ட் பவர்பாயின்ட் வழங்கல்
Comment[te]=మైక్రొసాఫ్ట్ పవర్ పాయింట్ పత్రం
Comment[tg]=Презинтатсия Microsoft PowerPoint
Comment[th]=เอกสารนำเสนอไมโครซอฟต์เพาเวอร์พอยนต์
Comment[tr]=Microsoft PowerPoint Sunumu
Comment[tt]=Microsoft PowerPoint Täqbire
Comment[uk]=Презентація MS PowerPoint
Comment[uz]=Microsoft PowerPoint namunasi
Comment[uz@cyrillic]=Microsoft PowerPoint намунаси
Comment[vi]=Trình diễn PowerPoint của Microsoft™.
Comment[wa]=Prezintaedje Microsoft PowerPoint
Comment[zh_CN]=Microsoft PowerPoint 演示文稿
Comment[zh_HK]=微軟 PowerPoint 文件
Comment[zh_TW]=微軟 PowerPoint 文件
[Property::X-KDE-NativeExtension]
Type=QString
Value=.ppt

@ -0,0 +1,86 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.ms-powerpoint.template.macroEnabled.12
Patterns=*.potm;*.POTM
Icon=presentation
Comment=Microsoft PowerPoint Presentation Template Macro Enabled
Comment[af]=Microsoft Powerpoint Voorlegging
Comment[ar]=مستند مايكروسوفت باوربوينت
Comment[az]=Microsoft PowerPoint Sənədi
Comment[be]=Прэзентацыя Microsoft PowerPoint
Comment[bg]=Документ на Microsoft PowerPoint
Comment[bn]=মাইক্রোসফট পাওয়ার-পয়েন্ট নথী
Comment[br]=Emginnig Microsoft PowerPoint
Comment[bs]=Microsoft PowerPoint prezentacija
Comment[ca]=Presentació de Microsoft PowerPoint
Comment[cs]=Prezentace Microsoft Powerpoint
Comment[csb]=Prezentacëjô Microsoft PowerPointa
Comment[cy]=Cyflwyniad Microsoft PowerPoint
Comment[da]=Microsoft PowerPoint-præsentation
Comment[de]=MS-PowerPoint-Präsentation
Comment[el]=Παρουσίαση Microsoft PowerPoint
Comment[eo]=Mikrosoft-PowerPoint-dokumento
Comment[es]=Presentación de Microsoft PowerPoint
Comment[et]=Microsoft PowerPointi esitlus
Comment[eu]=Microsoft PowerPoint aurkezpena
Comment[fa]=میکروسافت پاورپوینت
Comment[fi]=Microsoft PowerPoint -esitys
Comment[fr]=Présentation Microsoft PowerPoint
Comment[fy]=Microsoft PowerPoint Presintaasje
Comment[ga]=Cáipéis Microsoft PowerPoint
Comment[gl]=Apresentación de Microsoft PowerPoint
Comment[he]=מצגת Microsoft PowerPoint
Comment[hi]=माइक्रोसाफ्ट पावरपाइंट प्रेजेंटेशन
Comment[hr]=Microsoft PowerPointa prezentacija
Comment[hu]=Microsoft PowerPoint dokumentum
Comment[id]=Presentasi Microsoft PowerPoint
Comment[is]=Microsoft PowerPoint kynning
Comment[it]=Presentazione Microsoft PowerPoint
Comment[ja]=Microsoft PowerPoint プレゼンテーション
Comment[ka]=Microsoft PowerPointის დოკუმენტი
Comment[kk]=Microsoft PowerPoint презентациясы
Comment[km]=ការ​បង្ហាញ Microsoft PowerPoint
Comment[ko]=마이크로소프트 파워포인트 프리젠테이션
Comment[lb]=Microsoft-PowerPoint-Präsentatioun
Comment[lt]=Microsoft PowerPoint pristatymas
Comment[lv]=Microsoft PowerPoint prezentācija
Comment[mk]=Microsoft PowerPoint-презентација
Comment[mn]=MS-PowerPoint-Үзүүлэн
Comment[ms]=Persembahan Microsoft PowerPoint
Comment[nb]=Microsoft PowerPoint-dokument
Comment[nds]="Microsoft PowerPoint"-Presentatschoon
Comment[ne]=माइक्रोसफ्ट पावरप्वाइन्ट प्रस्तुतिकरण
Comment[nl]=Microsoft PowerPoint-presentatie
Comment[nn]=Microsoft PowerPoint-presentasjon
Comment[pa]=Microsoft PowerPoint ਪੇਸ਼ਕਾਰੀ
Comment[pl]=Prezentacja Microsoft PowerPointa
Comment[pt]=Apresentação do Microsoft PowerPoint
Comment[pt_BR]=Documento do Microsoft PowerPoint
Comment[ro]=Prezentare Microsoft PowerPoint
Comment[ru]=Презентация Microsoft PowerPoint
Comment[rw]=Iyerekana Microsoft PowerPoint
Comment[se]=Microsoft PowerPoint-dokumeanta
Comment[sk]=Prezentácia Microsoft PowerPoint
Comment[sl]=Predstavitev za Microsoft PowerPoint
Comment[sq]=Prezentim nga Microsoft PowerPoint
Comment[sr]=Microsoft PowerPoint-ова презентација
Comment[sr@Latn]=Microsoft PowerPoint-ova prezentacija
Comment[sv]=Microsoft PowerPoint-presentation
Comment[ta]=மைக்ரோசாப்ட் பவர்பாயின்ட் வழங்கல்
Comment[te]=మైక్రొసాఫ్ట్ పవర్ పాయింట్ పత్రం
Comment[tg]=Презинтатсия Microsoft PowerPoint
Comment[th]=เอกสารนำเสนอไมโครซอฟต์เพาเวอร์พอยนต์
Comment[tr]=Microsoft PowerPoint Sunumu
Comment[tt]=Microsoft PowerPoint Täqbire
Comment[uk]=Презентація MS PowerPoint
Comment[uz]=Microsoft PowerPoint namunasi
Comment[uz@cyrillic]=Microsoft PowerPoint намунаси
Comment[vi]=Trình diễn PowerPoint của Microsoft™.
Comment[wa]=Prezintaedje Microsoft PowerPoint
Comment[zh_CN]=Microsoft PowerPoint 演示文稿
Comment[zh_HK]=微軟 PowerPoint 文件
Comment[zh_TW]=微軟 PowerPoint 文件
[Property::X-KDE-NativeExtension]
Type=QString
Value=.ppt

@ -1,6 +1,7 @@
[Desktop Entry] [Desktop Entry]
Type=MimeType Type=MimeType
MimeType=application/vnd.ms-word MimeType=application/vnd.ms-word
Patterns=*.doc;*.DOC
Icon=wordprocessing Icon=wordprocessing
Comment=Microsoft Word Document Comment=Microsoft Word Document
Comment[af]=Microsoft Woord Dokument Comment[af]=Microsoft Woord Dokument

@ -0,0 +1,91 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.ms-word.document.macroEnabled.12
Patterns=*.docm;*.DOCM
Icon=wordprocessing
Comment=Microsoft Word Document Macro Enabled
Comment[af]=Microsoft Woord Dokument
Comment[ar]=مستند مايكروسوفت وورد
Comment[az]=Microsoft Word Sənədi
Comment[be]=Дакумент Microsoft Word
Comment[bg]=Документ на Microsoft Word
Comment[bn]=মাইক্রোসফট ওয়ার্ড নথী
Comment[br]=Teul Microsoft Word
Comment[bs]=Microsoft Word dokument
Comment[ca]=Document de Microsoft Word
Comment[cs]=Dokument programu Microsoft Word
Comment[csb]=Dokùment Microsoft Worda
Comment[cy]=Dogfen Microsoft Word
Comment[da]=Microsoft Word-dokument
Comment[de]=MS-Word-Dokument
Comment[el]=Έγγραφο Microsoft Word
Comment[eo]=Mikrosoft-Word-dokumento
Comment[es]=Documento de Microsoft Word
Comment[et]=Microsoft Wordi dokument
Comment[eu]=Microsoft Word dokumentua
Comment[fa]=سند میکروسافت ورد
Comment[fi]=Microsoft Word -asiakirja
Comment[fr]=Document Microsoft Word
Comment[fy]=Microsoft Word-dokumint
Comment[ga]=Cáipéis Microsoft Word
Comment[gl]=Documento de Microsoft Word
Comment[he]=מסמך Microsoft Word
Comment[hi]=माइक्रोसॉफ्ट वर्ड दस्तावेज़
Comment[hr]=Microsoft Word dokument
Comment[hu]=Microsoft Word dokumentum
Comment[id]=Dokumen Microsoft Word
Comment[is]=Microsoft Word skjal
Comment[it]=Documento Microsoft Word
Comment[ja]=Microsoft Word ドキュメント
Comment[ka]=Microsoft Wordის დოკუმენტი
Comment[kk]=Microsoft Word құжаты
Comment[km]=ឯកសារ Microsoft Word
Comment[ko]=마이크로소프트 글틀 문서
Comment[lb]=Microsoft-Word-Dokument
Comment[lt]=Microsoft Word dokumentas
Comment[lv]=Microsoft Word dokuments
Comment[mk]=Microsoft Word-документ
Comment[mn]=MS-Word-Баримт
Comment[ms]=Dokumen Microsoft Word
Comment[mt]=Dokument Microsoft Word
Comment[nb]=Microsoft Word-dokument
Comment[nds]="Microsoft Word"-Dokment
Comment[ne]=माइक्रोसफ्ट वर्ड कागजात
Comment[nl]=Microsoft Word-document
Comment[nn]=Microsoft Word-dokument
Comment[nso]=Tokomane ya Lentsu la Microsoft
Comment[pa]=Microsoft Word ਦਸਤਾਵੇਜ਼
Comment[pl]=Dokument Microsoft Worda
Comment[pt]=Documento do Microsoft Word
Comment[pt_BR]=Documento do Microsoft Word
Comment[ro]=Document Microsoft Word
Comment[ru]=Документ Microsoft Word
Comment[rw]=Microsoft Word Inyandiko
Comment[se]=Microsoft Word-dokumeanta
Comment[sk]=Dokument Microsoft Word
Comment[sl]=Dokument za Microsoft Word
Comment[sq]=Dokument nga Microsoft Word
Comment[sr]=Microsoft Word-ов документ
Comment[sr@Latn]=Microsoft Word-ov dokument
Comment[sv]=Microsoft Word-dokument
Comment[ta]=மைக்ரோசாப்ட் வேர்டு ஆவணம்
Comment[te]=మైక్రొసాఫ్ట్ పదం పత్రం
Comment[tg]=Ҳуҷҷати Microsoft Word
Comment[th]=เอกสารไมโครซอฟต์เวิร์ด
Comment[tr]=Microsoft Word Belgesi
Comment[tt]=Microsoft Word İstälege
Comment[uk]=Документ MS Word
Comment[uz]=Microsoft Word hujjati
Comment[uz@cyrillic]=Microsoft Word ҳужжати
Comment[ven]=Manwalwa a Microsoft Word
Comment[vi]=Tài liệu Word của Microsoft™.
Comment[wa]=Documint Microsoft Word
Comment[xh]=Uxwebhhu LweMicrosoft Word
Comment[zh_CN]=Microsoft Word 文档
Comment[zh_HK]=微軟 Word 文件
Comment[zh_TW]=微軟 Word 文件
Comment[zu]=Uhlu Lwamafayela lwe-Microsoft Word
[Property::X-KDE-NativeExtension]
Type=QString
Value=.doc

@ -0,0 +1,91 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.ms-word.template.macroEnabled.12
Patterns=*.dotm;*.DOTM
Icon=wordprocessing
Comment=Microsoft Word Document Template Macro Enabled
Comment[af]=Microsoft Woord Dokument
Comment[ar]=مستند مايكروسوفت وورد
Comment[az]=Microsoft Word Sənədi
Comment[be]=Дакумент Microsoft Word
Comment[bg]=Документ на Microsoft Word
Comment[bn]=মাইক্রোসফট ওয়ার্ড নথী
Comment[br]=Teul Microsoft Word
Comment[bs]=Microsoft Word dokument
Comment[ca]=Document de Microsoft Word
Comment[cs]=Dokument programu Microsoft Word
Comment[csb]=Dokùment Microsoft Worda
Comment[cy]=Dogfen Microsoft Word
Comment[da]=Microsoft Word-dokument
Comment[de]=MS-Word-Dokument
Comment[el]=Έγγραφο Microsoft Word
Comment[eo]=Mikrosoft-Word-dokumento
Comment[es]=Documento de Microsoft Word
Comment[et]=Microsoft Wordi dokument
Comment[eu]=Microsoft Word dokumentua
Comment[fa]=سند میکروسافت ورد
Comment[fi]=Microsoft Word -asiakirja
Comment[fr]=Document Microsoft Word
Comment[fy]=Microsoft Word-dokumint
Comment[ga]=Cáipéis Microsoft Word
Comment[gl]=Documento de Microsoft Word
Comment[he]=מסמך Microsoft Word
Comment[hi]=माइक्रोसॉफ्ट वर्ड दस्तावेज़
Comment[hr]=Microsoft Word dokument
Comment[hu]=Microsoft Word dokumentum
Comment[id]=Dokumen Microsoft Word
Comment[is]=Microsoft Word skjal
Comment[it]=Documento Microsoft Word
Comment[ja]=Microsoft Word ドキュメント
Comment[ka]=Microsoft Wordის დოკუმენტი
Comment[kk]=Microsoft Word құжаты
Comment[km]=ឯកសារ Microsoft Word
Comment[ko]=마이크로소프트 글틀 문서
Comment[lb]=Microsoft-Word-Dokument
Comment[lt]=Microsoft Word dokumentas
Comment[lv]=Microsoft Word dokuments
Comment[mk]=Microsoft Word-документ
Comment[mn]=MS-Word-Баримт
Comment[ms]=Dokumen Microsoft Word
Comment[mt]=Dokument Microsoft Word
Comment[nb]=Microsoft Word-dokument
Comment[nds]="Microsoft Word"-Dokment
Comment[ne]=माइक्रोसफ्ट वर्ड कागजात
Comment[nl]=Microsoft Word-document
Comment[nn]=Microsoft Word-dokument
Comment[nso]=Tokomane ya Lentsu la Microsoft
Comment[pa]=Microsoft Word ਦਸਤਾਵੇਜ਼
Comment[pl]=Dokument Microsoft Worda
Comment[pt]=Documento do Microsoft Word
Comment[pt_BR]=Documento do Microsoft Word
Comment[ro]=Document Microsoft Word
Comment[ru]=Документ Microsoft Word
Comment[rw]=Microsoft Word Inyandiko
Comment[se]=Microsoft Word-dokumeanta
Comment[sk]=Dokument Microsoft Word
Comment[sl]=Dokument za Microsoft Word
Comment[sq]=Dokument nga Microsoft Word
Comment[sr]=Microsoft Word-ов документ
Comment[sr@Latn]=Microsoft Word-ov dokument
Comment[sv]=Microsoft Word-dokument
Comment[ta]=மைக்ரோசாப்ட் வேர்டு ஆவணம்
Comment[te]=మైక్రొసాఫ్ట్ పదం పత్రం
Comment[tg]=Ҳуҷҷати Microsoft Word
Comment[th]=เอกสารไมโครซอฟต์เวิร์ด
Comment[tr]=Microsoft Word Belgesi
Comment[tt]=Microsoft Word İstälege
Comment[uk]=Документ MS Word
Comment[uz]=Microsoft Word hujjati
Comment[uz@cyrillic]=Microsoft Word ҳужжати
Comment[ven]=Manwalwa a Microsoft Word
Comment[vi]=Tài liệu Word của Microsoft™.
Comment[wa]=Documint Microsoft Word
Comment[xh]=Uxwebhhu LweMicrosoft Word
Comment[zh_CN]=Microsoft Word 文档
Comment[zh_HK]=微軟 Word 文件
Comment[zh_TW]=微軟 Word 文件
Comment[zu]=Uhlu Lwamafayela lwe-Microsoft Word
[Property::X-KDE-NativeExtension]
Type=QString
Value=.doc

@ -0,0 +1,9 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.oasis.opendocument.database
Patterns=*.odb;*.ODB
Icon=database
Comment=OASIS OpenDocument Database
[Property::X-KDE-NativeExtension]
Type=QString
Value=.odb

@ -0,0 +1,86 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.openxmlformats-officedocument.presentationml.presentation
Patterns=*.pptx;*.PPTX
Icon=presentation
Comment=Microsoft PowerPoint Presentation
Comment[af]=Microsoft Powerpoint Voorlegging
Comment[ar]=مستند مايكروسوفت باوربوينت
Comment[az]=Microsoft PowerPoint Sənədi
Comment[be]=Прэзентацыя Microsoft PowerPoint
Comment[bg]=Документ на Microsoft PowerPoint
Comment[bn]=মাইক্রোসফট পাওয়ার-পয়েন্ট নথী
Comment[br]=Emginnig Microsoft PowerPoint
Comment[bs]=Microsoft PowerPoint prezentacija
Comment[ca]=Presentació de Microsoft PowerPoint
Comment[cs]=Prezentace Microsoft Powerpoint
Comment[csb]=Prezentacëjô Microsoft PowerPointa
Comment[cy]=Cyflwyniad Microsoft PowerPoint
Comment[da]=Microsoft PowerPoint-præsentation
Comment[de]=MS-PowerPoint-Präsentation
Comment[el]=Παρουσίαση Microsoft PowerPoint
Comment[eo]=Mikrosoft-PowerPoint-dokumento
Comment[es]=Presentación de Microsoft PowerPoint
Comment[et]=Microsoft PowerPointi esitlus
Comment[eu]=Microsoft PowerPoint aurkezpena
Comment[fa]=میکروسافت پاورپوینت
Comment[fi]=Microsoft PowerPoint -esitys
Comment[fr]=Présentation Microsoft PowerPoint
Comment[fy]=Microsoft PowerPoint Presintaasje
Comment[ga]=Cáipéis Microsoft PowerPoint
Comment[gl]=Apresentación de Microsoft PowerPoint
Comment[he]=מצגת Microsoft PowerPoint
Comment[hi]=माइक्रोसाफ्ट पावरपाइंट प्रेजेंटेशन
Comment[hr]=Microsoft PowerPointa prezentacija
Comment[hu]=Microsoft PowerPoint dokumentum
Comment[id]=Presentasi Microsoft PowerPoint
Comment[is]=Microsoft PowerPoint kynning
Comment[it]=Presentazione Microsoft PowerPoint
Comment[ja]=Microsoft PowerPoint プレゼンテーション
Comment[ka]=Microsoft PowerPointის დოკუმენტი
Comment[kk]=Microsoft PowerPoint презентациясы
Comment[km]=ការ​បង្ហាញ Microsoft PowerPoint
Comment[ko]=마이크로소프트 파워포인트 프리젠테이션
Comment[lb]=Microsoft-PowerPoint-Präsentatioun
Comment[lt]=Microsoft PowerPoint pristatymas
Comment[lv]=Microsoft PowerPoint prezentācija
Comment[mk]=Microsoft PowerPoint-презентација
Comment[mn]=MS-PowerPoint-Үзүүлэн
Comment[ms]=Persembahan Microsoft PowerPoint
Comment[nb]=Microsoft PowerPoint-dokument
Comment[nds]="Microsoft PowerPoint"-Presentatschoon
Comment[ne]=माइक्रोसफ्ट पावरप्वाइन्ट प्रस्तुतिकरण
Comment[nl]=Microsoft PowerPoint-presentatie
Comment[nn]=Microsoft PowerPoint-presentasjon
Comment[pa]=Microsoft PowerPoint ਪੇਸ਼ਕਾਰੀ
Comment[pl]=Prezentacja Microsoft PowerPointa
Comment[pt]=Apresentação do Microsoft PowerPoint
Comment[pt_BR]=Documento do Microsoft PowerPoint
Comment[ro]=Prezentare Microsoft PowerPoint
Comment[ru]=Презентация Microsoft PowerPoint
Comment[rw]=Iyerekana Microsoft PowerPoint
Comment[se]=Microsoft PowerPoint-dokumeanta
Comment[sk]=Prezentácia Microsoft PowerPoint
Comment[sl]=Predstavitev za Microsoft PowerPoint
Comment[sq]=Prezentim nga Microsoft PowerPoint
Comment[sr]=Microsoft PowerPoint-ова презентација
Comment[sr@Latn]=Microsoft PowerPoint-ova prezentacija
Comment[sv]=Microsoft PowerPoint-presentation
Comment[ta]=மைக்ரோசாப்ட் பவர்பாயின்ட் வழங்கல்
Comment[te]=మైక్రొసాఫ్ట్ పవర్ పాయింట్ పత్రం
Comment[tg]=Презинтатсия Microsoft PowerPoint
Comment[th]=เอกสารนำเสนอไมโครซอฟต์เพาเวอร์พอยนต์
Comment[tr]=Microsoft PowerPoint Sunumu
Comment[tt]=Microsoft PowerPoint Täqbire
Comment[uk]=Презентація MS PowerPoint
Comment[uz]=Microsoft PowerPoint namunasi
Comment[uz@cyrillic]=Microsoft PowerPoint намунаси
Comment[vi]=Trình diễn PowerPoint của Microsoft™.
Comment[wa]=Prezintaedje Microsoft PowerPoint
Comment[zh_CN]=Microsoft PowerPoint 演示文稿
Comment[zh_HK]=微軟 PowerPoint 文件
Comment[zh_TW]=微軟 PowerPoint 文件
[Property::X-KDE-NativeExtension]
Type=QString
Value=.ppt

@ -0,0 +1,86 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.openxmlformats-officedocument.presentationml.slideshow
Patterns=*.ppsx;*.PPSX
Icon=presentation
Comment=Microsoft PowerPoint Presentation SlideShow
Comment[af]=Microsoft Powerpoint Voorlegging
Comment[ar]=مستند مايكروسوفت باوربوينت
Comment[az]=Microsoft PowerPoint Sənədi
Comment[be]=Прэзентацыя Microsoft PowerPoint
Comment[bg]=Документ на Microsoft PowerPoint
Comment[bn]=মাইক্রোসফট পাওয়ার-পয়েন্ট নথী
Comment[br]=Emginnig Microsoft PowerPoint
Comment[bs]=Microsoft PowerPoint prezentacija
Comment[ca]=Presentació de Microsoft PowerPoint
Comment[cs]=Prezentace Microsoft Powerpoint
Comment[csb]=Prezentacëjô Microsoft PowerPointa
Comment[cy]=Cyflwyniad Microsoft PowerPoint
Comment[da]=Microsoft PowerPoint-præsentation
Comment[de]=MS-PowerPoint-Präsentation
Comment[el]=Παρουσίαση Microsoft PowerPoint
Comment[eo]=Mikrosoft-PowerPoint-dokumento
Comment[es]=Presentación de Microsoft PowerPoint
Comment[et]=Microsoft PowerPointi esitlus
Comment[eu]=Microsoft PowerPoint aurkezpena
Comment[fa]=میکروسافت پاورپوینت
Comment[fi]=Microsoft PowerPoint -esitys
Comment[fr]=Présentation Microsoft PowerPoint
Comment[fy]=Microsoft PowerPoint Presintaasje
Comment[ga]=Cáipéis Microsoft PowerPoint
Comment[gl]=Apresentación de Microsoft PowerPoint
Comment[he]=מצגת Microsoft PowerPoint
Comment[hi]=माइक्रोसाफ्ट पावरपाइंट प्रेजेंटेशन
Comment[hr]=Microsoft PowerPointa prezentacija
Comment[hu]=Microsoft PowerPoint dokumentum
Comment[id]=Presentasi Microsoft PowerPoint
Comment[is]=Microsoft PowerPoint kynning
Comment[it]=Presentazione Microsoft PowerPoint
Comment[ja]=Microsoft PowerPoint プレゼンテーション
Comment[ka]=Microsoft PowerPointის დოკუმენტი
Comment[kk]=Microsoft PowerPoint презентациясы
Comment[km]=ការ​បង្ហាញ Microsoft PowerPoint
Comment[ko]=마이크로소프트 파워포인트 프리젠테이션
Comment[lb]=Microsoft-PowerPoint-Präsentatioun
Comment[lt]=Microsoft PowerPoint pristatymas
Comment[lv]=Microsoft PowerPoint prezentācija
Comment[mk]=Microsoft PowerPoint-презентација
Comment[mn]=MS-PowerPoint-Үзүүлэн
Comment[ms]=Persembahan Microsoft PowerPoint
Comment[nb]=Microsoft PowerPoint-dokument
Comment[nds]="Microsoft PowerPoint"-Presentatschoon
Comment[ne]=माइक्रोसफ्ट पावरप्वाइन्ट प्रस्तुतिकरण
Comment[nl]=Microsoft PowerPoint-presentatie
Comment[nn]=Microsoft PowerPoint-presentasjon
Comment[pa]=Microsoft PowerPoint ਪੇਸ਼ਕਾਰੀ
Comment[pl]=Prezentacja Microsoft PowerPointa
Comment[pt]=Apresentação do Microsoft PowerPoint
Comment[pt_BR]=Documento do Microsoft PowerPoint
Comment[ro]=Prezentare Microsoft PowerPoint
Comment[ru]=Презентация Microsoft PowerPoint
Comment[rw]=Iyerekana Microsoft PowerPoint
Comment[se]=Microsoft PowerPoint-dokumeanta
Comment[sk]=Prezentácia Microsoft PowerPoint
Comment[sl]=Predstavitev za Microsoft PowerPoint
Comment[sq]=Prezentim nga Microsoft PowerPoint
Comment[sr]=Microsoft PowerPoint-ова презентација
Comment[sr@Latn]=Microsoft PowerPoint-ova prezentacija
Comment[sv]=Microsoft PowerPoint-presentation
Comment[ta]=மைக்ரோசாப்ட் பவர்பாயின்ட் வழங்கல்
Comment[te]=మైక్రొసాఫ్ట్ పవర్ పాయింట్ పత్రం
Comment[tg]=Презинтатсия Microsoft PowerPoint
Comment[th]=เอกสารนำเสนอไมโครซอฟต์เพาเวอร์พอยนต์
Comment[tr]=Microsoft PowerPoint Sunumu
Comment[tt]=Microsoft PowerPoint Täqbire
Comment[uk]=Презентація MS PowerPoint
Comment[uz]=Microsoft PowerPoint namunasi
Comment[uz@cyrillic]=Microsoft PowerPoint намунаси
Comment[vi]=Trình diễn PowerPoint của Microsoft™.
Comment[wa]=Prezintaedje Microsoft PowerPoint
Comment[zh_CN]=Microsoft PowerPoint 演示文稿
Comment[zh_HK]=微軟 PowerPoint 文件
Comment[zh_TW]=微軟 PowerPoint 文件
[Property::X-KDE-NativeExtension]
Type=QString
Value=.ppt

@ -0,0 +1,86 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.openxmlformats-officedocument.presentationml.template
Patterns=*.potx;*.POTX
Icon=presentation
Comment=Microsoft PowerPoint Presentation Template
Comment[af]=Microsoft Powerpoint Voorlegging
Comment[ar]=مستند مايكروسوفت باوربوينت
Comment[az]=Microsoft PowerPoint Sənədi
Comment[be]=Прэзентацыя Microsoft PowerPoint
Comment[bg]=Документ на Microsoft PowerPoint
Comment[bn]=মাইক্রোসফট পাওয়ার-পয়েন্ট নথী
Comment[br]=Emginnig Microsoft PowerPoint
Comment[bs]=Microsoft PowerPoint prezentacija
Comment[ca]=Presentació de Microsoft PowerPoint
Comment[cs]=Prezentace Microsoft Powerpoint
Comment[csb]=Prezentacëjô Microsoft PowerPointa
Comment[cy]=Cyflwyniad Microsoft PowerPoint
Comment[da]=Microsoft PowerPoint-præsentation
Comment[de]=MS-PowerPoint-Präsentation
Comment[el]=Παρουσίαση Microsoft PowerPoint
Comment[eo]=Mikrosoft-PowerPoint-dokumento
Comment[es]=Presentación de Microsoft PowerPoint
Comment[et]=Microsoft PowerPointi esitlus
Comment[eu]=Microsoft PowerPoint aurkezpena
Comment[fa]=میکروسافت پاورپوینت
Comment[fi]=Microsoft PowerPoint -esitys
Comment[fr]=Présentation Microsoft PowerPoint
Comment[fy]=Microsoft PowerPoint Presintaasje
Comment[ga]=Cáipéis Microsoft PowerPoint
Comment[gl]=Apresentación de Microsoft PowerPoint
Comment[he]=מצגת Microsoft PowerPoint
Comment[hi]=माइक्रोसाफ्ट पावरपाइंट प्रेजेंटेशन
Comment[hr]=Microsoft PowerPointa prezentacija
Comment[hu]=Microsoft PowerPoint dokumentum
Comment[id]=Presentasi Microsoft PowerPoint
Comment[is]=Microsoft PowerPoint kynning
Comment[it]=Presentazione Microsoft PowerPoint
Comment[ja]=Microsoft PowerPoint プレゼンテーション
Comment[ka]=Microsoft PowerPointის დოკუმენტი
Comment[kk]=Microsoft PowerPoint презентациясы
Comment[km]=ការ​បង្ហាញ Microsoft PowerPoint
Comment[ko]=마이크로소프트 파워포인트 프리젠테이션
Comment[lb]=Microsoft-PowerPoint-Präsentatioun
Comment[lt]=Microsoft PowerPoint pristatymas
Comment[lv]=Microsoft PowerPoint prezentācija
Comment[mk]=Microsoft PowerPoint-презентација
Comment[mn]=MS-PowerPoint-Үзүүлэн
Comment[ms]=Persembahan Microsoft PowerPoint
Comment[nb]=Microsoft PowerPoint-dokument
Comment[nds]="Microsoft PowerPoint"-Presentatschoon
Comment[ne]=माइक्रोसफ्ट पावरप्वाइन्ट प्रस्तुतिकरण
Comment[nl]=Microsoft PowerPoint-presentatie
Comment[nn]=Microsoft PowerPoint-presentasjon
Comment[pa]=Microsoft PowerPoint ਪੇਸ਼ਕਾਰੀ
Comment[pl]=Prezentacja Microsoft PowerPointa
Comment[pt]=Apresentação do Microsoft PowerPoint
Comment[pt_BR]=Documento do Microsoft PowerPoint
Comment[ro]=Prezentare Microsoft PowerPoint
Comment[ru]=Презентация Microsoft PowerPoint
Comment[rw]=Iyerekana Microsoft PowerPoint
Comment[se]=Microsoft PowerPoint-dokumeanta
Comment[sk]=Prezentácia Microsoft PowerPoint
Comment[sl]=Predstavitev za Microsoft PowerPoint
Comment[sq]=Prezentim nga Microsoft PowerPoint
Comment[sr]=Microsoft PowerPoint-ова презентација
Comment[sr@Latn]=Microsoft PowerPoint-ova prezentacija
Comment[sv]=Microsoft PowerPoint-presentation
Comment[ta]=மைக்ரோசாப்ட் பவர்பாயின்ட் வழங்கல்
Comment[te]=మైక్రొసాఫ్ట్ పవర్ పాయింట్ పత్రం
Comment[tg]=Презинтатсия Microsoft PowerPoint
Comment[th]=เอกสารนำเสนอไมโครซอฟต์เพาเวอร์พอยนต์
Comment[tr]=Microsoft PowerPoint Sunumu
Comment[tt]=Microsoft PowerPoint Täqbire
Comment[uk]=Презентація MS PowerPoint
Comment[uz]=Microsoft PowerPoint namunasi
Comment[uz@cyrillic]=Microsoft PowerPoint намунаси
Comment[vi]=Trình diễn PowerPoint của Microsoft™.
Comment[wa]=Prezintaedje Microsoft PowerPoint
Comment[zh_CN]=Microsoft PowerPoint 演示文稿
Comment[zh_HK]=微軟 PowerPoint 文件
Comment[zh_TW]=微軟 PowerPoint 文件
[Property::X-KDE-NativeExtension]
Type=QString
Value=.ppt

@ -0,0 +1,89 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
Patterns=*.xlsx;*.XLSX
Icon=spreadsheet
Comment=Microsoft Excel Spreadsheet
Comment[af]=Microsoft Excel Spreiblad
Comment[ar]=ورقة عمل مايكروسوفت اكسل
Comment[az]=Microsoft Excel Sənədi
Comment[be]=Разліковы аркуш Microsoft Excel
Comment[bg]=Документ на Microsoft Excel
Comment[bn]=মাইক্রোসফট এক্সসেল নথী
Comment[br]=Loger Microsoft Excel
Comment[bs]=Microsoft Excel proračunska tablica
Comment[ca]=Full de càlcul de Microsoft Excel
Comment[cs]=Tabulka programu Microsoft Excel
Comment[csb]=Bòga Microsoft Excela
Comment[cy]=Taenlen Microsoft Excel
Comment[da]=Microsoft Excel-regneark
Comment[de]=MS-Excel-Arbeitsblatt
Comment[el]=Φύλλο εργασίας Microsoft Excel
Comment[eo]=Mikrosoft-Excel-dokumento
Comment[es]=Hoja de cálculo de Microsoft Excel
Comment[et]=Microsoft Exceli tabel
Comment[eu]=Microsoft Excel kalkulu-orria
Comment[fa]=صفحۀ گستردۀ میکروسافت اکسل
Comment[fi]=Microsoft Excel -taulukko
Comment[fr]=Feuille de calcul Microsoft Excel
Comment[fy]=Microsoft Excel-Rekkenboerd
Comment[ga]=Scarbhileog Microsoft Excel
Comment[gl]=Folla de cálculo Microsoft Excel
Comment[he]=גיליון אלקטרוני של Microsoft Excel
Comment[hi]=माइक्रोसॉफ्ट एक्सेल स्प्रेडशीट
Comment[hr]=Microsoft Excel proračunska tablica
Comment[hu]=Microsoft Excel dokumentum
Comment[id]=Lembar Kerja Microsoft Excel
Comment[is]=Microsoft Excel tafla
Comment[it]=Foglio di calcolo Microsoft Excel
Comment[ja]=Microsoft Excel スプレッドシート
Comment[ka]=Microsoft Excelის ცხრილი
Comment[kk]=Microsoft Excel эл.кестесі
Comment[km]=សៀវភៅ​បញ្ជី Microsoft Excel
Comment[ko]=마이크로소프트 엑셀 스프레드시트
Comment[lb]=Microsoft-Excel-Tabellëblat
Comment[lt]=Microsoft Excel elektroninė lentelė
Comment[lv]=Microsoft Excel izklājlapa
Comment[mk]=Microsoft Excel-табеларна пресметка
Comment[mn]=MS-Excel-Хүснэгт
Comment[ms]=Hamparan helaian Microsoft Excel
Comment[mt]=Spreadsheet Microsoft Excel
Comment[nb]=Microsoft Excel-regneark
Comment[nds]="Microsoft Excel"-Arbeitblatt
Comment[ne]=माइक्रोसफ्ट एक्सेल स्प्रेडसिट
Comment[nl]=Microsoft Excel-spreadsheet
Comment[nn]=Microsoft Excel-rekneark
Comment[nso]=Letlakala la Phatlalatso la Bokgoni bja Microsoft
Comment[pa]=Microsoft Excel ਸਾਰਣੀਕਾਰ
Comment[pl]=Arkusz Microsoft Excela
Comment[pt]=Folha de cálculo do Microsoft Excel
Comment[pt_BR]=Planilha do Microsoft Excel
Comment[ro]=Foaie de calcul tabelar Microsoft Excel
Comment[ru]=Таблица Microsoft Excel
Comment[rw]=Urupapurorusesuye Microsoft Excel
Comment[se]=Microsoft Excel-tabealla
Comment[sk]=Dokument Microsoft Excel
Comment[sl]=Preglednica za Microsoft Excel
Comment[sq]=Tabak nga Microsoft Excel
Comment[sr]=Унакрсна табела Microsoft-овог Excel-а
Comment[sr@Latn]=Unakrsna tabela Microsoft-ovog Excel-a
Comment[sv]=Microsoft Excel-kalkylark
Comment[ta]=மைக்ரோசாப்ட் எக்செல் விரிதாள்
Comment[te]=మైక్రొసాఫ్ట్ ఎక్సెల్ స్ప్రెడ్ షీట్
Comment[tg]=Ҷадвалҳои электронӣ Microsoft Excel
Comment[th]=ตารางคำนวณไมโครซอฟต์เอ็กเซล
Comment[tr]=Microsoft Excel Hesap Çizelgesi
Comment[tt]=Microsoft Excel İsäpcäymäse
Comment[uk]=Таблиця MS Excel
Comment[uz]=Microsoft Excel elektron jadvali
Comment[uz@cyrillic]=Microsoft Excel электрон жадвали
Comment[ven]=Bammbiri lo navhaho la microsoft Excel
Comment[vi]=Bảng tính Excel của Microsoft™.
Comment[wa]=Fitchî tåvleu Microsoft Excel
Comment[zh_CN]=Microsoft Excel 电子表格
Comment[zh_HK]=微軟 Excel 表格
Comment[zh_TW]=微軟 Excel 表格
Comment[zu]= Ipheshana lesitayela le-Microsoft Excel
[Property::X-KDE-NativeExtension]
Type=QString
Value=.xls

@ -0,0 +1,89 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.openxmlformats-officedocument.spreadsheetml.template
Patterns=*.xltx;*.XLTX
Icon=spreadsheet
Comment=Microsoft Excel Spreadsheet Template
Comment[af]=Microsoft Excel Spreiblad
Comment[ar]=ورقة عمل مايكروسوفت اكسل
Comment[az]=Microsoft Excel Sənədi
Comment[be]=Разліковы аркуш Microsoft Excel
Comment[bg]=Документ на Microsoft Excel
Comment[bn]=মাইক্রোসফট এক্সসেল নথী
Comment[br]=Loger Microsoft Excel
Comment[bs]=Microsoft Excel proračunska tablica
Comment[ca]=Full de càlcul de Microsoft Excel
Comment[cs]=Tabulka programu Microsoft Excel
Comment[csb]=Bòga Microsoft Excela
Comment[cy]=Taenlen Microsoft Excel
Comment[da]=Microsoft Excel-regneark
Comment[de]=MS-Excel-Arbeitsblatt
Comment[el]=Φύλλο εργασίας Microsoft Excel
Comment[eo]=Mikrosoft-Excel-dokumento
Comment[es]=Hoja de cálculo de Microsoft Excel
Comment[et]=Microsoft Exceli tabel
Comment[eu]=Microsoft Excel kalkulu-orria
Comment[fa]=صفحۀ گستردۀ میکروسافت اکسل
Comment[fi]=Microsoft Excel -taulukko
Comment[fr]=Feuille de calcul Microsoft Excel
Comment[fy]=Microsoft Excel-Rekkenboerd
Comment[ga]=Scarbhileog Microsoft Excel
Comment[gl]=Folla de cálculo Microsoft Excel
Comment[he]=גיליון אלקטרוני של Microsoft Excel
Comment[hi]=माइक्रोसॉफ्ट एक्सेल स्प्रेडशीट
Comment[hr]=Microsoft Excel proračunska tablica
Comment[hu]=Microsoft Excel dokumentum
Comment[id]=Lembar Kerja Microsoft Excel
Comment[is]=Microsoft Excel tafla
Comment[it]=Foglio di calcolo Microsoft Excel
Comment[ja]=Microsoft Excel スプレッドシート
Comment[ka]=Microsoft Excelის ცხრილი
Comment[kk]=Microsoft Excel эл.кестесі
Comment[km]=សៀវភៅ​បញ្ជី Microsoft Excel
Comment[ko]=마이크로소프트 엑셀 스프레드시트
Comment[lb]=Microsoft-Excel-Tabellëblat
Comment[lt]=Microsoft Excel elektroninė lentelė
Comment[lv]=Microsoft Excel izklājlapa
Comment[mk]=Microsoft Excel-табеларна пресметка
Comment[mn]=MS-Excel-Хүснэгт
Comment[ms]=Hamparan helaian Microsoft Excel
Comment[mt]=Spreadsheet Microsoft Excel
Comment[nb]=Microsoft Excel-regneark
Comment[nds]="Microsoft Excel"-Arbeitblatt
Comment[ne]=माइक्रोसफ्ट एक्सेल स्प्रेडसिट
Comment[nl]=Microsoft Excel-spreadsheet
Comment[nn]=Microsoft Excel-rekneark
Comment[nso]=Letlakala la Phatlalatso la Bokgoni bja Microsoft
Comment[pa]=Microsoft Excel ਸਾਰਣੀਕਾਰ
Comment[pl]=Arkusz Microsoft Excela
Comment[pt]=Folha de cálculo do Microsoft Excel
Comment[pt_BR]=Planilha do Microsoft Excel
Comment[ro]=Foaie de calcul tabelar Microsoft Excel
Comment[ru]=Таблица Microsoft Excel
Comment[rw]=Urupapurorusesuye Microsoft Excel
Comment[se]=Microsoft Excel-tabealla
Comment[sk]=Dokument Microsoft Excel
Comment[sl]=Preglednica za Microsoft Excel
Comment[sq]=Tabak nga Microsoft Excel
Comment[sr]=Унакрсна табела Microsoft-овог Excel-а
Comment[sr@Latn]=Unakrsna tabela Microsoft-ovog Excel-a
Comment[sv]=Microsoft Excel-kalkylark
Comment[ta]=மைக்ரோசாப்ட் எக்செல் விரிதாள்
Comment[te]=మైక్రొసాఫ్ట్ ఎక్సెల్ స్ప్రెడ్ షీట్
Comment[tg]=Ҷадвалҳои электронӣ Microsoft Excel
Comment[th]=ตารางคำนวณไมโครซอฟต์เอ็กเซล
Comment[tr]=Microsoft Excel Hesap Çizelgesi
Comment[tt]=Microsoft Excel İsäpcäymäse
Comment[uk]=Таблиця MS Excel
Comment[uz]=Microsoft Excel elektron jadvali
Comment[uz@cyrillic]=Microsoft Excel электрон жадвали
Comment[ven]=Bammbiri lo navhaho la microsoft Excel
Comment[vi]=Bảng tính Excel của Microsoft™.
Comment[wa]=Fitchî tåvleu Microsoft Excel
Comment[zh_CN]=Microsoft Excel 电子表格
Comment[zh_HK]=微軟 Excel 表格
Comment[zh_TW]=微軟 Excel 表格
Comment[zu]= Ipheshana lesitayela le-Microsoft Excel
[Property::X-KDE-NativeExtension]
Type=QString
Value=.xls

@ -0,0 +1,91 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.openxmlformats-officedocument.wordprocessingml.document
Patterns=*.docx;*.DOCX
Icon=wordprocessing
Comment=Microsoft Word Document
Comment[af]=Microsoft Woord Dokument
Comment[ar]=مستند مايكروسوفت وورد
Comment[az]=Microsoft Word Sənədi
Comment[be]=Дакумент Microsoft Word
Comment[bg]=Документ на Microsoft Word
Comment[bn]=মাইক্রোসফট ওয়ার্ড নথী
Comment[br]=Teul Microsoft Word
Comment[bs]=Microsoft Word dokument
Comment[ca]=Document de Microsoft Word
Comment[cs]=Dokument programu Microsoft Word
Comment[csb]=Dokùment Microsoft Worda
Comment[cy]=Dogfen Microsoft Word
Comment[da]=Microsoft Word-dokument
Comment[de]=MS-Word-Dokument
Comment[el]=Έγγραφο Microsoft Word
Comment[eo]=Mikrosoft-Word-dokumento
Comment[es]=Documento de Microsoft Word
Comment[et]=Microsoft Wordi dokument
Comment[eu]=Microsoft Word dokumentua
Comment[fa]=سند میکروسافت ورد
Comment[fi]=Microsoft Word -asiakirja
Comment[fr]=Document Microsoft Word
Comment[fy]=Microsoft Word-dokumint
Comment[ga]=Cáipéis Microsoft Word
Comment[gl]=Documento de Microsoft Word
Comment[he]=מסמך Microsoft Word
Comment[hi]=माइक्रोसॉफ्ट वर्ड दस्तावेज़
Comment[hr]=Microsoft Word dokument
Comment[hu]=Microsoft Word dokumentum
Comment[id]=Dokumen Microsoft Word
Comment[is]=Microsoft Word skjal
Comment[it]=Documento Microsoft Word
Comment[ja]=Microsoft Word ドキュメント
Comment[ka]=Microsoft Wordის დოკუმენტი
Comment[kk]=Microsoft Word құжаты
Comment[km]=ឯកសារ Microsoft Word
Comment[ko]=마이크로소프트 글틀 문서
Comment[lb]=Microsoft-Word-Dokument
Comment[lt]=Microsoft Word dokumentas
Comment[lv]=Microsoft Word dokuments
Comment[mk]=Microsoft Word-документ
Comment[mn]=MS-Word-Баримт
Comment[ms]=Dokumen Microsoft Word
Comment[mt]=Dokument Microsoft Word
Comment[nb]=Microsoft Word-dokument
Comment[nds]="Microsoft Word"-Dokment
Comment[ne]=माइक्रोसफ्ट वर्ड कागजात
Comment[nl]=Microsoft Word-document
Comment[nn]=Microsoft Word-dokument
Comment[nso]=Tokomane ya Lentsu la Microsoft
Comment[pa]=Microsoft Word ਦਸਤਾਵੇਜ਼
Comment[pl]=Dokument Microsoft Worda
Comment[pt]=Documento do Microsoft Word
Comment[pt_BR]=Documento do Microsoft Word
Comment[ro]=Document Microsoft Word
Comment[ru]=Документ Microsoft Word
Comment[rw]=Microsoft Word Inyandiko
Comment[se]=Microsoft Word-dokumeanta
Comment[sk]=Dokument Microsoft Word
Comment[sl]=Dokument za Microsoft Word
Comment[sq]=Dokument nga Microsoft Word
Comment[sr]=Microsoft Word-ов документ
Comment[sr@Latn]=Microsoft Word-ov dokument
Comment[sv]=Microsoft Word-dokument
Comment[ta]=மைக்ரோசாப்ட் வேர்டு ஆவணம்
Comment[te]=మైక్రొసాఫ్ట్ పదం పత్రం
Comment[tg]=Ҳуҷҷати Microsoft Word
Comment[th]=เอกสารไมโครซอฟต์เวิร์ด
Comment[tr]=Microsoft Word Belgesi
Comment[tt]=Microsoft Word İstälege
Comment[uk]=Документ MS Word
Comment[uz]=Microsoft Word hujjati
Comment[uz@cyrillic]=Microsoft Word ҳужжати
Comment[ven]=Manwalwa a Microsoft Word
Comment[vi]=Tài liệu Word của Microsoft™.
Comment[wa]=Documint Microsoft Word
Comment[xh]=Uxwebhhu LweMicrosoft Word
Comment[zh_CN]=Microsoft Word 文档
Comment[zh_HK]=微軟 Word 文件
Comment[zh_TW]=微軟 Word 文件
Comment[zu]=Uhlu Lwamafayela lwe-Microsoft Word
[Property::X-KDE-NativeExtension]
Type=QString
Value=.doc

@ -0,0 +1,91 @@
[Desktop Entry]
Type=MimeType
MimeType=application/vnd.openxmlformats-officedocument.wordprocessingml.template
Patterns=*.dotx;*.DOTX
Icon=wordprocessing
Comment=Microsoft Word Document Template
Comment[af]=Microsoft Woord Dokument
Comment[ar]=مستند مايكروسوفت وورد
Comment[az]=Microsoft Word Sənədi
Comment[be]=Дакумент Microsoft Word
Comment[bg]=Документ на Microsoft Word
Comment[bn]=মাইক্রোসফট ওয়ার্ড নথী
Comment[br]=Teul Microsoft Word
Comment[bs]=Microsoft Word dokument
Comment[ca]=Document de Microsoft Word
Comment[cs]=Dokument programu Microsoft Word
Comment[csb]=Dokùment Microsoft Worda
Comment[cy]=Dogfen Microsoft Word
Comment[da]=Microsoft Word-dokument
Comment[de]=MS-Word-Dokument
Comment[el]=Έγγραφο Microsoft Word
Comment[eo]=Mikrosoft-Word-dokumento
Comment[es]=Documento de Microsoft Word
Comment[et]=Microsoft Wordi dokument
Comment[eu]=Microsoft Word dokumentua
Comment[fa]=سند میکروسافت ورد
Comment[fi]=Microsoft Word -asiakirja
Comment[fr]=Document Microsoft Word
Comment[fy]=Microsoft Word-dokumint
Comment[ga]=Cáipéis Microsoft Word
Comment[gl]=Documento de Microsoft Word
Comment[he]=מסמך Microsoft Word
Comment[hi]=माइक्रोसॉफ्ट वर्ड दस्तावेज़
Comment[hr]=Microsoft Word dokument
Comment[hu]=Microsoft Word dokumentum
Comment[id]=Dokumen Microsoft Word
Comment[is]=Microsoft Word skjal
Comment[it]=Documento Microsoft Word
Comment[ja]=Microsoft Word ドキュメント
Comment[ka]=Microsoft Wordის დოკუმენტი
Comment[kk]=Microsoft Word құжаты
Comment[km]=ឯកសារ Microsoft Word
Comment[ko]=마이크로소프트 글틀 문서
Comment[lb]=Microsoft-Word-Dokument
Comment[lt]=Microsoft Word dokumentas
Comment[lv]=Microsoft Word dokuments
Comment[mk]=Microsoft Word-документ
Comment[mn]=MS-Word-Баримт
Comment[ms]=Dokumen Microsoft Word
Comment[mt]=Dokument Microsoft Word
Comment[nb]=Microsoft Word-dokument
Comment[nds]="Microsoft Word"-Dokment
Comment[ne]=माइक्रोसफ्ट वर्ड कागजात
Comment[nl]=Microsoft Word-document
Comment[nn]=Microsoft Word-dokument
Comment[nso]=Tokomane ya Lentsu la Microsoft
Comment[pa]=Microsoft Word ਦਸਤਾਵੇਜ਼
Comment[pl]=Dokument Microsoft Worda
Comment[pt]=Documento do Microsoft Word
Comment[pt_BR]=Documento do Microsoft Word
Comment[ro]=Document Microsoft Word
Comment[ru]=Документ Microsoft Word
Comment[rw]=Microsoft Word Inyandiko
Comment[se]=Microsoft Word-dokumeanta
Comment[sk]=Dokument Microsoft Word
Comment[sl]=Dokument za Microsoft Word
Comment[sq]=Dokument nga Microsoft Word
Comment[sr]=Microsoft Word-ов документ
Comment[sr@Latn]=Microsoft Word-ov dokument
Comment[sv]=Microsoft Word-dokument
Comment[ta]=மைக்ரோசாப்ட் வேர்டு ஆவணம்
Comment[te]=మైక్రొసాఫ్ట్ పదం పత్రం
Comment[tg]=Ҳуҷҷати Microsoft Word
Comment[th]=เอกสารไมโครซอฟต์เวิร์ด
Comment[tr]=Microsoft Word Belgesi
Comment[tt]=Microsoft Word İstälege
Comment[uk]=Документ MS Word
Comment[uz]=Microsoft Word hujjati
Comment[uz@cyrillic]=Microsoft Word ҳужжати
Comment[ven]=Manwalwa a Microsoft Word
Comment[vi]=Tài liệu Word của Microsoft™.
Comment[wa]=Documint Microsoft Word
Comment[xh]=Uxwebhhu LweMicrosoft Word
Comment[zh_CN]=Microsoft Word 文档
Comment[zh_HK]=微軟 Word 文件
Comment[zh_TW]=微軟 Word 文件
Comment[zu]=Uhlu Lwamafayela lwe-Microsoft Word
[Property::X-KDE-NativeExtension]
Type=QString
Value=.doc

@ -0,0 +1,11 @@
[Desktop Entry]
Encoding=UTF-8
Comment=NewzBin Usenet Index
Hidden=false
MimeType=application/x-nzb
Icon=bt
Type=MimeType
Patterns=*.nzb
X-KDE-AutoEmbed=false
X-KDE-isAlso=text/xml

@ -9,7 +9,7 @@ endif
bin_PROGRAMS = $(KSVGTOPNG) bin_PROGRAMS = $(KSVGTOPNG)
ksvgtopng_SOURCES = ksvgtopng.cpp ksvgtopng_SOURCES = ksvgtopng.cpp
ksvgtopng_LDADD = $(LIBART_LIBS) $(LIB_KDECORE) $(top_builddir)/kdecore/svgicons/libkdesvgicons.la ksvgtopng_LDADD = $(LIB_KDECORE) $(top_builddir)/kdecore/svgicons/libkdesvgicons.la
ksvgtopng_LDFLAGS = $(KDE_RPATH) $(all_libraries) ksvgtopng_LDFLAGS = $(KDE_RPATH) $(all_libraries)
install-data-local: install-data-local:

Loading…
Cancel
Save