From 59dd46ef985a719579132efa6a9aa49bfeeae112 Mon Sep 17 00:00:00 2001 From: Robert Xu Date: Sat, 31 Mar 2012 14:28:06 -0400 Subject: better late than never, hm... --- opensuse/core/tdelibs/.project | 12 - opensuse/core/tdelibs/3_5_BRANCH.diff | 126 - opensuse/core/tdelibs/CATALOG.kdelibs3.diff | 139 - opensuse/core/tdelibs/add-suse-translations.diff | 22 +- opensuse/core/tdelibs/admin.diff | 55 - opensuse/core/tdelibs/admin.tar.bz2 | Bin 188090 -> 0 bytes opensuse/core/tdelibs/allow-man-setgid.diff | 32 - .../core/tdelibs/applications.menu-fallback.diff | 4 +- opensuse/core/tdelibs/arts-acinclude.patch | 12 +- opensuse/core/tdelibs/artwork.diff | 46 - opensuse/core/tdelibs/autostart-spec.diff | 55 - opensuse/core/tdelibs/avahi-pidfile.diff | 13 - opensuse/core/tdelibs/bnc557126.diff | 21 - .../tdelibs/bug-382959_kabc_fix_vcardparser.patch | 330 +- .../core/tdelibs/bug-399296_ftphandling-fix.diff | 57 - opensuse/core/tdelibs/bundle-locale-help.diff | 107 - opensuse/core/tdelibs/clever-menu.diff | 221 - opensuse/core/tdelibs/default-useragent.diff | 6 +- opensuse/core/tdelibs/desktop-translations.diff | 209 - opensuse/core/tdelibs/disable-idn-support.diff | 12 +- .../tdelibs/disable-samba-dialog-without-smb.diff | 66 - opensuse/core/tdelibs/fileshare.diff | 296 - .../fix-dcopidlng-within-kdelibs-build.diff | 8 +- opensuse/core/tdelibs/fix-gnome-help-support.diff | 52 +- .../tdelibs/fix-gnome-help-support_legacy.diff | 46 +- opensuse/core/tdelibs/fix-kdemm-build.diff | 88 - opensuse/core/tdelibs/fix-kerberos-printing.diff | 37 - opensuse/core/tdelibs/fix-macmenu.patch | 11 - opensuse/core/tdelibs/fix-qxembed.diff | 80 - opensuse/core/tdelibs/flash-player-non-oss.diff | 64 +- .../core/tdelibs/fontconfig-reverse-lookup.diff | 137 - opensuse/core/tdelibs/gcc44.diff | 20 - opensuse/core/tdelibs/gcc45.diff | 31 - opensuse/core/tdelibs/google-mail.diff | 18 - opensuse/core/tdelibs/ignore-inline-menu.diff | 6 +- .../tdelibs/integrate-global-pixmaps-10.1.diff | 14 +- .../core/tdelibs/integrate-global-pixmaps-new.diff | 10 +- opensuse/core/tdelibs/kcontrol_crash_patch.diff | 11 - opensuse/core/tdelibs/kde3rc.dif | 18 +- opensuse/core/tdelibs/kde4-applications.diff | 70 - opensuse/core/tdelibs/kdecode_fakes_include.diff | 18 - .../tdelibs/kdelibs-3.5.10-CVE-2009-2702.patch | 62 - .../tdelibs/kdelibs-3.5.10-cve-2009-1698.patch | 42 - .../tdelibs/kdelibs-3.5.10-cve-2009-1725.patch | 13 - opensuse/core/tdelibs/kdelibs-3.5.10-kio.patch | 21 +- .../kdelibs-3.5.10-latex-syntax-kile-2.0.3.patch | 143 - .../core/tdelibs/kdelibs-3.5.10-ossl-1.x.patch | 180 - .../core/tdelibs/kdelibs-3.5.4-CVE-2009-1690.patch | 545 -- .../core/tdelibs/kdelibs3-gcc-4.1-miscompile.diff | 15 - .../tdelibs/kdelibs3-hicolor-scalable-sizes.patch | 2 +- .../tdelibs/kdelibs_networkstatus_branch2.diff | 69 - opensuse/core/tdelibs/kdemm-20050330.tar.bz2 | Bin 42068 -> 0 bytes opensuse/core/tdelibs/kdemm-filepreview.diff | 40 - opensuse/core/tdelibs/kdemm.diff | 669 --- opensuse/core/tdelibs/kdeprint-restart-cupsd.diff | 38 +- opensuse/core/tdelibs/kdeprint-utf8.diff | 13 - opensuse/core/tdelibs/kdesu-settings.diff | 50 - opensuse/core/tdelibs/kdeversion.diff | 8 +- opensuse/core/tdelibs/kfile-beagle.diff | 42 - opensuse/core/tdelibs/kickoff-drop-shadow.diff | 177 - opensuse/core/tdelibs/kimproxy-warning.diff | 13 - opensuse/core/tdelibs/kmimelist.diff | 81 - opensuse/core/tdelibs/kremoteencoding-utf8.diff | 28 - opensuse/core/tdelibs/ktip-icon-hack.diff | 56 - opensuse/core/tdelibs/kwalletd-try-open.diff | 81 - .../core/tdelibs/light_v_2_scrollbar_patch.patch | 34 - opensuse/core/tdelibs/limit-max-image-size.diff | 28 - opensuse/core/tdelibs/lpoptions-cups-1.2.diff | 28 - opensuse/core/tdelibs/mimetype-changes.diff | 36 - opensuse/core/tdelibs/mozilla-sliders.patch | 19 - opensuse/core/tdelibs/networkstatus.diff | 6006 -------------------- opensuse/core/tdelibs/no-debug-by-default.diff | 40 +- .../no-progress-for-beagle-status-query.diff | 13 - opensuse/core/tdelibs/noauto-package.diff | 2 +- opensuse/core/tdelibs/oom_score_adj.patch | 36 - .../core/tdelibs/patch-mimetype-iconnames.diff | 39 - .../core/tdelibs/prefer_distribution_settings.dif | 14 +- opensuse/core/tdelibs/printpreview.patch | 14 - opensuse/core/tdelibs/r874968-ebay-crash.diff | 24 - opensuse/core/tdelibs/rubberband-selection.diff | 380 -- opensuse/core/tdelibs/show-distribution.diff | 21 - opensuse/core/tdelibs/silence.diff | 13 - opensuse/core/tdelibs/smooth-scrolling.diff | 267 - opensuse/core/tdelibs/spellcheck-default-utf8.diff | 26 - opensuse/core/tdelibs/stat-on-media.diff | 14 - opensuse/core/tdelibs/tdelibs-devel-doc.spec | 6 +- opensuse/core/tdelibs/tdelibs.spec | 90 +- opensuse/core/tdelibs/tdelibs.spec.old | 826 --- opensuse/core/tdelibs/textcompletion-editor.diff | 344 -- opensuse/core/tdelibs/use-mediamanager.diff | 44 - opensuse/core/tdelibs/use-xauthlocalhostname.diff | 240 - opensuse/core/tdelibs/x-kde-InitialPreference.diff | 16 - opensuse/core/tdelibs/xinerama.patch | 543 -- opensuse/core/tdelibs/xml-catalog.diff | 44 - opensuse/core/tdelibs/xmlhttprequest_3.x.diff | 47 - 95 files changed, 426 insertions(+), 13796 deletions(-) delete mode 100644 opensuse/core/tdelibs/.project delete mode 100644 opensuse/core/tdelibs/3_5_BRANCH.diff delete mode 100644 opensuse/core/tdelibs/CATALOG.kdelibs3.diff delete mode 100644 opensuse/core/tdelibs/admin.diff delete mode 100644 opensuse/core/tdelibs/admin.tar.bz2 delete mode 100644 opensuse/core/tdelibs/allow-man-setgid.diff delete mode 100644 opensuse/core/tdelibs/artwork.diff delete mode 100644 opensuse/core/tdelibs/autostart-spec.diff delete mode 100644 opensuse/core/tdelibs/avahi-pidfile.diff delete mode 100644 opensuse/core/tdelibs/bnc557126.diff delete mode 100644 opensuse/core/tdelibs/bug-399296_ftphandling-fix.diff delete mode 100644 opensuse/core/tdelibs/bundle-locale-help.diff delete mode 100644 opensuse/core/tdelibs/clever-menu.diff delete mode 100644 opensuse/core/tdelibs/desktop-translations.diff delete mode 100644 opensuse/core/tdelibs/disable-samba-dialog-without-smb.diff delete mode 100644 opensuse/core/tdelibs/fileshare.diff delete mode 100644 opensuse/core/tdelibs/fix-kdemm-build.diff delete mode 100644 opensuse/core/tdelibs/fix-kerberos-printing.diff delete mode 100644 opensuse/core/tdelibs/fix-macmenu.patch delete mode 100644 opensuse/core/tdelibs/fix-qxembed.diff delete mode 100644 opensuse/core/tdelibs/fontconfig-reverse-lookup.diff delete mode 100644 opensuse/core/tdelibs/gcc44.diff delete mode 100644 opensuse/core/tdelibs/gcc45.diff delete mode 100644 opensuse/core/tdelibs/google-mail.diff delete mode 100644 opensuse/core/tdelibs/kcontrol_crash_patch.diff delete mode 100644 opensuse/core/tdelibs/kde4-applications.diff delete mode 100644 opensuse/core/tdelibs/kdecode_fakes_include.diff delete mode 100644 opensuse/core/tdelibs/kdelibs-3.5.10-CVE-2009-2702.patch delete mode 100644 opensuse/core/tdelibs/kdelibs-3.5.10-cve-2009-1698.patch delete mode 100644 opensuse/core/tdelibs/kdelibs-3.5.10-cve-2009-1725.patch delete mode 100644 opensuse/core/tdelibs/kdelibs-3.5.10-latex-syntax-kile-2.0.3.patch delete mode 100644 opensuse/core/tdelibs/kdelibs-3.5.10-ossl-1.x.patch delete mode 100644 opensuse/core/tdelibs/kdelibs-3.5.4-CVE-2009-1690.patch delete mode 100644 opensuse/core/tdelibs/kdelibs3-gcc-4.1-miscompile.diff delete mode 100644 opensuse/core/tdelibs/kdelibs_networkstatus_branch2.diff delete mode 100644 opensuse/core/tdelibs/kdemm-20050330.tar.bz2 delete mode 100644 opensuse/core/tdelibs/kdemm-filepreview.diff delete mode 100644 opensuse/core/tdelibs/kdemm.diff delete mode 100644 opensuse/core/tdelibs/kdeprint-utf8.diff delete mode 100644 opensuse/core/tdelibs/kdesu-settings.diff delete mode 100644 opensuse/core/tdelibs/kfile-beagle.diff delete mode 100644 opensuse/core/tdelibs/kickoff-drop-shadow.diff delete mode 100644 opensuse/core/tdelibs/kimproxy-warning.diff delete mode 100644 opensuse/core/tdelibs/kmimelist.diff delete mode 100644 opensuse/core/tdelibs/kremoteencoding-utf8.diff delete mode 100644 opensuse/core/tdelibs/ktip-icon-hack.diff delete mode 100644 opensuse/core/tdelibs/kwalletd-try-open.diff delete mode 100644 opensuse/core/tdelibs/light_v_2_scrollbar_patch.patch delete mode 100644 opensuse/core/tdelibs/limit-max-image-size.diff delete mode 100644 opensuse/core/tdelibs/lpoptions-cups-1.2.diff delete mode 100644 opensuse/core/tdelibs/mimetype-changes.diff delete mode 100644 opensuse/core/tdelibs/mozilla-sliders.patch delete mode 100644 opensuse/core/tdelibs/networkstatus.diff delete mode 100644 opensuse/core/tdelibs/no-progress-for-beagle-status-query.diff delete mode 100644 opensuse/core/tdelibs/oom_score_adj.patch delete mode 100644 opensuse/core/tdelibs/patch-mimetype-iconnames.diff delete mode 100644 opensuse/core/tdelibs/printpreview.patch delete mode 100644 opensuse/core/tdelibs/r874968-ebay-crash.diff delete mode 100644 opensuse/core/tdelibs/rubberband-selection.diff delete mode 100644 opensuse/core/tdelibs/show-distribution.diff delete mode 100644 opensuse/core/tdelibs/silence.diff delete mode 100644 opensuse/core/tdelibs/smooth-scrolling.diff delete mode 100644 opensuse/core/tdelibs/spellcheck-default-utf8.diff delete mode 100644 opensuse/core/tdelibs/stat-on-media.diff delete mode 100644 opensuse/core/tdelibs/tdelibs.spec.old delete mode 100644 opensuse/core/tdelibs/textcompletion-editor.diff delete mode 100644 opensuse/core/tdelibs/use-mediamanager.diff delete mode 100644 opensuse/core/tdelibs/use-xauthlocalhostname.diff delete mode 100644 opensuse/core/tdelibs/x-kde-InitialPreference.diff delete mode 100644 opensuse/core/tdelibs/xinerama.patch delete mode 100644 opensuse/core/tdelibs/xml-catalog.diff delete mode 100644 opensuse/core/tdelibs/xmlhttprequest_3.x.diff (limited to 'opensuse/core/tdelibs') diff --git a/opensuse/core/tdelibs/.project b/opensuse/core/tdelibs/.project deleted file mode 100644 index de1dea1f3..000000000 --- a/opensuse/core/tdelibs/.project +++ /dev/null @@ -1,12 +0,0 @@ - - - tdelibs - - - - - - - org.eclipse.linuxtools.rpm.core.rpmnature - - diff --git a/opensuse/core/tdelibs/3_5_BRANCH.diff b/opensuse/core/tdelibs/3_5_BRANCH.diff deleted file mode 100644 index 6809b8aea..000000000 --- a/opensuse/core/tdelibs/3_5_BRANCH.diff +++ /dev/null @@ -1,126 +0,0 @@ -package: kdelibs-3.5.10.tar.bz2 -kdemod: kdelibs -Index: BRANCH_STATUS -=================================================================== ---- /dev/null -+++ BRANCH_STATUS -@@ -0,0 +1,2 @@ -+current HEAD: 859452 -+svn di between //tags/KDE/3.5.10/kdelibs and //branches/KDE/3.5/kdelibs -Index: kinit/start_kdeinit.c -=================================================================== ---- kinit/start_kdeinit.c.orig -+++ kinit/start_kdeinit.c -@@ -44,7 +44,7 @@ static int set_protection( pid_t pid, in - { - char buf[ 1024 ]; - int procfile; -- sprintf( buf, "/proc/%d/oom_adj", pid ); -+ sprintf( buf, "/proc/%d/stat", pid ); - if( !enable ) { - /* Be paranoid and check that the pid we got from the pipe - belongs to this user. */ -@@ -52,6 +52,7 @@ static int set_protection( pid_t pid, in - if( lstat( buf, &st ) < 0 || st.st_uid != getuid()) - return 0; - } -+ sprintf( buf, "/proc/%d/oom_adj", pid ); - procfile = open( buf, O_WRONLY ); - if( procfile >= 0 ) { - if( enable ) -Index: kio/kio/configure.in.in -=================================================================== ---- kio/kio/configure.in.in.orig -+++ kio/kio/configure.in.in -@@ -139,8 +139,30 @@ if test "x$kde_enable_inotify" = "xyes"; - AC_LANG_RESTORE - ]) - -- if test "$kde_cv_have_inotify" = "yes" ; then -+ AC_CACHE_VAL(kde_cv_have_sys_inotify, -+ [ -+ kde_cv_have_sys_inotify=no -+ AC_LANG_SAVE -+ AC_LANG_C -+ -+ AC_TRY_COMPILE( -+ [ -+#include -+ ], -+ [ -+#ifndef IN_ALL_EVENTS -+#error no inotify notification -+#endif -+ ],kde_cv_have_sys_inotify=yes,kde_cv_have_sys_inotify=no) -+ -+ AC_LANG_RESTORE -+ ]) -+ -+ if test "$kde_cv_have_inotify" = "yes" -o "$kde_cv_have_sys_inotify" = "yes"; then - AC_DEFINE_UNQUOTED(HAVE_INOTIFY, 1, [Define if your system has Linux Inode Notification]) -+ if test "$kde_cv_have_sys_inotify" = "yes"; then -+ AC_DEFINE_UNQUOTED(HAVE_SYS_INOTIFY, 1, [Define if your system has glibc support for inotify]) -+ fi - AC_MSG_RESULT(yes) - else - AC_MSG_RESULT(no) -Index: kio/kio/kdirwatch.cpp -=================================================================== ---- kio/kio/kdirwatch.cpp.orig -+++ kio/kio/kdirwatch.cpp -@@ -64,11 +64,13 @@ - // debug - #include - --#ifdef HAVE_INOTIFY -+#ifdef HAVE_SYS_INOTIFY -+#include -+#include -+#elif HAVE_INOTIFY - #include - #include - #include --#include - // Linux kernel headers are documented to not compile - #define _S390_BITOPS_H - #include -@@ -87,7 +89,9 @@ static inline int inotify_rm_watch (int - { - return syscall (__NR_inotify_rm_watch, fd, wd); - } -+#endif - -+#ifdef HAVE_INOTIFY - #ifndef IN_ONLYDIR - #define IN_ONLYDIR 0x01000000 - #endif -@@ -99,7 +103,6 @@ static inline int inotify_rm_watch (int - #ifndef IN_MOVE_SELF - #define IN_MOVE_SELF 0x00000800 - #endif -- - #endif - - #include -Index: kdoctools/customization/pt-BR/user.entities -=================================================================== ---- kdoctools/customization/pt-BR/user.entities.orig -+++ kdoctools/customization/pt-BR/user.entities -@@ -17,7 +17,7 @@ - Esc"> - etc"> - por exemplo"> --FAQ)"> -+FAQ)"> - HTML'> - - Centro de Informações"> -@@ -34,7 +34,7 @@ - esquerdo do mouse"> - meio do mouse"> - Sistema Operacional"> --direto do mouse"> -+direito do mouse"> - Shift"> - bandeja do sistema"> - Tab"> diff --git a/opensuse/core/tdelibs/CATALOG.kdelibs3.diff b/opensuse/core/tdelibs/CATALOG.kdelibs3.diff deleted file mode 100644 index 5fac7cf92..000000000 --- a/opensuse/core/tdelibs/CATALOG.kdelibs3.diff +++ /dev/null @@ -1,139 +0,0 @@ -Index: kdelibs-3.5.10/CATALOG.kdelibs3 -=================================================================== ---- /dev/null -+++ kdelibs-3.5.10/CATALOG.kdelibs3 -@@ -0,0 +1,134 @@ -+-- -+Catalogue for KDE DocBook XML -+ -+Copyright (C) 2001,2002 Frederik Fouvry -+ -+This program is free software; you can redistribute it and/or -+modify it under the terms of the GNU General Public License -+as published by the Free Software Foundation; either version 2 -+of the License, or (at your option) any later version. -+ -+This program is distributed in the hope that it will be useful, -+but WITHOUT ANY WARRANTY; without even the implied warranty of -+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+GNU General Public License for more details. -+ -+You should have received a copy of the GNU General Public License -+along with this program; if not, write to the Free Software -+Foundation, Inc., 51 Franklin Steet, Fifth Floor, Boston, MA 02110-1301, USA. -+ -+Send suggestions, comments, etc. to the KDE DocBook mailing list -+. -+-- -+ -+OVERRIDE YES -+-- SGMLDECL "xml.dcl" -- -+DTDDECL "-//KDE//DTD DocBook XML V4.2-Based Variant V1.1//EN" /usr/share/sgml/opensp/xml.dcl -+DTDDECL "-//KDE//ELEMENTS DocBook XML Hierarchy Redeclarations 2 V1.0//EN" /usr/share/sgml/opensp/xml.dcl -+DTDDECL "-//KDE//ELEMENTS DocBook XML Pool Redeclarations V1.1//EN" /usr/share/sgml/opensp/xml.dcl -+DTDDECL "-//KDE//ELEMENTS DocBook XML Modifications (Restrictions) V1.1//EN" /usr/share/sgml/opensp/xml.dcl -+DTDDECL "-//KDE//ENTITIES DocBook XML General Entity Declarations V1.2//EN" /usr/share/sgml/opensp/xml.dcl -+DTDDECL "-//KDE//ENTITIES DocBook XML General Entity Declarations (Persons) V1.0//EN" /usr/share/sgml/opensp/xml.dcl -+DTDDECL "-//KDE//ENTITIES DocBook XML Localisation Entity Declarations V1.0//EN" /usr/share/sgml/opensp/xml.dcl -+ -+ -- DocBook -- -+ -+-- DocBook 4.2 KDE Variant V1.1 -- -+ -+PUBLIC "-//KDE//DTD DocBook XML V4.2-Based Variant V1.1//EN" -+ "dtd/kdex.dtd" -+PUBLIC "-//KDE//ELEMENTS DocBook XML Hierarchy Redeclarations 2 V1.0//EN" -+ "dtd/rdbhier2.elements" -+PUBLIC "-//KDE//ELEMENTS DocBook XML Pool Redeclarations V1.1//EN" -+ "dtd/rdbpool.elements" -+PUBLIC "-//KDE//ELEMENTS DocBook XML Modifications (Restrictions) V1.1//EN" -+ "dtd/modifications.elements" -+ -+PUBLIC "-//KDE//ENTITIES DocBook XML General Entity Declarations V1.2//EN" -+ "entities/general.entities" -+PUBLIC "-//KDE//ENTITIES DocBook XML General Entity Declarations (Persons) V1.0//EN" -+ "entities/contributor.entities" -+ -+ -- General KDE Entities -- -+ -+PUBLIC "-//KDE//ENTITIES DocBook XML Localisation Entity Declarations V1.0//EN" -+ "entities/l10n.entities" -+ -+ -- Various external files -- -+ -+-- only DocBook XML files are in entities, the others are in -+ kdelibs/doc/common or in kdelibs/licenses -- -+ -+PUBLIC "-//GNU//DOCUMENT GNU General Public License V2//EN" -+ "entities/gpl-license" -+PUBLIC "-//GNU//DOCUMENT GNU Lesser General Public License V2.1//EN" -+ "entities/lgpl-license" -+PUBLIC "-//GNU//DOCUMENT GNU Free Documentation License V1.1//EN" -+ "entities/fdl-license" -+PUBLIC "-//KDE//DOCUMENT X11 License//EN" -+ "entities/x11-license" -+PUBLIC "-//KDE//DOCUMENT BSD License//EN" -+ "entities/bsd-license" -+PUBLIC "-//KDE//DOCUMENT Artistic License//EN" -+ "entities/artistic-license" -+ -+CATALOG af/catalog -+CATALOG bg/catalog -+CATALOG ca/catalog -+CATALOG cs/catalog -+CATALOG da/catalog -+CATALOG de/catalog -+CATALOG el/catalog -+CATALOG en/catalog -+CATALOG en-GB/catalog -+CATALOG es/catalog -+CATALOG et/catalog -+CATALOG fi/catalog -+CATALOG fo/catalog -+CATALOG fr/catalog -+CATALOG he/catalog -+CATALOG hu/catalog -+CATALOG id/catalog -+CATALOG it/catalog -+CATALOG ja/catalog -+CATALOG ko/catalog -+CATALOG lt/catalog -+CATALOG nl/catalog -+CATALOG no/catalog -- considered to be the same as nb -- -+CATALOG nn/catalog -- incorrectly known as no_NY -- -+CATALOG pl/catalog -+CATALOG pt-BR/catalog -+CATALOG pt/catalog -+CATALOG ro/catalog -+CATALOG ru/catalog -+CATALOG sk/catalog -+CATALOG sl/catalog -+CATALOG sr/catalog -+CATALOG sv/catalog -+CATALOG tr/catalog -+CATALOG uk/catalog -+CATALOG wa/catalog -+CATALOG xh/catalog -+CATALOG zh-CN/catalog -+CATALOG zh-TW/catalog -+ -+-- DocBook 4.1.2 KDE Variant V1.1 -- -+ -+PUBLIC "-//KDE//DTD DocBook XML V4.1.2-Based Variant V1.1//EN" -+ "obsolete/kdex.dtd" -+PUBLIC "-//KDE//ENTITIES DocBook XML General Entity Declarations V1.1//EN" -+ "obsolete/general.entities" -+PUBLIC "-//KDE//ELEMENTS DocBook XML Pool Redeclarations V1.0//EN" -+ "obsolete/rdbpool.elements" -+PUBLIC "-//KDE//ELEMENTS DocBook XML Modifications V1.0//EN" -+ "obsolete/modifications.elements" -+ -+-- DocBook 4.1.2 KDE Variant V1.0 -- -+ -+PUBLIC "-//KDE//DTD DocBook XML V4.1.2-Based Variant V1.0//EN" -+ "obsolete/kdex-412-10.dtd" -+ -+-- DocBook 4.1 KDE Variant V1.0 -- -+ -+PUBLIC "-//KDE//DTD DocBook XML V4.1-Based Variant V1.0//EN" -+ "obsolete/kdex-412-10.dtd" diff --git a/opensuse/core/tdelibs/add-suse-translations.diff b/opensuse/core/tdelibs/add-suse-translations.diff index 2cb8ce8cb..b95ad9b7c 100644 --- a/opensuse/core/tdelibs/add-suse-translations.diff +++ b/opensuse/core/tdelibs/add-suse-translations.diff @@ -1,14 +1,14 @@ -Index: kdecore/klocale.cpp +Index: tdecore/klocale.cpp =================================================================== ---- kdecore/klocale.cpp.orig -+++ kdecore/klocale.cpp -@@ -131,6 +131,9 @@ void KLocale::initMainCatalogues(const Q - d->catalogNames.append( mainCatalogue ); // application catalog - d->catalogNames.append( SYSTEM_MESSAGES ); // always include kdelibs.mo - d->catalogNames.append( "kio" ); // always include kio.mo -+ KGlobal::dirs()->addResourceDir("locale", "/usr/share/locale"); -+ d->catalogNames.append( "desktop_translations" ); -+ d->catalogNames.append( "susetranslations" ); +--- tdecore/klocale.cpp.orig ++++ tdecore/klocale.cpp +@@ -139,6 +139,9 @@ void KLocale::initMainCatalogues(const Q + d->catalogNames.append( SYSTEM_MESSAGES ); // always include tdelibs.mo + d->catalogNames.append( "kio" ); // always include kio.mo + d->catalogNames.append( "xdg-user-dirs" ); ++ KGlobal::dirs()->addResourceDir("locale", "/usr/share/locale"); ++ d->catalogNames.append( "desktop_translations" ); ++ d->catalogNames.append( "susetranslations" ); + } updateCatalogues(); // evaluate this for all languages } - } diff --git a/opensuse/core/tdelibs/admin.diff b/opensuse/core/tdelibs/admin.diff deleted file mode 100644 index 8abac2426..000000000 --- a/opensuse/core/tdelibs/admin.diff +++ /dev/null @@ -1,55 +0,0 @@ -Index: admin/acinclude.m4.in -=================================================================== ---- admin/acinclude.m4.in.orig -+++ admin/acinclude.m4.in -@@ -4988,6 +4988,7 @@ AC_DEFUN([KDE_SET_PREFIX_CORE], - fi - # And delete superfluous '/' to make compares easier - prefix=`echo "$prefix" | sed 's,//*,/,g' | sed -e 's,/$,,'` -+ kde_libs_htmldir=$prefix/share/doc/HTML/ - exec_prefix=`echo "$exec_prefix" | sed 's,//*,/,g' | sed -e 's,/$,,'` - - kde_libs_prefix='$(prefix)' -Index: admin/detect-autoconf.pl -=================================================================== ---- admin/detect-autoconf.pl.orig -+++ admin/detect-autoconf.pl -@@ -216,7 +216,7 @@ $unsermake = ""; - # backward compatible: if $UNSERMAKE points to a path, use it - $unsermake = findProgram('unsermake') if (defined($ENV{'UNSERMAKE'}) and $ENV{'UNSERMAKE'} =~ /\//); - # new compatible: if it says 'yes', use the one from path --$unsermake = which('unsermake') if ($ENV{'UNSERMAKE'} ne 'no'); -+$unsermake = which('unsermake') if ($ENV{'UNSERMAKE'} eq 'yes'); - - ($automake_suffix) = $automake =~ /.*automake(.*)$/; - - ---- admin/cvs.sh -+++ admin/cvs.sh -@@ -32,7 +32,7 @@ check_autotool_versions() - required_autoconf_version="2.53 or newer" - AUTOCONF_VERSION=`$AUTOCONF --version | head -n 1` - case $AUTOCONF_VERSION in -- Autoconf*2.5* | autoconf*2.5* | autoconf*2.6* ) : ;; -+ autoconf* ) : ;; - "" ) - echo "*** AUTOCONF NOT FOUND!." - echo "*** KDE requires autoconf $required_autoconf_version" -@@ -47,7 +47,7 @@ esac - - AUTOHEADER_VERSION=`$AUTOHEADER --version | head -n 1` - case $AUTOHEADER_VERSION in -- Autoconf*2.5* | autoheader*2.5* | autoheader*2.6* ) : ;; -+ autoheader* ) : ;; - "" ) - echo "*** AUTOHEADER NOT FOUND!." - echo "*** KDE requires autoheader $required_autoconf_version" -@@ -68,7 +68,7 @@ case $AUTOMAKE_STRING in - echo "*** KDE requires automake $required_automake_version" - exit 1 - ;; -- automake*1.6.* | automake*1.7* | automake*1.8* | automake*1.9* | automake*1.10*) -+ automake*) - echo "*** $AUTOMAKE_STRING found." - UNSERMAKE=no - ;; diff --git a/opensuse/core/tdelibs/admin.tar.bz2 b/opensuse/core/tdelibs/admin.tar.bz2 deleted file mode 100644 index 7a2e55a1e..000000000 Binary files a/opensuse/core/tdelibs/admin.tar.bz2 and /dev/null differ diff --git a/opensuse/core/tdelibs/allow-man-setgid.diff b/opensuse/core/tdelibs/allow-man-setgid.diff deleted file mode 100644 index 51a47d720..000000000 --- a/opensuse/core/tdelibs/allow-man-setgid.diff +++ /dev/null @@ -1,32 +0,0 @@ -Index: kdecore/kapplication.cpp -=================================================================== ---- kdecore/kapplication.cpp.orig -+++ kdecore/kapplication.cpp -@@ -87,6 +87,8 @@ - #include - #endif - #include -+#include -+#include - - #ifndef Q_WS_WIN - #include "kwin.h" -@@ -776,10 +778,15 @@ void KApplication::init(bool GUIenabled) - { - d->guiEnabled = GUIenabled; - if ((getuid() != geteuid()) || -- (getgid() != getegid())) -+ (getgid() != getegid()) ) - { -- fprintf(stderr, "The KDE libraries are not designed to run with suid privileges.\n"); -- ::exit(127); -+ // man permissions are not exploitable and better than -+ // world writable directories -+ struct group *man = getgrnam("man"); -+ if ( !man || man->gr_gid != getegid() ){ -+ fprintf(stderr, "The KDE libraries are not designed to run with suid privileges.\n"); -+ ::exit(127); -+ } - } - - KProcessController::ref(); diff --git a/opensuse/core/tdelibs/applications.menu-fallback.diff b/opensuse/core/tdelibs/applications.menu-fallback.diff index 69450dad8..b2c339b1d 100644 --- a/opensuse/core/tdelibs/applications.menu-fallback.diff +++ b/opensuse/core/tdelibs/applications.menu-fallback.diff @@ -4,8 +4,8 @@ Index: kded/kbuildsycoca.cpp +++ kded/kbuildsycoca.cpp @@ -378,8 +378,12 @@ bool KBuildSycoca::build() - connect(g_vfolder, SIGNAL(newService(const QString &, KService **)), - this, SLOT(slotCreateEntry(const QString &, KService **))); + connect(g_vfolder, TQT_SIGNAL(newService(const TQString &, KService **)), + this, TQT_SLOT(slotCreateEntry(const TQString &, KService **))); - - VFolderMenu::SubMenu *kdeMenu = g_vfolder->parseMenu("applications.menu", true); + diff --git a/opensuse/core/tdelibs/arts-acinclude.patch b/opensuse/core/tdelibs/arts-acinclude.patch index 0610d6df5..e387ac2f2 100644 --- a/opensuse/core/tdelibs/arts-acinclude.patch +++ b/opensuse/core/tdelibs/arts-acinclude.patch @@ -11,7 +11,7 @@ should go upstream. --- arts-1.5.10/admin/acinclude.m4.in 2008-08-20 18:07:05.000000000 +0200 +++ arts-1.5.10/admin/acinclude.m4.in 2009-12-09 17:30:57.000000000 +0100 -@@ -3081,8 +3081,18 @@ +@@ -3364,8 +3364,18 @@ fi ]) @@ -30,7 +30,7 @@ should go upstream. AC_ARG_ENABLE(debug, AC_HELP_STRING([--enable-debug=ARG],[enables debug symbols (yes|no|full) [default=no]]), [ -@@ -3141,11 +3151,6 @@ +@@ -3424,11 +3434,6 @@ [kde_use_profiling="no"] ) @@ -40,9 +40,9 @@ should go upstream. - AC_PROG_CC - AC_PROG_CPP - - if test "$GCC" = "yes"; then -@@ -3174,10 +3179,6 @@ + + AC_C_BIGENDIAN +@@ -3459,10 +3464,6 @@ LDFLAGS="" fi @@ -53,7 +53,7 @@ should go upstream. KDE_CHECK_FOR_BAD_COMPILER if test "$GXX" = "yes" || test "$CXX" = "KCC"; then -@@ -3503,8 +3504,8 @@ +@@ -3802,8 +3803,8 @@ AC_REQUIRE([AC_LIBTOOL_DLOPEN]) AC_REQUIRE([KDE_CHECK_LIB64]) diff --git a/opensuse/core/tdelibs/artwork.diff b/opensuse/core/tdelibs/artwork.diff deleted file mode 100644 index 0c6742d22..000000000 --- a/opensuse/core/tdelibs/artwork.diff +++ /dev/null @@ -1,46 +0,0 @@ -Index: kdecore/eventsrc -=================================================================== ---- kdecore/eventsrc.orig -+++ kdecore/eventsrc -@@ -2572,7 +2572,7 @@ Comment[wa]=On messaedje critike est hå - Comment[zh_CN]=正在显示关键消息 - Comment[zh_HK]=顯示嚴重警告訊息 - Comment[zh_TW]=嚴重的警告訊息已顯示 --default_sound=KDE_Glass_Break.ogg -+default_sound=KDE_Error_1.ogg - default_presentation=65 - nopresentation=18 - level=4 -Index: mimetypes/application/x-bittorrent.desktop -=================================================================== ---- mimetypes/application/x-bittorrent.desktop.orig -+++ mimetypes/application/x-bittorrent.desktop -@@ -1,4 +1,5 @@ - [Desktop Entry] -+Icon=torrent - Comment=BitTorrent Download - Comment[af]=BitTorrent Aflaai - Comment[ar]=ملف تنزيل BitTorrent -Index: mimetypes/application/x-msdos-program.desktop -=================================================================== ---- mimetypes/application/x-msdos-program.desktop.orig -+++ mimetypes/application/x-msdos-program.desktop -@@ -85,5 +85,5 @@ MimeType=application/x-msdos-program - X-KDE-IsAlso=application/x-executable - [Property::X-KDE-NativeExtension] - Type=QString --Value=.exe -+Value=.exe;.EXE; - -Index: kresources/kresources.desktop -=================================================================== ---- kresources/kresources.desktop.orig -+++ kresources/kresources.desktop -@@ -1,6 +1,6 @@ - [Desktop Entry] - Exec=kcmshell kresources --Icon=date -+Icon=about_kde - Type=Application - Terminal=false - diff --git a/opensuse/core/tdelibs/autostart-spec.diff b/opensuse/core/tdelibs/autostart-spec.diff deleted file mode 100644 index a67a8e487..000000000 --- a/opensuse/core/tdelibs/autostart-spec.diff +++ /dev/null @@ -1,55 +0,0 @@ -Index: kdecore/kstandarddirs.cpp -=================================================================== ---- kdecore/kstandarddirs.cpp.orig -+++ kdecore/kstandarddirs.cpp -@@ -100,7 +100,7 @@ static const char* const types[] = {"htm - "wallpaper", "lib", "pixmap", "templates", - "module", "qtplugins", - "xdgdata-apps", "xdgdata-dirs", "xdgconf-menu", -- "xdgdata-icon", "xdgdata-pixmap", -+ "xdgdata-icon", "xdgdata-pixmap", "xdgconf-autostart", - "kcfg", "emoticons", 0 }; - - static int tokenize( QStringList& token, const QString& str, -@@ -1067,6 +1067,8 @@ QString KStandardDirs::kde_default(const - return "desktop-directories/"; - if (!strcmp(type, "xdgconf-menu")) - return "menus/"; -+ if (!strcmp(type, "xdgconf-autostart")) -+ return "autostart/"; - if (!strcmp(type, "kcfg")) - return "share/config.kcfg"; - if (!strcmp(type, "emoticons")) -Index: kinit/autostart.cpp -=================================================================== ---- kinit/autostart.cpp.orig -+++ kinit/autostart.cpp -@@ -104,7 +104,9 @@ static bool startCondition(const QString - void - AutoStart::loadAutoStartList() - { -- QStringList files = KGlobal::dirs()->findAllResources("autostart", "*.desktop", false, true); -+ QStringList files = KGlobal::dirs()->findAllResources("xdgconf-autostart", "*.desktop", false, true); -+ QStringList kdefiles = KGlobal::dirs()->findAllResources("autostart", "*.desktop", false, true); -+ files += kdefiles; - - for(QStringList::ConstIterator it = files.begin(); - it != files.end(); -@@ -129,6 +131,17 @@ AutoStart::loadAutoStartList() - continue; - } - -+ if (config.hasKey("OnlyShowIn")) -+ { -+ if (!config.readListEntry("OnlyShowIn", ';').contains("KDE")) -+ continue; -+ } -+ if (config.hasKey("NotShowIn")) -+ { -+ if (config.readListEntry("NotShowIn", ';').contains("KDE")) -+ continue; -+ } -+ - AutoStartItem *item = new AutoStartItem; - item->name = extractName(*it); - item->service = *it; diff --git a/opensuse/core/tdelibs/avahi-pidfile.diff b/opensuse/core/tdelibs/avahi-pidfile.diff deleted file mode 100644 index 62cd3d8da..000000000 --- a/opensuse/core/tdelibs/avahi-pidfile.diff +++ /dev/null @@ -1,13 +0,0 @@ -Index: dnssd/servicebrowser.cpp -=================================================================== ---- dnssd/servicebrowser.cpp.orig -+++ dnssd/servicebrowser.cpp -@@ -30,7 +30,7 @@ - #include - #endif - --#define MDNSD_PID "/var/run/mdnsd.pid" -+#define MDNSD_PID "/var/run/avahi-daemon/pid" - - namespace DNSSD - { diff --git a/opensuse/core/tdelibs/bnc557126.diff b/opensuse/core/tdelibs/bnc557126.diff deleted file mode 100644 index 0782537b9..000000000 --- a/opensuse/core/tdelibs/bnc557126.diff +++ /dev/null @@ -1,21 +0,0 @@ ------------------------------------------------------------------------- -r1052100 | mueller | 2009-11-20 19:35:00 +0000 (Fri, 20 Nov 2009) | 2 lines -Changed paths: - M /branches/KDE/4.3/kdelibs/kjs/dtoa.cpp - -fix array overrun (CVE-2009-0689) - ------------------------------------------------------------------------- -Index: dtoa.cpp -=================================================================== ---- kjs/dtoa.cpp (revision 1052099) -+++ kjs/dtoa.cpp (revision 1052100) -@@ -457,7 +457,7 @@ - #define FREE_DTOA_LOCK(n) /*nothing*/ - #endif - --#define Kmax 15 -+#define Kmax (sizeof(size_t) << 3) - - struct - Bigint { diff --git a/opensuse/core/tdelibs/bug-382959_kabc_fix_vcardparser.patch b/opensuse/core/tdelibs/bug-382959_kabc_fix_vcardparser.patch index f7c3ee78d..543545f29 100644 --- a/opensuse/core/tdelibs/bug-382959_kabc_fix_vcardparser.patch +++ b/opensuse/core/tdelibs/bug-382959_kabc_fix_vcardparser.patch @@ -2,11 +2,11 @@ Index: kabc/vcardconverter.cpp =================================================================== --- kabc/vcardconverter.cpp.orig +++ kabc/vcardconverter.cpp -@@ -51,6 +51,14 @@ QString VCardConverter::createVCard( con +@@ -51,6 +51,14 @@ TQString VCardConverter::createVCard( co return createVCards( list, version ); } -+QCString VCardConverter::createVCardRaw( const Addressee &addr, Version version ) ++TQCString VCardConverter::createVCardRaw( const Addressee &addr, Version version ) +{ + Addressee::List list; + list.append( addr ); @@ -14,42 +14,42 @@ Index: kabc/vcardconverter.cpp + return createVCardsRaw( list, version ); +} + - QString VCardConverter::createVCards( Addressee::List list, Version version ) + TQString VCardConverter::createVCards( Addressee::List list, Version version ) { VCardTool tool; -@@ -58,6 +66,13 @@ QString VCardConverter::createVCards( Ad +@@ -58,6 +66,13 @@ TQString VCardConverter::createVCards( A return tool.createVCards( list, ( version == v3_0 ? VCard::v3_0 : VCard::v2_1 ) ); } -+QCString VCardConverter::createVCardsRaw( Addressee::List list, Version version ) ++TQCString VCardConverter::createVCardsRaw( Addressee::List list, Version version ) +{ + VCardTool tool; + + return tool.createVCardsRaw( list, ( version == v3_0 ? VCard::v3_0 : VCard::v2_1 ) ); +} + - Addressee VCardConverter::parseVCard( const QString& vcard ) + Addressee VCardConverter::parseVCard( const TQString& vcard ) { Addressee::List list = parseVCards( vcard ); @@ -65,6 +80,13 @@ Addressee VCardConverter::parseVCard( co return list[ 0 ]; } -+Addressee VCardConverter::parseVCardRaw( const QCString& vcard ) ++Addressee VCardConverter::parseVCardRaw( const TQCString& vcard ) +{ + Addressee::List list = parseVCardsRaw( vcard ); + + return list[ 0 ]; +} + - Addressee::List VCardConverter::parseVCards( const QString& vcard ) + Addressee::List VCardConverter::parseVCards( const TQString& vcard ) { VCardTool tool; @@ -72,6 +94,13 @@ Addressee::List VCardConverter::parseVCa return tool.parseVCards( vcard ); } -+Addressee::List VCardConverter::parseVCardsRaw( const QCString& vcard ) ++Addressee::List VCardConverter::parseVCardsRaw( const TQCString& vcard ) +{ + VCardTool tool; + @@ -58,7 +58,7 @@ Index: kabc/vcardconverter.cpp + // ---------------------------- deprecated stuff ---------------------------- // - bool VCardConverter::vCardToAddressee( const QString &str, Addressee &addr, Version version ) + bool VCardConverter::vCardToAddressee( const TQString &str, Addressee &addr, Version version ) Index: kabc/vcardconverter.h =================================================================== --- kabc/vcardconverter.h.orig @@ -66,33 +66,33 @@ Index: kabc/vcardconverter.h @@ -82,6 +82,7 @@ class KABC_EXPORT VCardConverter @param version The version of the generated vCard format */ - QString createVCard( const Addressee &addr, Version version = v3_0 ); -+ QCString createVCardRaw( const Addressee &addr, Version version = v3_0 ); + TQString createVCard( const Addressee &addr, Version version = v3_0 ); ++ TQCString createVCardRaw( const Addressee &addr, Version version = v3_0 ); /** Creates a string in vCard format which contains the given @@ -92,6 +93,7 @@ class KABC_EXPORT VCardConverter */ // FIXME: Add error handling - QString createVCards( Addressee::List list, Version version = v3_0 ); -+ QCString createVCardsRaw( Addressee::List list, Version version = v3_0 ); + TQString createVCards( Addressee::List list, Version version = v3_0 ); ++ TQCString createVCardsRaw( Addressee::List list, Version version = v3_0 ); // FIXME: Add "createVCards( AddressBook * )" @@ -99,12 +101,14 @@ class KABC_EXPORT VCardConverter Parses a string in vCard format and returns the first contact. */ - Addressee parseVCard( const QString& vcard ); -+ Addressee parseVCardRaw( const QCString& vcard ); + Addressee parseVCard( const TQString& vcard ); ++ Addressee parseVCardRaw( const TQCString& vcard ); /** Parses a string in vCard format and returns a list of contact objects. */ // FIXME: Add error handling - Addressee::List parseVCards( const QString& vcard ); -+ Addressee::List parseVCardsRaw( const QCString& vcard ); + Addressee::List parseVCards( const TQString& vcard ); ++ Addressee::List parseVCardsRaw( const TQCString& vcard ); - // FIXME: Add "bool parseVCards( AddressBook *, const QString &vcard )" + // FIXME: Add "bool parseVCards( AddressBook *, const TQString &vcard )" Index: kabc/vcardformatplugin.cpp =================================================================== @@ -100,15 +100,15 @@ Index: kabc/vcardformatplugin.cpp +++ kabc/vcardformatplugin.cpp @@ -38,14 +38,11 @@ VCardFormatPlugin::~VCardFormatPlugin() - bool VCardFormatPlugin::load( Addressee &addressee, QFile *file ) + bool VCardFormatPlugin::load( Addressee &addressee, TQFile *file ) { -- QString data; +- TQString data; - -- QTextStream t( file ); -- t.setEncoding( QTextStream::Latin1 ); +- TQTextStream t( file ); +- t.setEncoding( TQTextStream::Latin1 ); - data = t.read(); -+ const QByteArray rawData = file->readAll(); -+ const QCString data( rawData.data(), rawData.size() ); ++ const TQByteArray rawData = file->readAll(); ++ const TQCString data( rawData.data(), rawData.size() ); VCardConverter converter; - Addressee::List l = converter.parseVCards( data ); @@ -118,15 +118,15 @@ Index: kabc/vcardformatplugin.cpp addressee = l.first(); @@ -57,15 +54,11 @@ bool VCardFormatPlugin::load( Addressee - bool VCardFormatPlugin::loadAll( AddressBook*, Resource *resource, QFile *file ) + bool VCardFormatPlugin::loadAll( AddressBook*, Resource *resource, TQFile *file ) { -- QString data; +- TQString data; - -- QTextStream t( file ); -- t.setEncoding( QTextStream::Latin1 ); +- TQTextStream t( file ); +- t.setEncoding( TQTextStream::Latin1 ); - data = t.read(); -+ const QByteArray rawData = file->readAll(); -+ const QCString data( rawData.data(), rawData.size() ); ++ const TQByteArray rawData = file->readAll(); ++ const TQCString data( rawData.data(), rawData.size() ); VCardConverter converter; - @@ -139,26 +139,26 @@ Index: kabc/vcardformatplugin.cpp vcardlist.append( addressee ); -- QTextStream t( file ); -- t.setEncoding( QTextStream::UnicodeUTF8 ); +- TQTextStream t( file ); +- t.setEncoding( TQTextStream::UnicodeUTF8 ); - t << converter.createVCards( vcardlist ); -+ const QCString data = converter.createVCardsRaw( vcardlist ); ++ const TQCString data = converter.createVCardsRaw( vcardlist ); + file->writeBlock( data, data.length() ); } - void VCardFormatPlugin::saveAll( AddressBook*, Resource *resource, QFile *file ) + void VCardFormatPlugin::saveAll( AddressBook*, Resource *resource, TQFile *file ) @@ -102,9 +94,8 @@ void VCardFormatPlugin::saveAll( Address vcardlist.append( *it ); } -- QTextStream t( file ); -- t.setEncoding( QTextStream::UnicodeUTF8 ); +- TQTextStream t( file ); +- t.setEncoding( TQTextStream::UnicodeUTF8 ); - t << converter.createVCards( vcardlist ); -+ const QCString data = converter.createVCardsRaw( vcardlist ); ++ const TQCString data = converter.createVCardsRaw( vcardlist ); + file->writeBlock( data, data.length() ); } - bool VCardFormatPlugin::checkFormat( QFile *file ) const + bool VCardFormatPlugin::checkFormat( TQFile *file ) const Index: kabc/vcardparser/vcardparser.cpp =================================================================== --- kabc/vcardparser/vcardparser.cpp.orig @@ -167,10 +167,10 @@ Index: kabc/vcardparser/vcardparser.cpp Boston, MA 02110-1301, USA. */ -+#include - #include - #include -+#include ++#include + #include + #include ++#include #include +#include @@ -181,20 +181,20 @@ Index: kabc/vcardparser/vcardparser.cpp using namespace KABC; --static QString backslash( "\\\\" ); --static QString comma( "\\," ); --static QString newline( "\\n" ); --static QString cr( "\\r" ); -+typedef QValueList QCStringList; +-static TQString backslash( "\\\\" ); +-static TQString comma( "\\," ); +-static TQString newline( "\\n" ); +-static TQString cr( "\\r" ); ++typedef TQValueList TQCStringList; --static void addEscapes( QString &str ) -+QValueList splitCString( const QCString &str, char sep ) +-static void addEscapes( TQString &str ) ++QValueList splitCString( const TQCString &str, char sep ) { - str.replace( '\\', backslash ); - str.replace( ',', comma ); - str.replace( '\r', cr ); - str.replace( '\n', newline ); -+ QValueList list; ++ TQValueList list; + int start = 0; + int end; + while ((end = str.find(sep, start)) != -1) { @@ -206,9 +206,9 @@ Index: kabc/vcardparser/vcardparser.cpp + return list; +} + -+QValueList splitCString( const QCString &str, const QRegExp &exp ) ++TQValueList splitCString( const TQCString &str, const TQRegExp &exp ) +{ -+ QValueList list; ++ TQValueList list; + int start = 0; + int end; + while ((end = str.find(exp, start)) != -1) { @@ -220,18 +220,18 @@ Index: kabc/vcardparser/vcardparser.cpp + return list; +} + -+bool cStringStartsWith( const QCString &str, const QCString &pattern ) ++bool cStringStartsWith( const TQCString &str, const TQCString &pattern ) +{ + const int length = pattern.length(); + if ( length == 0 ) + return true; + -+ const QCString part = str.left( length ); ++ const TQCString part = str.left( length ); + return (pattern == part); } --static void removeEscapes( QString &str ) -+static void addEscapes( QCString &str ) +-static void removeEscapes( TQString &str ) ++static void addEscapes( TQCString &str ) { - str.replace( cr, "\\r" ); - str.replace( newline, "\n" ); @@ -243,7 +243,7 @@ Index: kabc/vcardparser/vcardparser.cpp + str.replace( '\n', "\\n" ); +} + -+static void removeEscapes( QCString &str ) ++static void removeEscapes( TQCString &str ) +{ + str.replace( "\\r", "\r" ); + str.replace( "\\n", "\n" ); @@ -254,35 +254,35 @@ Index: kabc/vcardparser/vcardparser.cpp VCardParser::VCardParser() @@ -60,24 +98,29 @@ VCardParser::~VCardParser() - VCard::List VCardParser::parseVCards( const QString& text ) + VCard::List VCardParser::parseVCards( const TQString& text ) { + return parseVCardsRaw( text.utf8() ); +} + -+VCard::List VCardParser::parseVCardsRaw( const QCString& text ) ++VCard::List VCardParser::parseVCardsRaw( const TQCString& text ) +{ - static QRegExp sep( "[\x0d\x0a]" ); + static TQRegExp sep( "[\x0d\x0a]" ); VCard currentVCard; VCard::List vCardList; -- QString currentLine; -+ QCString currentLine; +- TQString currentLine; ++ TQCString currentLine; -- const QStringList lines = QStringList::split( sep, text ); -- QStringList::ConstIterator it; -+ const QCStringList lines = splitCString( text, sep ); -+ QCStringList::ConstIterator it; +- const TQStringList lines = TQStringList::split( sep, text ); +- TQStringList::ConstIterator it; ++ const TQCStringList lines = splitCString( text, sep ); ++ TQCStringList::ConstIterator it; bool inVCard = false; -- QStringList::ConstIterator linesEnd( lines.end() ); -+ QCStringList::ConstIterator linesEnd( lines.end() ); +- TQStringList::ConstIterator linesEnd( lines.end() ); ++ TQCStringList::ConstIterator linesEnd( lines.end() ); for ( it = lines.begin(); it != linesEnd; ++it ) { if ( (*it).isEmpty() ) // empty line continue; if ( (*it)[ 0 ] == ' ' || (*it)[ 0 ] == '\t' ) { // folded line => append to previous -- currentLine += QString( *it ).remove( 0, 1 ); +- currentLine += TQString( *it ).remove( 0, 1 ); + currentLine.append( (*it).mid( 1 ) ); continue; } else { @@ -291,32 +291,32 @@ Index: kabc/vcardparser/vcardparser.cpp } VCardLine vCardLine; -- const QString key = currentLine.left( colon ).stripWhiteSpace(); -- QString value = currentLine.mid( colon + 1 ); -+ const QCString key = currentLine.left( colon ).stripWhiteSpace(); -+ QCString value = currentLine.mid( colon + 1 ); +- const TQString key = currentLine.left( colon ).stripWhiteSpace(); +- TQString value = currentLine.mid( colon + 1 ); ++ const TQCString key = currentLine.left( colon ).stripWhiteSpace(); ++ TQCString value = currentLine.mid( colon + 1 ); -- QStringList params = QStringList::split( ';', key ); -+ QCStringList params = splitCString( key, ';' ); +- TQStringList params = TQStringList::split( ';', key ); ++ TQCStringList params = splitCString( key, ';' ); // check for group if ( params[0].find( '.' ) != -1 ) { -- const QStringList groupList = QStringList::split( '.', params[0] ); +- const TQStringList groupList = TQStringList::split( '.', params[0] ); - vCardLine.setGroup( groupList[0] ); - vCardLine.setIdentifier( groupList[1] ); -+ const QCStringList groupList = splitCString( params[0], '.' ); -+ vCardLine.setGroup( QString::fromLatin1( groupList[0] ) ); -+ vCardLine.setIdentifier( QString::fromLatin1( groupList[1] ) ); ++ const TQCStringList groupList = splitCString( params[0], '.' ); ++ vCardLine.setGroup( TQString::tqfromLatin1( groupList[0] ) ); ++ vCardLine.setIdentifier( TQString::tqfromLatin1( groupList[1] ) ); } else - vCardLine.setIdentifier( params[0] ); -+ vCardLine.setIdentifier( QString::fromLatin1( params[0] ) ); ++ vCardLine.setIdentifier( TQString::tqfromLatin1( params[0] ) ); if ( params.count() > 1 ) { // find all parameters -- QStringList::ConstIterator paramIt = params.begin(); -+ QCStringList::ConstIterator paramIt = params.begin(); +- TQStringList::ConstIterator paramIt = params.begin(); ++ TQCStringList::ConstIterator paramIt = params.begin(); for ( ++paramIt; paramIt != params.end(); ++paramIt ) { -- QStringList pair = QStringList::split( '=', *paramIt ); -+ QCStringList pair = splitCString( *paramIt, '=' ); +- TQStringList pair = TQStringList::split( '=', *paramIt ); ++ TQCStringList pair = splitCString( *paramIt, '=' ); if ( pair.size() == 1 ) { // correct the fucking 2.1 'standard' if ( pair[0].lower() == "quoted-printable" ) { @@ -324,29 +324,29 @@ Index: kabc/vcardparser/vcardparser.cpp } // This is pretty much a faster pair[1].contains( ',' )... if ( pair[1].find( ',' ) != -1 ) { // parameter in type=x,y,z format -- const QStringList args = QStringList::split( ',', pair[ 1 ] ); -- QStringList::ConstIterator argIt; -+ const QCStringList args = splitCString( pair[ 1 ], ',' ); -+ QCStringList::ConstIterator argIt; +- const TQStringList args = TQStringList::split( ',', pair[ 1 ] ); +- TQStringList::ConstIterator argIt; ++ const TQCStringList args = splitCString( pair[ 1 ], ',' ); ++ TQCStringList::ConstIterator argIt; for ( argIt = args.begin(); argIt != args.end(); ++argIt ) - vCardLine.addParameter( pair[0].lower(), *argIt ); -+ vCardLine.addParameter( QString::fromLatin1( pair[0].lower() ), QString::fromLatin1( *argIt ) ); ++ vCardLine.addParameter( TQString::tqfromLatin1( pair[0].lower() ), TQString::tqfromLatin1( *argIt ) ); } else - vCardLine.addParameter( pair[0].lower(), pair[1] ); -+ vCardLine.addParameter( QString::fromLatin1( pair[0].lower() ), QString::fromLatin1( pair[1] ) ); ++ vCardLine.addParameter( TQString::tqfromLatin1( pair[0].lower() ), TQString::tqfromLatin1( pair[1] ) ); } } @@ -133,10 +176,8 @@ VCard::List VCardParser::parseVCards( co - QByteArray output; + TQByteArray output; bool wasBase64Encoded = false; - params = vCardLine.parameterList(); - if ( params.findIndex( "encoding" ) != -1 ) { // have to decode the data -- QByteArray input; -- input = QCString(value.latin1()); +- TQByteArray input; +- input = TQCString(value.latin1()); + if ( vCardLine.parameterList().findIndex( "encoding" ) != -1 ) { // have to decode the data -+ QByteArray input = value; ++ TQByteArray input = value; if ( vCardLine.parameter( "encoding" ).lower() == "b" || vCardLine.parameter( "encoding" ).lower() == "base64" ) { KCodecs::base64Decode( input, output ); @@ -354,59 +354,59 @@ Index: kabc/vcardparser/vcardparser.cpp value = value.remove( value.length() - 1, 1 ) + (*it); ++it; } -- input = QCString(value.latin1()); +- input = TQCString(value.latin1()); + input = value; KCodecs::quotedPrintableDecode( input, output ); } } else { -- output = QCString(value.latin1()); +- output = TQCString(value.latin1()); + output = value; } - if ( params.findIndex( "charset" ) != -1 ) { // have to convert the data + if ( vCardLine.parameterList().findIndex( "charset" ) != -1 ) { // have to convert the data - QTextCodec *codec = - QTextCodec::codecForName( vCardLine.parameter( "charset" ).latin1() ); + TQTextCodec *codec = + TQTextCodec::codecForName( vCardLine.parameter( "charset" ).latin1() ); if ( codec ) { @@ -173,17 +214,17 @@ VCard::List VCardParser::parseVCards( co } // we do not save the start and end tag as vcardline - if ( (*it).lower().startsWith( "begin:vcard" ) ) { -+ if ( cStringStartsWith( (*it).lower(), QCString( "begin:vcard" ) ) ) { ++ if ( cStringStartsWith( (*it).lower(), TQCString( "begin:vcard" ) ) ) { inVCard = true; - currentLine.setLength( 0 ); -+ currentLine = QCString(); ++ currentLine = TQCString(); currentVCard.clear(); // flush vcard continue; } - if ( (*it).lower().startsWith( "end:vcard" ) ) { -+ if ( cStringStartsWith( (*it).lower(), QCString( "end:vcard" ) ) ) { ++ if ( cStringStartsWith( (*it).lower(), TQCString( "end:vcard" ) ) ) { inVCard = false; vCardList.append( currentVCard ); - currentLine.setLength( 0 ); -+ currentLine = QCString(); ++ currentLine = TQCString(); currentVCard.clear(); // flush vcard continue; } @@ -197,8 +238,13 @@ VCard::List VCardParser::parseVCards( co - QString VCardParser::createVCards( const VCard::List& list ) + TQString VCardParser::createVCards( const VCard::List& list ) { -- QString text; -- QString textLine; -+ return QString::fromUtf8( createVCardsRaw( list ) ); +- TQString text; +- TQString textLine; ++ return TQString::fromUtf8( createVCardsRaw( list ) ); +} + -+QCString VCardParser::createVCardsRaw( const VCard::List& list ) ++TQCString VCardParser::createVCardsRaw( const VCard::List& list ) +{ -+ QCString text; -+ QCString textLine; - QString encodingType; - QStringList idents; - QStringList params; -@@ -213,7 +259,7 @@ QString VCardParser::createVCards( const ++ TQCString text; ++ TQCString textLine; + TQString encodingType; + TQStringList idents; + TQStringList params; +@@ -213,7 +259,7 @@ TQString VCardParser::createVCards( cons bool hasEncoding; @@ -415,54 +415,54 @@ Index: kabc/vcardparser/vcardparser.cpp // iterate over the cards VCard::List::ConstIterator listEnd( list.end() ); -@@ -228,9 +274,9 @@ QString VCardParser::createVCards( const - for ( lineIt = lines.constBegin(); lineIt != lines.constEnd(); ++lineIt ) { +@@ -229,9 +275,9 @@ TQString VCardParser::createVCards( cons if ( !(*lineIt).value().asString().isEmpty() ) { - if ( (*lineIt).hasGroup() ) -- textLine = (*lineIt).group() + "." + (*lineIt).identifier(); -+ textLine = (*lineIt).group().latin1() + QCString( "." ) + (*lineIt).identifier().latin1(); - else -- textLine = (*lineIt).identifier(); -+ textLine = (*lineIt).identifier().latin1(); - - params = (*lineIt).parameterList(); - hasEncoding = false; -@@ -243,9 +289,9 @@ QString VCardParser::createVCards( const - - values = (*lineIt).parameters( *paramIt ); - for ( valueIt = values.constBegin(); valueIt != values.constEnd(); ++valueIt ) { -- textLine.append( ";" + (*paramIt).upper() ); -+ textLine.append( QCString( ";" ) + (*paramIt).upper().latin1() ); - if ( !(*valueIt).isEmpty() ) -- textLine.append( "=" + (*valueIt) ); -+ textLine.append( QCString( "=" ) + (*valueIt).latin1() ); + if ((*lineIt).identifier() != TQString("URI")) { + if ( (*lineIt).hasGroup() ) +- textLine = (*lineIt).group() + "." + (*lineIt).identifier(); ++ textLine = (*lineIt).group().latin1() + TQCString( "." ) + (*lineIt).identifier().latin1(); + else +- textLine = (*lineIt).identifier(); ++ textLine = (*lineIt).identifier().latin1(); + + params = (*lineIt).parameterList(); + hasEncoding = false; +@@ -244,9 +290,9 @@ TQString VCardParser::createVCards( cons + + values = (*lineIt).parameters( *paramIt ); + for ( valueIt = values.constBegin(); valueIt != values.constEnd(); ++valueIt ) { +- textLine.append( ";" + (*paramIt).upper() ); ++ textLine.append( TQCString( ";" ) + (*paramIt).upper().latin1() ); + if ( !(*valueIt).isEmpty() ) +- textLine.append( "=" + (*valueIt) ); ++ textLine.append( TQCString( "=" ) + (*valueIt).latin1() ); + } } } - } -@@ -261,11 +307,11 @@ QString VCardParser::createVCards( const - KCodecs::quotedPrintableEncode( input, output, false ); - } +@@ -262,11 +308,11 @@ TQString VCardParser::createVCards( cons + KCodecs::quotedPrintableEncode( input, output, false ); + } -- QString value( output ); -+ QCString value( output ); - addEscapes( value ); - textLine.append( ":" + value ); - } else { -- QString value( (*lineIt).value().asString() ); -+ QCString value( (*lineIt).value().toString().utf8() ); - addEscapes( value ); - textLine.append( ":" + value ); - } +- TQString value( output ); ++ TQCString value( output ); + addEscapes( value ); + textLine.append( ":" + value ); + } else { +- TQString value( (*lineIt).value().asString() ); ++ TQCString value( (*lineIt).value().toString().utf8() ); + addEscapes( value ); + textLine.append( ":" + value ); + } Index: kabc/vcardparser/vcardparser.h =================================================================== --- kabc/vcardparser/vcardparser.h.orig +++ kabc/vcardparser/vcardparser.h @@ -34,6 +34,9 @@ class VCardParser - static VCard::List parseVCards( const QString& text ); - static QString createVCards( const VCard::List& list ); + static VCard::List parseVCards( const TQString& text ); + static TQString createVCards( const VCard::List& list ); -+ static VCard::List parseVCardsRaw( const QCString& text ); -+ static QCString createVCardsRaw( const VCard::List& list ); ++ static VCard::List parseVCardsRaw( const TQCString& text ); ++ static TQCString createVCardsRaw( const VCard::List& list ); + private: class VCardParserPrivate; @@ -476,14 +476,14 @@ Index: kabc/vcardtool.cpp } -// TODO: make list a const& -+QCString VCardTool::createVCardsRaw( Addressee::List list, VCard::Version version ) ++TQCString VCardTool::createVCardsRaw( Addressee::List list, VCard::Version version ) +{ + const VCard::List vCardList = createVCardsInternal( list, version ); + + return VCardParser::createVCardsRaw( vCardList ); +} + - QString VCardTool::createVCards( Addressee::List list, VCard::Version version ) + TQString VCardTool::createVCards( Addressee::List list, VCard::Version version ) { - VCard::List vCardList; + const VCard::List vCardList = createVCardsInternal( list, version ); @@ -500,10 +500,10 @@ Index: kabc/vcardtool.cpp for ( addrIt = list.constBegin(); addrIt != listEnd; ++addrIt ) { - VCard card; + KABC::VCard card; - QStringList::ConstIterator strIt; + TQStringList::ConstIterator strIt; // ADR + LABEL -@@ -348,17 +361,30 @@ QString VCardTool::createVCards( Address +@@ -351,17 +364,30 @@ QString VCardTool::createVCards( Address vCardList.append( card ); } @@ -511,14 +511,14 @@ Index: kabc/vcardtool.cpp + return vCardList; +} + -+Addressee::List VCardTool::parseVCardsRaw( const QCString& vcard ) ++Addressee::List VCardTool::parseVCardsRaw( const TQCString& vcard ) +{ + const VCard::List vCardList = VCardParser::parseVCardsRaw( vcard ); + + return parseVCardsInternal( vCardList ); } - Addressee::List VCardTool::parseVCards( const QString& vcard ) + Addressee::List VCardTool::parseVCards( const TQString& vcard ) { + const VCard::List vCardList = VCardParser::parseVCards( vcard ); + @@ -527,9 +527,9 @@ Index: kabc/vcardtool.cpp + +Addressee::List VCardTool::parseVCardsInternal( const VCard::List &vCardList ) +{ - static const QChar semicolonSep( ';' ); - static const QChar commaSep( ',' ); - QString identifier; + static const TQChar semicolonSep( ';' ); + static const TQChar commaSep( ',' ); + TQString identifier; Addressee::List addrList; - const VCard::List vCardList = VCardParser::parseVCards( vcard ); @@ -542,16 +542,16 @@ Index: kabc/vcardtool.h +++ kabc/vcardtool.h @@ -46,12 +46,19 @@ class KABC_EXPORT VCardTool */ - QString createVCards( Addressee::List list, VCard::Version version = VCard::v3_0 ); + TQString createVCards( Addressee::List list, VCard::Version version = VCard::v3_0 ); -+ QCString createVCardsRaw( Addressee::List list, VCard::Version version = VCard::v3_0 ); ++ TQCString createVCardsRaw( Addressee::List list, VCard::Version version = VCard::v3_0 ); + /** Parses the string and returns a list of addressee objects. */ - Addressee::List parseVCards( const QString& vcard ); + Addressee::List parseVCards( const TQString& vcard ); -+ Addressee::List parseVCardsRaw( const QCString& vcard ); ++ Addressee::List parseVCardsRaw( const TQCString& vcard ); + private: + VCard::List createVCardsInternal( Addressee::List list, VCard::Version version ); diff --git a/opensuse/core/tdelibs/bug-399296_ftphandling-fix.diff b/opensuse/core/tdelibs/bug-399296_ftphandling-fix.diff deleted file mode 100644 index a8719ab92..000000000 --- a/opensuse/core/tdelibs/bug-399296_ftphandling-fix.diff +++ /dev/null @@ -1,57 +0,0 @@ -Index: kioslave/ftp/ftp.cc -=================================================================== ---- kioslave/ftp/ftp.cc.orig -+++ kioslave/ftp/ftp.cc -@@ -1275,6 +1275,16 @@ bool Ftp::ftpRename( const QString & src - return false; - } - -+ // Must check if dst already exists, RNFR+RNTO overwrites by default (#127793). -+ if (ftpFileExists(dst)) { -+ error(ERR_FILE_ALREADY_EXIST, dst); -+ return false; -+ } -+ if (ftpFolder(dst, false)) { -+ error(ERR_DIR_ALREADY_EXIST, dst); -+ return false; -+ } -+ - int pos = src.findRev("/"); - if( !ftpFolder(src.left(pos+1), false) ) - return false; -@@ -2406,6 +2416,19 @@ bool Ftp::ftpSize( const QString & path, - return true; - } - -+bool Ftp::ftpFileExists(const QString& path) -+{ -+ QCString buf; -+ buf = "SIZE "; -+ buf += remoteEncoding()->encode(path); -+ if( !ftpSendCmd( buf ) || (m_iRespType != 2) ) -+ return false; -+ -+ // skip leading "213 " (response code) -+ const char* psz = ftpResponse(4); -+ return psz != 0; -+} -+ - // Today the differences between ASCII and BINARY are limited to - // CR or CR/LF line terminators. Many servers ignore ASCII (like - // win2003 -or- vsftp with default config). In the early days of -Index: kioslave/ftp/ftp.h -=================================================================== ---- kioslave/ftp/ftp.h.orig -+++ kioslave/ftp/ftp.h -@@ -350,6 +350,11 @@ private: - /** - * Set the current working directory, but only if not yet current - */ -+ bool ftpFileExists(const QString& path); -+ -+ /** -+ * Set the current working directory, but only if not yet current -+ */ - bool ftpFolder(const QString& path, bool bReportError); - - /** diff --git a/opensuse/core/tdelibs/bundle-locale-help.diff b/opensuse/core/tdelibs/bundle-locale-help.diff deleted file mode 100644 index 8305fad3a..000000000 --- a/opensuse/core/tdelibs/bundle-locale-help.diff +++ /dev/null @@ -1,107 +0,0 @@ -Index: kdecore/kstandarddirs.cpp -=================================================================== ---- kdecore/kstandarddirs.cpp.orig -+++ kdecore/kstandarddirs.cpp -@@ -94,8 +94,8 @@ KStandardDirsSingleton* KStandardDirsSin - return s_self; - } - --static const char* const types[] = {"html", "icon", "apps", "sound", -- "data", "locale", "services", "mime", -+static const char* const types[] = {"html", "html-bundle", "icon", "apps", "sound", -+ "data", "locale", "locale-bundle", "services", "mime", - "servicetypes", "config", "exe", - "wallpaper", "lib", "pixmap", "templates", - "module", "qtplugins", -@@ -1023,6 +1023,8 @@ static int tokenize( QStringList& tokens - QString KStandardDirs::kde_default(const char *type) { - if (!strcmp(type, "data")) - return "share/apps/"; -+ if (!strcmp(type, "html-bundle")) -+ return "share/doc-bundle/HTML/"; - if (!strcmp(type, "html")) - return "share/doc/HTML/"; - if (!strcmp(type, "icon")) -@@ -1035,6 +1037,8 @@ QString KStandardDirs::kde_default(const - return "share/applnk/"; - if (!strcmp(type, "sound")) - return "share/sounds/"; -+ if (!strcmp(type, "locale-bundle")) -+ return "share/locale-bundle/"; - if (!strcmp(type, "locale")) - return "share/locale/"; - if (!strcmp(type, "services")) -Index: kdecore/kcatalogue.cpp -=================================================================== ---- kdecore/kcatalogue.cpp.orig -+++ kdecore/kcatalogue.cpp -@@ -66,7 +66,11 @@ KCatalogue::KCatalogue(const QString & n - .arg( d->language ) - .arg( d->name ); - -- setFileName( locate( "locale", path ) ); -+ QString fileName = locate( "locale", path ); -+ if (fileName.isEmpty()) -+ fileName = locate( "locale-bundle", path ); -+ -+ setFileName( fileName ); - - } - -Index: kdecore/klocale.cpp -=================================================================== ---- kdecore/klocale.cpp.orig -+++ kdecore/klocale.cpp -@@ -402,7 +402,11 @@ QString KLocale::catalogueFileName(const - .arg( language ) - .arg( catalog.name() ); - -- return locate( "locale", path ); -+ QString fileName = locate( "locale", path ); -+ if (fileName.isEmpty()) -+ fileName = locate( "locale-bundle", path ); -+ -+ return fileName; - } - - bool KLocale::setLanguage(const QString & language) -@@ -501,6 +505,9 @@ bool KLocale::isApplicationTranslatedInt - // kdDebug() << "isApplicationTranslatedInto: filename " << sFileName << endl; - - QString sAbsFileName = locate( "locale", sFileName ); -+ if (sAbsFileName.isEmpty()) -+ sAbsFileName = locate( "locale-bundle", sFileName ); -+ - // kdDebug() << "isApplicationTranslatedInto: absname " << sAbsFileName << endl; - return ! sAbsFileName.isEmpty(); - } -Index: kdoctools/kio_help.cpp -=================================================================== ---- kdoctools/kio_help.cpp.orig -+++ kdoctools/kio_help.cpp -@@ -42,7 +42,7 @@ QString HelpProtocol::langLookup(const Q - QStringList search; - - // assemble the local search paths -- const QStringList localDoc = KGlobal::dirs()->resourceDirs("html"); -+ const QStringList localDoc = KGlobal::dirs()->resourceDirs("html") + KGlobal::dirs()->resourceDirs("html-bundle"); - - kdDebug( 7119 ) << "Looking up help for: " << fname << endl; - QString _fname = fname; -@@ -60,10 +60,14 @@ QString HelpProtocol::langLookup(const Q - QStringList langs = KGlobal::locale()->languageList(); - QStringList::ConstIterator lang; - for (lang = langs.begin(); lang != langs.end(); ++lang) -- if ((*lang).left(2) == "en") -+ if ((*lang).left(2) == "en") { - search.append(QString("/usr/share/gnome/help/%1/C%2").arg(path).arg(_fname)); -- else -+ search.append(QString("/usr/share/gnome/help-bundle/%1/C%2").arg(path).arg(_fname)); -+ } -+ else { - search.append(QString("/usr/share/gnome/help/%1/%2%3").arg(path).arg(*lang).arg(_fname)); -+ search.append(QString("/usr/share/gnome/help-bundle/%1/%2%3").arg(path).arg(*lang).arg(_fname)); -+ } - - langs.append( "en" ); - langs.remove( "C" ); diff --git a/opensuse/core/tdelibs/clever-menu.diff b/opensuse/core/tdelibs/clever-menu.diff deleted file mode 100644 index e2ae876c5..000000000 --- a/opensuse/core/tdelibs/clever-menu.diff +++ /dev/null @@ -1,221 +0,0 @@ -Index: kio/kio/kservice.cpp -=================================================================== ---- kio/kio/kservice.cpp.orig -+++ kio/kio/kservice.cpp -@@ -725,6 +725,20 @@ QString KService::untranslatedGenericNam - return v.isValid() ? v.toString() : QString::null; - } - -+bool KService::SuSEunimportant() const { -+ QMap::ConstIterator it = m_mapProps.find( "X-SuSE-Unimportant" ); -+ if ( (it == m_mapProps.end()) || (!it.data().isValid())) -+ { -+ return false; -+ } -+ -+ QString aValue = it.data().toString(); -+ if (aValue == "true" || aValue == "on" || aValue == "yes") -+ return true; -+ else -+ return false; -+} -+ - QString KService::parentApp() const { - QMap::ConstIterator it = m_mapProps.find( "X-KDE-ParentApp" ); - if ( (it == m_mapProps.end()) || (!it.data().isValid())) -Index: kio/kio/kservice.h -=================================================================== ---- kio/kio/kservice.h.orig -+++ kio/kio/kservice.h -@@ -327,6 +327,10 @@ public: - * @return true to suppress this service - */ - bool noDisplay() const; -+ /** -+ * check if the application entry is important -+ */ -+ bool SuSEunimportant() const; - - /** - * Name of the application this service belongs to. -Index: kio/kio/kservicegroup.cpp -=================================================================== ---- kio/kio/kservicegroup.cpp.orig -+++ kio/kio/kservicegroup.cpp -@@ -31,8 +31,10 @@ - class KServiceGroup::Private - { - public: -- Private() { m_bNoDisplay = false; m_bShowEmptyMenu = false;m_bShowInlineHeader=false;m_bInlineAlias=false; m_bAllowInline = false;m_inlineValue = 4;} -+ Private() { m_bNoDisplay = false; m_bShowEmptyMenu = false;m_bShowInlineHeader=false;m_bInlineAlias=false; m_bAllowInline = false; m_inlineValue = 4; m_bShortMenu = false; m_bGeneralDescription = false;} - bool m_bNoDisplay; -+ bool m_bShortMenu; -+ bool m_bGeneralDescription; - bool m_bShowEmptyMenu; - bool m_bShowInlineHeader; - bool m_bInlineAlias; -@@ -73,6 +75,11 @@ KServiceGroup::KServiceGroup( const QStr - m_strComment = config.readEntry( "Comment" ); - m_bDeleted = config.readBoolEntry( "Hidden", false ); - d->m_bNoDisplay = config.readBoolEntry( "NoDisplay", false ); -+ if (d->directoryEntryPath.startsWith(QDir::homeDirPath())) -+ d->m_bShortMenu = false; -+ else -+ d->m_bShortMenu = config.readBoolEntry( "X-SuSE-AutoShortMenu", true ); -+ d->m_bGeneralDescription = config.readBoolEntry( "X-SuSE-GeneralDescription", false ); - QStringList tmpList; - if (config.hasKey("OnlyShowIn")) - { -@@ -120,6 +127,10 @@ int KServiceGroup::childCount() - { - if (m_childCount == -1) - { -+ KConfig global("kdeglobals"); -+ global.setGroup("KDE"); -+ bool showUnimportant = global.readBoolEntry("showUnimportant", false); -+ - m_childCount = 0; - - for( List::ConstIterator it = m_serviceList.begin(); -@@ -130,7 +141,8 @@ int KServiceGroup::childCount() - { - KService *service = static_cast(p); - if (!service->noDisplay()) -- m_childCount++; -+ if ( showUnimportant || !service->SuSEunimportant() ) -+ m_childCount++; - } - else if (p->isType(KST_KServiceGroup)) - { -@@ -203,6 +215,16 @@ QStringList KServiceGroup::suppressGener - return d->suppressGenericNames; - } - -+bool KServiceGroup::SuSEgeneralDescription() const -+{ -+ return d->m_bGeneralDescription; -+} -+ -+bool KServiceGroup::SuSEshortMenu() const -+{ -+ return d->m_bShortMenu; -+} -+ - void KServiceGroup::load( QDataStream& s ) - { - QStringList groupList; -@@ -214,7 +236,8 @@ void KServiceGroup::load( QDataStream& s - s >> m_strCaption >> m_strIcon >> - m_strComment >> groupList >> m_strBaseGroupName >> m_childCount >> - noDisplay >> d->suppressGenericNames >> d->directoryEntryPath >> -- d->sortOrder >> _showEmptyMenu >> inlineHeader >> _inlineAlias >> _allowInline; -+ d->sortOrder >> _showEmptyMenu >> inlineHeader >> _inlineAlias >> -+ _allowInline >> d->m_bShortMenu >> d->m_bGeneralDescription; - - d->m_bNoDisplay = (noDisplay != 0); - d->m_bShowEmptyMenu = ( _showEmptyMenu != 0 ); -@@ -286,7 +309,8 @@ void KServiceGroup::save( QDataStream& s - s << m_strCaption << m_strIcon << - m_strComment << groupList << m_strBaseGroupName << m_childCount << - noDisplay << d->suppressGenericNames << d->directoryEntryPath << -- d->sortOrder <<_showEmptyMenu <sortOrder <<_showEmptyMenu <m_bShortMenu << d->m_bGeneralDescription; - } - - KServiceGroup::List -@@ -312,6 +336,12 @@ static void addItem(KServiceGroup::List - KServiceGroup::List - KServiceGroup::entries(bool sort, bool excludeNoDisplay, bool allowSeparators, bool sortByGenericName) - { -+ return SuSEentries(sort, excludeNoDisplay, allowSeparators, sortByGenericName); -+} -+ -+KServiceGroup::List -+KServiceGroup::SuSEentries(bool sort, bool excludeNoDisplay, bool allowSeparators, bool sortByGenericName, bool excludeSuSEunimportant) -+{ - KServiceGroup *group = this; - - // If the entries haven't been loaded yet, we have to reload ourselves -@@ -338,11 +368,18 @@ KServiceGroup::entries(bool sort, bool e - for (List::ConstIterator it(group->m_serviceList.begin()); it != group->m_serviceList.end(); ++it) - { - KSycocaEntry *p = (*it); -+ if( !p->isType(KST_KServiceGroup) && !p->isType(KST_KService)) -+ continue; - bool noDisplay = p->isType(KST_KServiceGroup) ? - static_cast(p)->noDisplay() : - static_cast(p)->noDisplay(); - if (excludeNoDisplay && noDisplay) - continue; -+ bool SuSEunimportant = p->isType(KST_KService) && -+ static_cast(p)->SuSEunimportant(); -+ if (excludeSuSEunimportant && SuSEunimportant) -+ continue; -+ - // Choose the right list - KSortableValueList & list = p->isType(KST_KServiceGroup) ? glist : slist; - QString name; -@@ -374,6 +411,15 @@ KServiceGroup::entries(bool sort, bool e - } - list.insert(key,SPtr(*it)); - } -+ -+ return group->SuSEsortEntries( slist, glist, excludeNoDisplay, allowSeparators ); -+} -+ -+KServiceGroup::List -+KServiceGroup::SuSEsortEntries( KSortableValueList slist, KSortableValueList glist, bool excludeNoDisplay, bool allowSeparators ) -+{ -+ KServiceGroup *group = this; -+ - // Now sort - slist.sort(); - glist.sort(); -@@ -415,6 +461,8 @@ KServiceGroup::entries(bool sort, bool e - // TODO: This prevents duplicates - for(KSortableValueList::Iterator it2 = slist.begin(); it2 != slist.end(); ++it2) - { -+ if (!(*it2).value()->isType(KST_KService)) -+ continue; - KService *service = (KService *)((KSycocaEntry *)((*it2).value())); - if (service->menuId() == item) - { -Index: kio/kio/kservicegroup.h -=================================================================== ---- kio/kio/kservicegroup.h.orig -+++ kio/kio/kservicegroup.h -@@ -26,6 +26,7 @@ - #include - - #include -+#include - - #include "ksycocaentry.h" - #include "ksycocatype.h" -@@ -201,6 +202,12 @@ public: - void setLayoutInfo(const QStringList &layout); - - /** -+ * SuSE special, not part of KDE API -+ */ -+ bool SuSEshortMenu() const; -+ bool SuSEgeneralDescription() const; -+ -+ /** - * @internal - * Returns information related to the layout of services in this group. - */ -@@ -238,6 +245,12 @@ public: - */ - virtual List entries(bool sorted = false); - -+ /* -+ * UNOFFICIAL SuSE special -+ */ -+ virtual List SuSEentries(bool sort, bool excludeNoDisplay, bool allowSeparators, bool sortByGenericName, bool excludeSuSEunimportant = true); -+ virtual List SuSEsortEntries( KSortableValueList slist, KSortableValueList glist, bool excludeNoDisplay, bool allowSeparators ); -+ - /** - * Returns a non-empty string if the group is a special base group. - * By default, "Settings/" is the kcontrol base group ("settings") diff --git a/opensuse/core/tdelibs/default-useragent.diff b/opensuse/core/tdelibs/default-useragent.diff index 76b92aef8..c5073f6da 100644 --- a/opensuse/core/tdelibs/default-useragent.diff +++ b/opensuse/core/tdelibs/default-useragent.diff @@ -6,8 +6,8 @@ Index: kio/kio/kprotocolmanager.cpp // DEFAULT USERAGENT STRING #define CFG_DEFAULT_UAGENT(X) \ --QString("Mozilla/5.0 (compatible; Konqueror/%1.%2%3) KHTML/%4.%5.%6 (like Gecko)") \ -+QString("Mozilla/5.0 (compatible; Konqueror/%1.%2%3) KHTML/%4.%5.%6 (like Gecko) SUSE") \ - .arg(KDE_VERSION_MAJOR).arg(KDE_VERSION_MINOR).arg(X).arg(KDE_VERSION_MAJOR).arg(KDE_VERSION_MINOR).arg(KDE_VERSION_RELEASE) +-TQString("Mozilla/5.0 (compatible; Konqueror/%1.%2%3) KHTML/%4.%5.%6 (like Gecko)") \ ++TQString("Mozilla/5.0 (compatible; Konqueror/%1.%2%3) KHTML/%4.%5.%6 (like Gecko) TDE SUSE") \ + .arg(TDE_VERSION_MAJOR).arg(TDE_VERSION_MINOR).arg(X).arg(TDE_VERSION_MAJOR).arg(TDE_VERSION_MINOR).arg(TDE_VERSION_RELEASE) void KProtocolManager::reparseConfiguration() diff --git a/opensuse/core/tdelibs/desktop-translations.diff b/opensuse/core/tdelibs/desktop-translations.diff deleted file mode 100644 index 6bf878469..000000000 --- a/opensuse/core/tdelibs/desktop-translations.diff +++ /dev/null @@ -1,209 +0,0 @@ -Index: kdecore/kconfigbase.h -=================================================================== ---- kdecore/kconfigbase.h.orig -+++ kdecore/kconfigbase.h -@@ -1985,6 +1985,7 @@ public: - - protected: - QCString readEntryUtf8( const char *pKey) const; -+ bool hasTranslatedKey( const char *pKey ) const; - - /** - * The currently selected group. */ -Index: kdecore/kconfigbase.cpp -=================================================================== ---- kdecore/kconfigbase.cpp.orig -+++ kdecore/kconfigbase.cpp -@@ -131,6 +131,24 @@ bool KConfigBase::hasKey(const char *pKe - return !entry.mValue.isNull(); - } - -+bool KConfigBase::hasTranslatedKey(const char* pKey) const -+{ -+ KEntryKey aEntryKey(mGroup, 0); -+ aEntryKey.c_key = pKey; -+ aEntryKey.bDefault = readDefaults(); -+ -+ if (!locale().isNull()) { -+ // try the localized key first -+ aEntryKey.bLocal = true; -+ KEntry entry = lookupData(aEntryKey); -+ if (!entry.mValue.isNull()) -+ return true; -+ aEntryKey.bLocal = false; -+ } -+ -+ return false; -+} -+ - bool KConfigBase::hasGroup(const QString &group) const - { - return internalHasGroup( group.utf8()); -Index: kdecore/kdesktopfile.h -=================================================================== ---- kdecore/kdesktopfile.h.orig -+++ kdecore/kdesktopfile.h -@@ -236,6 +236,8 @@ private: - - private: - -+ QString translatedEntry(const char*) const; -+ - // copy-construction and assignment are not allowed - KDesktopFile( const KDesktopFile& ); - KDesktopFile& operator= ( const KDesktopFile& ); -Index: kdecore/kdesktopfile.cpp -=================================================================== ---- kdecore/kdesktopfile.cpp.orig -+++ kdecore/kdesktopfile.cpp -@@ -34,6 +34,8 @@ - #include "kapplication.h" - #include "kstandarddirs.h" - #include "kmountpoint.h" -+#include "kcatalogue.h" -+#include "klocale.h" - - #include "kdesktopfile.h" - #include "kdesktopfile.moc" -@@ -145,6 +147,27 @@ bool KDesktopFile::isAuthorizedDesktopFi - return false; - } - -+QString KDesktopFile::translatedEntry(const char* key) const -+{ -+ if (hasTranslatedKey(key)) -+ return readEntry(key); -+ -+ if (hasKey(key)) { -+ QString value = readEntryUntranslated(key); -+ QString fName = fileName(); -+ fName = fName.mid(fName.findRev('/')+1); -+ QString po_lookup_key = QString::fromLatin1(key) + "(" + fName + "): " + value; -+ QString po_value = KGlobal::locale()->translate(po_lookup_key.utf8().data()); -+ -+ if (po_value == po_lookup_key) -+ return value; -+ -+ return po_value; -+ } -+ -+ return QString::null; -+} -+ - QString KDesktopFile::readType() const - { - return readEntry("Type"); -@@ -157,17 +180,17 @@ QString KDesktopFile::readIcon() const - - QString KDesktopFile::readName() const - { -- return readEntry("Name"); -+ return translatedEntry("Name"); - } - - QString KDesktopFile::readComment() const - { -- return readEntry("Comment"); -+ return translatedEntry("Comment"); - } - - QString KDesktopFile::readGenericName() const - { -- return readEntry("GenericName"); -+ return translatedEntry("GenericName"); - } - - QString KDesktopFile::readPath() const -@@ -342,5 +365,3 @@ KDesktopFile* KDesktopFile::copyTo(const - config->setDesktopGroup(); - return config; - } -- -- -Index: kio/kio/kservice.cpp -=================================================================== ---- kio/kio/kservice.cpp.orig -+++ kio/kio/kservice.cpp -@@ -114,7 +114,7 @@ KService::init( KDesktopFile *config ) - return; - } - -- m_strName = config->readEntry( "Name" ); -+ m_strName = config->readName(); - entryMap.remove("Name"); - if ( m_strName.isEmpty() ) - { -@@ -134,7 +134,7 @@ KService::init( KDesktopFile *config ) - m_strName = m_strName.left(i); - } - -- m_strType = config->readEntry( "Type" ); -+ m_strType = config->readType(); - entryMap.remove("Type"); - if ( m_strType.isEmpty() ) - { -@@ -204,11 +204,11 @@ KService::init( KDesktopFile *config ) - entryMap.remove("Terminal"); - m_strTerminalOptions = config->readEntry( "TerminalOptions" ); // should be a property IMHO - entryMap.remove("TerminalOptions"); -- m_strPath = config->readPathEntry( "Path" ); -+ m_strPath = config->readPath(); - entryMap.remove("Path"); -- m_strComment = config->readEntry( "Comment" ); -+ m_strComment = config->readComment(); - entryMap.remove("Comment"); -- m_strGenName = config->readEntry( "GenericName" ); -+ m_strGenName = config->readGenericName(); - entryMap.remove("GenericName"); - QString untranslatedGenericName = config->readEntryUntranslated( "GenericName" ); - if (!untranslatedGenericName.isEmpty()) -Index: kio/kio/kservicegroup.cpp -=================================================================== ---- kio/kio/kservicegroup.cpp.orig -+++ kio/kio/kservicegroup.cpp -@@ -66,13 +66,11 @@ KServiceGroup::KServiceGroup( const QStr - - d->directoryEntryPath = cfg; - -- KConfig config( cfg, true, false, "apps" ); -+ KDesktopFile config( cfg, true, "apps" ); - -- config.setDesktopGroup(); -- -- m_strCaption = config.readEntry( "Name" ); -- m_strIcon = config.readEntry( "Icon" ); -- m_strComment = config.readEntry( "Comment" ); -+ m_strCaption = config.readName(); -+ m_strIcon = config.readIcon(); -+ m_strComment = config.readComment(); - m_bDeleted = config.readBoolEntry( "Hidden", false ); - d->m_bNoDisplay = config.readBoolEntry( "NoDisplay", false ); - if (d->directoryEntryPath.startsWith(QDir::homeDirPath())) -Index: kio/kio/kmimetype.cpp -=================================================================== ---- kio/kio/kmimetype.cpp.orig -+++ kio/kio/kmimetype.cpp -@@ -677,9 +677,8 @@ QString KFolderType::comment( const KURL - KURL u( _url ); - u.addPath( ".directory" ); - -- KSimpleConfig cfg( u.path(), true ); -- cfg.setDesktopGroup(); -- QString comment = cfg.readEntry( "Comment" ); -+ KDesktopFile cfg( u.path(), true ); -+ QString comment = cfg.readComment(); - if ( comment.isEmpty() ) - return KMimeType::comment( _url, _is_local ); - -@@ -772,9 +771,8 @@ QString KDEDesktopMimeType::comment( con - if ( !_is_local ) - return KMimeType::comment( _url, _is_local ); - -- KSimpleConfig cfg( _url.path(), true ); -- cfg.setDesktopGroup(); -- QString comment = cfg.readEntry( "Comment" ); -+ KDesktopFile cfg( _url.path(), true ); -+ QString comment = cfg.readComment(); - if ( comment.isEmpty() ) - return KMimeType::comment( _url, _is_local ); - diff --git a/opensuse/core/tdelibs/disable-idn-support.diff b/opensuse/core/tdelibs/disable-idn-support.diff index 37c59bc91..eab2b7282 100644 --- a/opensuse/core/tdelibs/disable-idn-support.diff +++ b/opensuse/core/tdelibs/disable-idn-support.diff @@ -1,7 +1,7 @@ -Index: kdecore/network/kresolver.cpp +Index: tdecore/network/kresolver.cpp =================================================================== ---- kdecore/network/kresolver.cpp.orig -+++ kdecore/network/kresolver.cpp +--- tdecore/network/kresolver.cpp.orig ++++ tdecore/network/kresolver.cpp @@ -50,6 +50,7 @@ // IDN @@ -11,7 +11,7 @@ Index: kdecore/network/kresolver.cpp #endif @@ -1084,6 +1085,10 @@ static QStringList splitLabels(const QSt - static QCString ToASCII(const QString& label) + static TQCString ToASCII(const TQString& label) { #ifdef HAVE_IDNA_H + // We do disable it by default for security reasons for now. @@ -22,13 +22,13 @@ Index: kdecore/network/kresolver.cpp // function :) @@ -1118,6 +1123,10 @@ static QCString ToASCII(const QString& l - static QString ToUnicode(const QString& label) + static TQString ToUnicode(const TQString& label) { #ifdef HAVE_IDNA_H + // We do disable it by default for security reasons for now. + if ( getenv("KDE_NO_IPV6") && strcmp( getenv("KDE_NO_IPV6"), "no" ) ) + return label; + - // We have idna.h, so we can use the idna_to_unicode + // We have idna.h, so we can use the idna_to_tqunicode // function :) diff --git a/opensuse/core/tdelibs/disable-samba-dialog-without-smb.diff b/opensuse/core/tdelibs/disable-samba-dialog-without-smb.diff deleted file mode 100644 index cd0c29927..000000000 --- a/opensuse/core/tdelibs/disable-samba-dialog-without-smb.diff +++ /dev/null @@ -1,66 +0,0 @@ -Index: kio/kio/kfileshare.cpp -=================================================================== ---- kio/kio/kfileshare.cpp.orig -+++ kio/kio/kfileshare.cpp -@@ -291,4 +291,24 @@ bool KFileShare::setShared( const QStrin - return ok; - } - -+bool KFileShare::sambaActive() -+{ -+ // rcsmb is not executable by users, try ourselves -+ int status = system( "/sbin/checkproc -p /var/run/samba/smbd.pid /usr/sbin/smbd" ); -+ return status != -1 && WIFEXITED( status ) && WEXITSTATUS( status ) == 0; -+} -+ -+bool KFileShare::nfsActive() -+{ -+ // rcnfsserver is not executable by users, try ourselves -+ int status = system( "/sbin/checkproc /usr/sbin/rpc.mountd" ); -+ if( status != -1 && WIFEXITED( status ) && WEXITSTATUS( status ) == 0 ) -+ { -+ status = system( "/sbin/checkproc -n nfsd" ); -+ if( status != -1 && WIFEXITED( status ) && WEXITSTATUS( status ) == 0 ) -+ return true; -+ } -+ return false; -+} -+ - #include "kfileshare.moc" -Index: kio/kio/kfileshare.h -=================================================================== ---- kio/kio/kfileshare.h.orig -+++ kio/kio/kfileshare.h -@@ -131,6 +131,18 @@ public: - * Returns whether NFS is enabled - */ - static bool nfsEnabled(); -+ -+ /** -+ * Returns whether Samba is active (service is running) -+ * @internal -+ */ -+ static bool sambaActive(); -+ -+ /** -+ * Returns whether NFS is active (service is running) -+ * @internal -+ */ -+ static bool nfsActive(); - - private: - static Authorization s_authorization; -Index: kio/kfile/kfilesharedlg.cpp -=================================================================== ---- kio/kfile/kfilesharedlg.cpp.orig -+++ kio/kfile/kfilesharedlg.cpp -@@ -167,6 +167,9 @@ void KFileSharePropsPlugin::init() - vbox->addWidget( m_pbConfig, 0, Qt::AlignHCenter ); - - vbox->addStretch( 10 ); -+ -+ if( !KFileShare::sambaActive() && !KFileShare::nfsActive()) -+ m_widget->setEnabled( false ); - } - } - break; diff --git a/opensuse/core/tdelibs/fileshare.diff b/opensuse/core/tdelibs/fileshare.diff deleted file mode 100644 index 86f7d0941..000000000 --- a/opensuse/core/tdelibs/fileshare.diff +++ /dev/null @@ -1,296 +0,0 @@ ---- kio/kfile/kfilesharedlg.cpp -+++ kio/kfile/kfilesharedlg.cpp 2004/08/06 08:38:31 -@@ -24,6 +24,7 @@ - #include - #include - #include -+#include - #include - #include - #include -@@ -93,8 +94,10 @@ - delete m_widget; - m_rbShare = 0L; - m_rbUnShare = 0L; -+ m_rbSharerw = 0L; - m_widget = new QWidget( d->m_vBox ); - QVBoxLayout * vbox = new QVBoxLayout( m_widget ); -+ //QHBoxLayout * hbox = new QHBoxLayout( vbox ); - - switch ( KFileShare::authorization() ) { - case KFileShare::Authorized: -@@ -105,18 +108,31 @@ - home += '/'; - bool ok = true; - KFileItemList items = properties->items(); -- // We have 3 possibilities: all shared, all unshared, or mixed. -+ // We have some possibilities: all shared, all unshared (ro,rw), or mixed. - bool allShared = true; - bool allUnshared = true; -+ bool allreadonly = true; - KFileItemListIterator it( items ); - for ( ; it.current() && ok; ++it ) { - QString path = (*it)->url().path(); -+ -+ // 0 => not shared -+ // 1 => shared read only -+ // 3 => shared writeable -+ int dirStatus = KFileShare::isDirectoryShared( path ); - if ( !path.startsWith( home ) ) - ok = false; -- if ( KFileShare::isDirectoryShared( path ) ) -+ if ( dirStatus == 1 ) { - allUnshared = false; -- else -+ } -+ else if ( dirStatus == 3 ) { -+ allUnshared = false; -+ allreadonly = false; -+ } -+ else { - allShared = false; -+ allreadonly = false; -+ } - } - if ( !ok ) - { -@@ -136,16 +152,31 @@ - vbox->addWidget( m_rbUnShare, 0 ); - rbGroup->insert( m_rbUnShare ); - -- m_rbShare = new QRadioButton( i18n("Shared"), m_widget ); -+ m_rbShare = new QRadioButton( i18n("Shared - read only for others"), m_widget ); - connect( m_rbShare, SIGNAL( toggled(bool) ), SIGNAL( changed() ) ); - vbox->addWidget( m_rbShare, 0 ); - rbGroup->insert( m_rbShare ); - -+ m_rbSharerw = new QRadioButton( i18n("Shared - writeable for others"), m_widget ); -+ connect( m_rbSharerw, SIGNAL( toggled(bool) ), SIGNAL( changed() ) ); -+ vbox->addWidget( m_rbSharerw, 0 ); -+ rbGroup->insert( m_rbSharerw ); -+ -+ //QLabel *testlabel1 = new QLabel(i18n("Enter Samba Share Name here"),m_widget); -+ //m_leSmbShareName = new QLineEdit(m_widget); -+ //m_leSmbShareName->setMaxLength(12); -+ -+ //hbox->addWidget( testlabel1, 0 ); -+ //hbox->addWidget( m_leSmbShareName ); -+ //vbox->addLayout( hbox ); -+ - // Activate depending on status - if ( allShared ) -- m_rbShare->setChecked(true); -+ m_rbSharerw->setChecked(true); - if ( allUnshared ) - m_rbUnShare->setChecked(true); -+ if ( allreadonly ) -+ m_rbShare->setChecked(true); - - // Some help text - QLabel *label = new QLabel( i18n("Sharing this folder makes it available under Linux/UNIX (NFS) and Windows (Samba).") , m_widget ); -@@ -204,7 +235,7 @@ - void KFileSharePropsPlugin::applyChanges() - { - kdDebug() << "KFileSharePropsPlugin::applyChanges" << endl; -- if ( m_rbShare && m_rbUnShare ) -+ if ( m_rbShare && m_rbUnShare && m_rbSharerw ) - { - bool share = m_rbShare->isChecked(); - KFileItemList items = properties->items(); -@@ -212,7 +243,7 @@ - bool ok = true; - for ( ; it.current() && ok; ++it ) { - QString path = (*it)->url().path(); -- ok = setShared( path, share ); -+ ok = SuSEsetShared( path, share, m_rbSharerw->isChecked() ); - if (!ok) { - if (share) - KMessageBox::detailedError(properties, -@@ -239,8 +270,14 @@ - - bool KFileSharePropsPlugin::setShared( const QString& path, bool shared ) - { -- kdDebug() << "KFileSharePropsPlugin::setShared " << path << "," << shared << endl; -- return KFileShare::setShared( path, shared ); -+ return SuSEsetShared( path, shared, true ); -+} -+ -+bool KFileSharePropsPlugin::SuSEsetShared( const QString& path, bool shared, bool readonly ) -+{ -+ kdDebug() << "KFileSharePropsPlugin::setShared " << path << "," -+ << shared << readonly << endl; -+ return KFileShare::SuSEsetShared( path, shared, readonly ); - } - - QWidget* KFileSharePropsPlugin::page() const ---- kio/kfile/kfilesharedlg.h -+++ kio/kfile/kfilesharedlg.h 2004/08/06 08:38:31 -@@ -54,10 +54,13 @@ - private: - void init(); - bool setShared( const QString&path, bool shared ); -+ bool SuSEsetShared( const QString&path, bool shared, bool readonly ); - - QWidget *m_widget; - QRadioButton *m_rbShare; -+ QRadioButton *m_rbSharerw; - QRadioButton *m_rbUnShare; -+ //QLineEdit *m_leSmbShareName; - QPushButton *m_pbConfig; - class Private; - Private *d; ---- kio/kio/kfileshare.cpp -+++ kio/kio/kfileshare.cpp 2004/08/06 08:38:51 -@@ -20,6 +20,7 @@ - #include "kfileshare.h" - #include - #include -+#include - #include - #include - #include -@@ -35,8 +36,10 @@ - #include - - KFileShare::Authorization KFileShare::s_authorization = NotInitialized; --QStringList* KFileShare::s_shareList = 0L; --static KStaticDeleter sdShareList; -+//QStringList* KFileShare::s_shareList = 0L; -+//static KStaticDeleter sdShareList; -+QMap* KFileShare::s_shareMap = 0L; -+static KStaticDeleter > sdShareMap; - - KFileShare::ShareMode KFileShare::s_shareMode; - bool KFileShare::s_sambaEnabled; -@@ -164,10 +167,10 @@ - void KFileShare::readShareList() - { - KFileSharePrivate::self(); -- if ( !s_shareList ) -- sdShareList.setObject( s_shareList, new QStringList ); -+ if ( !s_shareMap ) -+ sdShareMap.setObject( s_shareMap, new QMap ); - else -- s_shareList->clear(); -+ s_shareMap->clear(); - - // /usr/sbin on Mandrake, $PATH allows flexibility for other distributions - QString exe = findExe( "filesharelist" ); -@@ -185,29 +188,45 @@ - - // Reading code shamelessly stolen from khostname.cpp ;) - QString line; -+ QString options; -+ QString path; - int length; -+ QRegExp rx_line("([^\\s]+)\\s+(.*)"); - do { - length = proc.readln(line, true); - if ( length > 0 ) - { - if ( line[length-1] != '/' ) - line += '/'; -- s_shareList->append(line); -+ if( rx_line.search( line ) != -1 ) { -+ options = rx_line.cap(1); -+ path = rx_line.cap(2); -+ (*s_shareMap)[path] = options; -+ } - kdDebug(7000) << "Shared dir:" << line << endl; - } - } while (length > -1); - } - - --bool KFileShare::isDirectoryShared( const QString& _path ) -+int KFileShare::isDirectoryShared( const QString& _path ) - { -- if ( ! s_shareList ) -+ int ret(0); -+ -+ if ( ! s_shareMap ) - readShareList(); - - QString path( _path ); - if ( path[path.length()-1] != '/' ) - path += '/'; -- return s_shareList && s_shareList->contains( path ); -+ //return s_shareList && s_shareList->contains( path ); -+ if( (*s_shareMap).contains(path) && !((*s_shareMap)[path].isEmpty()) ) { -+ ret+=1; -+ if( (*s_shareMap)[path].find("readwrite") != -1 ) -+ ret+=2; -+ } -+ -+ return ret; - } - - KFileShare::Authorization KFileShare::authorization() -@@ -230,17 +249,30 @@ - - bool KFileShare::setShared( const QString& path, bool shared ) - { -+ return SuSEsetShared( path, shared, false ); -+} -+ -+bool KFileShare::SuSEsetShared( const QString& path, bool shared, bool rw ) -+{ - if (! KFileShare::sharingEnabled() || - KFileShare::shareMode() == Advanced) - return false; - -- kdDebug(7000) << "KFileShare::setShared " << path << "," << shared << endl; - QString exe = KFileShare::findExe( "fileshareset" ); - if (exe.isEmpty()) - return false; -- -+ -+ // we want to share, so we kick it first - just to be sure - KProcess proc; - proc << exe; -+ proc << "--remove"; -+ proc << path; -+ proc.start( KProcess::Block ); -+ proc.clearArguments(); -+ -+ proc << exe; -+ if( rw ) -+ proc << "--rw"; - if ( shared ) - proc << "--add"; - else ---- kio/kio/kfileshare.h -+++ kio/kio/kfileshare.h 2004/08/06 08:38:31 -@@ -65,7 +65,7 @@ - /** - * Call this to know if a directory is currently shared - */ -- static bool isDirectoryShared( const QString& path ); -+ static int isDirectoryShared( const QString& path ); - - enum Authorization { NotInitialized, ErrorNotFound, Authorized, UserNotAllowed }; - /** -@@ -83,7 +83,12 @@ - * @returns wether the perl script was successful - */ - static bool setShared( const QString& path, bool shared ); -- -+ -+ /* -+ * SuSE only enhancement for now -+ */ -+ static bool SuSEsetShared( const QString& path, bool shared, bool ro ); -+ - /** - * The used share mode. - * Simple means that the simple sharing dialog is used and -@@ -132,7 +137,8 @@ - - private: - static Authorization s_authorization; -- static QStringList* s_shareList; -+// static QStringList* s_shareList; -+ static QMap* s_shareMap; - static ShareMode s_shareMode; - static bool s_sambaEnabled; - static bool s_nfsEnabled; diff --git a/opensuse/core/tdelibs/fix-dcopidlng-within-kdelibs-build.diff b/opensuse/core/tdelibs/fix-dcopidlng-within-kdelibs-build.diff index bac35d2b4..76caf2f77 100644 --- a/opensuse/core/tdelibs/fix-dcopidlng-within-kdelibs-build.diff +++ b/opensuse/core/tdelibs/fix-dcopidlng-within-kdelibs-build.diff @@ -2,15 +2,15 @@ Index: dcop/dcopidlng/dcopidlng =================================================================== --- dcop/dcopidlng/dcopidlng.orig +++ dcop/dcopidlng/dcopidlng -@@ -5,7 +5,11 @@ trap "rm -f dcopidlng.stderr.$$" 0 1 2 1 +@@ -6,7 +6,11 @@ trap "rm -f dcopidlng.stderr.$$" 0 1 2 1 if test -z "$KDECONFIG"; then - KDECONFIG=kde-config + KDECONFIG=tde-config fi -+if type kde-config > /dev/null; then ++if type tde-config > /dev/null; then LIBDIR="`$KDECONFIG --install data --expandvars`/dcopidlng" +else +LIBDIR="${0%/*}" +fi - 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=$? if [ $RET -ne 0 ] diff --git a/opensuse/core/tdelibs/fix-gnome-help-support.diff b/opensuse/core/tdelibs/fix-gnome-help-support.diff index c9778f9bf..78921f3b3 100644 --- a/opensuse/core/tdelibs/fix-gnome-help-support.diff +++ b/opensuse/core/tdelibs/fix-gnome-help-support.diff @@ -2,14 +2,14 @@ Index: kdoctools/kio_help.cpp =================================================================== --- kdoctools/kio_help.cpp.orig +++ kdoctools/kio_help.cpp -@@ -44,7 +44,27 @@ QString HelpProtocol::langLookup(const Q +@@ -44,7 +44,27 @@ TQString HelpProtocol::langLookup(const // assemble the local search paths - const QStringList localDoc = KGlobal::dirs()->resourceDirs("html"); + const TQStringList localDoc = KGlobal::dirs()->resourceDirs("html") + KGlobal::dirs()->resourceDirs("html-bundle"); + kdDebug( 7119 ) << "Looking up help for: " << fname << endl; -+ QString _fname = fname; ++ TQString _fname = fname; + -+ QString path; ++ TQString path; + int slash = _fname.findRev ('/'); + if (slash == -1 || slash == 0) { + path = _fname; @@ -19,34 +19,34 @@ Index: kdoctools/kio_help.cpp + _fname = _fname.right (_fname.length() - slash); + } + - QStringList langs = KGlobal::locale()->languageList(); -+ QStringList::ConstIterator lang; + TQStringList langs = KGlobal::locale()->languageList(); ++ TQStringList::ConstIterator lang; + for (lang = langs.begin(); lang != langs.end(); ++lang) + if ((*lang).left(2) == "en") -+ search.append(QString("/usr/share/gnome/help/%1/C%2").arg(path).arg(_fname)); ++ search.append(TQString("/usr/share/gnome/help/%1/C%2").arg(path).arg(_fname)); + else -+ search.append(QString("/usr/share/gnome/help/%1/%2%3").arg(path).arg(*lang).arg(_fname)); ++ search.append(TQString("/usr/share/gnome/help/%1/%2%3").arg(path).arg(*lang).arg(_fname)); + langs.append( "en" ); langs.remove( "C" ); -@@ -60,7 +80,7 @@ QString HelpProtocol::langLookup(const Q +@@ -60,7 +80,7 @@ TQString HelpProtocol::langLookup(const { - QStringList::ConstIterator lang; + TQStringList::ConstIterator lang; for (lang = langs.begin(); lang != langs.end(); ++lang) -- search.append(QString("%1%2/%3").arg(localDoc[id], *lang, fname)); -+ search.append(QString("%1%2/%3").arg(localDoc[id], *lang, path + _fname)); +- search.append(TQString("%1%2/%3").arg(localDoc[id], *lang, fname)); ++ search.append(TQString("%1%2/%3").arg(localDoc[id], *lang, path + _fname)); } // try to locate the file -@@ -81,6 +101,15 @@ QString HelpProtocol::langLookup(const Q +@@ -81,6 +101,15 @@ TQString HelpProtocol::langLookup(const if (info.exists() && info.isFile() && info.isReadable()) return *it; } + + if ( ( *it ).right( 5 ) == ".html" ) + { -+ QString file = (*it).left((*it).findRev('/')) + "/" + path + ".xml"; ++ TQString file = (*it).left((*it).findRev('/')) + "/" + path + ".xml"; + kdDebug( 7119 ) << "Looking for help in: " << file << endl; + info.setFile(file); + if (info.exists() && info.isFile() && info.isReadable()) @@ -55,7 +55,7 @@ Index: kdoctools/kio_help.cpp } -@@ -100,7 +129,7 @@ QString HelpProtocol::lookupFile(const Q +@@ -100,7 +129,7 @@ TQString HelpProtocol::lookupFile(const result = langLookup(path); if (result.isEmpty()) { @@ -67,16 +67,16 @@ Index: kdoctools/kio_help.cpp @@ -190,12 +219,26 @@ void HelpProtocol::get( const KURL& url } } else { - QString docbook_file = file.left(file.findRev('/')) + "/index.docbook"; + TQString docbook_file = file.left(file.findRev('/')) + "/index.docbook"; + int last_slash = file.findRev('/'); + if (last_slash != -1 && last_slash != 0) { + int slash2 = file.findRev('/', last_slash -1); + if (slash2 != -1 && slash2 != 0) { + int slash3 = file.findRev('/', slash2 - 1); + if (slash3 != -1) { -+ QString xml_file = file.left(file.findRev('/')) + "/" + file.mid(slash3 + 1, slash2 - (slash3 + 1)) + ".xml"; ++ TQString xml_file = file.left(file.findRev('/')) + "/" + file.mid(slash3 + 1, slash2 - (slash3 + 1)) + ".xml"; + kdDebug( 7119 ) << "xml_file " << xml_file << endl; -+ QFileInfo fi(xml_file); ++ TQFileInfo fi(xml_file); + if (fi.exists()) + docbook_file = xml_file; + } @@ -85,7 +85,7 @@ Index: kdoctools/kio_help.cpp if (!KStandardDirs::exists(file)) { file = docbook_file; } else { - QFileInfo fi(file); + TQFileInfo fi(file); if (fi.isDir()) { - file = file + "/index.docbook"; + file = docbook_file; @@ -96,8 +96,8 @@ Index: kdoctools/kio_help.cpp mParsed = transform(file, locate("dtd", "customization/kde-chunk.xsl")); if ( !mParsed.isEmpty() ) { infoMessage( i18n( "Saving to cache" ) ); -- QString cache = file.left( file.length() - 7 ); -+ QString cache; +- TQString cache = file.left( file.length() - 7 ); ++ TQString cache; + if (file.endsWith(".xml")) + cache = file.left( file.length() - strlen ("xml") ); + else @@ -109,22 +109,22 @@ Index: kdoctools/xslt.cpp =================================================================== --- kdoctools/xslt.cpp.orig +++ kdoctools/xslt.cpp -@@ -278,10 +278,16 @@ static bool readCache( const QString &fi - QString lookForCache( const QString &filename ) +@@ -278,10 +278,16 @@ static bool readCache( const TQString &f + TQString lookForCache( const TQString &filename ) { kdDebug() << "lookForCache " << filename << endl; - assert( filename.endsWith( ".docbook" ) ); + assert( filename.endsWith( ".docbook" ) || filename.endsWith( ".xml" ) ); assert( filename.at( 0 ) == '/' ); -- QString cache = filename.left( filename.length() - 7 ); -+ QString cache; +- TQString cache = filename.left( filename.length() - 7 ); ++ TQString cache; + + if (filename.endsWith( ".xml" )) + cache = filename.left( filename.length() - strlen ("xml") ); + else + cache = filename.left( filename.length() - strlen ("docbook") ); + - QString output; + TQString output; if ( readCache( filename, cache + "cache.bz2", output) ) return output; diff --git a/opensuse/core/tdelibs/fix-gnome-help-support_legacy.diff b/opensuse/core/tdelibs/fix-gnome-help-support_legacy.diff index 0e2922e41..5db880383 100644 --- a/opensuse/core/tdelibs/fix-gnome-help-support_legacy.diff +++ b/opensuse/core/tdelibs/fix-gnome-help-support_legacy.diff @@ -2,12 +2,12 @@ +++ kdoctools/kio_help.cpp @@ -44,7 +44,27 @@ // assemble the local search paths - const QStringList localDoc = KGlobal::dirs()->resourceDirs("html"); + const TQStringList localDoc = KGlobal::dirs()->resourceDirs("html") + KGlobal::dirs()->resourceDirs("html-bundle"); + kdDebug( 7119 ) << "Looking up help for: " << fname << endl; -+ QString _fname = fname; ++ TQString _fname = fname; + -+ QString path; ++ TQString path; + int slash = _fname.findRev ('/'); + if (slash == -1 || slash == 0) { + path = _fname; @@ -17,23 +17,23 @@ + _fname = _fname.right (_fname.length() - slash); + } + - QStringList langs = KGlobal::locale()->languageList(); -+ QStringList::ConstIterator lang; + TQStringList langs = KGlobal::locale()->languageList(); ++ TQStringList::ConstIterator lang; + for (lang = langs.begin(); lang != langs.end(); ++lang) + if ((*lang).left(2) == "en") -+ search.append(QString("/opt/gnome/share/gnome/help/%1/C%2").arg(path).arg(_fname)); ++ search.append(TQString("/opt/gnome/share/gnome/help/%1/C%2").arg(path).arg(_fname)); + else -+ search.append(QString("/opt/gnome/share/gnome/help/%1/%2%3").arg(path).arg(*lang).arg(_fname)); ++ search.append(TQString("/opt/gnome/share/gnome/help/%1/%2%3").arg(path).arg(*lang).arg(_fname)); + langs.append( "en" ); langs.remove( "C" ); @@ -60,7 +80,7 @@ { - QStringList::ConstIterator lang; + TQStringList::ConstIterator lang; for (lang = langs.begin(); lang != langs.end(); ++lang) -- search.append(QString("%1%2/%3").arg(localDoc[id], *lang, fname)); -+ search.append(QString("%1%2/%3").arg(localDoc[id], *lang, path + _fname)); +- search.append(TQString("%1%2/%3").arg(localDoc[id], *lang, fname)); ++ search.append(TQString("%1%2/%3").arg(localDoc[id], *lang, path + _fname)); } // try to locate the file @@ -44,7 +44,7 @@ + + if ( ( *it ).right( 5 ) == ".html" ) + { -+ QString file = (*it).left((*it).findRev('/')) + "/" + path + ".xml"; ++ TQString file = (*it).left((*it).findRev('/')) + "/" + path + ".xml"; + kdDebug( 7119 ) << "Looking for help in: " << file << endl; + info.setFile(file); + if (info.exists() && info.isFile() && info.isReadable()) @@ -65,16 +65,16 @@ @@ -190,12 +219,26 @@ } } else { - QString docbook_file = file.left(file.findRev('/')) + "/index.docbook"; + TQString docbook_file = file.left(file.findRev('/')) + "/index.docbook"; + int last_slash = file.findRev('/'); + if (last_slash != -1 && last_slash != 0) { + int slash2 = file.findRev('/', last_slash -1); + if (slash2 != -1 && slash2 != 0) { + int slash3 = file.findRev('/', slash2 - 1); + if (slash3 != -1) { -+ QString xml_file = file.left(file.findRev('/')) + "/" + file.mid(slash3 + 1, slash2 - (slash3 + 1)) + ".xml"; ++ TQString xml_file = file.left(file.findRev('/')) + "/" + file.mid(slash3 + 1, slash2 - (slash3 + 1)) + ".xml"; + kdDebug( 7119 ) << "xml_file " << xml_file << endl; -+ QFileInfo fi(xml_file); ++ TQFileInfo fi(xml_file); + if (fi.exists()) + docbook_file = xml_file; + } @@ -83,7 +83,7 @@ if (!KStandardDirs::exists(file)) { file = docbook_file; } else { - QFileInfo fi(file); + TQFileInfo fi(file); if (fi.isDir()) { - file = file + "/index.docbook"; + file = docbook_file; @@ -94,8 +94,8 @@ mParsed = transform(file, locate("dtd", "customization/kde-chunk.xsl")); if ( !mParsed.isEmpty() ) { infoMessage( i18n( "Saving to cache" ) ); -- QString cache = file.left( file.length() - 7 ); -+ QString cache; +- TQString cache = file.left( file.length() - 7 ); ++ TQString cache; + if (file.endsWith(".xml")) + cache = file.left( file.length() - strlen ("xml") ); + else @@ -105,22 +105,22 @@ "cache.bz2" ) ); --- kdoctools/xslt.cpp +++ kdoctools/xslt.cpp -@@ -274,10 +274,16 @@ - QString lookForCache( const QString &filename ) +@@ -278,10 +278,16 @@ + TQString lookForCache( const TQString &filename ) { kdDebug() << "lookForCache " << filename << endl; - assert( filename.endsWith( ".docbook" ) ); + assert( filename.endsWith( ".docbook" ) || filename.endsWith( ".xml" ) ); - assert( filename.at( 0 ) == '/' ); + assert( filename.tqat( 0 ) == '/' ); -- QString cache = filename.left( filename.length() - 7 ); -+ QString cache; +- TQString cache = filename.left( filename.length() - 7 ); ++ TQString cache; + + if (filename.endsWith( ".xml" )) + cache = filename.left( filename.length() - strlen ("xml") ); + else + cache = filename.left( filename.length() - strlen ("docbook") ); + - QString output; + TQString output; if ( readCache( filename, cache + "cache.bz2", output) ) return output; diff --git a/opensuse/core/tdelibs/fix-kdemm-build.diff b/opensuse/core/tdelibs/fix-kdemm-build.diff deleted file mode 100644 index befe5e324..000000000 --- a/opensuse/core/tdelibs/fix-kdemm-build.diff +++ /dev/null @@ -1,88 +0,0 @@ -Index: kdemm/backend.h -=================================================================== ---- kdemm/backend.h.orig -+++ kdemm/backend.h -@@ -41,7 +41,7 @@ namespace Multimedia - * \author Matthias Kretz - * \since 4.0 - */ -- class Backend : public QObject -+ class KDE_EXPORT Backend : public QObject - { - Q_OBJECT - public: -Index: kdemm/channel.h -=================================================================== ---- kdemm/channel.h.orig -+++ kdemm/channel.h -@@ -34,7 +34,7 @@ namespace Multimedia - * \author Matthias Kretz - * \since 4.0 - */ -- class Channel : public QObject, virtual public MixerIface -+ class KDE_EXPORT Channel : public QObject, virtual public MixerIface - { - Q_OBJECT - public: -Index: kdemm/factory.h -=================================================================== ---- kdemm/factory.h.orig -+++ kdemm/factory.h -@@ -64,7 +64,7 @@ class VideoPlayer; - * \author Matthias Kretz - * \since 4.0 - */ --class Factory : public QObject, public DCOPObject -+class KDE_EXPORT Factory : public QObject, public DCOPObject - { - Q_OBJECT - public: -Index: kdemm/player.h -=================================================================== ---- kdemm/player.h.orig -+++ kdemm/player.h -@@ -20,6 +20,7 @@ - #ifndef PLAYOBJECT_H - #define PLAYOBJECT_H - -+#include - #include - - class KURL; -@@ -35,7 +36,7 @@ namespace Multimedia - * \author Matthias Kretz - * \since 4.0 - */ -- class Player : public QObject -+ class KDE_EXPORT Player : public QObject - { - Q_OBJECT - public: -Index: kdemm/simpleplayer.h -=================================================================== ---- kdemm/simpleplayer.h.orig -+++ kdemm/simpleplayer.h -@@ -32,7 +32,7 @@ namespace KDE - namespace Multimedia - { - --class SimplePlayer : public QObject -+class KDE_EXPORT SimplePlayer : public QObject - { - Q_OBJECT - public: -Index: kdemm/mixeriface.h -=================================================================== ---- kdemm/mixeriface.h.orig -+++ kdemm/mixeriface.h -@@ -21,8 +21,9 @@ - #define MIXERIFACE_H - - #include -+#include - --class MixerIface : public DCOPObject -+class KDE_EXPORT MixerIface : public DCOPObject - { - K_DCOP - k_dcop: diff --git a/opensuse/core/tdelibs/fix-kerberos-printing.diff b/opensuse/core/tdelibs/fix-kerberos-printing.diff deleted file mode 100644 index 0276cdd06..000000000 --- a/opensuse/core/tdelibs/fix-kerberos-printing.diff +++ /dev/null @@ -1,37 +0,0 @@ -Index: kdeprint/management/smbview.cpp -=================================================================== ---- kdeprint/management/smbview.cpp.orig -+++ kdeprint/management/smbview.cpp -@@ -187,13 +187,26 @@ void SmbView::setOpen(QListViewItem *ite - } - else if (item->depth() == 1) - { // opening server -+ char *krb5ccname = getenv ("KRB5CCNAME"); - m_current = item; -- *m_proc << "smbclient -N -L "; -- *m_proc << KProcess::quote(item->text(0)); -- *m_proc << " -W "; -- *m_proc << KProcess::quote(item->parent()->text(0)); -- *m_proc << " -A "; -- *m_proc << KProcess::quote(m_passwdFile->name()); -+ if (krb5ccname) -+ { -+ *m_proc << "smbclient -k -N -L "; -+ } -+ else -+ { -+ *m_proc << "smbclient -N -L "; -+ } -+ *m_proc << KProcess::quote (item->text (0)); -+ *m_proc << " -W "; -+ *m_proc << KProcess::quote (item->parent ()-> -+ text (0)); -+ if (!krb5ccname) -+ { -+ *m_proc << " -A "; -+ *m_proc << KProcess:: -+ quote (m_passwdFile->name ()); -+ } - startProcess(ShareListing); - } - } diff --git a/opensuse/core/tdelibs/fix-macmenu.patch b/opensuse/core/tdelibs/fix-macmenu.patch deleted file mode 100644 index 4b8f6b1cf..000000000 --- a/opensuse/core/tdelibs/fix-macmenu.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- kdeui/kmenubar.cpp.sav 2008-03-08 17:32:38.000000000 +0100 -+++ kdeui/kmenubar.cpp 2009-08-30 09:27:29.000000000 +0200 -@@ -308,7 +308,7 @@ void KMenuBar::updateFallbackSize() - if( d->fallback_mode ) - { - d->fallback_mode = false; --// KWin::setStrut( winId(), 0, 0, 0, 0 ); KWin will set strut as it will see fit -+ KWin::setStrut( winId(), 0, 0, 0, 0 ); - setMinimumSize( 0, 0 ); - setMaximumSize( QWIDGETSIZE_MAX, QWIDGETSIZE_MAX ); - updateMenuBarSize(); diff --git a/opensuse/core/tdelibs/fix-qxembed.diff b/opensuse/core/tdelibs/fix-qxembed.diff deleted file mode 100644 index 8ea18d69d..000000000 --- a/opensuse/core/tdelibs/fix-qxembed.diff +++ /dev/null @@ -1,80 +0,0 @@ -Index: kdeui/qxembed.h -=================================================================== ---- kdeui/qxembed.h.orig -+++ kdeui/qxembed.h -@@ -191,6 +191,11 @@ public: - void enterWhatsThisMode(); // temporary, fix in Qt (Matthias, Mon Jul 17 15:20:55 CEST 2000 ) - virtual void reparent( QWidget * parent, WFlags f, const QPoint & p, bool showIt = false ); - -+ /** -+ * @internal -+ */ -+ void updateEmbeddedFocus( bool hasfocus ); -+ - signals: - /** - * This signal is emitted when the embedded window has been lost (destroyed or reparented away) -Index: kdeui/qxembed.cpp -=================================================================== ---- kdeui/qxembed.cpp.orig -+++ kdeui/qxembed.cpp -@@ -314,8 +314,8 @@ bool QXEmbedAppFilter::eventFilter( QObj - if ( qApp->focusWidget() == o && - ((QPublicWidget*)qApp->focusWidget()->topLevelWidget())->topData()->embedded ) { - QFocusEvent* fe = (QFocusEvent*) e; -- if ( obeyFocus || fe->reason() == QFocusEvent::Mouse || -- fe->reason() == QFocusEvent::Shortcut ) { -+ if ( obeyFocus || fe->reason() != QFocusEvent::ActiveWindow /*|| fe->reason() == QFocusEvent::Mouse || -+ fe->reason() == QFocusEvent::Shortcut*/ ) { - // L0614: A widget in the embedded client was just given the Qt focus. - // Variable `obeyFocus' suggests that this is the result of mouse - // activity in the client. The XEMBED_REQUEST_FOCUS message causes -@@ -478,8 +478,11 @@ static int qxembed_x11_event_filter( XEv - switch ( detail ) { - case XEMBED_FOCUS_CURRENT: - // L0683: Set focus on saved focus widget -- if ( focusCurrent ) -+ if ( focusCurrent ) { - focusCurrent->setFocus(); -+ if( QXEmbed* emb = dynamic_cast< QXEmbed* >( focusCurrent )) -+ emb->updateEmbeddedFocus( true ); -+ } - else if ( !w->topLevelWidget()->focusWidget() ) - w->topLevelWidget()->setFocus(); - break; -@@ -511,6 +514,8 @@ static int qxembed_x11_event_filter( XEv - // We first record what the focus widget was - // and clear the Qt focus. - if ( w->topLevelWidget()->focusWidget() ) { -+ if( QXEmbed* emb = dynamic_cast< QXEmbed* >( w->topLevelWidget()->focusWidget())) -+ emb->updateEmbeddedFocus( false ); - focusMap->insert( w->topLevelWidget(), - new QGuardedPtr(w->topLevelWidget()->focusWidget() ) ); - w->topLevelWidget()->focusWidget()->clearFocus(); -@@ -919,6 +924,17 @@ void QXEmbed::focusOutEvent( QFocusEvent - } - - -+// When QXEmbed has Qt focus and gets/loses X focus, make sure the client knows -+// about the state of the focus. -+void QXEmbed::updateEmbeddedFocus( bool hasfocus ){ -+ if (!window || d->xplain) -+ return; -+ if( hasfocus ) -+ sendXEmbedMessage( window, XEMBED_FOCUS_IN, XEMBED_FOCUS_CURRENT); -+ else -+ sendXEmbedMessage( window, XEMBED_FOCUS_OUT); -+} -+ - // L1600: Helper for QXEmbed::embed() - // Check whether a window is in withdrawn state. - static bool wstate_withdrawn( WId winid ) -@@ -1161,6 +1177,8 @@ bool QXEmbed::x11Event( XEvent* e) - // L2085: The client asks for the focus. - case XEMBED_REQUEST_FOCUS: - if( ((QPublicWidget*)topLevelWidget())->topData()->embedded ) { -+ focusMap->remove( topLevelWidget() ); -+ focusMap->insert( topLevelWidget(), new QGuardedPtr( this )); - WId window = ((QPublicWidget*)topLevelWidget())->topData()->parentWinId; - sendXEmbedMessage( window, XEMBED_REQUEST_FOCUS ); - } else { diff --git a/opensuse/core/tdelibs/flash-player-non-oss.diff b/opensuse/core/tdelibs/flash-player-non-oss.diff index e3bcdc3e4..f6b3da259 100644 --- a/opensuse/core/tdelibs/flash-player-non-oss.diff +++ b/opensuse/core/tdelibs/flash-player-non-oss.diff @@ -1,44 +1,42 @@ -Index: khtml/rendering/render_frames.cpp -=================================================================== ---- khtml/rendering/render_frames.cpp.orig -+++ khtml/rendering/render_frames.cpp -@@ -940,14 +940,33 @@ void RenderPartObject::slotPartLoadingEr - // 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), +--- khtml/rendering/render_frames.cpp.orig 2011-12-11 21:10:39.556986274 +0100 ++++ khtml/rendering/render_frames.cpp 2011-12-11 21:19:11.017986213 +0100 +@@ -953,14 +953,33 @@ + // Prepare the URL to show in the question (host only if http, to make it short) + KURL pluginPageURL( embed->pluginPage ); + TQString 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), + -+ int res; -+ if (mimeName.startsWith("Shockwave Flash",false)) -+ { -+ res = KMessageBox::questionYesNo( m_view, -+ i18n("No plugin found for '%1'.\nDo you want to download one from %2?").arg(mimeName).arg("openSUSE"), - i18n("Missing Plugin"), i18n("Download"), i18n("Do Not Download"), QString("plugin-")+serviceType); -- if ( res == KMessageBox::Yes ) ++ int res; ++ if (mimeName.startsWith("Shockwave Flash",false)) ++ { ++ res = KMessageBox::questionYesNo( m_view, ++ i18n("No plugin found for '%1'.\nDo you want to download one from %2?").arg(mimeName).arg("openSUSE"), + i18n("Missing Plugin"), i18n("Download"), i18n("Do Not Download"), TQString("plugin-")+serviceType); +- if ( res == KMessageBox::Yes ) + -+ if ( res == KMessageBox::Yes ) -+ { ++ if ( res == KMessageBox::Yes ) ++ { + // Open YMP file + KURL ymp_flash ("http://download.opensuse.org/YaST/flash-player.ymp"); + ext->openURLRequest( ymp_flash ); + return; -+ } -+ } -+ else - { -- // Display vendor download page -- ext->createNewWindow( pluginPageURL ); -- return; -+ 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 ) -+ { ++ } ++ } ++ else + { +- // Display vendor download page +- ext->createNewWindow( pluginPageURL ); +- return; ++ 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"), TQString("plugin-")+serviceType); ++ if ( res == KMessageBox::Yes ) ++ { + // Display vendor download page + ext->createNewWindow( pluginPageURL ); + return; -+ } ++ } + } } } - } diff --git a/opensuse/core/tdelibs/fontconfig-reverse-lookup.diff b/opensuse/core/tdelibs/fontconfig-reverse-lookup.diff deleted file mode 100644 index af32e5600..000000000 --- a/opensuse/core/tdelibs/fontconfig-reverse-lookup.diff +++ /dev/null @@ -1,137 +0,0 @@ -Index: kdeui/Makefile.am -=================================================================== ---- kdeui/Makefile.am.orig -+++ kdeui/Makefile.am -@@ -20,7 +20,7 @@ - - SUBDIRS = . kdetrayproxy tests about - --INCLUDES= -I$(top_srcdir)/kdefx -I$(top_srcdir)/interfaces $(all_includes) -+INCLUDES= -I/usr/include/freetype2/ -I$(top_srcdir)/kdefx -I$(top_srcdir)/interfaces $(all_includes) - - # For the future: examine if condensing the tons of *_LDFLAGS variables - # into $(all_libraries) isn't better -Index: kdeui/kaction.cpp -=================================================================== ---- kdeui/kaction.cpp.orig -+++ kdeui/kaction.cpp -@@ -42,6 +42,17 @@ - #include - #include - -+#include -+#include FT_FREETYPE_H -+#include -+#include -+#include -+#include -+#include -+#include -+ -+#include -+ - /** - * How it works. - * KActionCollection is an organizing container for KActions. -Index: kdeui/kactionclasses.cpp -=================================================================== ---- kdeui/kactionclasses.cpp.orig -+++ kdeui/kactionclasses.cpp -@@ -27,6 +27,9 @@ - #include "kactionclasses.h" - - #include -+#include -+#include FT_FREETYPE_H -+#include - - #include - #include -@@ -35,6 +38,7 @@ - #include - #include - #include -+#include - - #include - #include -@@ -1498,7 +1502,24 @@ void KFontAction::setFont( const QString - return; - } - } -- kdDebug(129) << "Font not found " << family.lower() << endl; -+ -+ // nothing matched yet, try a fontconfig reverse lookup and -+ // check again to solve an alias -+ FcPattern *pattern = NULL; -+ FcConfig *config = NULL; -+ QString realFamily; -+ QRegExp regExp("[-:]"); -+ pattern = FcNameParse( (unsigned char*) family.ascii() ); -+ FcDefaultSubstitute(pattern); -+ FcConfigSubstitute (config, pattern, FcMatchPattern); -+ pattern = FcFontMatch(NULL, pattern, NULL); -+ realFamily = (char*)FcNameUnparse(pattern); -+ realFamily.remove(realFamily.find(regExp), realFamily.length()); -+ -+ if ( !realFamily.isEmpty() && realFamily != family ) -+ setFont( realFamily ); -+ else -+ kdDebug(129) << "Font not found " << family.lower() << endl; - } - - int KFontAction::plug( QWidget *w, int index ) -Index: kdeui/kfontcombo.cpp -=================================================================== ---- kdeui/kfontcombo.cpp.orig -+++ kdeui/kfontcombo.cpp -@@ -20,6 +20,7 @@ - #include - #include - #include -+#include - - #include - #include -@@ -29,6 +30,18 @@ - #include "kfontcombo.h" - #include "kfontcombo.moc" - -+#include -+#include FT_FREETYPE_H -+#include -+#include -+#include -+#include -+#include -+#include -+ -+#include -+ -+ - struct KFontComboPrivate - { - KFontComboPrivate() -@@ -227,6 +240,22 @@ void KFontCombo::setCurrentFont(const QS - return; - } - } -+ -+ // nothing matched yet, try a fontconfig reverse lookup and -+ // check again to solve an alias -+ FcPattern *pattern = NULL; -+ FcConfig *config = NULL; -+ QString realFamily; -+ QRegExp regExp("[-:]"); -+ pattern = FcNameParse( (unsigned char*) family.ascii() ); -+ FcDefaultSubstitute(pattern); -+ FcConfigSubstitute (config, pattern, FcMatchPattern); -+ pattern = FcFontMatch(NULL, pattern, NULL); -+ realFamily = (char*)FcNameUnparse(pattern); -+ realFamily.remove(realFamily.find(regExp), realFamily.length()); -+ -+ if ( !realFamily.isEmpty() && realFamily != family ) -+ setCurrentFont( realFamily ); - } - - void KFontCombo::slotModified( int ) diff --git a/opensuse/core/tdelibs/gcc44.diff b/opensuse/core/tdelibs/gcc44.diff deleted file mode 100644 index f191e1202..000000000 --- a/opensuse/core/tdelibs/gcc44.diff +++ /dev/null @@ -1,20 +0,0 @@ ---- kioslave/ftp/ftp.cc.sav 2009-05-29 13:38:11.000000000 +0200 -+++ kioslave/ftp/ftp.cc 2009-05-29 13:38:38.000000000 +0200 -@@ -876,7 +876,7 @@ int Ftp::ftpOpenPASVDataConnection() - // The usual answer is '227 Entering Passive Mode. (160,39,200,55,6,245)' - // but anonftpd gives '227 =160,39,200,55,6,245' - int i[6]; -- char *start = strchr(ftpResponse(3), '('); -+ const char *start = strchr(ftpResponse(3), '('); - if ( !start ) - start = strchr(ftpResponse(3), '='); - if ( !start || -@@ -931,7 +931,7 @@ int Ftp::ftpOpenEPSVDataConnection() - return ERR_INTERNAL; - } - -- char *start = strchr(ftpResponse(3), '|'); -+ const char *start = strchr(ftpResponse(3), '|'); - if ( !start || sscanf(start, "|||%d|", &portnum) != 1) - return ERR_INTERNAL; - diff --git a/opensuse/core/tdelibs/gcc45.diff b/opensuse/core/tdelibs/gcc45.diff deleted file mode 100644 index a4b8679bf..000000000 --- a/opensuse/core/tdelibs/gcc45.diff +++ /dev/null @@ -1,31 +0,0 @@ ------------------------------------------------------------------------- -r1074156 | mueller | 2010-01-13 16:02:53 +0100 (Mi, 13. Jan 2010) | 2 Zeilen - -fix build with gcc 4.5 - ------------------------------------------------------------------------- -Index: kate/part/katehighlight.cpp -=================================================================== ---- kate/part/katehighlight.cpp (Revision 1074155) -+++ kate/part/katehighlight.cpp (Revision 1074156) -@@ -3225,7 +3225,7 @@ void KateHlManager::getDefaults(uint sch - list.append(charAttribute); - - KateAttribute* string = new KateAttribute(); -- string->setTextColor(QColor::QColor("#D00")); -+ string->setTextColor(QColor("#D00")); - string->setSelectedTextColor(Qt::red); - list.append(string); - -@@ -3242,9 +3242,9 @@ void KateHlManager::getDefaults(uint sch - - KateAttribute* alert = new KateAttribute(); - alert->setTextColor(Qt::black); -- alert->setSelectedTextColor( QColor::QColor("#FCC") ); -+ alert->setSelectedTextColor( QColor("#FCC") ); - alert->setBold(true); -- alert->setBGColor( QColor::QColor("#FCC") ); -+ alert->setBGColor( QColor("#FCC") ); - list.append(alert); - - KateAttribute* functionAttribute = new KateAttribute(); diff --git a/opensuse/core/tdelibs/google-mail.diff b/opensuse/core/tdelibs/google-mail.diff deleted file mode 100644 index 59b132529..000000000 --- a/opensuse/core/tdelibs/google-mail.diff +++ /dev/null @@ -1,18 +0,0 @@ -Index: khtml/html/html_elementimpl.cpp -=================================================================== ---- khtml/html/html_elementimpl.cpp.orig -+++ khtml/html/html_elementimpl.cpp -@@ -565,6 +565,13 @@ DocumentFragment HTMLElementImpl::create - - 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 ); - if ( fragment.isNull() ) { - exceptioncode = DOMException::NO_MODIFICATION_ALLOWED_ERR; diff --git a/opensuse/core/tdelibs/ignore-inline-menu.diff b/opensuse/core/tdelibs/ignore-inline-menu.diff index 106bc5284..09ec6b853 100644 --- a/opensuse/core/tdelibs/ignore-inline-menu.diff +++ b/opensuse/core/tdelibs/ignore-inline-menu.diff @@ -1,14 +1,14 @@ --- kded/vfolder_menu.cpp 2009/11/07 07:01:12 1.1 +++ kded/vfolder_menu.cpp 2009/11/07 07:01:42 -@@ -1496,6 +1496,7 @@ +@@ -1498,6 +1498,7 @@ else kdDebug()<<" Error in parsing show_empty attribute :"<fileName().startsWith("/usr/share/applications/kde4/"); - - config->setDesktopGroup(); - -@@ -133,6 +134,8 @@ KService::init( KDesktopFile *config ) - if (i != -1) - m_strName = m_strName.left(i); - } -+ if (kde4application) -+ m_strName += "/KDE4"; - - m_strType = config->readType(); - entryMap.remove("Type"); -@@ -196,6 +199,18 @@ KService::init( KDesktopFile *config ) - name = name.left(pos); - - m_strExec = config->readPathEntry( "Exec" ); -+ if (kde4application && !m_strExec.startsWith("/")) -+ m_strExec = "/usr/bin/"+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"); - - m_strIcon = config->readEntry( "Icon", "unknown" ); -@@ -245,6 +260,8 @@ KService::init( KDesktopFile *config ) - m_DCOPServiceType = DCOP_None; - - m_strDesktopEntryName = name.lower(); -+ if (kde4application) -+ m_strDesktopEntryName = "kde4-" + m_strDesktopEntryName; - - m_bAllowAsDefault = config->readBoolEntry( "AllowDefault", true ); - entryMap.remove("AllowDefault"); -@@ -254,6 +271,8 @@ KService::init( KDesktopFile *config ) - if ( m_initialPreference == 1 ) - m_initialPreference = config->readNumEntry( "InitialPreference", 1 ); - entryMap.remove("InitialPreference"); -+ if (kde4application) -+ m_initialPreference = 1; - - // Store all additional entries in the property map. - // A QMap would be easier for this but we can't -@@ -263,7 +282,10 @@ KService::init( KDesktopFile *config ) - for( ; it != entryMap.end();++it) - { - //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())); - } - } - diff --git a/opensuse/core/tdelibs/kdecode_fakes_include.diff b/opensuse/core/tdelibs/kdecode_fakes_include.diff deleted file mode 100644 index a00585286..000000000 --- a/opensuse/core/tdelibs/kdecode_fakes_include.diff +++ /dev/null @@ -1,18 +0,0 @@ ---- kdecore/fakes.c -+++ kdecore/fakes.c 2010/01/10 14:00:22 -@@ -323,6 +323,7 @@ - #endif - - #ifndef HAVE_STRLCPY -+#include - KDECORE_EXPORT unsigned long strlcpy(char* d, const char* s, unsigned long bufsize) - { - unsigned long len, ret = strlen(s); -@@ -341,6 +342,7 @@ - #endif - - #ifndef HAVE_STRLCAT -+#include - KDECORE_EXPORT unsigned long strlcat(char* d, const char* s, unsigned long bufsize) - { - char *cp; diff --git a/opensuse/core/tdelibs/kdelibs-3.5.10-CVE-2009-2702.patch b/opensuse/core/tdelibs/kdelibs-3.5.10-CVE-2009-2702.patch deleted file mode 100644 index e6f06a779..000000000 --- a/opensuse/core/tdelibs/kdelibs-3.5.10-CVE-2009-2702.patch +++ /dev/null @@ -1,62 +0,0 @@ -diff -pruN kdelibs-3.5.4.orig/kio/kssl/kopenssl.cc kdelibs-3.5.4/kio/kssl/kopenssl.cc ---- kdelibs-3.5.4.orig/kio/kssl/kopenssl.cc 2009-08-31 20:50:12.000000000 +0200 -+++ kdelibs-3.5.4/kio/kssl/kopenssl.cc 2009-08-31 21:46:47.000000000 +0200 -@@ -196,6 +196,7 @@ static int (*K_X509_NAME_add_entry_by_tx - static X509_NAME *(*K_X509_NAME_new)() = 0L; - static int (*K_X509_REQ_set_subject_name)(X509_REQ*,X509_NAME*) = 0L; - static unsigned char *(*K_ASN1_STRING_data)(ASN1_STRING*) = 0L; -+static int (*K_ASN1_STRING_length)(ASN1_STRING*) = 0L; - static STACK_OF(SSL_CIPHER) *(*K_SSL_get_ciphers)(const SSL *ssl) = 0L; - - #endif -@@ -498,6 +499,7 @@ KConfig *cfg; - K_X509_NAME_new = (X509_NAME *(*)()) _cryptoLib->symbol("X509_NAME_new"); - K_X509_REQ_set_subject_name = (int (*)(X509_REQ*,X509_NAME*)) _cryptoLib->symbol("X509_REQ_set_subject_name"); - K_ASN1_STRING_data = (unsigned char *(*)(ASN1_STRING*)) _cryptoLib->symbol("ASN1_STRING_data"); -+ K_ASN1_STRING_length = (int (*)(ASN1_STRING*)) _cryptoLib->symbol("ASN1_STRING_length"); - #endif - } - -@@ -1549,6 +1551,13 @@ unsigned char *KOpenSSLProxy::ASN1_STRIN - return 0L; - } - -+ -+int KOpenSSLProxy::ASN1_STRING_length(ASN1_STRING *x) { -+ if (K_ASN1_STRING_length) return (K_ASN1_STRING_length)(x); -+ return 0L; -+} -+ -+ - STACK_OF(SSL_CIPHER) *KOpenSSLProxy::SSL_get_ciphers(const SSL* ssl) { - if (K_SSL_get_ciphers) return (K_SSL_get_ciphers)(ssl); - return 0L; -diff -pruN kdelibs-3.5.4.orig/kio/kssl/kopenssl.h kdelibs-3.5.4/kio/kssl/kopenssl.h ---- kdelibs-3.5.4.orig/kio/kssl/kopenssl.h 2006-07-22 10:16:39.000000000 +0200 -+++ kdelibs-3.5.4/kio/kssl/kopenssl.h 2009-08-31 21:46:47.000000000 +0200 -@@ -622,6 +622,11 @@ public: - unsigned char *ASN1_STRING_data(ASN1_STRING *x); - - /* -+ * ASN1_STRING_length -+ */ -+ int ASN1_STRING_length(ASN1_STRING *x); -+ -+ /* - * - */ - int OBJ_obj2nid(ASN1_OBJECT *o); -diff -pruN kdelibs-3.5.4.orig/kio/kssl/ksslcertificate.cc kdelibs-3.5.4/kio/kssl/ksslcertificate.cc ---- kdelibs-3.5.4.orig/kio/kssl/ksslcertificate.cc 2006-01-19 18:06:12.000000000 +0100 -+++ kdelibs-3.5.4/kio/kssl/ksslcertificate.cc 2009-08-31 21:54:38.000000000 +0200 -@@ -1099,7 +1099,9 @@ QStringList KSSLCertificate::subjAltName - } - - QString s = (const char *)d->kossl->ASN1_STRING_data(val->d.ia5); -- if (!s.isEmpty()) { -+ if (!s.isEmpty() && -+ /* skip subjectAltNames with embedded NULs */ -+ s.length() == d->kossl->ASN1_STRING_length(val->d.ia5)) { - rc += s; - } - } diff --git a/opensuse/core/tdelibs/kdelibs-3.5.10-cve-2009-1698.patch b/opensuse/core/tdelibs/kdelibs-3.5.10-cve-2009-1698.patch deleted file mode 100644 index ab9fea5c2..000000000 --- a/opensuse/core/tdelibs/kdelibs-3.5.10-cve-2009-1698.patch +++ /dev/null @@ -1,42 +0,0 @@ -diff -ur kdelibs-3.5.10/khtml/css/cssparser.cpp kdelibs-3.5.10-cve-2009-1698/khtml/css/cssparser.cpp ---- kdelibs-3.5.10/khtml/css/cssparser.cpp 2007-01-15 12:34:04.000000000 +0100 -+++ kdelibs-3.5.10-cve-2009-1698/khtml/css/cssparser.cpp 2009-07-26 05:46:39.000000000 +0200 -@@ -1344,6 +1344,14 @@ - if ( args->size() != 1) - return false; - Value *a = args->current(); -+ if (a->unit != CSSPrimitiveValue::CSS_IDENT) { -+ isValid=false; -+ break; -+ } -+ if (qString(a->string)[0] == '-') { -+ isValid=false; -+ break; -+ } - parsedValue = new CSSPrimitiveValueImpl(domString(a->string), CSSPrimitiveValue::CSS_ATTR); - } - else -@@ -1396,7 +1404,8 @@ - - CounterImpl *counter = new CounterImpl; - Value *i = args->current(); --// if (i->unit != CSSPrimitiveValue::CSS_IDENT) goto invalid; -+ if (i->unit != CSSPrimitiveValue::CSS_IDENT) goto invalid; -+ if (qString(i->string)[0] == '-') goto invalid; - counter->m_identifier = domString(i->string); - if (counters) { - i = args->next(); -diff -ur kdelibs-3.5.10/khtml/css/css_valueimpl.cpp kdelibs-3.5.10-cve-2009-1698/khtml/css/css_valueimpl.cpp ---- kdelibs-3.5.10/khtml/css/css_valueimpl.cpp 2006-07-22 10:16:49.000000000 +0200 -+++ kdelibs-3.5.10-cve-2009-1698/khtml/css/css_valueimpl.cpp 2009-07-26 05:45:36.000000000 +0200 -@@ -736,7 +736,9 @@ - text = getValueName(m_value.ident); - break; - case CSSPrimitiveValue::CSS_ATTR: -- // ### -+ text = "attr("; -+ text += DOMString( m_value.string ); -+ text += ")"; - break; - case CSSPrimitiveValue::CSS_COUNTER: - text = "counter("; diff --git a/opensuse/core/tdelibs/kdelibs-3.5.10-cve-2009-1725.patch b/opensuse/core/tdelibs/kdelibs-3.5.10-cve-2009-1725.patch deleted file mode 100644 index ee8fdbc3f..000000000 --- a/opensuse/core/tdelibs/kdelibs-3.5.10-cve-2009-1725.patch +++ /dev/null @@ -1,13 +0,0 @@ -Index: khtml/html/htmltokenizer.cpp -=================================================================== ---- khtml/html/htmltokenizer.cpp (revision 1002163) -+++ khtml/html/htmltokenizer.cpp (revision 1002164) -@@ -736,7 +736,7 @@ - #ifdef TOKEN_DEBUG - kdDebug( 6036 ) << "unknown entity!" << endl; - #endif -- checkBuffer(10); -+ checkBuffer(11); - // ignore the sequence, add it to the buffer as plaintext - *dest++ = '&'; - for(unsigned int i = 0; i < cBufferPos; i++) diff --git a/opensuse/core/tdelibs/kdelibs-3.5.10-kio.patch b/opensuse/core/tdelibs/kdelibs-3.5.10-kio.patch index 9fb299d4a..8cba39f49 100644 --- a/opensuse/core/tdelibs/kdelibs-3.5.10-kio.patch +++ b/opensuse/core/tdelibs/kdelibs-3.5.10-kio.patch @@ -4,12 +4,12 @@ return true; } -+bool KZip::writeDir(const QString& name, const QString& user, const QString& group) ++bool KZip::writeDir(const TQString& name, const TQString& user, const TQString& group) +{ + // Zip files have no explicit directories, they are implicitly created during extraction time + // when file entries have paths in them. + // However, to support empty directories, we must create a dummy file entry which ends with '/'. -+ QString dirName = name; ++ TQString dirName = name; + if (!name.endsWith("/")) + dirName = dirName.append('/'); + @@ -19,17 +19,8 @@ +} + // Doesn't need to be reimplemented anymore. Remove for KDE-4.0 - bool KZip::writeFile( const QString& name, const QString& user, const QString& group, uint size, const char* data ) + bool KZip::writeFile( const TQString& name, const TQString& user, const TQString& group, uint size, const char* data ) { -@@ -1114,7 +1128,7 @@ - } - - // delete entries in the filelist with the same filename as the one we want -- // to save, so that we dont have duplicate file entries when viewing the zip -+ // to save, so that we don�t have duplicate file entries when viewing the zip - // with konqi... - // CAUTION: the old file itself is still in the zip and won't be removed !!! - QPtrListIterator it( d->m_fileList ); diff -up kdelibs-3.5.10/kio/kio/kzip.h.orig kdelibs-3.5.10/kio/kio/kzip.h --- kdelibs-3.5.10/kio/kio/kzip.h.orig 2009-12-09 19:35:42.000000000 +0100 +++ kdelibs-3.5.10/kio/kio/kzip.h 2009-12-09 19:35:48.000000000 +0100 @@ -40,8 +31,8 @@ diff -up kdelibs-3.5.10/kio/kio/kzip.h.orig kdelibs-3.5.10/kio/kio/kzip.h - /** - * @internal Not needed for zip - */ -- virtual bool writeDir( const QString& name, const QString& user, const QString& group) { Q_UNUSED(name); Q_UNUSED(user); Q_UNUSED(group); return true; } -+ virtual bool writeDir(const QString& name, const QString& user, const QString& group); +- virtual bool writeDir( const TQString& name, const TQString& user, const TQString& group) { Q_UNUSED(name); Q_UNUSED(user); Q_UNUSED(group); return true; } ++ virtual bool writeDir(const TQString& name, const TQString& user, const TQString& group); // TODO(BIC) uncomment and make virtual for KDE 4. - // bool writeDir( const QString& name, const QString& user, const QString& group, + // bool writeDir( const TQString& name, const TQString& user, const TQString& group, // mode_t perm, time_t atime, time_t mtime, time_t ctime ); diff --git a/opensuse/core/tdelibs/kdelibs-3.5.10-latex-syntax-kile-2.0.3.patch b/opensuse/core/tdelibs/kdelibs-3.5.10-latex-syntax-kile-2.0.3.patch deleted file mode 100644 index 450dd1fe8..000000000 --- a/opensuse/core/tdelibs/kdelibs-3.5.10-latex-syntax-kile-2.0.3.patch +++ /dev/null @@ -1,143 +0,0 @@ -diff -ur kdelibs-3.5.10/kate/data/latex.xml kdelibs-3.5.10-latex-syntax-kile-2.0.3/kate/data/latex.xml ---- kdelibs-3.5.10/kate/data/latex.xml 2007-05-14 09:52:27.000000000 +0200 -+++ kdelibs-3.5.10-latex-syntax-kile-2.0.3/kate/data/latex.xml 2008-12-05 14:08:28.000000000 +0100 -@@ -1,16 +1,18 @@ - - -- -+ - - - - - - -- -+ - -+ - - -+ - - - -@@ -22,6 +24,11 @@ - - - -+ -+ -+ -+ -+ - - - -@@ -59,9 +66,46 @@ - - - -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ - - -- -+ - - - -@@ -137,8 +181,9 @@ - - - -- - -+ -+ - - - -@@ -228,6 +273,28 @@ - - - -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ - - - -@@ -315,11 +382,18 @@ - - - -+ -+ - - - - - -+ -+ -+ -+ -+ - - - diff --git a/opensuse/core/tdelibs/kdelibs-3.5.10-ossl-1.x.patch b/opensuse/core/tdelibs/kdelibs-3.5.10-ossl-1.x.patch deleted file mode 100644 index a948b884a..000000000 --- a/opensuse/core/tdelibs/kdelibs-3.5.10-ossl-1.x.patch +++ /dev/null @@ -1,180 +0,0 @@ -diff -up kdelibs-3.5.10/kio/kssl/kopenssl.cc.ossl-1.x kdelibs-3.5.10/kio/kssl/kopenssl.cc ---- kdelibs-3.5.10/kio/kssl/kopenssl.cc.ossl-1.x 2009-09-04 23:10:53.000000000 +0200 -+++ kdelibs-3.5.10/kio/kssl/kopenssl.cc 2009-09-04 23:10:53.000000000 +0200 -@@ -96,9 +96,14 @@ static int (*K_BIO_write) (BIO *b, cons - static int (*K_PEM_ASN1_write_bio) (int (*)(),const char *,BIO *,char *, - const EVP_CIPHER *,unsigned char *,int , - pem_password_cb *, void *) = 0L; -+#if OPENSSL_VERSION_NUMBER >= 0x10000000L -+static int (*K_ASN1_item_i2d_fp)(ASN1_ITEM *,FILE *,unsigned char *) = 0L; -+static ASN1_ITEM *K_NETSCAPE_X509_it = 0L; -+#else - static ASN1_METHOD* (*K_X509_asn1_meth) (void) = 0L; - static int (*K_ASN1_i2d_fp)(int (*)(),FILE *,unsigned char *) = 0L; - static int (*K_i2d_ASN1_HEADER)(ASN1_HEADER *, unsigned char **) = 0L; -+#endif - static int (*K_X509_print_fp) (FILE *, X509*) = 0L; - static int (*K_i2d_PKCS12) (PKCS12*, unsigned char**) = 0L; - static int (*K_i2d_PKCS12_fp) (FILE *, PKCS12*) = 0L; -@@ -430,9 +435,14 @@ KConfig *cfg; - K_BIO_ctrl = (long (*) (BIO *,int,long,void *)) _cryptoLib->symbol("BIO_ctrl"); - K_BIO_write = (int (*) (BIO *b, const void *data, int len)) _cryptoLib->symbol("BIO_write"); - K_PEM_ASN1_write_bio = (int (*)(int (*)(), const char *,BIO*, char*, const EVP_CIPHER *, unsigned char *, int, pem_password_cb *, void *)) _cryptoLib->symbol("PEM_ASN1_write_bio"); -+#if OPENSSL_VERSION_NUMBER >= 0x10000000L -+ K_ASN1_item_i2d_fp = (int (*)(ASN1_ITEM *, FILE*, unsigned char *)) _cryptoLib->symbol("ASN1_item_i2d_fp"); -+ K_NETSCAPE_X509_it = (ASN1_ITEM *) _cryptoLib->symbol("NETSCAPE_X509_it"); -+#else - K_X509_asn1_meth = (ASN1_METHOD* (*)(void)) _cryptoLib->symbol("X509_asn1_meth"); - K_ASN1_i2d_fp = (int (*)(int (*)(), FILE*, unsigned char *)) _cryptoLib->symbol("ASN1_i2d_fp"); - K_i2d_ASN1_HEADER = (int (*)(ASN1_HEADER *, unsigned char **)) _cryptoLib->symbol("i2d_ASN1_HEADER"); -+#endif - K_X509_print_fp = (int (*)(FILE*, X509*)) _cryptoLib->symbol("X509_print_fp"); - K_i2d_PKCS12 = (int (*)(PKCS12*, unsigned char**)) _cryptoLib->symbol("i2d_PKCS12"); - K_i2d_PKCS12_fp = (int (*)(FILE *, PKCS12*)) _cryptoLib->symbol("i2d_PKCS12_fp"); -@@ -594,7 +604,7 @@ KConfig *cfg; - K_SSL_set_session = (int (*)(SSL*,SSL_SESSION*)) _sslLib->symbol("SSL_set_session"); - K_d2i_SSL_SESSION = (SSL_SESSION* (*)(SSL_SESSION**,unsigned char**, long)) _sslLib->symbol("d2i_SSL_SESSION"); - K_i2d_SSL_SESSION = (int (*)(SSL_SESSION*,unsigned char**)) _sslLib->symbol("i2d_SSL_SESSION"); -- K_SSL_get_ciphers = (STACK *(*)(const SSL*)) _sslLib->symbol("SSL_get_ciphers"); -+ K_SSL_get_ciphers = (STACK_OF(SSL_CIPHER) *(*)(const SSL*)) _sslLib->symbol("SSL_get_ciphers"); - #endif - - -@@ -982,7 +992,13 @@ int KOpenSSLProxy::PEM_write_bio_X509(BI - else return -1; - } - -- -+#if OPENSSL_VERSION_NUMBER >= 0x10000000L -+int KOpenSSLProxy::ASN1_i2d_fp(FILE *out,unsigned char *x) { -+ if (K_ASN1_item_i2d_fp && K_NETSCAPE_X509_it) -+ return (K_ASN1_item_i2d_fp)(K_NETSCAPE_X509_it, out, x); -+ else return -1; -+} -+#else - ASN1_METHOD *KOpenSSLProxy::X509_asn1_meth(void) { - if (K_X509_asn1_meth) return (K_X509_asn1_meth)(); - else return 0L; -@@ -994,7 +1010,7 @@ int KOpenSSLProxy::ASN1_i2d_fp(FILE *out - return (K_ASN1_i2d_fp)((int (*)())K_i2d_ASN1_HEADER, out, x); - else return -1; - } -- -+#endif - - int KOpenSSLProxy::X509_print(FILE *fp, X509 *x) { - if (K_X509_print_fp) return (K_X509_print_fp)(fp, x); -diff -up kdelibs-3.5.10/kio/kssl/kopenssl.h.ossl-1.x kdelibs-3.5.10/kio/kssl/kopenssl.h ---- kdelibs-3.5.10/kio/kssl/kopenssl.h.ossl-1.x 2006-07-22 10:16:39.000000000 +0200 -+++ kdelibs-3.5.10/kio/kssl/kopenssl.h 2009-09-04 23:10:53.000000000 +0200 -@@ -48,6 +48,9 @@ class KOpenSSLProxyPrivate; - #include - #include - #undef crypt -+#if OPENSSL_VERSION_NUMBER >= 0x10000000L -+#define STACK _STACK -+#endif - #endif - - #include -@@ -446,12 +449,12 @@ public: - */ - int PEM_write_bio_X509(BIO *bp, X509 *x); - -- -+#if OPENSSL_VERSION_NUMBER < 0x10000000L - /* - * X509_asn1_meth - used for netscape output - */ - ASN1_METHOD *X509_asn1_meth(); -- -+#endif - - /* - * ASN1_i2d_fp - used for netscape output -@@ -531,6 +534,9 @@ public: - */ - void sk_free(STACK *s); - -+#if OPENSSL_VERSION_NUMBER >= 0x10000000L -+ void sk_free(void *s) { return sk_free(reinterpret_cast(s)); } -+#endif - - /* - * Number of elements in the stack -@@ -543,6 +549,9 @@ public: - */ - char *sk_value(STACK *s, int n); - -+#if OPENSSL_VERSION_NUMBER >= 0x10000000L -+ char *sk_value(void *s, int n) { return sk_value(reinterpret_cast(s), n); } -+#endif - - /* - * Create a new stack -@@ -555,6 +564,9 @@ public: - */ - int sk_push(STACK *s, char *d); - -+#if OPENSSL_VERSION_NUMBER >= 0x10000000L -+ int sk_push(void *s, void *d) { return sk_push(reinterpret_cast(s), reinterpret_cast(d)); } -+#endif - - /* - * Duplicate the stack -diff -up kdelibs-3.5.10/kio/kssl/ksmimecrypto.cc.ossl-1.x kdelibs-3.5.10/kio/kssl/ksmimecrypto.cc ---- kdelibs-3.5.10/kio/kssl/ksmimecrypto.cc.ossl-1.x 2005-10-10 17:05:44.000000000 +0200 -+++ kdelibs-3.5.10/kio/kssl/ksmimecrypto.cc 2009-09-04 23:10:53.000000000 +0200 -@@ -87,7 +87,7 @@ KSMIMECryptoPrivate::KSMIMECryptoPrivate - - - STACK_OF(X509) *KSMIMECryptoPrivate::certsToX509(QPtrList &certs) { -- STACK_OF(X509) *x509 = sk_new(NULL); -+ STACK_OF(X509) *x509 = reinterpret_cast(sk_new(NULL)); - KSSLCertificate *cert = certs.first(); - while(cert) { - sk_X509_push(x509, cert->getCert()); -diff -up kdelibs-3.5.10/kio/kssl/ksslcertificate.cc.ossl-1.x kdelibs-3.5.10/kio/kssl/ksslcertificate.cc ---- kdelibs-3.5.10/kio/kssl/ksslcertificate.cc.ossl-1.x 2006-01-19 18:06:12.000000000 +0100 -+++ kdelibs-3.5.10/kio/kssl/ksslcertificate.cc 2009-09-04 23:10:53.000000000 +0200 -@@ -1003,17 +1003,31 @@ return qba; - QByteArray KSSLCertificate::toNetscape() { - QByteArray qba; - #ifdef KSSL_HAVE_SSL --ASN1_HEADER ah; --ASN1_OCTET_STRING os; --KTempFile ktf; -+#if OPENSSL_VERSION_NUMBER >= 0x10000000L -+ NETSCAPE_X509 nx; -+ ASN1_OCTET_STRING hdr; -+#else -+ ASN1_HEADER ah; -+ ASN1_OCTET_STRING os; -+#endif -+ KTempFile ktf; - -- os.data = (unsigned char *)NETSCAPE_CERT_HDR; -- os.length = strlen(NETSCAPE_CERT_HDR); -- ah.header = &os; -- ah.data = (char *)getCert(); -- ah.meth = d->kossl->X509_asn1_meth(); -+#if OPENSSL_VERSION_NUMBER >= 0x10000000L -+ hdr.data = (unsigned char *)NETSCAPE_CERT_HDR; -+ hdr.length = strlen(NETSCAPE_CERT_HDR); -+ nx.header = &hdr; -+ nx.cert = getCert(); -+ -+ d->kossl->ASN1_i2d_fp(ktf.fstream(),(unsigned char *)&nx); -+#else -+ os.data = (unsigned char *)NETSCAPE_CERT_HDR; -+ os.length = strlen(NETSCAPE_CERT_HDR); -+ ah.header = &os; -+ ah.data = (char *)getCert(); -+ ah.meth = d->kossl->X509_asn1_meth(); - -- d->kossl->ASN1_i2d_fp(ktf.fstream(),(unsigned char *)&ah); -+ d->kossl->ASN1_i2d_fp(ktf.fstream(),(unsigned char *)&ah); -+#endif - - ktf.close(); - diff --git a/opensuse/core/tdelibs/kdelibs-3.5.4-CVE-2009-1690.patch b/opensuse/core/tdelibs/kdelibs-3.5.4-CVE-2009-1690.patch deleted file mode 100644 index 2972d0ebf..000000000 --- a/opensuse/core/tdelibs/kdelibs-3.5.4-CVE-2009-1690.patch +++ /dev/null @@ -1,545 +0,0 @@ ---- kdelibs-3.5.4/khtml/html/RefPtr.h.CVE-2009-1690 2009-06-17 14:19:00.000000000 +0200 -+++ kdelibs-3.5.4/khtml/html/RefPtr.h 2009-06-17 14:19:00.000000000 +0200 -@@ -0,0 +1,202 @@ -+// -*- mode: c++; c-basic-offset: 4 -*- -+/* -+ * Copyright (C) 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. -+ * -+ * 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 Street, Fifth Floor, -+ * Boston, MA 02110-1301, USA. -+ * -+ */ -+ -+#ifndef WTF_RefPtr_h -+#define WTF_RefPtr_h -+ -+#include -+#include "AlwaysInline.h" -+ -+namespace WTF { -+ -+ enum PlacementNewAdoptType { PlacementNewAdopt }; -+ -+ template class PassRefPtr; -+ -+ enum HashTableDeletedValueType { HashTableDeletedValue }; -+ -+ template class RefPtr { -+ public: -+ RefPtr() : m_ptr(0) { } -+ RefPtr(T* ptr) : m_ptr(ptr) { if (ptr) ptr->ref(); } -+ RefPtr(const RefPtr& o) : m_ptr(o.m_ptr) { if (T* ptr = m_ptr) ptr->ref(); } -+ // see comment in PassRefPtr.h for why this takes const reference -+ template RefPtr(const PassRefPtr&); -+ -+ // Special constructor for cases where we overwrite an object in place. -+ RefPtr(PlacementNewAdoptType) { } -+ -+ // Hash table deleted values, which are only constructed and never copied or destroyed. -+ RefPtr(HashTableDeletedValueType) : m_ptr(hashTableDeletedValue()) { } -+ bool isHashTableDeletedValue() const { return m_ptr == hashTableDeletedValue(); } -+ -+ ~RefPtr() { if (T* ptr = m_ptr) ptr->deref(); } -+ -+ template RefPtr(const RefPtr& o) : m_ptr(o.get()) { if (T* ptr = m_ptr) ptr->ref(); } -+ -+ T* get() const { return m_ptr; } -+ -+ void clear() { if (T* ptr = m_ptr) ptr->deref(); m_ptr = 0; } -+ PassRefPtr release() { PassRefPtr tmp = adoptRef(m_ptr); m_ptr = 0; return tmp; } -+ -+ T& operator*() const { return *m_ptr; } -+ ALWAYS_INLINE T* operator->() const { return m_ptr; } -+ -+ bool operator!() const { return !m_ptr; } -+ -+ // This conversion operator allows implicit conversion to bool but not to other integer types. -+ typedef T* RefPtr::*UnspecifiedBoolType; -+ operator UnspecifiedBoolType() const { return m_ptr ? &RefPtr::m_ptr : 0; } -+ -+ RefPtr& operator=(const RefPtr&); -+ RefPtr& operator=(T*); -+ RefPtr& operator=(const PassRefPtr&); -+ template RefPtr& operator=(const RefPtr&); -+ template RefPtr& operator=(const PassRefPtr&); -+ -+ void swap(RefPtr&); -+ -+ private: -+ static T* hashTableDeletedValue() { return reinterpret_cast(-1); } -+ -+ T* m_ptr; -+ }; -+ -+ template template inline RefPtr::RefPtr(const PassRefPtr& o) -+ : m_ptr(o.releaseRef()) -+ { -+ } -+ -+ template inline RefPtr& RefPtr::operator=(const RefPtr& o) -+ { -+ T* optr = o.get(); -+ if (optr) -+ optr->ref(); -+ T* ptr = m_ptr; -+ m_ptr = optr; -+ if (ptr) -+ ptr->deref(); -+ return *this; -+ } -+ -+ template template inline RefPtr& RefPtr::operator=(const RefPtr& o) -+ { -+ T* optr = o.get(); -+ if (optr) -+ optr->ref(); -+ T* ptr = m_ptr; -+ m_ptr = optr; -+ if (ptr) -+ ptr->deref(); -+ return *this; -+ } -+ -+ template inline RefPtr& RefPtr::operator=(T* optr) -+ { -+ if (optr) -+ optr->ref(); -+ T* ptr = m_ptr; -+ m_ptr = optr; -+ if (ptr) -+ ptr->deref(); -+ return *this; -+ } -+ -+ template inline RefPtr& RefPtr::operator=(const PassRefPtr& o) -+ { -+ T* ptr = m_ptr; -+ m_ptr = o.releaseRef(); -+ if (ptr) -+ ptr->deref(); -+ return *this; -+ } -+ -+ template template inline RefPtr& RefPtr::operator=(const PassRefPtr& o) -+ { -+ T* ptr = m_ptr; -+ m_ptr = o.releaseRef(); -+ if (ptr) -+ ptr->deref(); -+ return *this; -+ } -+ -+ template inline void RefPtr::swap(RefPtr& o) -+ { -+ std::swap(m_ptr, o.m_ptr); -+ } -+ -+ template inline void swap(RefPtr& a, RefPtr& b) -+ { -+ a.swap(b); -+ } -+ -+ template inline bool operator==(const RefPtr& a, const RefPtr& b) -+ { -+ return a.get() == b.get(); -+ } -+ -+ template inline bool operator==(const RefPtr& a, U* b) -+ { -+ return a.get() == b; -+ } -+ -+ template inline bool operator==(T* a, const RefPtr& b) -+ { -+ return a == b.get(); -+ } -+ -+ template inline bool operator!=(const RefPtr& a, const RefPtr& b) -+ { -+ return a.get() != b.get(); -+ } -+ -+ template inline bool operator!=(const RefPtr& a, U* b) -+ { -+ return a.get() != b; -+ } -+ -+ template inline bool operator!=(T* a, const RefPtr& b) -+ { -+ return a != b.get(); -+ } -+ -+ template inline RefPtr static_pointer_cast(const RefPtr& p) -+ { -+ return RefPtr(static_cast(p.get())); -+ } -+ -+ template inline RefPtr const_pointer_cast(const RefPtr& p) -+ { -+ return RefPtr(const_cast(p.get())); -+ } -+ -+ template inline T* getPtr(const RefPtr& p) -+ { -+ return p.get(); -+ } -+ -+} // namespace WTF -+ -+using WTF::RefPtr; -+using WTF::static_pointer_cast; -+using WTF::const_pointer_cast; -+ -+#endif // WTF_RefPtr_h ---- kdelibs-3.5.4/khtml/html/htmlparser.cpp.CVE-2009-1690 2006-07-22 10:16:43.000000000 +0200 -+++ kdelibs-3.5.4/khtml/html/htmlparser.cpp 2009-06-17 11:51:15.000000000 +0200 -@@ -199,7 +199,6 @@ - - form = 0; - map = 0; -- head = 0; - end = false; - isindex = 0; - -@@ -616,8 +615,7 @@ - case ID_BASE: - if(!head) { - head = new HTMLHeadElementImpl(document); -- e = head; -- insertNode(e); -+ insertNode(head.get()); - handled = true; - } - break; -@@ -839,7 +837,7 @@ - case ID_HEAD: - if(!head && current->id() == ID_HTML) { - head = new HTMLHeadElementImpl(document); -- n = head; -+ n = head.get(); - } - break; - case ID_BODY: -@@ -1679,12 +1677,12 @@ - head = new HTMLHeadElementImpl(document); - HTMLElementImpl *body = doc()->body(); - int exceptioncode = 0; -- doc()->firstChild()->insertBefore(head, body, exceptioncode); -+ doc()->firstChild()->insertBefore(head.get(), body, exceptioncode); - if ( exceptioncode ) { - #ifdef PARSER_DEBUG - kdDebug( 6035 ) << "creation of head failed!!!!" << endl; - #endif -- delete head; -+ delete head.get(); - head = 0; - } - } ---- kdelibs-3.5.4/khtml/html/Platform.h.CVE-2009-1690 2009-06-17 14:19:07.000000000 +0200 -+++ kdelibs-3.5.4/khtml/html/Platform.h 2009-06-17 14:19:07.000000000 +0200 -@@ -0,0 +1,218 @@ -+/* -*- mode: c++; c-basic-offset: 4 -*- */ -+/* -+ * Copyright (C) 2006 Apple Computer, Inc. All rights reserved. -+ * -+ * Redistribution and use in source and binary forms, with or without -+ * modification, are permitted provided that the following conditions -+ * are met: -+ * 1. Redistributions of source code must retain the above copyright -+ * notice, this list of conditions and the following disclaimer. -+ * 2. Redistributions in binary form must reproduce the above copyright -+ * notice, this list of conditions and the following disclaimer in the -+ * documentation and/or other materials provided with the distribution. -+ * -+ * THIS SOFTWARE IS PROVIDED BY APPLE COMPUTER, INC. ``AS IS'' AND ANY -+ * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE COMPUTER, INC. OR -+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, -+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, -+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY -+ * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -+ */ -+ -+#ifndef WTF_Platform_h -+#define WTF_Platform_h -+ -+/* Force KDE build here in our tree... */ -+#ifndef BUILDING_KDE__ -+#define BUILDING_KDE__ 1 -+#endif -+ -+/* PLATFORM handles OS, operating environment, graphics API, and CPU */ -+#define PLATFORM(WTF_FEATURE) (defined( WTF_PLATFORM_##WTF_FEATURE ) && WTF_PLATFORM_##WTF_FEATURE) -+#define COMPILER(WTF_FEATURE) (defined( WTF_COMPILER_##WTF_FEATURE ) && WTF_COMPILER_##WTF_FEATURE) -+#define HAVE(WTF_FEATURE) (defined( HAVE_##WTF_FEATURE ) && HAVE_##WTF_FEATURE) -+#define USE(WTF_FEATURE) (defined( WTF_USE_##WTF_FEATURE ) && WTF_USE_##WTF_FEATURE) -+#define ENABLE(WTF_FEATURE) (defined( ENABLE_##WTF_FEATURE ) && ENABLE_##WTF_FEATURE) -+ -+/* Operating systems - low-level dependencies */ -+ -+/* PLATFORM(DARWIN) */ -+/* Operating system level dependencies for Mac OS X / Darwin that should */ -+/* be used regardless of operating environment */ -+#ifdef __APPLE__ -+#define WTF_PLATFORM_DARWIN 1 -+#endif -+ -+/* PLATFORM(WIN_OS) */ -+/* Operating system level dependencies for Windows that should be used */ -+/* regardless of operating environment */ -+#if defined(WIN32) || defined(_WIN32) -+#define WTF_PLATFORM_WIN_OS 1 -+#endif -+ -+/* PLATFORM(UNIX) */ -+/* Operating system level dependencies for Unix-like systems that */ -+/* should be used regardless of operating environment */ -+/* (includes PLATFORM(DARWIN)) */ -+#if defined(__APPLE__) \ -+ || defined(unix) \ -+ || defined(__unix) \ -+ || defined(__unix__) \ -+ || defined (__NetBSD__) \ -+ || defined(_AIX) -+#define WTF_PLATFORM_UNIX 1 -+#endif -+ -+/* PLATFORM(SOLARIS_OS) */ -+/* Operating system level dependencies for Sun (Open)Solaris 10. */ -+/* Studio 12 on Solaris defines __SunOS; gcc defines __sun__; */ -+/* Both compilers define __sun and sun. */ -+#if defined(__sun) || defined(sun) -+#define WTF_PLATFORM_SOLARIS_OS 1 -+#endif -+ -+/* Operating environments */ -+ -+/* I made the BUILDING_KDE__ macro up for the KDE build system to define */ -+ -+/* PLATFORM(KDE) */ -+/* PLATFORM(MAC) */ -+/* PLATFORM(WIN) */ -+#if BUILDING_KDE__ -+#define WTF_PLATFORM_KDE 1 -+#elif PLATFORM(DARWIN) -+#define WTF_PLATFORM_MAC 1 -+#elif PLATFORM(WIN_OS) -+#define WTF_PLATFORM_WIN 1 -+#endif -+#if defined(BUILDING_GDK__) -+#define WTF_PLATFORM_GDK 1 -+#endif -+ -+ -+/* CPU */ -+ -+/* PLATFORM(PPC) */ -+#if defined(__ppc__) \ -+ || defined(__PPC__) \ -+ || defined(__powerpc__) \ -+ || defined(__powerpc) \ -+ || defined(__POWERPC__) \ -+ || defined(_M_PPC) \ -+ || defined(__PPC) -+#define WTF_PLATFORM_PPC 1 -+#define WTF_PLATFORM_BIG_ENDIAN 1 -+#endif -+ -+/* PLATFORM(PPC64) */ -+#if defined(__ppc64__) \ -+ || defined(__PPC64__) -+#define WTF_PLATFORM_PPC64 1 -+#define WTF_PLATFORM_BIG_ENDIAN 1 -+#endif -+ -+#if defined(arm) -+#define WTF_PLATFORM_ARM 1 -+#if defined(__ARMEB__) -+#define WTF_PLATFORM_BIG_ENDIAN 1 -+#elif !defined(__ARM_EABI__) && !defined(__ARMEB__) -+#define WTF_PLATFORM_MIDDLE_ENDIAN 1 -+#endif -+#if !defined(__ARM_EABI__) -+#define WTF_PLATFORM_FORCE_PACK 1 -+#endif -+#endif -+ -+/* PLATFORM(X86) */ -+#if defined(__i386__) \ -+ || defined(i386) \ -+ || defined(_M_IX86) \ -+ || defined(_X86_) \ -+ || defined(__THW_INTEL) -+#define WTF_PLATFORM_X86 1 -+#endif -+ -+/* PLATFORM(X86_64) */ -+#if defined(__x86_64__) \ -+ || defined(__ia64__) -+#define WTF_PLATFORM_X86_64 1 -+#endif -+ -+/* PLATFORM(SPARC) */ -+#if defined(sparc) -+#define WTF_PLATFORM_SPARC 1 -+#endif -+ -+/* Compiler */ -+ -+/* COMPILER(CWP) */ -+#if defined(__MWERKS__) -+#define WTF_COMPILER_CWP 1 -+#endif -+ -+/* COMPILER(MSVC) */ -+#if defined(_MSC_VER) -+#define WTF_COMPILER_MSVC 1 -+#endif -+ -+/* COMPILER(GCC) */ -+#if defined(__GNUC__) -+#define WTF_COMPILER_GCC 1 -+#endif -+ -+/* COMPILER(SUNPRO) */ -+#if defined(__SUNPRO_CC) -+#define WTF_COMPILER_SUNPRO 1 -+#endif -+ -+/* COMPILER(BORLAND) */ -+/* not really fully supported - is this relevant any more? */ -+#if defined(__BORLANDC__) -+#define WTF_COMPILER_BORLAND 1 -+#endif -+ -+/* COMPILER(CYGWIN) */ -+/* not really fully supported - is this relevant any more? */ -+#if defined(__CYGWIN__) -+#define WTF_COMPILER_CYGWIN 1 -+#endif -+ -+/* multiple threads only supported on Mac for now */ -+#if PLATFORM(MAC) -+#ifndef WTF_USE_MULTIPLE_THREADS -+#define WTF_USE_MULTIPLE_THREADS 1 -+#endif -+#ifndef WTF_USE_BINDINGS -+#define WTF_USE_BINDINGS 1 -+#endif -+#endif -+ -+/* for Unicode, KDE uses Qt, everything else uses ICU */ -+#if PLATFORM(KDE) || PLATFORM(QT) -+#define WTF_USE_QT4_UNICODE 1 -+#elif PLATFORM(SYMBIAN) -+#define WTF_USE_SYMBIAN_UNICODE 1 -+#else -+#define WTF_USE_ICU_UNICODE 1 -+#endif -+ -+#if PLATFORM(MAC) -+#define WTF_PLATFORM_CF 1 -+#endif -+ -+#if PLATFORM(WIN) -+#define WTF_USE_WININET 1 -+#endif -+ -+#if PLATFORM(GDK) -+#define WTF_USE_CURL 1 -+#endif -+ -+/* ENABLE macro defaults */ -+ -+#endif /* WTF_Platform_h */ ---- kdelibs-3.5.4/khtml/html/AlwaysInline.h.CVE-2009-1690 2009-06-17 14:18:52.000000000 +0200 -+++ kdelibs-3.5.4/khtml/html/AlwaysInline.h 2009-06-17 13:56:36.000000000 +0200 -@@ -0,0 +1,49 @@ -+/* -+ * Copyright (C) 2005, 2007 Apple Inc. All rights reserved. -+ * -+ * 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 Street, Fifth Floor, -+ * Boston, MA 02110-1301, USA. -+ * -+ */ -+ -+#include "html/Platform.h" -+ -+ -+#ifndef ALWAYS_INLINE -+#if COMPILER(GCC) && defined(NDEBUG) && __GNUC__ > 3 -+#define ALWAYS_INLINE inline __attribute__ ((__always_inline__)) -+#elif COMPILER(MSVC) && defined(NDEBUG) -+#define ALWAYS_INLINE __forceinline -+#else -+#define ALWAYS_INLINE inline -+#endif -+#endif -+ -+#ifndef ALWAYS_INLINE_INTO -+#if COMPILER(GCC) && defined(NDEBUG) && ((__GNUC__ == 4 && __GNUC_MINOR__ >= 1) || __GNUC__ > 4) -+#define ALWAYS_INLINE_INTO __attribute__ ((__flatten__)) -+#else -+#define ALWAYS_INLINE_INTO -+#endif -+#endif -+ -+ -+#ifndef NEVER_INLINE -+#if COMPILER(GCC) && __GNUC__ > 3 -+#define NEVER_INLINE __attribute__ ((__noinline__)) -+#else -+#define NEVER_INLINE -+#endif -+#endif ---- kdelibs-3.5.4/khtml/html/htmlparser.h.CVE-2009-1690 2005-10-10 17:06:04.000000000 +0200 -+++ kdelibs-3.5.4/khtml/html/htmlparser.h 2009-06-17 14:42:27.000000000 +0200 -@@ -38,10 +38,10 @@ - #include - #endif - -- - #include "dom/dom_string.h" - #include "xml/dom_nodeimpl.h" - #include "html/html_documentimpl.h" -+#include "html/RefPtr.h" - - class KHTMLView; - class HTMLStackElem; -@@ -148,7 +148,7 @@ - /* - * the head element. Needed for crappy html which defines after - */ -- DOM::HTMLHeadElementImpl *head; -+ RefPtr head; - - /* - * a possible element in the head. Compatibility hack for diff --git a/opensuse/core/tdelibs/kdelibs3-gcc-4.1-miscompile.diff b/opensuse/core/tdelibs/kdelibs3-gcc-4.1-miscompile.diff deleted file mode 100644 index cad4ceedd..000000000 --- a/opensuse/core/tdelibs/kdelibs3-gcc-4.1-miscompile.diff +++ /dev/null @@ -1,15 +0,0 @@ -Index: kdecore/kwinmodule.cpp -=================================================================== ---- kdecore/kwinmodule.cpp.orig -+++ kdecore/kwinmodule.cpp -@@ -436,7 +436,9 @@ QRect KWinModule::workArea( const QValue - if ( strut.bottom > 0 ) - r.setBottom( r.bottom() - (int) strut.bottom ); - -- a = a.intersect(r); -+ QRect tmp; -+ tmp = a.intersect(r); -+ a = tmp; - } - return a; - } diff --git a/opensuse/core/tdelibs/kdelibs3-hicolor-scalable-sizes.patch b/opensuse/core/tdelibs/kdelibs3-hicolor-scalable-sizes.patch index 9f06adc93..4ab77bfae 100644 --- a/opensuse/core/tdelibs/kdelibs3-hicolor-scalable-sizes.patch +++ b/opensuse/core/tdelibs/kdelibs3-hicolor-scalable-sizes.patch @@ -1,7 +1,7 @@ diff -uNr kdelibs-3.5.1.old/pics/hicolor/index.theme kdelibs-3.5.1/pics/hicolor/index.theme --- kdelibs-3.5.1.old/pics/hicolor/index.theme 2006-01-20 07:53:04.000000000 +0100 +++ kdelibs-3.5.1/pics/hicolor/index.theme 2006-04-12 20:18:31.907163700 +0200 -@@ -314,36 +314,36 @@ +@@ -333,36 +333,36 @@ Type=Threshold [scalable/actions] diff --git a/opensuse/core/tdelibs/kdelibs_networkstatus_branch2.diff b/opensuse/core/tdelibs/kdelibs_networkstatus_branch2.diff deleted file mode 100644 index 069dffbea..000000000 --- a/opensuse/core/tdelibs/kdelibs_networkstatus_branch2.diff +++ /dev/null @@ -1,69 +0,0 @@ -Index: kioslave/http/http.cc -=================================================================== ---- kioslave/http/http.cc.orig -+++ kioslave/http/http.cc -@@ -1804,9 +1804,11 @@ bool HTTPProtocol::isOffline(const KURL - QByteArray reply; - - QDataStream stream(params, IO_WriteOnly); -- stream << url.url(); - -- if ( dcopClient()->call( "kded", "networkstatus", "status(QString)", -+ if ( url.host() == QString::fromLatin1("localhost") || url.host() == QString::fromLatin1("127.0.0.1") || url.host() == QString::fromLatin1("::") ) { -+ return false; -+ } -+ if ( dcopClient()->call( "kded", "networkstatus", "status()", - params, replyType, reply ) && (replyType == "int") ) - { - int result; -@@ -2210,6 +2212,11 @@ bool HTTPProtocol::httpOpen() - // Conditional cache hit. (Validate) - } - -+ if (bCacheOnly && bOffline) -+ { -+ error( ERR_OFFLINE_MODE, m_request.url.url() ); -+ return false; -+ } - if (bCacheOnly) - { - error( ERR_DOES_NOT_EXIST, m_request.url.url() ); -@@ -2217,7 +2224,7 @@ bool HTTPProtocol::httpOpen() - } - if (bOffline) - { -- error( ERR_COULD_NOT_CONNECT, m_request.url.url() ); -+ error( ERR_OFFLINE_MODE, m_request.url.url() ); - return false; - } - } -Index: kio/kio/global.cpp -=================================================================== ---- kio/kio/global.cpp.orig -+++ kio/kio/global.cpp -@@ -408,6 +408,9 @@ KIO_EXPORT QString KIO::buildErrorString - case KIO::ERR_POST_DENIED: - result = i18n( "Access to restricted port in POST denied."); - break; -+ case KIO::ERR_OFFLINE_MODE: -+ result = i18n( "Could not access %1.\nOffline mode active.").arg( errorText ); -+ break; - default: - result = i18n( "Unknown error code %1\n%2\nPlease send a full bug report at http://bugs.kde.org." ).arg( errorCode ).arg( errorText ); - break; -Index: kio/kio/global.h -=================================================================== ---- kio/kio/global.h.orig -+++ kio/kio/global.h -@@ -244,8 +244,10 @@ namespace KIO - ERR_UPGRADE_REQUIRED = 64, // A transport upgrade is required to access this - // object. For instance, TLS is demanded by - // the server in order to continue. -- ERR_POST_DENIED = 65 // Issued when trying to POST data to a certain Ports -+ ERR_POST_DENIED = 65, // Issued when trying to POST data to a certain Ports - // see job.cpp -+ ERR_OFFLINE_MODE = 66 // Used when an app is in offline mode and a -+ // requested document is unavailable. - }; - - /** diff --git a/opensuse/core/tdelibs/kdemm-20050330.tar.bz2 b/opensuse/core/tdelibs/kdemm-20050330.tar.bz2 deleted file mode 100644 index e71e379e4..000000000 Binary files a/opensuse/core/tdelibs/kdemm-20050330.tar.bz2 and /dev/null differ diff --git a/opensuse/core/tdelibs/kdemm-filepreview.diff b/opensuse/core/tdelibs/kdemm-filepreview.diff deleted file mode 100644 index 227dc39ec..000000000 --- a/opensuse/core/tdelibs/kdemm-filepreview.diff +++ /dev/null @@ -1,40 +0,0 @@ -Index: interfaces/kmediaplayer/kfileaudiopreview/Makefile.am -=================================================================== ---- interfaces/kmediaplayer/kfileaudiopreview/Makefile.am.orig -+++ interfaces/kmediaplayer/kfileaudiopreview/Makefile.am -@@ -1,11 +1,11 @@ --INCLUDES = -I$(top_srcdir)/interfaces/ -I$(top_srcdir)/arts/kde -I$(includedir)/arts $(all_includes) -+INCLUDES = -I$(top_srcdir)/interfaces/ $(all_includes) - METASOURCES = AUTO - - kde_module_LTLIBRARIES = kfileaudiopreview.la - - kfileaudiopreview_la_SOURCES = kfileaudiopreview.cpp - 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)/kdemm/libkdemm.la $(LIB_KIO) - - noinst_HEADERS = kfileaudiopreview.h - -Index: interfaces/kmediaplayer/kfileaudiopreview/kfileaudiopreview.cpp -=================================================================== ---- interfaces/kmediaplayer/kfileaudiopreview/kfileaudiopreview.cpp.orig -+++ interfaces/kmediaplayer/kfileaudiopreview/kfileaudiopreview.cpp -@@ -13,7 +13,7 @@ - #include - #include - --#include -+#include - - #include - -@@ -58,7 +58,7 @@ KFileAudioPreview::KFileAudioPreview( QW - { - KGlobal::locale()->insertCatalogue("kfileaudiopreview"); - -- QStringList formats = KDE::PlayObjectFactory::mimeTypes(); -+ QStringList formats = KDE::Multimedia::Factory::self()->playableMimeTypes(); - // ### - QStringList::ConstIterator it = formats.begin(); - for ( ; it != formats.end(); ++it ) diff --git a/opensuse/core/tdelibs/kdemm.diff b/opensuse/core/tdelibs/kdemm.diff deleted file mode 100644 index 3d1e3d925..000000000 --- a/opensuse/core/tdelibs/kdemm.diff +++ /dev/null @@ -1,669 +0,0 @@ -Index: arts/knotify/knotify.cpp -=================================================================== ---- arts/knotify/knotify.cpp.orig -+++ arts/knotify/knotify.cpp -@@ -5,6 +5,7 @@ - 2000 Matthias Ettrich (ettrich@kde.org) - 2000 Waldo Bastian - 2000-2003 Carsten Pfeiffer -+ 2004 Allan Sandfeld Jensen - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by -@@ -26,21 +27,12 @@ - #include - #include - --#include --#ifndef WITHOUT_ARTS --// aRts headers --#include --#include --#include --#include --#include --#endif -- - // QT headers - #include - #include - #include - #include -+#include - - // KDE headers - #include -@@ -80,15 +72,11 @@ public: - QString externalPlayer; - KProcess *externalPlayerProc; - --#ifndef WITHOUT_ARTS -- QPtrList playObjects; -- QMap playObjectEventMap; -- KAudioManagerPlay *audioManager; --#endif -+ QMap playObjectEventMap; - int externalPlayerEventId; - - bool useExternal; -- bool useArts; -+ bool useKDEMM; - int volume; - QTimer *playTimer; - bool inStartup; -@@ -106,12 +94,13 @@ extern "C"{ - KDE_EXPORT int kdemain(int argc, char **argv) - { - KAboutData aboutdata("knotify", I18N_NOOP("KNotify"), -- "3.0", I18N_NOOP("KDE Notification Server"), -+ "4.0", I18N_NOOP("KDE Notification Server"), - KAboutData::License_GPL, "(C) 1997-2003, KDE Developers"); - aboutdata.addAuthor("Carsten Pfeiffer",I18N_NOOP("Current Maintainer"),"pfeiffer@kde.org"); - aboutdata.addAuthor("Christian Esken",0,"esken@kde.org"); - aboutdata.addAuthor("Stefan Westerfeld",I18N_NOOP("Sound support"),"stefan@space.twc.de"); - aboutdata.addAuthor("Charles Samuels",I18N_NOOP("Previous Maintainer"),"charles@kde.org"); -+ aboutdata.addAuthor("Allan Sandfeld Jensen",I18N_NOOP("Conversion to KDEMM"),"kde@carewolf.com"); - - KCmdLineArgs::init( argc, argv, &aboutdata ); - KUniqueApplication::addCmdLineOptions(); -@@ -126,145 +115,36 @@ KDE_EXPORT int kdemain(int argc, char ** - KUniqueApplication app; - app.disableSessionManagement(); - -- // KNotify is started on KDE startup and on demand (using -- // KNotifClient::startDaemon()) whenever a KNotify event occurs. Especially -- // KWin may fire many events (e.g. when a window pops up). When we have -- // problems with aRts or the installation, we might get an infinite loop -- // of knotify crashing, popping up the crashhandler window and kwin firing -- // another event, starting knotify again... -- // We try to prevent this by tracking our startup and offer options to -- // abort this. -- --#ifndef WITHOUT_ARTS -- KConfigGroup config( KGlobal::config(), "StartProgress" ); -- KConfig artsKCMConfig( "kcmartsrc" ); -- artsKCMConfig.setGroup( "Arts" ); -- bool useArts = artsKCMConfig.readBoolEntry( "StartServer", true ); -- if (useArts) -- useArts = config.readBoolEntry( "Use Arts", useArts ); -- bool ok = config.readBoolEntry( "Arts Init", true ); -- -- if ( useArts && !ok ) -- { -- if ( KMessageBox::questionYesNo( -- 0L, -- i18n("During the previous startup, KNotify crashed while creating " -- "Arts::Dispatcher. Do you want to try again or disable " -- "aRts sound output?\n\n" -- "If you choose to disable aRts output now, you can re-enable " -- "it later or select an alternate sound player " -- "in the System Notifications control panel."), -- i18n("KNotify Problem"), -- i18n("&Try Again"), -- i18n("D&isable aRts Output"), -- "KNotifyStartProgress", -- 0 /* don't call KNotify :) */ -- ) -- == KMessageBox::No ) -- { -- useArts = false; -- } -- } -- -- // when ArtsDispatcher crashes, we know it the next start. -- config.writeEntry( "Arts Init", false ); -- config.writeEntry( "Use Arts", useArts ); -- config.sync(); -- -- KArtsDispatcher *dispatcher = 0; -- if ( useArts ) -- { -- dispatcher = new KArtsDispatcher; -- soundServer = new KArtsServer; -- } -- -- // ok, seemed to work. -- config.writeEntry("Arts Init", useArts ); -- config.sync(); -- -- ok = config.readBoolEntry( "KNotify Init", true ); -- if ( useArts && !ok ) -- { -- if ( KMessageBox::questionYesNo( -- 0L, -- i18n("During the previous startup, KNotify crashed while instantiating " -- "KNotify. Do you want to try again or disable " -- "aRts sound output?\n\n" -- "If you choose to disable aRts output now, you can re-enable " -- "it later or select an alternate sound player " -- "in the System Notifications control panel."), -- i18n("KNotify Problem"), -- i18n("&Try Again"), -- i18n("D&isable aRts Output"), -- "KNotifyStartProgress", -- 0 /* don't call KNotify :) */ -- ) -- == KMessageBox::No ) -- { -- useArts = false; -- delete soundServer; -- soundServer = 0L; -- delete dispatcher; -- dispatcher = 0L; -- } -- } -- -- // when KNotify instantiation crashes, we know it the next start. -- config.writeEntry( "KNotify Init", false ); -- config.writeEntry( "Use Arts", useArts ); -- config.sync(); -- - // start notify service -- KNotify *notify = new KNotify( useArts ); -- -- config.writeEntry( "KNotify Init", true ); -- config.sync(); -- --#else -- -- // start notify service, without aRts -- KNotify *notify = new KNotify( false ); -- --#endif -+ KNotify notify( true ); - - app.dcopClient()->setDefaultObject( "Notify" ); - app.dcopClient()->setDaemonMode( true ); - // kdDebug() << "knotify starting" << endl; - - int ret = app.exec(); -- delete notify; --#ifndef WITHOUT_ARTS -- delete soundServer; -- delete dispatcher; --#endif - return ret; - } - }// end extern "C" - --KNotify::KNotify( bool useArts ) -+KNotify::KNotify( bool useKDEMM ) - : QObject(), DCOPObject("Notify") - { - d = new KNotifyPrivate; - d->globalEvents = new KConfig("knotify/eventsrc", true, false, "data"); - d->globalConfig = new KConfig("knotify.eventsrc", true, false); - d->externalPlayerProc = 0; -- d->useArts = useArts; -- d->inStartup = true; --#ifndef WITHOUT_ARTS -- d->playObjects.setAutoDelete(true); -- d->audioManager = 0; -- if( useArts ) -- { -- connect( soundServer, SIGNAL( restartedServer() ), this, SLOT( restartedArtsd() ) ); -- restartedArtsd(); //started allready need to initialize d->audioManager -- } --#endif -+ d->useKDEMM = useKDEMM; - -- d->volume = 100; -+ d->inStartup = 0; -+ d->volume = 100; - - d->playTimer = 0; - - loadConfig(); -+ -+ connect ( this, SIGNAL(deletePlayObject(KDE::Multimedia::SimplePlayer*)), -+ SLOT(objectDeleter(KDE::Multimedia::SimplePlayer*)) ); - } - - KNotify::~KNotify() -@@ -272,12 +152,9 @@ KNotify::~KNotify() - reconfigure(); - - #ifndef WITHOUT_ARTS -- d->playObjects.clear(); -- - delete d->globalEvents; - delete d->globalConfig; - delete d->externalPlayerProc; -- delete d->audioManager; - #endif - delete d; - } -@@ -293,7 +170,7 @@ void KNotify::loadConfig() { - // try to locate a suitable player if none is configured - if ( d->externalPlayer.isEmpty() ) { - QStringList players; -- players << "wavplay" << "aplay" << "auplay"; -+ players << "wavplay" << "aplay" << "auplay" << "artsplay" << "akodeplay"; - QStringList::Iterator it = players.begin(); - while ( d->externalPlayer.isEmpty() && it != players.end() ) { - d->externalPlayer = KStandardDirs::findExe( *it ); -@@ -456,9 +333,9 @@ bool KNotify::notifyBySound( const QStri - if ( soundFile.isEmpty() ) - soundFile = locate( "sound", sound ); - } -- if ( soundFile.isEmpty() || isPlaying( soundFile ) ) -+ if ( soundFile.isEmpty() ) - { -- soundFinished( eventId, soundFile.isEmpty() ? NoSoundFile : FileAlreadyPlaying ); -+ soundFinished( eventId, NoSoundFile ); - return false; - } - -@@ -466,64 +343,18 @@ bool KNotify::notifyBySound( const QStri - // kdDebug() << "KNotify::notifyBySound - trying to play file " << soundFile << endl; - - if (!external) { -- //If we disabled using aRts, just return, -- //(If we don't, we'll blow up accessing the null soundServer) -- if (!d->useArts) -+ //If we disabled audio, just return, -+ if (!d->useKDEMM) - { - soundFinished( eventId, NoSoundSupport ); - return false; - } - --#ifndef WITHOUT_ARTS -- // play sound finally -- while( d->playObjects.count()>5 ) -- abortFirstPlayObject(); -- -- KDE::PlayObjectFactory factory(soundServer->server()); -- if( d->audioManager ) -- factory.setAudioManagerPlay( d->audioManager ); - KURL soundURL; - soundURL.setPath(soundFile); -- KDE::PlayObject *playObject = factory.createPlayObject(soundURL, false); -- -- if (playObject->isNull()) -- { -- soundFinished( eventId, NoSoundSupport ); -- delete playObject; -- return false; -- } -- -- if ( d->volume != 100 ) -- { -- // It works to access the playObject immediately because we don't allow -- // non-file URLs for sounds. -- Arts::StereoVolumeControl volumeControl = Arts::DynamicCast(soundServer->server().createObject("Arts::StereoVolumeControl")); -- Arts::PlayObject player = playObject->object(); -- Arts::Synth_AMAN_PLAY ap = d->audioManager->amanPlay(); -- if( ! volumeControl.isNull() && ! player.isNull() && ! ap.isNull() ) -- { -- volumeControl.scaleFactor( d->volume/100.0 ); -- -- ap.stop(); -- Arts::disconnect( player, "left", ap, "left" ); -- Arts::disconnect( player, "right", ap, "right" ); -- -- ap.start(); -- volumeControl.start(); -- -- Arts::connect(player,"left",volumeControl,"inleft"); -- Arts::connect(player,"right",volumeControl,"inright"); -- -- Arts::connect(volumeControl,"outleft",ap,"left"); -- Arts::connect(volumeControl,"outright",ap,"right"); -- -- player._addChild( volumeControl, "volume" ); -- } -- } -- -- playObject->play(); -- d->playObjects.append( playObject ); -+ KDE::Multimedia::SimplePlayer* playObject = new KDE::Multimedia::SimplePlayer( this ); - d->playObjectEventMap.insert( playObject, eventId ); -+ playObject->play( soundURL ); - - if ( !d->playTimer ) - { -@@ -532,8 +363,7 @@ bool KNotify::notifyBySound( const QStri - } - if ( !d->playTimer->isActive() ) - d->playTimer->start( 1000 ); --#endif -- return true; -+ return playObject->isPlaying(); - - } else if(!d->externalPlayer.isEmpty()) { - // use an external player to play the sound -@@ -686,58 +516,39 @@ void KNotify::setVolume( int volume ) - d->volume = volume; - } - -+void KNotify::slotPlayerProcessExited( KProcess *proc ) -+{ -+ soundFinished( d->externalPlayerEventId, -+ (proc->normalExit() && proc->exitStatus() == 0) ? PlayedOK : Unknown ); -+} -+ -+ - void KNotify::playTimeout() - { --#ifndef WITHOUT_ARTS -- for ( QPtrListIterator< KDE::PlayObject > it(d->playObjects); *it;) -+qDebug("KNotify::playTimeout"); -+ for( QMap< KDE::Multimedia::SimplePlayer*, int >::Iterator it = d->playObjectEventMap.begin(); -+ it != d->playObjectEventMap.end(); -+ ) - { -- QPtrListIterator< KDE::PlayObject > current = it; -+ QMap< KDE::Multimedia::SimplePlayer*, int >::Iterator current = it; - ++it; -- if ( (*current)->state() != Arts::posPlaying ) -+ KDE::Multimedia::SimplePlayer* playObject = current.key(); -+ if ( !playObject->isPlaying() || playObject->totalTime() <= 0 ) // may be "playing" even if there's an error - { -- QMap::Iterator eit = d->playObjectEventMap.find( *current ); -- if ( eit != d->playObjectEventMap.end() ) -- { -- soundFinished( *eit, PlayedOK ); -- d->playObjectEventMap.remove( eit ); -- } -- d->playObjects.remove( current ); -+ soundFinished( *current, PlayedOK ); -+ d->playObjectEventMap.remove( current ); -+ disconnect( playObject, SIGNAL( finished() ) ); -+ playObject->stop(); -+ emit deletePlayObject(playObject); - } - } -- if ( !d->playObjects.count() ) -+ if ( !d->playObjectEventMap.count() ) - d->playTimer->stop(); --#endif - } - --bool KNotify::isPlaying( const QString& soundFile ) const -+void KNotify::objectDeleter( KDE::Multimedia::SimplePlayer *playObject ) - { --#ifndef WITHOUT_ARTS -- for ( QPtrListIterator< KDE::PlayObject > it(d->playObjects); *it; ++it) -- { -- if ( (*it)->mediaName() == soundFile ) -- return true; -- } --#endif -- return false; --} -- --void KNotify::slotPlayerProcessExited( KProcess *proc ) --{ -- soundFinished( d->externalPlayerEventId, -- (proc->normalExit() && proc->exitStatus() == 0) ? PlayedOK : Unknown ); --} -- --void KNotify::abortFirstPlayObject() --{ --#ifndef WITHOUT_ARTS -- QMap::Iterator it = d->playObjectEventMap.find( d->playObjects.getFirst() ); -- if ( it != d->playObjectEventMap.end() ) -- { -- soundFinished( it.data(), Aborted ); -- d->playObjectEventMap.remove( it ); -- } -- d->playObjects.removeFirst(); --#endif -+ delete playObject; - } - - void KNotify::soundFinished( int eventId, PlayingFinishedStatus reason ) -@@ -780,16 +591,6 @@ WId KNotify::checkWinId( const QString & - return senderWinId; - } - --void KNotify::restartedArtsd() --{ --#ifndef WITHOUT_ARTS -- delete d->audioManager; -- d->audioManager = new KAudioManagerPlay( soundServer ); -- d->audioManager->setTitle( i18n( "KDE System Notifications" ) ); -- d->audioManager->setAutoRestoreID( "KNotify Aman Play" ); --#endif --} -- - void KNotify::sessionReady() - { - if( d->inStartup && !d->startupEvents.isEmpty()) -Index: arts/knotify/knotify.h -=================================================================== ---- arts/knotify/knotify.h.orig -+++ arts/knotify/knotify.h -@@ -24,9 +24,10 @@ - #include - #include - -+#include -+ - class KNotifyPrivate; - class KProcess; --class KConfig; - - class KNotify : public QObject, public DCOPObject - { -@@ -76,19 +77,16 @@ private: - bool notifyByStderr(const QString &text); - bool notifyByPassivePopup(const QString &text, const QString &appName, - KConfig* eventsFile, WId winId ); -- bool notifyByExecute(const QString &command, -- const QString& event, -- const QString& fromApp, -+ bool notifyByExecute(const QString &command, -+ const QString& event, -+ const QString& fromApp, - const QString& text, - int winId, - int eventId ); -- bool notifyByTaskbar( WId winId ); -- -- bool isPlaying( const QString& soundFile ) const; -- -- void soundFinished( int eventId, PlayingFinishedStatus reason ); -- void abortFirstPlayObject(); -- -+ bool notifyByTaskbar( WId winId ); -+ -+ void soundFinished( int eventId, PlayingFinishedStatus reason ); -+ - WId checkWinId( const QString& appName, WId senderWinId ); - - /** -@@ -97,9 +95,13 @@ private: - bool isGlobal(const QString &eventname); - - private slots: -- void playTimeout(); -- void slotPlayerProcessExited( KProcess *proc ); -- void restartedArtsd(); -+ void playTimeout(); -+ void slotPlayerProcessExited( KProcess *proc ); -+ void objectDeleter( KDE::Multimedia::SimplePlayer* ); -+ -+signals: -+ void deletePlayObject( KDE::Multimedia::SimplePlayer* ); -+ - - private: - KNotifyPrivate* d; -Index: arts/knotify/Makefile.am -=================================================================== ---- arts/knotify/Makefile.am.orig -+++ arts/knotify/Makefile.am -@@ -3,12 +3,13 @@ INCLUDES= -I$(top_srcdir)/arts/kde -I$(i - - ####### Files - --kde_module_LTLIBRARIES = knotify.la -+#kde_module_LTLIBRARIES = knotify.la -+bin_PROGRAMS = -+lib_LTLIBRARIES = -+kdeinit_LTLIBRARIES = knotify.la - - knotify_la_SOURCES = knotify.cpp knotify.skel --if include_ARTS --knotify_la_LIBADD = -lsoundserver_idl -lqtmcop $(LIB_KDEUI) $(top_builddir)/arts/kde/libartskde.la --endif -+knotify_la_LIBADD = $(LIB_KDEUI) $(top_builddir)/kdemm/libkdemm.la - knotify_la_LDFLAGS = $(all_libraries) -module -avoid-version - knotify_la_METASOURCES = AUTO - -Index: kdemm/channel.h -=================================================================== ---- kdemm/channel.h.orig -+++ kdemm/channel.h -@@ -83,7 +83,7 @@ namespace Multimedia - * You can not instantiate channels yourself, use the Factory to - * create them. - */ -- Channel( const QString & name, const QString & type, Direction direction, -+ Channel( const QString & channelName, const QString & type, Direction direction, - QObject * parent = 0, const char * name = 0 ); - - private: -Index: kdemm/factory.cpp -=================================================================== ---- kdemm/factory.cpp.orig -+++ kdemm/factory.cpp -@@ -80,6 +80,7 @@ class Factory::Private - ":\n" << e << endl; - } - } -+#if 0 - if( 0 == backend ) - { - if( offers.size() == 0 ) -@@ -100,6 +101,7 @@ class Factory::Private - i18n( "Unable to use any of the available Multimedia Backends" ), details ); - } - } -+#endif - } - - Backend * backend; -Index: kdemm/simpleplayer.cpp -=================================================================== ---- kdemm/simpleplayer.cpp.orig -+++ kdemm/simpleplayer.cpp -@@ -50,10 +50,12 @@ SimplePlayer::SimplePlayer( QObject * pa - connect( Factory::self(), SIGNAL( recreateObjects() ), SLOT( recreateObjects() ) ); - d->channel = Factory::self()->createChannel( KGlobal::instance()->aboutData()->programName() ); - d->player = Factory::self()->createPlayer(); -- d->player->setOutputChannel( d->channel ); -- connect( d->player, SIGNAL( stateChanged( KDE::Multimedia::Player::State, KDE::Multimedia::Player::State ) ), -+ if ( d->player ) { -+ d->player->setOutputChannel( d->channel ); -+ connect( d->player, SIGNAL( stateChanged( KDE::Multimedia::Player::State, KDE::Multimedia::Player::State ) ), - SLOT( stateChanged( KDE::Multimedia::Player::State, KDE::Multimedia::Player::State ) ) ); -- connect( d->player, SIGNAL( finished() ), SIGNAL( finished() ) ); -+ connect( d->player, SIGNAL( finished() ), SIGNAL( finished() ) ); -+ }; - } - - SimplePlayer::~SimplePlayer() -@@ -64,6 +66,8 @@ SimplePlayer::~SimplePlayer() - - void SimplePlayer::play( const KURL & url ) - { -+ if( ! d->player ) -+ return; - if( isPaused() && url == d->url ) - { - d->player->play(); -@@ -78,51 +82,71 @@ void SimplePlayer::play( const KURL & ur - - void SimplePlayer::pause() - { -+ if( ! d->player ) -+ return; - d->player->pause(); - } - - void SimplePlayer::stop() - { -+ if( ! d->player ) -+ return; - d->player->stop(); - } - - long SimplePlayer::totalTime() const - { -+ if( ! d->player ) -+ return 0; - return d->player->totalTime(); - } - - long SimplePlayer::currentTime() const - { -+ if( ! d->player ) -+ return 0; - return d->player->currentTime(); - } - - void SimplePlayer::seek( long ms ) - { -+ if( ! d->player ) -+ return; - d->player->seek( ms ); - } - - float SimplePlayer::volume() const - { -+ if( ! d->player ) -+ return 0; - return d->channel->volume(); - } - - void SimplePlayer::setVolume( float v ) - { -+ if( ! d->player ) -+ return; - d->channel->setVolume( v ); - } - - bool SimplePlayer::isPlaying() const - { -+ if( ! d->player ) -+ return false; - return ( d->player->state() == Player::Playing ); - } - - bool SimplePlayer::isPaused() const - { -+ if( ! d->player ) -+ return false; - return ( d->player->state() == Player::Paused ); - } - - void SimplePlayer::stateChanged( Player::State ns, Player::State os ) - { -+ if( ! d->player ) -+ return; - if( os == Player::Loading && ns == Player::Stopped ) - d->player->play(); - } -@@ -135,7 +159,8 @@ void SimplePlayer::deleteYourObjects() - d->title = d->channel->channelName(); - d->type = d->channel->channelType(); - -- d->player->stop(); -+ if( d->player ) -+ d->player->stop(); - - delete d->player; - delete d->channel; -@@ -149,6 +174,9 @@ void SimplePlayer::recreateObjects() - d->channel->setVolume( d->channelvolume ); - - d->player = Factory::self()->createPlayer(); -+ if( ! d->player ) -+ return; -+ - d->player->setOutputChannel( d->channel ); - - if( d->state != Player::NoMedia ) diff --git a/opensuse/core/tdelibs/kdeprint-restart-cupsd.diff b/opensuse/core/tdelibs/kdeprint-restart-cupsd.diff index d464098eb..2fc7cccb3 100644 --- a/opensuse/core/tdelibs/kdeprint-restart-cupsd.diff +++ b/opensuse/core/tdelibs/kdeprint-restart-cupsd.diff @@ -1,32 +1,16 @@ -Index: kdeprint/cups/cupsdconf2/cupsddialog.cpp +Index: tdeprint/cups/cupsdconf2/cupsddialog.cpp =================================================================== ---- kdeprint/cups/cupsdconf2/cupsddialog.cpp.orig -+++ kdeprint/cups/cupsdconf2/cupsddialog.cpp -@@ -45,6 +45,7 @@ - #include - #include - -+#include - #include - #include - -@@ -205,15 +206,13 @@ bool CupsdDialog::restartServer(QString& - } - else +--- tdeprint/cups/cupsdconf2/cupsddialog.cpp.orig ++++ tdeprint/cups/cupsdconf2/cupsddialog.cpp +@@ -208,7 +208,10 @@ { -+ KProcess proc; bool success = false; - if (getuid() == 0 ) -- success = (::kill(serverPid, SIGHUP) == 0); -+ proc << "rccups" << "force-reload"; - else -- { -- KProcess proc; -- proc << "kdesu" << "-c" << "kill -SIGHUP " + QString::number( serverPid ); -- success = proc.start( KProcess::Block ) && proc.normalExit(); -- } -+ proc << "kdesu" << "-c" << "rccups" << "force-reload"; -+ success = proc.start( KProcess::Block ) && proc.normalExit(); + KProcess proc; +- proc << "tdesu" << "-c" << "/etc/init.d/cupsys restart"; ++ if (getuid() == 0 ) ++ proc << "rccups" << "force-reload"; ++ else ++ proc << "tdesu" << "-c" << "rccups" << "force-reload"; + success = proc.start( KProcess::Block ) && proc.normalExit(); if( !success ) msg = i18n("Unable to restart CUPS server (pid = %1)").arg(serverPid); - } diff --git a/opensuse/core/tdelibs/kdeprint-utf8.diff b/opensuse/core/tdelibs/kdeprint-utf8.diff deleted file mode 100644 index ed2ad79da..000000000 --- a/opensuse/core/tdelibs/kdeprint-utf8.diff +++ /dev/null @@ -1,13 +0,0 @@ -Index: kdeprint/cups/kmcupsmanager.cpp -=================================================================== ---- kdeprint/cups/kmcupsmanager.cpp.orig -+++ kdeprint/cups/kmcupsmanager.cpp -@@ -85,7 +85,7 @@ static int trials = 5; - // change LANG variable so that CUPS is always using - // english language: translation may only come from the PPD - // itself, or from KDE. -- setenv("LANG", "en", 1); -+ setenv("LANG", "en_US.UTF-8", 1); - } - - KMCupsManager::~KMCupsManager() diff --git a/opensuse/core/tdelibs/kdesu-settings.diff b/opensuse/core/tdelibs/kdesu-settings.diff deleted file mode 100644 index fc24c09b6..000000000 --- a/opensuse/core/tdelibs/kdesu-settings.diff +++ /dev/null @@ -1,50 +0,0 @@ -Subject: Change kdesu settings -From: Lubos Lunak -Bug: 216796 -Relates: kdelibs4/kdesu-settings.diff -Patch-upstream: never - -Change kdesu(d) password keeping timeout only to 5 minutes and enable -it by default (to match kdesu using sudo in 10.3 behaviour). -KDE3 needs a hack in KPasswordDialog for enabling it by default. - -Update: Change the timeout back to 2 hours (bnc#404521). - -Index: kdesu/defaults.h -=================================================================== ---- kdesu/defaults.h.orig -+++ kdesu/defaults.h -@@ -13,8 +13,9 @@ - #ifndef __Defaults_h_included__ - #define __Defaults_h_included__ - -+/*const int defTimeout = 120*60;*/ - const int defTimeout = 120*60; - const int defEchoMode = 0; --const int defKeep = false; -+const int defKeep = true; - - #endif -Index: kdeui/kpassdlg.cpp -=================================================================== ---- kdeui/kpassdlg.cpp.orig -+++ kdeui/kpassdlg.cpp -@@ -49,6 +49,8 @@ - - #include "kpassdlg.h" - -+#include "../kdesu/defaults.h" -+ - /* - * Password line editor. - */ -@@ -337,7 +339,8 @@ void KPasswordDialog::init() - - KConfig* const cfg = KGlobal::config(); - const KConfigGroupSaver saver(cfg, "Passwords"); -- if (m_Keep && cfg->readBoolEntry("Keep", false)) -+ bool def = ( qstrcmp( qAppName(), "kdesu" ) == 0 ? defKeep : false ); -+ if (m_Keep && cfg->readBoolEntry("Keep", def)) - ++m_Keep; - - m_pMain = new QWidget(this); diff --git a/opensuse/core/tdelibs/kdeversion.diff b/opensuse/core/tdelibs/kdeversion.diff index f9b4cc1c2..a367c7e1a 100644 --- a/opensuse/core/tdelibs/kdeversion.diff +++ b/opensuse/core/tdelibs/kdeversion.diff @@ -1,10 +1,10 @@ -Index: kdecore/kdeversion.h +Index: tdecore/tdeversion.h =================================================================== ---- kdecore/kdeversion.h.orig -+++ kdecore/kdeversion.h +--- tdecore/tdeversion.h.orig ++++ tdecore/tdeversion.h @@ -33,6 +33,8 @@ - #define KDE_IS_VERSION(a,b,c) ( KDE_VERSION >= KDE_MAKE_VERSION(a,b,c) ) + #define KDE_IS_VERSION(a,b,c) ( TDE_VERSION >= TDE_MAKE_VERSION(a,b,c) ) +#define KDELIBS_SUSE + diff --git a/opensuse/core/tdelibs/kfile-beagle.diff b/opensuse/core/tdelibs/kfile-beagle.diff deleted file mode 100644 index 467e68ed4..000000000 --- a/opensuse/core/tdelibs/kfile-beagle.diff +++ /dev/null @@ -1,42 +0,0 @@ -Index: kio/kfile/kurlbar.cpp -=================================================================== ---- kio/kfile/kurlbar.cpp.orig -+++ kio/kfile/kurlbar.cpp -@@ -605,8 +605,19 @@ void KURLBar::readItem( int i, KConfig * - if ( !url.isValid() || !KProtocolInfo::isKnownProtocol( url )) - return; // nothing we could do. - -+ QString description = config->readEntry( QString("Description_") + number ); -+ -+ if (description.isEmpty() && url.protocol()=="beagle") { -+ KIO::UDSEntry uds; -+ const KURL kurl("beagle:?beagled-status"); -+ if (!KIO::NetAccess::stat(kurl, uds)) -+ return; -+ -+ description = i18n("Desktop Search"); -+ } -+ - insertItem( url, -- config->readEntry( QString("Description_") + number ), -+ description, - applicationLocal, - config->readEntry( QString("Icon_") + number ), - static_cast( -Index: kio/kfile/kfiledialog.cpp -=================================================================== ---- kio/kfile/kfiledialog.cpp.orig -+++ kio/kfile/kfiledialog.cpp -@@ -1165,6 +1165,12 @@ void KFileDialog::urlEntered(const KURL& - d->pathCombo->setURL( url ); - } - -+ if (url.protocol()=="beagle" && url.path()=="/") { -+ d->pathCombo->setEditText("beagle:/<"+i18n("search term")+">"); -+ d->pathCombo->lineEdit()->setSelection(8,255); -+ d->pathCombo->setFocus(); -+ } -+ - locationEdit->blockSignals( true ); - locationEdit->setCurrentItem( 0 ); - if ( d->keepLocation ) diff --git a/opensuse/core/tdelibs/kickoff-drop-shadow.diff b/opensuse/core/tdelibs/kickoff-drop-shadow.diff deleted file mode 100644 index e4c7befc2..000000000 --- a/opensuse/core/tdelibs/kickoff-drop-shadow.diff +++ /dev/null @@ -1,177 +0,0 @@ -Index: kdefx/kstyle.cpp -=================================================================== ---- kdefx/kstyle.cpp.orig -+++ kdefx/kstyle.cpp -@@ -31,6 +31,7 @@ - - #include - #include -+#include - #include - #include - #include -@@ -79,7 +80,7 @@ namespace - QWidget* w1; - QWidget* w2; - }; -- typedef QMap ShadowMap; -+ typedef QMap ShadowMap; - static ShadowMap *_shadowMap = 0; - QSingleCleanupHandler cleanupShadowMap; - ShadowMap &shadowMap() { -@@ -113,8 +114,13 @@ namespace - - const double shadow_strip[4] = - { 0.565, 0.675, 0.835, 0.945 }; --} - -+ static bool useDropShadow(QWidget* w) -+ { -+ return w && w->metaObject() && -+ w->metaObject()->findProperty("KStyleMenuDropShadow") != -1; -+ } -+} - - namespace - { -@@ -128,12 +134,12 @@ class TransparencyHandler : public QObje - - protected: - void blendToColor(const QColor &col); -- void blendToPixmap(const QColorGroup &cg, const QPopupMenu* p); -+ void blendToPixmap(const QColorGroup &cg, const QWidget* p); - #ifdef HAVE_XRENDER -- void XRenderBlendToPixmap(const QPopupMenu* p); -+ void XRenderBlendToPixmap(const QWidget* p); - #endif -- void createShadowWindows(const QPopupMenu* p); -- void removeShadowWindows(const QPopupMenu* p); -+ void createShadowWindows(const QWidget* p); -+ void removeShadowWindows(const QWidget* p); - void rightShadow(QImage& dst); - void bottomShadow(QImage& dst); - private: -@@ -256,8 +262,16 @@ void KStyle::polish( QWidget* widget ) - widget->installEventFilter(this); - } - } --} -+ if (widget->isTopLevel()) -+ { -+ if (!d->menuHandler && useDropShadow(widget)) -+ d->menuHandler = new TransparencyHandler(this, Disabled, 1.0, false); - -+ if (d->menuHandler && useDropShadow(widget)) -+ widget->installEventFilter(d->menuHandler); -+ } -+} -+ - - void KStyle::unPolish( QWidget* widget ) - { -@@ -267,8 +281,10 @@ void KStyle::unPolish( QWidget* widget ) - QFrame::Shape shape = frame->frameShape(); - if (shape == QFrame::ToolBarPanel || shape == QFrame::MenuBarPanel) - widget->removeEventFilter(this); -- } -+ } - } -+ if (widget->isTopLevel() && d->menuHandler && useDropShadow(widget)) -+ widget->removeEventFilter(d->menuHandler); - } - - -@@ -1997,7 +2013,7 @@ void TransparencyHandler::bottomShadow(Q - } - - // Create a shadow of thickness 4. --void TransparencyHandler::createShadowWindows(const QPopupMenu* p) -+void TransparencyHandler::createShadowWindows(const QWidget* p) - { - #ifdef Q_WS_X11 - int x2 = p->x()+p->width(); -@@ -2044,7 +2060,7 @@ void TransparencyHandler::createShadowWi - #endif - } - --void TransparencyHandler::removeShadowWindows(const QPopupMenu* p) -+void TransparencyHandler::removeShadowWindows(const QWidget* p) - { - #ifdef Q_WS_X11 - ShadowMap::iterator it = shadowMap().find(p); -@@ -2070,7 +2086,7 @@ bool TransparencyHandler::eventFilter( Q - // Copyright (C) 2000 Daniel M. Duley - - // Added 'fake' menu shadows <04-Jul-2002> -- Karol -- QPopupMenu* p = (QPopupMenu*)object; -+ QWidget* p = (QWidget*)object; - QEvent::Type et = event->type(); - - if (et == QEvent::Show) -@@ -2109,13 +2125,23 @@ bool TransparencyHandler::eventFilter( Q - // * shadows after duplicate show events. - // * TODO : determine real cause for duplicate events - // * till 20021005 -- if (dropShadow && p->width() > 16 && p->height() > 16 && !shadowMap().contains( p )) -+ if ((dropShadow || useDropShadow(p)) -+ && p->width() > 16 && p->height() > 16 && !shadowMap().contains( p )) - createShadowWindows(p); - } -+ else if (et == QEvent::Resize && p->isShown() && p->isTopLevel()) -+ { -+ // Handle drop shadow -+ if (dropShadow || useDropShadow(p)) -+ { -+ removeShadowWindows(p); -+ createShadowWindows(p); -+ } -+ } - else if (et == QEvent::Hide) - { - // Handle drop shadow -- if (dropShadow) -+ if (dropShadow || useDropShadow(p)) - removeShadowWindows(p); - - // Handle translucency -@@ -2140,7 +2166,7 @@ void TransparencyHandler::blendToColor(c - } - - --void TransparencyHandler::blendToPixmap(const QColorGroup &cg, const QPopupMenu* p) -+void TransparencyHandler::blendToPixmap(const QColorGroup &cg, const QWidget* p) - { - if (opacity < 0.0 || opacity > 1.0) - return; -@@ -2153,7 +2179,10 @@ void TransparencyHandler::blendToPixmap( - return; - - // Allow styles to define the blend pixmap - allows for some interesting effects. -- kstyle->renderMenuBlendPixmap( blendPix, cg, p ); -+ if (::qt_cast(p)) -+ kstyle->renderMenuBlendPixmap( blendPix, cg, ::qt_cast(p) ); -+ else -+ blendPix.fill(cg.button()); // Just tint as the default behavior - - QImage blendImg = blendPix.convertToImage(); - QImage backImg = pix.convertToImage(); -@@ -2166,13 +2195,17 @@ void TransparencyHandler::blendToPixmap( - // Here we go, use XRender in all its glory. - // NOTE: This is actually a bit slower than the above routines - // on non-accelerated displays. -- Karol. --void TransparencyHandler::XRenderBlendToPixmap(const QPopupMenu* p) -+void TransparencyHandler::XRenderBlendToPixmap(const QWidget* p) - { - KPixmap renderPix; - renderPix.resize( pix.width(), pix.height() ); - - // Allow styles to define the blend pixmap - allows for some interesting effects. -- kstyle->renderMenuBlendPixmap( renderPix, p->colorGroup(), p ); -+ if (::qt_cast(p)) -+ kstyle->renderMenuBlendPixmap( renderPix, p->colorGroup(), -+ ::qt_cast(p) ); -+ else -+ renderPix.fill(p->colorGroup().button()); // Just tint as the default behavior - - Display* dpy = qt_xdisplay(); - Pixmap alphaPixmap; diff --git a/opensuse/core/tdelibs/kimproxy-warning.diff b/opensuse/core/tdelibs/kimproxy-warning.diff deleted file mode 100644 index 0731ebf4b..000000000 --- a/opensuse/core/tdelibs/kimproxy-warning.diff +++ /dev/null @@ -1,13 +0,0 @@ -Index: interfaces/kimproxy/library/kimproxy.cpp -=================================================================== ---- interfaces/kimproxy/library/kimproxy.cpp.orig -+++ interfaces/kimproxy/library/kimproxy.cpp -@@ -204,7 +204,7 @@ KIMProxy::KIMProxy( DCOPClient* dc ) : D - - // FIXME: make this work when the sender object id is set to KIMIFace - if ( !connectDCOPSignal( 0, 0, method, method, false ) ) -- KMessageBox::information( 0, QString( "Couldn't connect DCOP signal.\nWon't receive any status notifications!" ) ); -+ kdWarning() << "Couldn't connect DCOP signal. Won't receive any status notifications!" << endl; - } - - KIMProxy::~KIMProxy( ) diff --git a/opensuse/core/tdelibs/kmimelist.diff b/opensuse/core/tdelibs/kmimelist.diff deleted file mode 100644 index 484523f25..000000000 --- a/opensuse/core/tdelibs/kmimelist.diff +++ /dev/null @@ -1,81 +0,0 @@ -Index: kded/Makefile.am -=================================================================== ---- kded/Makefile.am.orig -+++ kded/Makefile.am -@@ -36,12 +36,16 @@ kbuildsycoca_la_SOURCES = kbuildsycoca.c - kctimefactory.cpp \ - vfolder_menu.cpp - --bin_PROGRAMS = kdontchangethehostname kde-menu -+bin_PROGRAMS = kdontchangethehostname kde-menu kmimelist - - kdontchangethehostname_LDFLAGS = $(all_libraries) $(KDE_RPATH) - kdontchangethehostname_LDADD = $(LIB_KDECORE) - kdontchangethehostname_SOURCES = khostname.cpp - -+kmimelist_LDFLAGS = $(all_libraries) $(KDE_RPATH) -+kmimelist_LDADD = ../kio/libkio.la -+kmimelist_SOURCES = kmimelist.cpp -+ - kde_menu_LDFLAGS = $(all_libraries) $(KDE_RPATH) - kde_menu_LDADD = $(LIB_KIO) - kde_menu_SOURCES = kde-menu.cpp -Index: kded/kmimelist.cpp -=================================================================== ---- /dev/null -+++ kded/kmimelist.cpp -@@ -0,0 +1,54 @@ -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+ -+#include -+ -+#include -+ -+int main(int argc, char *argv[]) -+{ -+ KApplication k(argc,argv,"blurb",false); -+ -+ KMimeType::List mtl = KMimeType::allMimeTypes( ); -+ assert( mtl.count() ); -+ qDebug( "Found %d mime types.", mtl.count() ); -+ QValueListIterator it(mtl.begin()); -+ KServiceTypeProfile::OfferList ol; -+ -+ for (; it != mtl.end(); ++it) -+ { -+ { -+ // Application -+ printf( "APP:%s:", (*it)->name().latin1() ); -+ ol = KServiceTypeProfile::offers((*it)->name(), "Application"); -+ QValueListIterator it2(ol.begin()); -+ for (; it2 != ol.end(); ++it2) { -+ if ((*it2).allowAsDefault()) -+ printf( " %s", (*it2).service()->desktopEntryPath().ascii() ); -+ -+ } -+ printf( "\n" ); -+ } -+ -+ { -+ // Embedded -+ printf( "PART:%s:", (*it)->name().latin1() ); -+ ol = KServiceTypeProfile::offers((*it)->name(), "KParts/ReadOnlyPart"); -+ QValueListIterator it2(ol.begin()); -+ for (; it2 != ol.end(); ++it2) { -+ if ((*it2).allowAsDefault()) -+ printf( " %s", (*it2).service()->desktopEntryPath().ascii() ); -+ -+ } -+ printf( "\n" ); -+ } -+ } -+} -+ diff --git a/opensuse/core/tdelibs/kremoteencoding-utf8.diff b/opensuse/core/tdelibs/kremoteencoding-utf8.diff deleted file mode 100644 index 74600a0f4..000000000 --- a/opensuse/core/tdelibs/kremoteencoding-utf8.diff +++ /dev/null @@ -1,28 +0,0 @@ -Index: kio/kio/kremoteencoding.cpp -=================================================================== ---- kio/kio/kremoteencoding.cpp.orig -+++ kio/kio/kremoteencoding.cpp -@@ -53,7 +53,7 @@ QCString KRemoteEncoding::encode(const Q - QCString result = codec->fromUnicode(name); - if (codec->toUnicode(result) != name) - return name.latin1(); -- -+ - return result; - } - -@@ -80,11 +80,13 @@ void KRemoteEncoding::setEncoding(const - - if (name) - codec = QTextCodec::codecForName(name); -+ else -+ codec = QTextCodec::codecForMib( 106 ); // fallback to UTF-8 - - if (codec == 0L) - codec = QTextCodec::codecForMib(1); - -- kdDebug() << k_funcinfo << "setting encoding " << codec->name() -+ kdDebug() << k_funcinfo << "setting encoding " << codec->name() - << " for name=" << name << endl; - } - diff --git a/opensuse/core/tdelibs/ktip-icon-hack.diff b/opensuse/core/tdelibs/ktip-icon-hack.diff deleted file mode 100644 index 4812646d1..000000000 --- a/opensuse/core/tdelibs/ktip-icon-hack.diff +++ /dev/null @@ -1,56 +0,0 @@ -Index: kdeui/ktip.cpp -=================================================================== ---- kdeui/ktip.cpp.orig -+++ kdeui/ktip.cpp -@@ -367,24 +367,47 @@ void KTipDialog::showMultiTip(QWidget *p - mInstance->raise(); - } - -+static QString fixTip(QString tip) -+{ -+ QRegExp iconRegExp(""); -+ iconRegExp.setMinimal(true); -+ if (iconRegExp.search(tip)>-1) { -+ QString iconName = iconRegExp.cap(1); -+ if (!iconName.isEmpty()) -+ if (KGlobal::dirs()->findResource("icon", iconName).isEmpty()) -+ tip.replace("crystalsvg","hicolor"); -+ } -+ -+ return tip; -+} -+ - void KTipDialog::prevTip() - { - mDatabase->prevTip(); -- mTipText->setText(QString::fromLatin1( -+ QString currentTip = QString::fromLatin1( - "%3") - .arg(mTextColor.name()) - .arg(mBaseColor.name()) -- .arg(i18n(mDatabase->tip().utf8()))); -+ .arg(i18n(mDatabase->tip().utf8())); -+ -+ -+ currentTip = fixTip(currentTip); -+ mTipText->setText(currentTip); - mTipText->setContentsPos(0, 0); - } - - void KTipDialog::nextTip() - { - mDatabase->nextTip(); -- mTipText->setText(QString::fromLatin1("%3") -+ QString currentTip = QString::fromLatin1( -+ "%3") - .arg(mTextColor.name()) - .arg(mBaseColor.name()) -- .arg(i18n(mDatabase->tip().utf8()))); -+ .arg(i18n(mDatabase->tip().utf8())); -+ -+ -+ currentTip = fixTip(currentTip); -+ mTipText->setText(currentTip); - mTipText->setContentsPos(0, 0); - } - diff --git a/opensuse/core/tdelibs/kwalletd-try-open.diff b/opensuse/core/tdelibs/kwalletd-try-open.diff deleted file mode 100644 index 547f8192d..000000000 --- a/opensuse/core/tdelibs/kwalletd-try-open.diff +++ /dev/null @@ -1,81 +0,0 @@ -Index: kio/misc/kwalletd/kwalletd.cpp -=================================================================== ---- kio/misc/kwalletd/kwalletd.cpp.orig -+++ kio/misc/kwalletd/kwalletd.cpp -@@ -355,6 +355,44 @@ int KWalletD::doTransactionOpen(const QC - return rc; - } - -+int KWalletD::tryOpen(const QString& wallet, const QCString& password) -+{ -+ if (isOpen(wallet)) -+ return 0; -+ -+ if (_tryOpenBlocked.isActive()) { -+ kdDebug() << "tryOpen is active.." << endl; -+ return -1; -+ } -+ -+ if (!KWallet::Backend::exists(wallet)) -+ return -2; -+ -+ KWallet::Backend *b = new KWallet::Backend(wallet, false /*isPath*/); -+ int rc = b->open(QByteArray().duplicate(password, strlen(password))); -+ if (rc == 0) { -+ _wallets.insert(rc = generateHandle(), b); -+ _passwords[wallet] = password; -+ b->ref(); -+ _tryOpenBlocked.stop(); -+ QByteArray data; -+ QDataStream ds(data, IO_WriteOnly); -+ ds << wallet; -+ emitDCOPSignal("walletOpened(QString)", data); -+ } -+ else { -+ delete b; -+ // make sure that we're not bombed with a dictionary attack -+ _tryOpenBlocked.start (30 * 1000, true /*single shot*/); -+ if (++_failed > 5) { -+ _failed = 0; -+ QTimer::singleShot(0, this, SLOT(notifyFailures())); -+ } -+ -+ rc = -1; -+ } -+ return rc; -+} - - int KWalletD::internalOpen(const QCString& appid, const QString& wallet, bool isPath, WId w, bool modal) { - int rc = -1; -Index: kio/misc/kwalletd/kwalletd.h -=================================================================== ---- kio/misc/kwalletd/kwalletd.h.orig -+++ kio/misc/kwalletd/kwalletd.h -@@ -26,6 +26,7 @@ - #include - #include - #include -+#include - #include - #include "kwalletbackend.h" - -@@ -51,8 +52,10 @@ class KWalletD : public KDEDModule { - - // Open and unlock the wallet - virtual int open(const QString& wallet, uint wId); -- -+ // Open and unlock the wallet -+ virtual int tryOpen(const QString& wallet, const QCString& passwd); - // Open and unlock the wallet with this path -+ - virtual int openPath(const QString& path, uint wId); - - // Asynchronous open - must give the object to return the handle -@@ -186,6 +189,7 @@ class KWalletD : public KDEDModule { - int _idleTime; - QMap _implicitAllowMap, _implicitDenyMap; - KTimeout *_timeouts; -+ QTimer _tryOpenBlocked; - - QPtrList _transactions; - QGuardedPtr< QWidget > activeDialog; diff --git a/opensuse/core/tdelibs/light_v_2_scrollbar_patch.patch b/opensuse/core/tdelibs/light_v_2_scrollbar_patch.patch deleted file mode 100644 index e4ad1dd81..000000000 --- a/opensuse/core/tdelibs/light_v_2_scrollbar_patch.patch +++ /dev/null @@ -1,34 +0,0 @@ -diff -ur kdelibs-3.5.10.orig/kstyles/light/lightstyle-v2.cpp kdelibs-3.5.10/kstyles/light/lightstyle-v2.cpp ---- kdelibs-3.5.10.orig/kstyles/light/lightstyle-v2.cpp 2006-03-17 13:19:10.000000000 +0300 -+++ kdelibs-3.5.10/kstyles/light/lightstyle-v2.cpp 2011-05-07 23:30:18.000000000 +0400 -@@ -501,12 +501,14 @@ - p->drawLine(r.topLeft(), r.topRight()); - p->setPen(cg.background()); - p->drawLine(r.left(), r.top() + 1, r.right(), r.top() + 1); -- fr.addCoords(0, 2, 0, 0); -+ p->drawLine(r.left(), r.bottom(), r.right(), r.bottom()); -+ fr.addCoords(0, 2, 0, -1); - } else { - p->drawLine(r.topLeft(), r.bottomLeft()); - p->setPen(cg.background()); - p->drawLine(r.left() + 1, r.top(), r.left() + 1, r.bottom()); -- fr.addCoords(2, 0, 0, 0); -+ p->drawLine(r.right(), r.top(), r.right(), r.bottom()); -+ fr.addCoords(2, 0, -1, 0); - } - - p->fillRect(fr, cg.brush((flags & Style_Down) ? -@@ -523,11 +525,13 @@ - if (flags & Style_Horizontal) { - p->drawLine(r.topLeft(), r.topRight()); - p->setPen(cg.background()); -+ p->drawLine(r.left(), r.bottom(), r.right(), r.bottom()); - p->drawLine(r.left(), r.top() + 1, r.right(), r.top() + 1); - fr.addCoords(0, 2, 0, -1); - } else { - p->drawLine(r.topLeft(), r.bottomLeft()); - p->setPen(cg.background()); -+ p->drawLine(r.right(), r.top(), r.right(), r.bottom()); - p->drawLine(r.left() + 1, r.top(), r.left() + 1, r.bottom()); - fr.addCoords(2, 0, -1, 0); - } diff --git a/opensuse/core/tdelibs/limit-max-image-size.diff b/opensuse/core/tdelibs/limit-max-image-size.diff deleted file mode 100644 index 6a01bf063..000000000 --- a/opensuse/core/tdelibs/limit-max-image-size.diff +++ /dev/null @@ -1,28 +0,0 @@ -Index: kapplication.cpp -=================================================================== -RCS file: /home/kde/kdelibs/kdecore/kapplication.cpp,v -retrieving revision 1.670 -diff -u -p -r1.670 kapplication.cpp ---- kdecore/kapplication.cpp 22 Jul 2004 16:50:04 -0000 1.670 -+++ kdecore/kapplication.cpp 16 Aug 2004 20:31:02 -0000 -@@ -43,6 +43,7 @@ - #include - #include - #include -+#include - #ifndef QT_NO_SQL - #include - #endif -@@ -1975,6 +1976,12 @@ void KApplication::propagateSettings(Set - KConfigBase* config = KGlobal::config(); - KConfigGroupSaver saver( config, "KDE" ); - -+#ifdef QT_HAVE_MAX_IMAGE_SIZE -+ QSize maxImageSize(4096, 4096); -+ maxImageSize = config->readSizeEntry("MaxImageSize", &maxImageSize); -+ QImage::setMaxImageSize(maxImageSize); -+#endif -+ - int num = config->readNumEntry("CursorBlinkRate", QApplication::cursorFlashTime()); - if ((num != 0) && (num < 200)) - num = 200; diff --git a/opensuse/core/tdelibs/lpoptions-cups-1.2.diff b/opensuse/core/tdelibs/lpoptions-cups-1.2.diff deleted file mode 100644 index aa3f5d5b6..000000000 --- a/opensuse/core/tdelibs/lpoptions-cups-1.2.diff +++ /dev/null @@ -1,28 +0,0 @@ -Index: kdeprint/kmvirtualmanager.cpp -=================================================================== ---- kdeprint/kmvirtualmanager.cpp.orig -+++ kdeprint/kmvirtualmanager.cpp -@@ -179,7 +179,7 @@ void KMVirtualManager::setAsDefault(KMPr - - void KMVirtualManager::refresh() - { -- QFileInfo fi(QDir::homeDirPath() + QFile::decodeName("/.lpoptions")); -+ QFileInfo fi(QDir::homeDirPath() + QFile::decodeName("/.cups/lpoptions")); - QFileInfo fi2(QFile::decodeName("/etc/cups/lpoptions")); - - // if root, then only use global file: trick -> use twice the same file -@@ -301,7 +301,13 @@ void KMVirtualManager::triggerSave() - filename = QFile::decodeName("/etc/cups/lpoptions"); - } - else -- filename = QDir::homeDirPath() + QFile::decodeName("/.lpoptions"); -+ { -+ QDir cupsDir(QDir::home().absPath()+"/.cups"); -+ if (!cupsDir.exists()) -+ cupsDir.mkdir(QDir::home().absPath()+"/.cups"); -+ filename = QDir::homeDirPath() + QFile::decodeName("/.cups/lpoptions"); -+ } -+ - if (!filename.isEmpty()) - { - saveFile(filename); diff --git a/opensuse/core/tdelibs/mimetype-changes.diff b/opensuse/core/tdelibs/mimetype-changes.diff deleted file mode 100644 index ea47629b8..000000000 --- a/opensuse/core/tdelibs/mimetype-changes.diff +++ /dev/null @@ -1,36 +0,0 @@ -Index: mimetypes/application/x-rpm.desktop -=================================================================== ---- mimetypes/application/x-rpm.desktop.orig -+++ mimetypes/application/x-rpm.desktop -@@ -1,4 +1,5 @@ - [Desktop Entry] -+X-KDE-AutoEmbed=true - Type=MimeType - MimeType=application/x-rpm - Icon=rpm -Index: mimetypes/application/x-ogg.desktop -=================================================================== ---- mimetypes/application/x-ogg.desktop.orig -+++ mimetypes/application/x-ogg.desktop -@@ -4,7 +4,7 @@ - # application/ogg "inherits" from it, so that apps associated with x-ogg can open ogg files. - Type=MimeType - MimeType=application/x-ogg --Icon=multimedia -+Icon=sound - Comment=Ogg Multimedia - Comment[ar]=وسائط Ogg متعددة - Comment[az]=Ogg Multimediya -Index: mimetypes/application/ogg.desktop -=================================================================== ---- mimetypes/application/ogg.desktop.orig -+++ mimetypes/application/ogg.desktop -@@ -1,7 +1,7 @@ - [Desktop Entry] - Type=MimeType - MimeType=application/ogg --Icon=multimedia -+Icon=sound - Patterns=*.ogg;*.OGG; - # Previous name of this mimetype - X-KDE-IsAlso=application/x-ogg diff --git a/opensuse/core/tdelibs/mozilla-sliders.patch b/opensuse/core/tdelibs/mozilla-sliders.patch deleted file mode 100644 index 004b0fd36..000000000 --- a/opensuse/core/tdelibs/mozilla-sliders.patch +++ /dev/null @@ -1,19 +0,0 @@ -Index: kdefx/kstyle.cpp -=================================================================== ---- kdefx/kstyle.cpp.orig -+++ kdefx/kstyle.cpp -@@ -2210,6 +2210,14 @@ void TransparencyHandler::XRenderBlendTo - void KStyle::virtual_hook( int, void* ) - { /*BASE::virtual_hook( id, data );*/ } - -+// HACK for gtk-qt-engine -+ -+KDE_EXPORT extern "C" -+void kde_kstyle_set_scrollbar_type_windows( void* style ) -+{ -+ ((KStyle*)style)->setScrollBarType( KStyle::WindowsStyleScrollBar ); -+} -+ - // vim: set noet ts=4 sw=4: - // kate: indent-width 4; replace-tabs off; tab-width 4; space-indent off; - diff --git a/opensuse/core/tdelibs/networkstatus.diff b/opensuse/core/tdelibs/networkstatus.diff deleted file mode 100644 index d7b4e8c89..000000000 --- a/opensuse/core/tdelibs/networkstatus.diff +++ /dev/null @@ -1,6006 +0,0 @@ -Index: networkstatus/connectionmanager.cpp -=================================================================== ---- /dev/null -+++ networkstatus/connectionmanager.cpp -@@ -0,0 +1,171 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#include -+#include -+#include -+ -+#include "connectionmanager.h" -+#include "connectionmanager_p.h" -+ -+// Connection manager itself -+ConnectionManager::ConnectionManager( QObject * parent, const char * name ) : DCOPObject( "ConnectionManager" ), QObject( parent, name ), d( new ConnectionManagerPrivate( this ) ) -+{ -+ d->service = new NetworkStatusIface_stub( kapp->dcopClient(), "kded", "networkstatus" ); -+ -+ connectDCOPSignal( "kded", "networkstatus", "statusChange(int)", "slotStatusChanged(int)", false ); -+ -+ initialise(); -+} -+ -+ConnectionManager::~ConnectionManager() -+{ -+ delete d; -+} -+ -+ConnectionManager *ConnectionManager::s_self = 0L; -+ -+ConnectionManager *ConnectionManager::self() -+{ -+ static KStaticDeleter deleter; -+ if(!s_self) -+ deleter.setObject( s_self, new ConnectionManager( 0, "connection_manager" ) ); -+ return s_self; -+} -+ -+void ConnectionManager::initialise() -+{ -+ // determine initial state and set the state object accordingly. -+ d->status = ( NetworkStatus::Status )d->service->status(); -+} -+ -+NetworkStatus::Status ConnectionManager::status() -+{ -+ return d->status; -+} -+ -+void ConnectionManager::slotStatusChanged( int status ) -+{ -+ d->status = ( NetworkStatus::Status )status; -+ switch ( status ) { -+ case NetworkStatus::NoNetworks: -+ break; -+ case NetworkStatus::Unreachable: -+ break; -+ case NetworkStatus::OfflineDisconnected: -+ case NetworkStatus::OfflineFailed: -+ case NetworkStatus::ShuttingDown: -+ case NetworkStatus::Offline: -+ case NetworkStatus::Establishing: -+ if ( d->disconnectPolicy == Managed ) { -+ emit d->disconnected(); -+ } else if ( d->disconnectPolicy == OnNextChange ) { -+ setDisconnectPolicy( Manual ); -+ emit d->disconnected(); -+ } -+ break; -+ case NetworkStatus::Online: -+ if ( d->disconnectPolicy == Managed ) { -+ emit d->connected(); -+ } else if ( d->disconnectPolicy == OnNextChange ) { -+ setConnectPolicy( Manual ); -+ emit d->connected(); -+ } -+ break; -+ default: -+ kdDebug() << k_funcinfo << "Unrecognised status code!" << endl; -+ } -+ emit statusChanged( d->status ); -+} -+ -+ConnectionManager::ConnectionPolicy ConnectionManager::connectPolicy() const -+{ -+ return d->connectPolicy; -+} -+ -+void ConnectionManager::setConnectPolicy( ConnectionManager::ConnectionPolicy policy ) -+{ -+ d->connectPolicy = policy; -+} -+ -+ConnectionManager::ConnectionPolicy ConnectionManager::disconnectPolicy() const -+{ -+ return d->disconnectPolicy; -+} -+ -+void ConnectionManager::setDisconnectPolicy( ConnectionManager::ConnectionPolicy policy ) -+{ -+ d->disconnectPolicy = policy; -+} -+ -+void ConnectionManager::setManualConnectionPolicies() -+{ -+ d->connectPolicy = ConnectionManager::Manual; -+ d->disconnectPolicy = ConnectionManager::Manual; -+} -+ -+void ConnectionManager::setManagedConnectionPolicies() -+{ -+ d->connectPolicy = ConnectionManager::Managed; -+ d->disconnectPolicy = ConnectionManager::Managed; -+} -+ -+void ConnectionManager::registerConnectSlot( QObject * receiver, const char * member ) -+{ -+ d->connectReceiver = receiver; -+ d->connectSlot = member; -+ connect( d, SIGNAL( connected() ), receiver, member ); -+} -+ -+void ConnectionManager::forgetConnectSlot() -+{ -+ disconnect( d, SIGNAL( connected() ), d->connectReceiver, d->connectSlot ); -+ d->connectReceiver = 0; -+ d->connectSlot = 0; -+} -+ -+bool ConnectionManager::isConnectSlotRegistered() const -+{ -+ return ( d->connectSlot != 0 ); -+} -+ -+void ConnectionManager::registerDisconnectSlot( QObject * receiver, const char * member ) -+{ -+ d->disconnectReceiver = receiver; -+ d->disconnectSlot = member; -+ connect( d, SIGNAL( disconnected() ), receiver, member ); -+} -+ -+void ConnectionManager::forgetDisconnectSlot() -+{ -+ disconnect( d, SIGNAL( disconnected() ), d->disconnectReceiver, d->disconnectSlot ); -+ d->disconnectReceiver = 0; -+ d->disconnectSlot = 0; -+} -+ -+bool ConnectionManager::isDisconnectSlotRegistered() const -+{ -+ return ( d->disconnectSlot != 0 ); -+} -+ -+#include "connectionmanager.moc" -+ -Index: networkstatus/connectionmanager.h -=================================================================== ---- /dev/null -+++ networkstatus/connectionmanager.h -@@ -0,0 +1,167 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef KDE_CONNECTION_MANAGER_H -+#define KDE_CONNECTION_MANAGER_H -+ -+#include -+#include -+ -+#include -+ -+class ConnectionManagerPrivate; -+ -+class KDE_EXPORT ConnectionManager : public QObject, virtual public DCOPObject -+{ -+Q_OBJECT -+K_DCOP -+k_dcop: -+ void slotStatusChanged( int status ); -+public: -+ /** -+ * This defines application policy in response to networking connect/disconnect events -+ * Manual - the app only disconnects when the user does so -+ * OnNextChange - the app should connect or disconnect the next time the network changes state, thereafter -+ * Manual -+ * Managed - the app should disconnect when the ConnectionManager thinks the system is -+ * offline -+ */ -+ enum ConnectionPolicy { Manual, OnNextChange, Managed }; -+ /** -+ * Set a policy to manage the application's connect behaviour -+ */ -+ void setConnectPolicy( ConnectionPolicy ); -+ /** -+ * Retrieve a policy managing the application's connect behaviour -+ */ -+ ConnectionPolicy connectPolicy() const; -+ -+ /** -+ * Set a policy to manage the application's disconnect behaviour -+ */ -+ void setDisconnectPolicy( ConnectionPolicy ); -+ -+ /** -+ * Retrieve a policy managing the application's disconnect behaviour -+ */ -+ ConnectionPolicy disconnectPolicy() const; -+ -+ /* -+ * We'll get logic of the form -+ * onStatusChange() { -+ * if ( ConnectionManager::self()->policy( ConnectionManager::ConnectBehaviour ) == ConnectionManager::OnNextChange || -+ * ConnectionManager::self()->policy( ConnectionManager::ConnectBehaviour ) == ConnectionManager::Managed ) -+ * { -+ * // do connect -+ * -+ * // reset the policy -+ * if ( ConnectionManager::self()->policy( ConnectionManager::ConnectBehaviour ) == ConnectionManager::OnNextChange ) -+ * ConnectionManager::self()->setPolicy( ConnectionManager::ConnectionManager, -+ * ConnectionManager::Manual ); -+ * } -+ * -+ * Do we just use the CM for policy storage, or do we try to factor the logic to implement the -+ * policy into the CM too? -+ * -+ * could signal doConnect(), then reset the policy -+ * or could register a connect slot -+ * registerConnectMethod( QObject * receiver, const char * member ); -+ * unregisterConnectMethod(); -+ * etc. -+ * -+ * The problem with automatically controlled behaviour, where policy may change as a result of a -+ * connect, is that if it is also manually altered, the CM needs to be updated. But the CM needs to -+ * be updated in any case. -+ * CM need -+ */ -+ /** -+ * Lazy-method to set Manual on both policies -+ */ -+ void setManualConnectionPolicies(); -+ /** -+ * Lazy-method to set Managed on both policies -+ */ -+ void setManagedConnectionPolicies(); -+ -+ /** -+ * Record a slot to call on a given receiving QObject when -+ * 1) the network connection is online, -+ * 2) the policy mandates that the app connect -+ * -+ * Only one slot may be registered at any one time. If a second slot is -+ * registered, the first slot is forgotten -+ * @param receiver the QObject where the slot is located -+ * @param member the slot to call. Set up member using the SLOT() macro. -+ */ -+ void registerConnectSlot( QObject * receiver, const char * member ); -+ -+ /** -+ * Forget any connect slot previously registered -+ */ -+ void forgetConnectSlot(); -+ -+ /** -+ * Has any slot been registered to be called on connect? -+ */ -+ bool isConnectSlotRegistered() const; -+ -+ /** -+ * Record a slot to call on a given receiving QObject when -+ * 1) the network connection goes offline (in any way ), -+ * 2) the policy mandates that the app disconnect -+ * -+ * Only one slot may be registered at any one time. If a second slot is -+ * registered, the first slot is forgotten -+ * @param receiver the QObject where the slot is located -+ * @param member the slot to call. Set up member using the SLOT() macro. -+ */ -+ void registerDisconnectSlot( QObject * receiver, const char * member ); -+ -+ /** -+ * Forget any disconnect slot previously registered -+ */ -+ void forgetDisconnectSlot(); -+ -+ /** -+ * Has any slot been registered to be called on disconnect? -+ */ -+ bool isDisconnectSlotRegistered() const; -+ -+ /// existing API -+ -+ static ConnectionManager* self(); -+ virtual ~ConnectionManager(); -+ NetworkStatus::Status status(); -+signals: -+ // signal that the network for a hostname is up/down -+ void statusChanged( NetworkStatus::Status status ); -+private: -+ // sets up internal state -+ void initialise(); -+ // reread the desktop status from the daemon and update internal state -+ ConnectionManager( QObject *parent, const char * name ); -+ ConnectionManagerPrivate * d; -+ static ConnectionManager * s_self; -+}; -+ -+#endif -+ -Index: networkstatus/connectionmanager_p.cpp -=================================================================== ---- /dev/null -+++ networkstatus/connectionmanager_p.cpp -@@ -0,0 +1,13 @@ -+#include "connectionmanager_p.h" -+ -+ConnectionManagerPrivate::ConnectionManagerPrivate(QObject * parent, const char * name ) : QObject( parent, name ), service( 0 ), connectPolicy( ConnectionManager::Managed ), -+ disconnectPolicy( ConnectionManager::Managed ), connectReceiver( 0 ), connectSlot( 0 ), -+ disconnectReceiver( 0 ), disconnectSlot( 0 ) -+{ -+} -+ -+ConnectionManagerPrivate::~ConnectionManagerPrivate() -+{ -+} -+ -+#include "connectionmanager_p.moc" -Index: networkstatus/connectionmanager_p.h -=================================================================== ---- /dev/null -+++ networkstatus/connectionmanager_p.h -@@ -0,0 +1,55 @@ -+/* This file is part of the KDE project -+ Copyright (C) 2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef CONNECTIONMANAGERPRIVATE_H -+#define CONNECTIONMANAGERPRIVATE_H -+ -+#include -+ -+#include "connectionmanager.h" -+#include "networkstatuscommon.h" -+#include "networkstatusiface_stub.h" -+ -+ -+// ConnectionManager's private parts -+class ConnectionManagerPrivate : public QObject -+{ -+Q_OBJECT -+ friend class ConnectionManager; -+public: -+ ConnectionManagerPrivate( QObject * parent = 0, const char * name = 0); -+ ~ConnectionManagerPrivate(); -+ // this holds the currently active state -+ NetworkStatus::Status status; -+ NetworkStatusIface_stub * service; -+ ConnectionManager::ConnectionPolicy connectPolicy; -+ ConnectionManager::ConnectionPolicy disconnectPolicy; -+ QObject * connectReceiver; -+ const char * connectSlot; -+ QObject * disconnectReceiver; -+ const char * disconnectSlot; -+signals: -+ void connected(); -+ void disconnected(); -+}; -+ -+#endif -Index: networkstatus/Makefile.am -=================================================================== ---- /dev/null -+++ networkstatus/Makefile.am -@@ -0,0 +1,45 @@ -+#SUBDIRS = networkstatustray -+ -+METASOURCES = AUTO -+ -+INCLUDES = -I$(top_srcdir)/kded -I$(top_srcdir) $(all_includes) -+ -+kde_module_LTLIBRARIES = kded_networkstatus.la -+ -+kded_networkstatus_la_SOURCES = networkstatus.cpp networkstatus.skel \ -+ network.cpp -+kded_networkstatus_la_LIBADD = $(LIB_KDECORE) $(LIB_KIO) ./libnetworkstatus.la -+kded_networkstatus_la_LDFLAGS = $(all_libraries) -module -avoid-version -+ -+servicesdir = $(kde_servicesdir)/kded -+ -+services_DATA = networkstatus.desktop -+ -+lib_LTLIBRARIES = libnetworkstatus.la libconnectionmanager.la -+ -+libnetworkstatus_la_LIBADD = $(LIB_KDECORE) -+libnetworkstatus_la_LDFLAGS = $(all_libraries) -+libnetworkstatus_la_SOURCES = networkstatuscommon.cpp -+ -+libconnectionmanager_la_LIBADD = $(LIB_KDECORE) libnetworkstatus.la -+libconnectionmanager_la_LDFLAGS = $(all_libraries) -+libconnectionmanager_la_SOURCES = connectionmanager.cpp connectionmanager_p.cpp networkstatusindicator.cpp connectionmanager.skel networkstatusiface.stub -+ -+noinst_PROGRAMS = networkstatustestservice networkstatustestclient managedconnectiontestclient -+ -+networkstatustestservice_LDFLAGS = $(all_libraries) -+networkstatustestservice_LDADD = $(LIB_KFILE) libnetworkstatus.la -+networkstatustestservice_SOURCES = testservice.cpp testserviceview.ui networkstatusiface.stub -+ -+networkstatustestclient_LDFLAGS = $(all_libraries) -+networkstatustestclient_LDADD = $(LIB_KFILE) libnetworkstatus.la libconnectionmanager.la -+networkstatustestclient_SOURCES = testclient.cpp testclientview.ui -+ -+managedconnectiontestclient_LDFLAGS = $(all_libraries) -+managedconnectiontestclient_LDADD = $(LIB_KFILE) libnetworkstatus.la libconnectionmanager.la -+managedconnectiontestclient_SOURCES = testclient2.cpp testclientview.ui -+ -+noinst_HEADERS = network.h testservice.h testclient.h -+ -+include_HEADERS = networkstatuscommon.h connectionmanager.h networkstatusindicator.h \ -+ networkstatusiface.h -Index: networkstatus/network.cpp -=================================================================== ---- /dev/null -+++ networkstatus/network.cpp -@@ -0,0 +1,62 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#include -+ -+#include "network.h" -+ -+Network::Network( NetworkStatus::Properties properties ) -+ : m_name( properties.name ), m_status( properties.status ), m_service( properties.service ) -+{ -+} -+ -+void Network::setStatus( NetworkStatus::Status status ) -+{ -+ m_status = status; -+} -+ -+NetworkStatus::Status Network::status() -+{ -+ return m_status; -+} -+ -+void Network::setName( const QString& name ) -+{ -+ m_name = name; -+} -+ -+QString Network::name() -+{ -+ return m_name; -+} -+ -+QString Network::service() -+{ -+ return m_service; -+} -+ -+void Network::setService( const QString& service ) -+{ -+ m_service = service; -+} -+ -+// vim: sw=4 ts=4 -Index: networkstatus/network.h -=================================================================== ---- /dev/null -+++ networkstatus/network.h -@@ -0,0 +1,60 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef NETWORKSTATUS_NETWORK_H -+#define NETWORKSTATUS_NETWORK_H -+ -+#include "networkstatuscommon.h" -+ -+class Network -+{ -+public: -+ Network( const QString name ); -+ Network( NetworkStatus::Properties properties ); -+ /** -+ * Update the status of this network -+ */ -+ void setStatus( NetworkStatus::Status status ); -+ /** -+ * The connection status of this network -+ */ -+ NetworkStatus::Status status(); -+ /** -+ * The name of this network -+ */ -+ QString name(); -+ void setName( const QString& name ); -+ /** -+ * Returns the service owning this network -+ */ -+ QString service(); -+ void setService( const QString& service ); -+ -+private: -+ Network( const Network & ); -+ QString m_name; -+ NetworkStatus::Status m_status; -+ QString m_service; -+}; -+ -+#endif -+// vim: sw=4 ts=4 -Index: networkstatus/networkstatuscommon.cpp -=================================================================== ---- /dev/null -+++ networkstatus/networkstatuscommon.cpp -@@ -0,0 +1,76 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#include "networkstatuscommon.h" -+ -+QDataStream & operator<< ( QDataStream & s, const NetworkStatus::Properties p ) -+{ -+ s << p.name; -+ s << (int)p.status; -+ s << p.service; -+ return s; -+} -+ -+QDataStream & operator>> ( QDataStream & s, NetworkStatus::Properties &p ) -+{ -+ int status; -+ s >> p.name; -+ s >> status; -+ p.status = (NetworkStatus::Status)status; -+ s >> p.service; -+ return s; -+} -+ -+namespace NetworkStatus -+{ -+ QString toString( NetworkStatus::Status st ) -+ { -+ QString str; -+ switch ( st ) { -+ case NetworkStatus::NoNetworks: -+ str = "NoNetworks"; -+ break; -+ case NetworkStatus::Unreachable: -+ str = "Unreachable"; -+ break; -+ case NetworkStatus::OfflineDisconnected: -+ str = "OfflineDisconnected"; -+ break; -+ case NetworkStatus::OfflineFailed: -+ str = "OfflineFailed"; -+ break; -+ case NetworkStatus::ShuttingDown: -+ str = "ShuttingDown"; -+ break; -+ case NetworkStatus::Offline: -+ str = "Offline"; -+ break; -+ case NetworkStatus::Establishing: -+ str = "Establishing"; -+ break; -+ case NetworkStatus::Online: -+ str = "Online"; -+ break; -+ } -+ return str; -+ } -+} // namespace NetworkStatus -Index: networkstatus/networkstatuscommon.h -=================================================================== ---- /dev/null -+++ networkstatus/networkstatuscommon.h -@@ -0,0 +1,52 @@ -+/* This file is part of kdepim -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef NETWORKSTATUS_COMMON_H -+#define NETWORKSTATUS_COMMON_H -+ -+#include -+ -+namespace NetworkStatus -+{ -+ enum Status { NoNetworks = 1, Unreachable, OfflineDisconnected, OfflineFailed, ShuttingDown, Offline, Establishing, Online }; -+ enum RequestResult { RequestAccepted = 1, Connected, UserRefused, Unavailable }; -+ enum UnusedDemandPolicy { All, User, None, Permanent }; -+ -+ // BINARY COMPATIBILITY ALERT BEGIN !!!! -+ struct Properties -+ { -+ QString name; -+ Status status; -+ UnusedDemandPolicy unused1; -+ QCString service; -+ bool unused3; -+ QStringList unused4; -+ }; -+ // BINARY COMPATIBILITY ALERT END !!!! -+ -+ QString toString( Status st ); -+} -+ -+QDataStream & operator>> ( QDataStream & s, NetworkStatus::Properties &p ); -+QDataStream & operator<< ( QDataStream & s, const NetworkStatus::Properties p ); -+ -+#endif -Index: networkstatus/networkstatus.cpp -=================================================================== ---- /dev/null -+++ networkstatus/networkstatus.cpp -@@ -0,0 +1,163 @@ -+/* This file is part of kdepim -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#include "networkstatus.h" -+ -+#include -+ -+#include -+#include -+#include -+ -+#include "network.h" -+#include -+ -+extern "C" { -+ KDE_EXPORT KDEDModule* create_networkstatus( const QCString& obj ) -+ { -+ return new NetworkStatusModule( obj ); -+ } -+} -+ -+// INTERNALLY USED STRUCTS AND TYPEDEFS -+ -+typedef QMap< QString, Network * > NetworkMap; -+ -+class NetworkStatusModule::Private -+{ -+public: -+ NetworkMap networks; -+ NetworkStatus::Status status; -+}; -+ -+// CTORS/DTORS -+ -+NetworkStatusModule::NetworkStatusModule( const QCString & obj ) : KDEDModule( obj ), d( new Private ) -+{ -+ d->status = NetworkStatus::NoNetworks; -+ connect( kapp->dcopClient(), SIGNAL( applicationRemoved( const QCString& ) ) , this, SLOT( unregisteredFromDCOP( const QCString& ) ) ); -+ // connect( kapp->dcopClient(), SIGNAL( applicationRegistered( const QCString& ) ) , this, SLOT( registeredToDCOP( const QCString& ) ) ); -+} -+ -+NetworkStatusModule::~NetworkStatusModule() -+{ -+ NetworkMap::ConstIterator it; -+ const NetworkMap::ConstIterator end = d->networks.end(); -+ -+ for ( it = d->networks.begin(); it != end; ++it ) { -+ delete ( *it ); -+ } -+ -+ delete d; -+} -+ -+// CLIENT INTERFACE -+ -+QStringList NetworkStatusModule::networks() -+{ -+ kdDebug() << k_funcinfo << " contains " << d->networks.count() << " networks" << endl; -+ return d->networks.keys(); -+} -+ -+int NetworkStatusModule::status() -+{ -+ kdDebug() << k_funcinfo << " status: " << (int)d->status << endl; -+ return (int)d->status; -+} -+ -+//protected: -+ -+void NetworkStatusModule::updateStatus() -+{ -+ NetworkStatus::Status bestStatus = NetworkStatus::NoNetworks; -+ const NetworkStatus::Status oldStatus = d->status; -+ -+ NetworkMap::ConstIterator it; -+ const NetworkMap::ConstIterator end = d->networks.end(); -+ for ( it = d->networks.begin(); it != end; ++it ) { -+ if ( ( *it )->status() > bestStatus ) -+ bestStatus = ( *it )->status(); -+ } -+ d->status = bestStatus; -+ -+ if ( oldStatus != d->status ) { -+ statusChange( (int)d->status ); -+ } -+} -+ -+void NetworkStatusModule::unregisteredFromDCOP( const QCString & appId ) -+{ -+ // unregister and delete any networks owned by a service that has just unregistered -+ NetworkMap::Iterator it = d->networks.begin(); -+ const NetworkMap::Iterator end = d->networks.end(); -+ while (it != d->networks.end()) -+ { -+ if ( ( *it )->service() == QString( appId ) ) -+ { -+ NetworkMap::Iterator toRemove = it++; -+ delete *toRemove; -+ d->networks.remove( toRemove ); -+ updateStatus(); -+ continue; -+ } -+ ++it; -+ } -+} -+ -+// SERVICE INTERFACE // -+void NetworkStatusModule::setNetworkStatus( const QString & networkName, int st ) -+{ -+ kdDebug() << k_funcinfo << networkName << ", " << st << endl; -+ NetworkStatus::Status changedStatus = (NetworkStatus::Status)st; -+ Network * net = 0; -+ NetworkMap::Iterator it = d->networks.find( networkName ); -+ if ( it != d->networks.end() ) { -+ net = (*it); -+ net->setStatus( changedStatus ); -+ updateStatus(); -+ } -+ else -+ kdDebug() << " No network named '" << networkName << "' found." << endl; -+} -+ -+void NetworkStatusModule::registerNetwork( const NetworkStatus::Properties properties ) -+{ -+ kdDebug() << k_funcinfo << properties.name << ", with status " << properties.status << endl; -+ -+ d->networks.insert( properties.name, new Network( properties ) ); -+ updateStatus(); -+} -+ -+void NetworkStatusModule::unregisterNetwork( const QString & networkName ) -+{ -+ kdDebug() << k_funcinfo << networkName << endl; -+ -+ NetworkMap::Iterator it = d->networks.find( networkName ); -+ if ( it != d->networks.end() ) { -+ delete *it; -+ d->networks.remove( it ); -+ } -+ updateStatus(); -+} -+ -+#include "networkstatus.moc" -+// vim: set noet sw=4 ts=4: -Index: networkstatus/networkstatus.desktop -=================================================================== ---- /dev/null -+++ networkstatus/networkstatus.desktop -@@ -0,0 +1,98 @@ -+[Desktop Entry] -+Encoding=UTF-8 -+Name=Network Status Daemon -+Name[af]=Netwerk status bediener -+Name[ar]=مراقب القرص و التنفيذ لحالة الشبكة -+Name[bg]=Демон за състояние на мрежата -+Name[ca]=Dimoni de l'estat de la xarxa -+Name[cs]=Démon stavu sítě -+Name[da]=Netværkstatusdæmon -+Name[de]=Überwachung des Netzwerkstatus -+Name[el]=Δαίμονας κατάστασης δικτύου -+Name[es]=Daemon de estado de la red -+Name[et]=Võrguoleku deemon -+Name[eu]=Sarearen egoera deabrua -+Name[fa]=شبح وضعیت شبکه -+Name[fi]=Verkkotilan tarkkailija -+Name[fr]=Suivi de l'état du réseau -+Name[fy]=Netwurktastândaemon -+Name[gl]=Daemon do Estado da Rede -+Name[hu]=Hálózati állapotjelző szolgáltatás -+Name[is]=Netstöðupúki -+Name[it]=Demone dello stato della rete -+Name[ja]=ネットワークステータスデーモン -+Name[kk]=Желі күйінің қызметі -+Name[km]=ដេមិន​ស្ថានភាព​បណ្ដាញ -+Name[lt]=Tinklo statuso tarnyba -+Name[mk]=Даемон за мрежен статус -+Name[ms]=Daemon Berstatus Rangkaian -+Name[nb]=Statusnisse for nettverket -+Name[nds]=Nettwarkstatus-Dämoon -+Name[ne]=सञ्जाल स्थिति डेइमन -+Name[nl]=Netwerkstatusdaemon -+Name[nn]=Statusnisse for nettverket -+Name[pl]=Usługa stanu sieci -+Name[pt]=Servidor de Estado de Rede -+Name[pt_BR]=Daemon de Status da Rede -+Name[ru]=Служба состояния сети -+Name[sk]=Daemon stavu siete -+Name[sl]=Demon za omrežno stanje -+Name[sr]=Демон за статус мреже -+Name[sr@Latn]=Demon za status mreže -+Name[sv]=Nätverksstatusdemon -+Name[ta]=வலைப்பின்னல் நிலை டெமான் -+Name[tr]=Ağ Durum İzleyici -+Name[uk]=Демон стану мережі -+Name[zh_CN]=网络状态守护程序 -+Name[zh_TW]=網路狀態守護程式 -+Comment=Tracks status of network interfaces and provides notification to applications using the network. -+Comment[af]=Hou tred van die status van netwerk intervlakke en verskaf kennisgewings na programme wat die netwerk gebruik. -+Comment[bg]=Следене на състоянието на мрежата и предаване на информацията на програмите, които имат нужда -+Comment[ca]=Controla l'estat de les interfícies de xarxa i proporciona notificacions a les aplicacions que usen la xarxa. -+Comment[cs]=Zjiš'tuje stav síťových rozhraní a upozorňuje v případě přístupu aplikací k síti. -+Comment[da]=Sporer status af netværksgrænseflade og sørger for meddelelser til programmer der bruger netværket. -+Comment[de]=Überprüft den Netzwerk-Status und benachrichtigt anfragende Anwendungen -+Comment[el]=Παρακολουθεί την κατάσταση του δικτύου και παρέχει ειδοποιήσεις σε εφαρμογές που χρησιμοποιούν το δίκτυο. -+Comment[es]=Sigue la pista de las interfaces de red y proporciona notificaciones a las aplicaciones que están usando la red. -+Comment[et]=Jälgib võrguliideste olekut ja annab sellest võrgu vahendusel rakendustele teada. -+Comment[eu]=Sare interfazeen egoera jarraitzen du eta sarea darabilten aplikazioei jakinarazten die. -+Comment[fa]=وضعیت واسطهای شبکه را شیار داده و با استفاده از شبکه، برای کاربردها اخطار فراهم می‌کند. -+Comment[fi]=Tarkkailee verkkoliitäntöjen tilaa ja varoittaa verkkoa käyttäviä sovelluksia. -+Comment[fr]=Surveille l'état des interfaces réseaux et fournit des notifications aux applications qui utilisent le réseau -+Comment[fy]=Hâldt de tastân by fan de Netwurkynterfaces en hâldt dêr de tapassings fan op de hichte. -+Comment[gl]=Monitoriza o estado das interfaces de rede e fornece notificacións ás aplicacións que usen a rede. -+Comment[hu]=Figyeli a hálózati csatolók állapotát és értesítési lehetőséget biztosít hálózati alkalmazások számára. -+Comment[is]=Fylgist með stöðu netkorta og sendir tilkynningar til forrita sem nota netið. -+Comment[it]=Controlla lo stato delle interfacce di rete e fornisce notifiche alle applicazioni che usano al rete. -+Comment[ja]=ネットワークインターフェースの状態を追跡し、ネットワークを用いるアプリケーションに通知します -+Comment[kk]=Желі интерфейстерінің күйін бақылап, желіні қолданатын бағдарламаларын құлақтандыру қызметі. -+Comment[km]=តាមដាន​ស្ថានភាព​របស់​ចំណុច​ប្រទាក់​បណ្ដាញ ព្រម​ទាំង​ផ្ដល់​នូវ​ការ​ជូនដំណឹង​ទៅ​កម្មវិធី ដែល​ប្រើ​បណ្ដាញ ។ -+Comment[lt]=Seka tinklo sąsajų būseną ir informuoja apie jas programas, naudojančias tinklą -+Comment[mk]=Го следи статусот на мрежните интерфејси и дава известувања на апликациите што ја користат мрежата. -+Comment[ms]=Menjejak status antara muka rangkaian dan memberitahu aplikasi yang menggunakan rangkaian tersebut. -+Comment[nb]=Overvåker status for nettverksgrensesnitt og varsler programmer som bruker nettverket. -+Comment[nds]=Överwacht den Tostand vun Nettwark-Koppelsteden un sendt Narichten na Programmen, de dat Nettwark bruukt. -+Comment[ne]=सञ्जाल इन्टरफेसको स्थिति ट्र्याक गर्दछ र सञ्जाल प्रयोग गरेर अनुप्रयोगमा जानकारी उपलब्ध गराउछ । -+Comment[nl]=Houdt de status bij van de netwerkinterfaces en houdt daar de toepassingen van op de hoogte. -+Comment[nn]=Overvakar status for nettverksgrensesnitt og varslar program som brukar nettverket. -+Comment[pl]=Śledzi stan interfejsów sieciowych i powiadamia programy używające sieci. -+Comment[pt]=Vigia o estado das interfaces de rede e avisa as aplicações que utilizam a rede. -+Comment[pt_BR]=Controla o status das interfaces de rede e fornece notificações para aplicativos utilizando a rede. -+Comment[ru]=Служба отслеживания состояния сетевых интерфейсов и обращения приложений к сети. -+Comment[sk]=Sleduje stav sieťových rozhraní a poskytuje upozornenia aplikáciám používajúcim sieť. -+Comment[sl]=Sledi stanju omrežnim vmesnikom in omogoča obvestila programom, ki uporabljajo omrežje -+Comment[sr]=Прати статус мрежних интерфејса и пружа обавештења програмима који користе мрежу. -+Comment[sr@Latn]=Prati status mrežnih interfejsa i pruža obaveštenja programima koji koriste mrežu. -+Comment[sv]=Bevakar status för nätverksgränssnitt och tillhandahåller underrättelser till program som använder nätverket. -+Comment[ta]=வலைப்பின்னலைப் பயன்படுத்தி வலைப்பின்னல் இடைமுகங்களின் நிலையை கண்காணிக்கிறது மற்றும் பயன்பாடுகளுக்கு அறிவிப்பை வழங்குகிறது. -+Comment[uk]=Слідкує за станом інтерфейсів мережі і сповіщає програми, які користуються мережею. -+Comment[zh_CN]=跟踪网卡的状态并为应用程序提供使用网络的通知。 -+Comment[zh_TW]=追蹤網路介面的狀態,並提供使用網路的應用程式的通知。 -+Type=Service -+ServiceTypes=KDEDModule -+X-KDE-ModuleType=Library -+X-KDE-Library=networkstatus -+X-KDE-FactoryName=networkstatus -+X-KDE-Kded-autoload=true -+X-KDE-Kded-load-on-demand=true -+ -Index: networkstatus/networkstatus.h -=================================================================== ---- /dev/null -+++ networkstatus/networkstatus.h -@@ -0,0 +1,66 @@ -+/* This file is part of kdepim -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef KDED_NETWORKSTATUS_H -+#define KDED_NETWORKSTATUS_H -+ -+#include -+ -+#include "networkstatuscommon.h" -+#include "network.h" -+ -+class NetworkStatusModule : virtual public KDEDModule -+{ -+Q_OBJECT -+K_DCOP -+public: -+ NetworkStatusModule( const QCString& obj ); -+ ~NetworkStatusModule(); -+k_dcop: -+ // Client interface -+ QStringList networks(); -+ int status(); -+ // Service interface -+ void setNetworkStatus( const QString & networkName, int status ); -+ void registerNetwork( NetworkStatus::Properties properties ); -+ void unregisterNetwork( const QString & networkName ); -+k_dcop_signals: -+ /** -+ * A status change occurred affecting the overall connectivity -+ * @param status The new status -+ */ -+ void statusChange( int status ); -+protected slots: -+ //void registeredToDCOP( const QCString& appId ); -+ void unregisteredFromDCOP( const QCString& appId ); -+ -+protected: -+ // recalculate cached status -+ void updateStatus(); -+ -+private: -+ class Private; -+ Private *d; -+}; -+ -+#endif -+// vim: sw=4 ts=4 -Index: networkstatus/networkstatusiface.h -=================================================================== ---- /dev/null -+++ networkstatus/networkstatusiface.h -@@ -0,0 +1,50 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef KDED_NETWORKSTATUSIFACE_H -+#define KDED_NETWORKSTATUSIFACE_H -+ -+#include -+#include -+ -+#include "networkstatuscommon.h" -+ -+class NetworkStatusIface : virtual public DCOPObject -+{ -+K_DCOP -+k_dcop: -+ // Client interface -+ virtual QStringList networks() = 0; -+ virtual int status() = 0; -+ // Service interface -+ virtual void setNetworkStatus( const QString & networkName, int status ) = 0; -+ virtual void registerNetwork( NetworkStatus::Properties properties ) = 0; -+ virtual void unregisterNetwork( const QString & networkName ) = 0 ; -+k_dcop_signals: -+ /** -+ * A status change occurred affecting the overall connectivity -+ * @param status The new status -+ */ -+ virtual void statusChange( int status ) = 0; -+}; -+#endif -+// vim: sw=4 ts=4 -Index: networkstatus/networkstatusindicator.cpp -=================================================================== ---- /dev/null -+++ networkstatus/networkstatusindicator.cpp -@@ -0,0 +1,64 @@ -+/* This file is part of the KDE project -+ Copyright (C) 2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#include -+#include -+#include -+#include -+ -+#include "connectionmanager.h" -+ -+#include "networkstatusindicator.h" -+ -+StatusBarNetworkStatusIndicator::StatusBarNetworkStatusIndicator( -+ QWidget * parent, const char * name ) : QHBox( parent, name )/*, d( new StatusBarNetworkStatusIndicatorPrivate )*/ -+{ -+ setMargin( 2 ); -+ setSpacing( 1 ); -+ QLabel * label = new QLabel( this, "offlinemodelabel" ); -+ label->setPixmap( SmallIcon("connect_no") ); -+ QToolTip::add( label, i18n( "The desktop is offline" ) ); -+ -+ connect( ConnectionManager::self(), SIGNAL( statusChanged( NetworkStatus::Status ) ), -+ SLOT( networkStatusChanged( NetworkStatus::Status) ) ); -+ -+} -+ -+void StatusBarNetworkStatusIndicator::init() -+{ -+ networkStatusChanged( ConnectionManager::self()->status()); -+} -+ -+StatusBarNetworkStatusIndicator::~StatusBarNetworkStatusIndicator() -+{ -+} -+ -+void StatusBarNetworkStatusIndicator::networkStatusChanged( NetworkStatus::Status status ) -+{ -+ if ( status == NetworkStatus::Online || status == NetworkStatus::NoNetworks ) { -+ hide(); -+ } else { -+ show(); -+ } -+} -+ -+#include "networkstatusindicator.moc" -Index: networkstatus/networkstatusindicator.h -=================================================================== ---- /dev/null -+++ networkstatus/networkstatusindicator.h -@@ -0,0 +1,42 @@ -+/* This file is part of the KDE project -+ Copyright (C) 2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef KDE_NETWORKSTATUS_INDICATOR_H -+#define KDE_NETWORKSTATUS_INDICATOR_H -+ -+#include -+#include -+#include -+ -+class StatusBarNetworkStatusIndicator : public QHBox -+{ -+Q_OBJECT -+public: -+ StatusBarNetworkStatusIndicator( QWidget * parent, const char * name ); -+ virtual ~StatusBarNetworkStatusIndicator(); -+ void init(); -+protected slots: -+ void networkStatusChanged( NetworkStatus::Status status ); -+}; -+ -+#endif -+ -Index: networkstatus/networkstatus.kdevelop -=================================================================== ---- /dev/null -+++ networkstatus/networkstatus.kdevelop -@@ -0,0 +1,108 @@ -+ -+ -+ -+ Will Stephenson -+ wstephenson@suse.de -+ $VERSION$ -+ KDevKDEAutoProject -+ C++ -+ -+ Qt -+ KDE -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ false -+ false -+ -+ -+ *.o,*.lo,CVS -+ false -+ -+ -+ -+ -+ ada -+ ada_bugs_gcc -+ bash -+ bash_bugs -+ clanlib -+ fortran_bugs_gcc -+ gnome1 -+ gnustep -+ gtk -+ gtk_bugs -+ haskell -+ haskell_bugs_ghc -+ java_bugs_gcc -+ java_bugs_sun -+ opengl -+ pascal_bugs_fp -+ php -+ php_bugs -+ perl -+ perl_bugs -+ python -+ python_bugs -+ ruby -+ ruby_bugs -+ sdl -+ stl -+ sw -+ w3c-dom-level2-html -+ w3c-svg -+ w3c-uaag10 -+ wxwidgets_bugs -+ -+ -+ qmake User Guide -+ -+ -+ -+ -+ libtool -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ executable -+ -+ -+ kded_networkstatus.la -+ -+ -+ -+ -+ -+ true -+ true -+ true -+ false -+ true -+ true -+ true -+ 250 -+ 400 -+ 250 -+ -+ -+ -Index: networkstatus/README.statetransition -=================================================================== ---- /dev/null -+++ networkstatus/README.statetransition -@@ -0,0 +1,29 @@ -+This table defines the actions to be taken on state transition. -+ -+TODO: potentially add extra states OnlineReading and OnlineWriting -+ -+ NEW -+ |Offline | Online | -+---+---+----------------+---------------+ -+ | | |N|set online | -+ | | |L|reload | -+ | O | |C|resources | -+ | F | +---------------+ -+ | F | |L|set online | -+O | | |C|reload res. | -+L | | | |write res. | -+D +---+----------------+---------------+ -+ | |N|set offline | | -+ | |C| | | -+ | | | | | -+ | O +---------------+| | -+ | N |U|set offline | | -+ | |W|write locally | | -+ | |C|(subject to | | -+ | | | save policy)| | -+---+---+----------------+---------------+ -+LC = Local changes exist -+NLC = No local changes exist -+UWC = Unsaved changes exist -+NC = no changes exist -+ -Index: networkstatus/.svn/dir-prop-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/dir-prop-base -@@ -0,0 +1,11 @@ -+K 10 -+svn:ignore -+V 83 -+Makefile -+Makefile.in -+Makefile.calls.in -+Makefile.rules.in -+*_skel.cpp -+*.kidl -+Doxyfile -+END -Index: networkstatus/.svn/entries -=================================================================== ---- /dev/null -+++ networkstatus/.svn/entries -@@ -0,0 +1,342 @@ -+8 -+ -+dir -+712059 -+svn+ssh://mueller@svn.kde.org/home/kde/branches/work/~wstephens/kdelibs/networkstatus -+svn+ssh://mueller@svn.kde.org/home/kde -+ -+ -+ -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+has-props -+ -+svn:special svn:externals svn:needs-lock -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+283d02a7-25f6-0310-bc7c-ecb5cbfe19da -+ -+network.h -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+034300313451d5b6a95bff1022861227 -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+has-props -+ -+networkstatusindicator.h -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+bbc7c6ea3b8da983d477d53556e39dd0 -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+ -+connectionmanager.h -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+7992e623b84fd99f9ff17c613a7269a3 -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+has-props -+ -+testservice.cpp -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+527dc95a7ae39d565bd29d5fe59de31a -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+has-props -+ -+testclient2.cpp -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+c426585cf5d9e3f4b06adcaff0a3ef32 -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+ -+networkstatus.h -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+8ca1d871b31d5840e2e3d24da4693f1d -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+has-props -+ -+testclientview.ui -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+8f63eb3db978c53143417ad33d45076b -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+ -+testservice.h -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+2b5693b2e174ebf96e460a52cfcf9739 -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+has-props -+ -+testclient2.h -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+3b9f645e56a92014b7a6547c5bc88527 -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+ -+README.statetransition -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+0091b6bdce4abe1e1260bf2a4cce984f -+2005-02-11T15:15:30.000000Z -+388364 -+wstephens -+has-props -+ -+networkstatuscommon.cpp -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+1516e99224ce850fb6d134346fd9d074 -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+has-props -+ -+connectionmanager_p.cpp -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+07e9643c6cdb39d28abc9c8992bcab23 -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+ -+networkstatuscommon.h -+file -+712062 -+ -+ -+ -+2007-09-13T13:10:21.000000Z -+a4f22eecd7d0a0fdcc78c9c31d5f14fd -+2007-09-13T13:12:05.866586Z -+712062 -+mueller -+has-props -+ -+testclient.cpp -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+d932143bab5c7985bc48e64e2bf0c227 -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+ -+connectionmanager_p.h -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+34ed7e34d50ae4b36342a6cc250ad386 -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+ -+testclient.h -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+67d3671e5fbeb51a333550f52ec34294 -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+ -+networkstatus.kdevelop -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+64e6cd906f82dad6a3c70a8dd7e69c3c -+2005-01-24T08:48:57.000000Z -+381869 -+wstephens -+has-props -+ -+networkstatus.desktop -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+1bc32c39d8c6ed9c63e6fdc1b3d34aba -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+has-props -+ -+testserviceview.ui -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+f8883c2425f16054c8cfd99a6c288000 -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+ -+Makefile.am -+file -+712061 -+ -+ -+ -+2007-09-13T13:10:11.000000Z -+70d1b224f8edc970fbdf2f4af63282f0 -+2007-09-13T13:11:26.289844Z -+712061 -+mueller -+has-props -+ -+network.cpp -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+1f481f54f0161b8a65d00753d6397904 -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+has-props -+ -+networkstatusindicator.cpp -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+243176eca79394c0e2a763b1e56a0690 -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+ -+networkstatusiface.h -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+285a14008068eb0cd26e3af2bb8fbb92 -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+ -+connectionmanager.cpp -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+922d360b2e43b6b35f56c0d97ab1afa9 -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+has-props -+ -+networkstatus.cpp -+file -+ -+ -+ -+ -+2007-09-13T13:09:10.000000Z -+433313b5f03259de305b6d722c0251e5 -+2007-08-06T09:06:39.201606Z -+696919 -+wstephens -+has-props -+ -Index: networkstatus/.svn/format -=================================================================== ---- /dev/null -+++ networkstatus/.svn/format -@@ -0,0 +1 @@ -+8 -Index: networkstatus/.svn/prop-base/connectionmanager.cpp.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/prop-base/connectionmanager.cpp.svn-base -@@ -0,0 +1,13 @@ -+K 13 -+svn:eol-style -+V 6 -+native -+K 12 -+svn:keywords -+V 23 -+Author Date Id Revision -+K 13 -+svn:mime-type -+V 13 -+text/x-c++src -+END -Index: networkstatus/.svn/prop-base/connectionmanager.h.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/prop-base/connectionmanager.h.svn-base -@@ -0,0 +1,13 @@ -+K 13 -+svn:eol-style -+V 6 -+native -+K 12 -+svn:keywords -+V 23 -+Author Date Id Revision -+K 13 -+svn:mime-type -+V 11 -+text/x-chdr -+END -Index: networkstatus/.svn/prop-base/Makefile.am.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/prop-base/Makefile.am.svn-base -@@ -0,0 +1,13 @@ -+K 13 -+svn:eol-style -+V 6 -+native -+K 12 -+svn:keywords -+V 23 -+Author Date Id Revision -+K 13 -+svn:mime-type -+V 9 -+text/x-am -+END -Index: networkstatus/.svn/prop-base/network.cpp.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/prop-base/network.cpp.svn-base -@@ -0,0 +1,13 @@ -+K 13 -+svn:eol-style -+V 6 -+native -+K 12 -+svn:keywords -+V 23 -+Author Date Id Revision -+K 13 -+svn:mime-type -+V 13 -+text/x-c++src -+END -Index: networkstatus/.svn/prop-base/network.h.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/prop-base/network.h.svn-base -@@ -0,0 +1,13 @@ -+K 13 -+svn:eol-style -+V 6 -+native -+K 12 -+svn:keywords -+V 23 -+Author Date Id Revision -+K 13 -+svn:mime-type -+V 11 -+text/x-chdr -+END -Index: networkstatus/.svn/prop-base/networkstatuscommon.cpp.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/prop-base/networkstatuscommon.cpp.svn-base -@@ -0,0 +1,13 @@ -+K 13 -+svn:eol-style -+V 6 -+native -+K 12 -+svn:keywords -+V 23 -+Author Date Id Revision -+K 13 -+svn:mime-type -+V 13 -+text/x-c++src -+END -Index: networkstatus/.svn/prop-base/networkstatuscommon.h.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/prop-base/networkstatuscommon.h.svn-base -@@ -0,0 +1,13 @@ -+K 13 -+svn:eol-style -+V 6 -+native -+K 12 -+svn:keywords -+V 23 -+Author Date Id Revision -+K 13 -+svn:mime-type -+V 11 -+text/x-chdr -+END -Index: networkstatus/.svn/prop-base/networkstatus.cpp.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/prop-base/networkstatus.cpp.svn-base -@@ -0,0 +1,13 @@ -+K 13 -+svn:eol-style -+V 6 -+native -+K 12 -+svn:keywords -+V 23 -+Author Date Id Revision -+K 13 -+svn:mime-type -+V 13 -+text/x-c++src -+END -Index: networkstatus/.svn/prop-base/networkstatus.desktop.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/prop-base/networkstatus.desktop.svn-base -@@ -0,0 +1,13 @@ -+K 13 -+svn:eol-style -+V 6 -+native -+K 12 -+svn:keywords -+V 23 -+Author Date Id Revision -+K 13 -+svn:mime-type -+V 14 -+text/x-desktop -+END -Index: networkstatus/.svn/prop-base/networkstatus.h.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/prop-base/networkstatus.h.svn-base -@@ -0,0 +1,13 @@ -+K 13 -+svn:eol-style -+V 6 -+native -+K 12 -+svn:keywords -+V 23 -+Author Date Id Revision -+K 13 -+svn:mime-type -+V 11 -+text/x-chdr -+END -Index: networkstatus/.svn/prop-base/networkstatus.kdevelop.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/prop-base/networkstatus.kdevelop.svn-base -@@ -0,0 +1,5 @@ -+K 12 -+svn:keywords -+V 23 -+Author Date Id Revision -+END -Index: networkstatus/.svn/prop-base/README.statetransition.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/prop-base/README.statetransition.svn-base -@@ -0,0 +1,5 @@ -+K 12 -+svn:keywords -+V 23 -+Author Date Id Revision -+END -Index: networkstatus/.svn/prop-base/testservice.cpp.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/prop-base/testservice.cpp.svn-base -@@ -0,0 +1,13 @@ -+K 13 -+svn:eol-style -+V 6 -+native -+K 12 -+svn:keywords -+V 23 -+Author Date Id Revision -+K 13 -+svn:mime-type -+V 13 -+text/x-c++src -+END -Index: networkstatus/.svn/prop-base/testservice.h.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/prop-base/testservice.h.svn-base -@@ -0,0 +1,13 @@ -+K 13 -+svn:eol-style -+V 6 -+native -+K 12 -+svn:keywords -+V 23 -+Author Date Id Revision -+K 13 -+svn:mime-type -+V 11 -+text/x-chdr -+END -Index: networkstatus/.svn/text-base/connectionmanager.cpp.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/connectionmanager.cpp.svn-base -@@ -0,0 +1,171 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#include -+#include -+#include -+ -+#include "connectionmanager.h" -+#include "connectionmanager_p.h" -+ -+// Connection manager itself -+ConnectionManager::ConnectionManager( QObject * parent, const char * name ) : DCOPObject( "ConnectionManager" ), QObject( parent, name ), d( new ConnectionManagerPrivate( this ) ) -+{ -+ d->service = new NetworkStatusIface_stub( kapp->dcopClient(), "kded", "networkstatus" ); -+ -+ connectDCOPSignal( "kded", "networkstatus", "statusChange(int)", "slotStatusChanged(int)", false ); -+ -+ initialise(); -+} -+ -+ConnectionManager::~ConnectionManager() -+{ -+ delete d; -+} -+ -+ConnectionManager *ConnectionManager::s_self = 0L; -+ -+ConnectionManager *ConnectionManager::self() -+{ -+ static KStaticDeleter deleter; -+ if(!s_self) -+ deleter.setObject( s_self, new ConnectionManager( 0, "connection_manager" ) ); -+ return s_self; -+} -+ -+void ConnectionManager::initialise() -+{ -+ // determine initial state and set the state object accordingly. -+ d->status = ( NetworkStatus::Status )d->service->status(); -+} -+ -+NetworkStatus::Status ConnectionManager::status() -+{ -+ return d->status; -+} -+ -+void ConnectionManager::slotStatusChanged( int status ) -+{ -+ d->status = ( NetworkStatus::Status )status; -+ switch ( status ) { -+ case NetworkStatus::NoNetworks: -+ break; -+ case NetworkStatus::Unreachable: -+ break; -+ case NetworkStatus::OfflineDisconnected: -+ case NetworkStatus::OfflineFailed: -+ case NetworkStatus::ShuttingDown: -+ case NetworkStatus::Offline: -+ case NetworkStatus::Establishing: -+ if ( d->disconnectPolicy == Managed ) { -+ emit d->disconnected(); -+ } else if ( d->disconnectPolicy == OnNextChange ) { -+ setDisconnectPolicy( Manual ); -+ emit d->disconnected(); -+ } -+ break; -+ case NetworkStatus::Online: -+ if ( d->disconnectPolicy == Managed ) { -+ emit d->connected(); -+ } else if ( d->disconnectPolicy == OnNextChange ) { -+ setConnectPolicy( Manual ); -+ emit d->connected(); -+ } -+ break; -+ default: -+ kdDebug() << k_funcinfo << "Unrecognised status code!" << endl; -+ } -+ emit statusChanged( d->status ); -+} -+ -+ConnectionManager::ConnectionPolicy ConnectionManager::connectPolicy() const -+{ -+ return d->connectPolicy; -+} -+ -+void ConnectionManager::setConnectPolicy( ConnectionManager::ConnectionPolicy policy ) -+{ -+ d->connectPolicy = policy; -+} -+ -+ConnectionManager::ConnectionPolicy ConnectionManager::disconnectPolicy() const -+{ -+ return d->disconnectPolicy; -+} -+ -+void ConnectionManager::setDisconnectPolicy( ConnectionManager::ConnectionPolicy policy ) -+{ -+ d->disconnectPolicy = policy; -+} -+ -+void ConnectionManager::setManualConnectionPolicies() -+{ -+ d->connectPolicy = ConnectionManager::Manual; -+ d->disconnectPolicy = ConnectionManager::Manual; -+} -+ -+void ConnectionManager::setManagedConnectionPolicies() -+{ -+ d->connectPolicy = ConnectionManager::Managed; -+ d->disconnectPolicy = ConnectionManager::Managed; -+} -+ -+void ConnectionManager::registerConnectSlot( QObject * receiver, const char * member ) -+{ -+ d->connectReceiver = receiver; -+ d->connectSlot = member; -+ connect( d, SIGNAL( connected() ), receiver, member ); -+} -+ -+void ConnectionManager::forgetConnectSlot() -+{ -+ disconnect( d, SIGNAL( connected() ), d->connectReceiver, d->connectSlot ); -+ d->connectReceiver = 0; -+ d->connectSlot = 0; -+} -+ -+bool ConnectionManager::isConnectSlotRegistered() const -+{ -+ return ( d->connectSlot != 0 ); -+} -+ -+void ConnectionManager::registerDisconnectSlot( QObject * receiver, const char * member ) -+{ -+ d->disconnectReceiver = receiver; -+ d->disconnectSlot = member; -+ connect( d, SIGNAL( disconnected() ), receiver, member ); -+} -+ -+void ConnectionManager::forgetDisconnectSlot() -+{ -+ disconnect( d, SIGNAL( disconnected() ), d->disconnectReceiver, d->disconnectSlot ); -+ d->disconnectReceiver = 0; -+ d->disconnectSlot = 0; -+} -+ -+bool ConnectionManager::isDisconnectSlotRegistered() const -+{ -+ return ( d->disconnectSlot != 0 ); -+} -+ -+#include "connectionmanager.moc" -+ -Index: networkstatus/.svn/text-base/connectionmanager.h.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/connectionmanager.h.svn-base -@@ -0,0 +1,167 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef KDE_CONNECTION_MANAGER_H -+#define KDE_CONNECTION_MANAGER_H -+ -+#include -+#include -+ -+#include -+ -+class ConnectionManagerPrivate; -+ -+class KDE_EXPORT ConnectionManager : public QObject, virtual public DCOPObject -+{ -+Q_OBJECT -+K_DCOP -+k_dcop: -+ void slotStatusChanged( int status ); -+public: -+ /** -+ * This defines application policy in response to networking connect/disconnect events -+ * Manual - the app only disconnects when the user does so -+ * OnNextChange - the app should connect or disconnect the next time the network changes state, thereafter -+ * Manual -+ * Managed - the app should disconnect when the ConnectionManager thinks the system is -+ * offline -+ */ -+ enum ConnectionPolicy { Manual, OnNextChange, Managed }; -+ /** -+ * Set a policy to manage the application's connect behaviour -+ */ -+ void setConnectPolicy( ConnectionPolicy ); -+ /** -+ * Retrieve a policy managing the application's connect behaviour -+ */ -+ ConnectionPolicy connectPolicy() const; -+ -+ /** -+ * Set a policy to manage the application's disconnect behaviour -+ */ -+ void setDisconnectPolicy( ConnectionPolicy ); -+ -+ /** -+ * Retrieve a policy managing the application's disconnect behaviour -+ */ -+ ConnectionPolicy disconnectPolicy() const; -+ -+ /* -+ * We'll get logic of the form -+ * onStatusChange() { -+ * if ( ConnectionManager::self()->policy( ConnectionManager::ConnectBehaviour ) == ConnectionManager::OnNextChange || -+ * ConnectionManager::self()->policy( ConnectionManager::ConnectBehaviour ) == ConnectionManager::Managed ) -+ * { -+ * // do connect -+ * -+ * // reset the policy -+ * if ( ConnectionManager::self()->policy( ConnectionManager::ConnectBehaviour ) == ConnectionManager::OnNextChange ) -+ * ConnectionManager::self()->setPolicy( ConnectionManager::ConnectionManager, -+ * ConnectionManager::Manual ); -+ * } -+ * -+ * Do we just use the CM for policy storage, or do we try to factor the logic to implement the -+ * policy into the CM too? -+ * -+ * could signal doConnect(), then reset the policy -+ * or could register a connect slot -+ * registerConnectMethod( QObject * receiver, const char * member ); -+ * unregisterConnectMethod(); -+ * etc. -+ * -+ * The problem with automatically controlled behaviour, where policy may change as a result of a -+ * connect, is that if it is also manually altered, the CM needs to be updated. But the CM needs to -+ * be updated in any case. -+ * CM need -+ */ -+ /** -+ * Lazy-method to set Manual on both policies -+ */ -+ void setManualConnectionPolicies(); -+ /** -+ * Lazy-method to set Managed on both policies -+ */ -+ void setManagedConnectionPolicies(); -+ -+ /** -+ * Record a slot to call on a given receiving QObject when -+ * 1) the network connection is online, -+ * 2) the policy mandates that the app connect -+ * -+ * Only one slot may be registered at any one time. If a second slot is -+ * registered, the first slot is forgotten -+ * @param receiver the QObject where the slot is located -+ * @param member the slot to call. Set up member using the SLOT() macro. -+ */ -+ void registerConnectSlot( QObject * receiver, const char * member ); -+ -+ /** -+ * Forget any connect slot previously registered -+ */ -+ void forgetConnectSlot(); -+ -+ /** -+ * Has any slot been registered to be called on connect? -+ */ -+ bool isConnectSlotRegistered() const; -+ -+ /** -+ * Record a slot to call on a given receiving QObject when -+ * 1) the network connection goes offline (in any way ), -+ * 2) the policy mandates that the app disconnect -+ * -+ * Only one slot may be registered at any one time. If a second slot is -+ * registered, the first slot is forgotten -+ * @param receiver the QObject where the slot is located -+ * @param member the slot to call. Set up member using the SLOT() macro. -+ */ -+ void registerDisconnectSlot( QObject * receiver, const char * member ); -+ -+ /** -+ * Forget any disconnect slot previously registered -+ */ -+ void forgetDisconnectSlot(); -+ -+ /** -+ * Has any slot been registered to be called on disconnect? -+ */ -+ bool isDisconnectSlotRegistered() const; -+ -+ /// existing API -+ -+ static ConnectionManager* self(); -+ virtual ~ConnectionManager(); -+ NetworkStatus::Status status(); -+signals: -+ // signal that the network for a hostname is up/down -+ void statusChanged( NetworkStatus::Status status ); -+private: -+ // sets up internal state -+ void initialise(); -+ // reread the desktop status from the daemon and update internal state -+ ConnectionManager( QObject *parent, const char * name ); -+ ConnectionManagerPrivate * d; -+ static ConnectionManager * s_self; -+}; -+ -+#endif -+ -Index: networkstatus/.svn/text-base/connectionmanager_p.cpp.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/connectionmanager_p.cpp.svn-base -@@ -0,0 +1,13 @@ -+#include "connectionmanager_p.h" -+ -+ConnectionManagerPrivate::ConnectionManagerPrivate(QObject * parent, const char * name ) : QObject( parent, name ), service( 0 ), connectPolicy( ConnectionManager::Managed ), -+ disconnectPolicy( ConnectionManager::Managed ), connectReceiver( 0 ), connectSlot( 0 ), -+ disconnectReceiver( 0 ), disconnectSlot( 0 ) -+{ -+} -+ -+ConnectionManagerPrivate::~ConnectionManagerPrivate() -+{ -+} -+ -+#include "connectionmanager_p.moc" -Index: networkstatus/.svn/text-base/connectionmanager_p.h.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/connectionmanager_p.h.svn-base -@@ -0,0 +1,55 @@ -+/* This file is part of the KDE project -+ Copyright (C) 2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef CONNECTIONMANAGERPRIVATE_H -+#define CONNECTIONMANAGERPRIVATE_H -+ -+#include -+ -+#include "connectionmanager.h" -+#include "networkstatuscommon.h" -+#include "networkstatusiface_stub.h" -+ -+ -+// ConnectionManager's private parts -+class ConnectionManagerPrivate : public QObject -+{ -+Q_OBJECT -+ friend class ConnectionManager; -+public: -+ ConnectionManagerPrivate( QObject * parent = 0, const char * name = 0); -+ ~ConnectionManagerPrivate(); -+ // this holds the currently active state -+ NetworkStatus::Status status; -+ NetworkStatusIface_stub * service; -+ ConnectionManager::ConnectionPolicy connectPolicy; -+ ConnectionManager::ConnectionPolicy disconnectPolicy; -+ QObject * connectReceiver; -+ const char * connectSlot; -+ QObject * disconnectReceiver; -+ const char * disconnectSlot; -+signals: -+ void connected(); -+ void disconnected(); -+}; -+ -+#endif -Index: networkstatus/.svn/text-base/Makefile.am.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/Makefile.am.svn-base -@@ -0,0 +1,45 @@ -+#SUBDIRS = networkstatustray -+ -+METASOURCES = AUTO -+ -+INCLUDES = -I$(top_srcdir)/kded -I$(top_srcdir) $(all_includes) -+ -+kde_module_LTLIBRARIES = kded_networkstatus.la -+ -+kded_networkstatus_la_SOURCES = networkstatus.cpp networkstatus.skel \ -+ network.cpp -+kded_networkstatus_la_LIBADD = $(LIB_KDECORE) $(LIB_KIO) ./libnetworkstatus.la -+kded_networkstatus_la_LDFLAGS = $(all_libraries) -module -avoid-version -+ -+servicesdir = $(kde_servicesdir)/kded -+ -+services_DATA = networkstatus.desktop -+ -+lib_LTLIBRARIES = libnetworkstatus.la libconnectionmanager.la -+ -+libnetworkstatus_la_LIBADD = $(LIB_KDECORE) -+libnetworkstatus_la_LDFLAGS = $(all_libraries) -+libnetworkstatus_la_SOURCES = networkstatuscommon.cpp -+ -+libconnectionmanager_la_LIBADD = $(LIB_KDECORE) libnetworkstatus.la -+libconnectionmanager_la_LDFLAGS = $(all_libraries) -+libconnectionmanager_la_SOURCES = connectionmanager.cpp connectionmanager_p.cpp networkstatusindicator.cpp connectionmanager.skel networkstatusiface.stub -+ -+noinst_PROGRAMS = networkstatustestservice networkstatustestclient managedconnectiontestclient -+ -+networkstatustestservice_LDFLAGS = $(all_libraries) -+networkstatustestservice_LDADD = $(LIB_KFILE) libnetworkstatus.la -+networkstatustestservice_SOURCES = testservice.cpp testserviceview.ui networkstatusiface.stub -+ -+networkstatustestclient_LDFLAGS = $(all_libraries) -+networkstatustestclient_LDADD = $(LIB_KFILE) libnetworkstatus.la libconnectionmanager.la -+networkstatustestclient_SOURCES = testclient.cpp testclientview.ui -+ -+managedconnectiontestclient_LDFLAGS = $(all_libraries) -+managedconnectiontestclient_LDADD = $(LIB_KFILE) libnetworkstatus.la libconnectionmanager.la -+managedconnectiontestclient_SOURCES = testclient2.cpp testclientview.ui -+ -+noinst_HEADERS = network.h testservice.h testclient.h -+ -+include_HEADERS = networkstatuscommon.h connectionmanager.h networkstatusindicator.h \ -+ networkstatusiface.h -Index: networkstatus/.svn/text-base/network.cpp.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/network.cpp.svn-base -@@ -0,0 +1,62 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#include -+ -+#include "network.h" -+ -+Network::Network( NetworkStatus::Properties properties ) -+ : m_name( properties.name ), m_status( properties.status ), m_service( properties.service ) -+{ -+} -+ -+void Network::setStatus( NetworkStatus::Status status ) -+{ -+ m_status = status; -+} -+ -+NetworkStatus::Status Network::status() -+{ -+ return m_status; -+} -+ -+void Network::setName( const QString& name ) -+{ -+ m_name = name; -+} -+ -+QString Network::name() -+{ -+ return m_name; -+} -+ -+QString Network::service() -+{ -+ return m_service; -+} -+ -+void Network::setService( const QString& service ) -+{ -+ m_service = service; -+} -+ -+// vim: sw=4 ts=4 -Index: networkstatus/.svn/text-base/network.h.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/network.h.svn-base -@@ -0,0 +1,60 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef NETWORKSTATUS_NETWORK_H -+#define NETWORKSTATUS_NETWORK_H -+ -+#include "networkstatuscommon.h" -+ -+class Network -+{ -+public: -+ Network( const QString name ); -+ Network( NetworkStatus::Properties properties ); -+ /** -+ * Update the status of this network -+ */ -+ void setStatus( NetworkStatus::Status status ); -+ /** -+ * The connection status of this network -+ */ -+ NetworkStatus::Status status(); -+ /** -+ * The name of this network -+ */ -+ QString name(); -+ void setName( const QString& name ); -+ /** -+ * Returns the service owning this network -+ */ -+ QString service(); -+ void setService( const QString& service ); -+ -+private: -+ Network( const Network & ); -+ QString m_name; -+ NetworkStatus::Status m_status; -+ QString m_service; -+}; -+ -+#endif -+// vim: sw=4 ts=4 -Index: networkstatus/.svn/text-base/networkstatuscommon.cpp.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/networkstatuscommon.cpp.svn-base -@@ -0,0 +1,76 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#include "networkstatuscommon.h" -+ -+QDataStream & operator<< ( QDataStream & s, const NetworkStatus::Properties p ) -+{ -+ s << p.name; -+ s << (int)p.status; -+ s << p.service; -+ return s; -+} -+ -+QDataStream & operator>> ( QDataStream & s, NetworkStatus::Properties &p ) -+{ -+ int status; -+ s >> p.name; -+ s >> status; -+ p.status = (NetworkStatus::Status)status; -+ s >> p.service; -+ return s; -+} -+ -+namespace NetworkStatus -+{ -+ QString toString( NetworkStatus::Status st ) -+ { -+ QString str; -+ switch ( st ) { -+ case NetworkStatus::NoNetworks: -+ str = "NoNetworks"; -+ break; -+ case NetworkStatus::Unreachable: -+ str = "Unreachable"; -+ break; -+ case NetworkStatus::OfflineDisconnected: -+ str = "OfflineDisconnected"; -+ break; -+ case NetworkStatus::OfflineFailed: -+ str = "OfflineFailed"; -+ break; -+ case NetworkStatus::ShuttingDown: -+ str = "ShuttingDown"; -+ break; -+ case NetworkStatus::Offline: -+ str = "Offline"; -+ break; -+ case NetworkStatus::Establishing: -+ str = "Establishing"; -+ break; -+ case NetworkStatus::Online: -+ str = "Online"; -+ break; -+ } -+ return str; -+ } -+} // namespace NetworkStatus -Index: networkstatus/.svn/text-base/networkstatuscommon.h.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/networkstatuscommon.h.svn-base -@@ -0,0 +1,52 @@ -+/* This file is part of kdepim -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef NETWORKSTATUS_COMMON_H -+#define NETWORKSTATUS_COMMON_H -+ -+#include -+ -+namespace NetworkStatus -+{ -+ enum Status { NoNetworks = 1, Unreachable, OfflineDisconnected, OfflineFailed, ShuttingDown, Offline, Establishing, Online }; -+ enum RequestResult { RequestAccepted = 1, Connected, UserRefused, Unavailable }; -+ enum UnusedDemandPolicy { All, User, None, Permanent }; -+ -+ // BINARY COMPATIBILITY ALERT BEGIN !!!! -+ struct Properties -+ { -+ QString name; -+ Status status; -+ UnusedDemandPolicy unused1; -+ QCString service; -+ bool unused3; -+ QStringList unused4; -+ }; -+ // BINARY COMPATIBILITY ALERT END !!!! -+ -+ QString toString( Status st ); -+} -+ -+QDataStream & operator>> ( QDataStream & s, NetworkStatus::Properties &p ); -+QDataStream & operator<< ( QDataStream & s, const NetworkStatus::Properties p ); -+ -+#endif -Index: networkstatus/.svn/text-base/networkstatus.cpp.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/networkstatus.cpp.svn-base -@@ -0,0 +1,162 @@ -+/* This file is part of kdepim -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#include "networkstatus.h" -+ -+#include -+ -+#include -+#include -+#include -+ -+#include "network.h" -+#include -+ -+extern "C" { -+ KDE_EXPORT KDEDModule* create_networkstatus( const QCString& obj ) -+ { -+ return new NetworkStatusModule( obj ); -+ } -+} -+ -+// INTERNALLY USED STRUCTS AND TYPEDEFS -+ -+typedef QMap< QString, Network * > NetworkMap; -+ -+class NetworkStatusModule::Private -+{ -+public: -+ NetworkMap networks; -+ NetworkStatus::Status status; -+}; -+ -+// CTORS/DTORS -+ -+NetworkStatusModule::NetworkStatusModule( const QCString & obj ) : KDEDModule( obj ), d( new Private ) -+{ -+ d->status = NetworkStatus::NoNetworks; -+ connect( kapp->dcopClient(), SIGNAL( applicationRemoved( const QCString& ) ) , this, SLOT( unregisteredFromDCOP( const QCString& ) ) ); -+ // connect( kapp->dcopClient(), SIGNAL( applicationRegistered( const QCString& ) ) , this, SLOT( registeredToDCOP( const QCString& ) ) ); -+} -+ -+NetworkStatusModule::~NetworkStatusModule() -+{ -+ NetworkMap::ConstIterator it; -+ const NetworkMap::ConstIterator end = d->networks.end(); -+ -+ for ( it = d->networks.begin(); it != end; ++it ) { -+ delete ( *it ); -+ } -+ -+ delete d; -+} -+ -+// CLIENT INTERFACE -+ -+QStringList NetworkStatusModule::networks() -+{ -+ kdDebug() << k_funcinfo << " contains " << d->networks.count() << " networks" << endl; -+ return d->networks.keys(); -+} -+ -+int NetworkStatusModule::status() -+{ -+ kdDebug() << k_funcinfo << " status: " << (int)d->status << endl; -+ return (int)d->status; -+} -+ -+//protected: -+ -+void NetworkStatusModule::updateStatus() -+{ -+ NetworkStatus::Status bestStatus = NetworkStatus::NoNetworks; -+ const NetworkStatus::Status oldStatus = d->status; -+ -+ NetworkMap::ConstIterator it; -+ const NetworkMap::ConstIterator end = d->networks.end(); -+ for ( it = d->networks.begin(); it != end; ++it ) { -+ if ( ( *it )->status() > bestStatus ) -+ bestStatus = ( *it )->status(); -+ } -+ d->status = bestStatus; -+ -+ if ( oldStatus != d->status ) { -+ statusChange( (int)d->status ); -+ } -+} -+ -+void NetworkStatusModule::unregisteredFromDCOP( const QCString & appId ) -+{ -+ // unregister and delete any networks owned by a service that has just unregistered -+ NetworkMap::Iterator it; -+ const NetworkMap::Iterator end = d->networks.end(); -+ for ( it = d->networks.begin(); it != end; ++it ) -+ { -+ if ( ( *it )->service() == QString( appId ) ) -+ { -+ NetworkMap::Iterator toRemove = it; -+ Network * removedNet = *toRemove; -+ d->networks.remove( toRemove ); -+ updateStatus(); -+ delete removedNet; -+ } -+ } -+} -+ -+// SERVICE INTERFACE // -+void NetworkStatusModule::setNetworkStatus( const QString & networkName, int st ) -+{ -+ kdDebug() << k_funcinfo << networkName << ", " << st << endl; -+ NetworkStatus::Status changedStatus = (NetworkStatus::Status)st; -+ Network * net = 0; -+ NetworkMap::Iterator it = d->networks.find( networkName ); -+ if ( it != d->networks.end() ) { -+ net = (*it); -+ net->setStatus( changedStatus ); -+ updateStatus(); -+ } -+ else -+ kdDebug() << " No network named '" << networkName << "' found." << endl; -+} -+ -+void NetworkStatusModule::registerNetwork( const NetworkStatus::Properties properties ) -+{ -+ kdDebug() << k_funcinfo << properties.name << ", with status " << properties.status << endl; -+ -+ d->networks.insert( properties.name, new Network( properties ) ); -+ updateStatus(); -+} -+ -+void NetworkStatusModule::unregisterNetwork( const QString & networkName ) -+{ -+ kdDebug() << k_funcinfo << networkName << endl; -+ -+ NetworkMap::Iterator it = d->networks.find( networkName ); -+ if ( it != d->networks.end() ) { -+ delete *it; -+ d->networks.remove( it ); -+ } -+ updateStatus(); -+} -+ -+#include "networkstatus.moc" -+// vim: set noet sw=4 ts=4: -Index: networkstatus/.svn/text-base/networkstatus.desktop.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/networkstatus.desktop.svn-base -@@ -0,0 +1,98 @@ -+[Desktop Entry] -+Encoding=UTF-8 -+Name=Network Status Daemon -+Name[af]=Netwerk status bediener -+Name[ar]=مراقب القرص و التنفيذ لحالة الشبكة -+Name[bg]=Демон за състояние на мрежата -+Name[ca]=Dimoni de l'estat de la xarxa -+Name[cs]=Démon stavu sítě -+Name[da]=Netværkstatusdæmon -+Name[de]=Überwachung des Netzwerkstatus -+Name[el]=Δαίμονας κατάστασης δικτύου -+Name[es]=Daemon de estado de la red -+Name[et]=Võrguoleku deemon -+Name[eu]=Sarearen egoera deabrua -+Name[fa]=شبح وضعیت شبکه -+Name[fi]=Verkkotilan tarkkailija -+Name[fr]=Suivi de l'état du réseau -+Name[fy]=Netwurktastândaemon -+Name[gl]=Daemon do Estado da Rede -+Name[hu]=Hálózati állapotjelző szolgáltatás -+Name[is]=Netstöðupúki -+Name[it]=Demone dello stato della rete -+Name[ja]=ネットワークステータスデーモン -+Name[kk]=Желі күйінің қызметі -+Name[km]=ដេមិន​ស្ថានភាព​បណ្ដាញ -+Name[lt]=Tinklo statuso tarnyba -+Name[mk]=Даемон за мрежен статус -+Name[ms]=Daemon Berstatus Rangkaian -+Name[nb]=Statusnisse for nettverket -+Name[nds]=Nettwarkstatus-Dämoon -+Name[ne]=सञ्जाल स्थिति डेइमन -+Name[nl]=Netwerkstatusdaemon -+Name[nn]=Statusnisse for nettverket -+Name[pl]=Usługa stanu sieci -+Name[pt]=Servidor de Estado de Rede -+Name[pt_BR]=Daemon de Status da Rede -+Name[ru]=Служба состояния сети -+Name[sk]=Daemon stavu siete -+Name[sl]=Demon za omrežno stanje -+Name[sr]=Демон за статус мреже -+Name[sr@Latn]=Demon za status mreže -+Name[sv]=Nätverksstatusdemon -+Name[ta]=வலைப்பின்னல் நிலை டெமான் -+Name[tr]=Ağ Durum İzleyici -+Name[uk]=Демон стану мережі -+Name[zh_CN]=网络状态守护程序 -+Name[zh_TW]=網路狀態守護程式 -+Comment=Tracks status of network interfaces and provides notification to applications using the network. -+Comment[af]=Hou tred van die status van netwerk intervlakke en verskaf kennisgewings na programme wat die netwerk gebruik. -+Comment[bg]=Следене на състоянието на мрежата и предаване на информацията на програмите, които имат нужда -+Comment[ca]=Controla l'estat de les interfícies de xarxa i proporciona notificacions a les aplicacions que usen la xarxa. -+Comment[cs]=Zjiš'tuje stav síťových rozhraní a upozorňuje v případě přístupu aplikací k síti. -+Comment[da]=Sporer status af netværksgrænseflade og sørger for meddelelser til programmer der bruger netværket. -+Comment[de]=Überprüft den Netzwerk-Status und benachrichtigt anfragende Anwendungen -+Comment[el]=Παρακολουθεί την κατάσταση του δικτύου και παρέχει ειδοποιήσεις σε εφαρμογές που χρησιμοποιούν το δίκτυο. -+Comment[es]=Sigue la pista de las interfaces de red y proporciona notificaciones a las aplicaciones que están usando la red. -+Comment[et]=Jälgib võrguliideste olekut ja annab sellest võrgu vahendusel rakendustele teada. -+Comment[eu]=Sare interfazeen egoera jarraitzen du eta sarea darabilten aplikazioei jakinarazten die. -+Comment[fa]=وضعیت واسطهای شبکه را شیار داده و با استفاده از شبکه، برای کاربردها اخطار فراهم می‌کند. -+Comment[fi]=Tarkkailee verkkoliitäntöjen tilaa ja varoittaa verkkoa käyttäviä sovelluksia. -+Comment[fr]=Surveille l'état des interfaces réseaux et fournit des notifications aux applications qui utilisent le réseau -+Comment[fy]=Hâldt de tastân by fan de Netwurkynterfaces en hâldt dêr de tapassings fan op de hichte. -+Comment[gl]=Monitoriza o estado das interfaces de rede e fornece notificacións ás aplicacións que usen a rede. -+Comment[hu]=Figyeli a hálózati csatolók állapotát és értesítési lehetőséget biztosít hálózati alkalmazások számára. -+Comment[is]=Fylgist með stöðu netkorta og sendir tilkynningar til forrita sem nota netið. -+Comment[it]=Controlla lo stato delle interfacce di rete e fornisce notifiche alle applicazioni che usano al rete. -+Comment[ja]=ネットワークインターフェースの状態を追跡し、ネットワークを用いるアプリケーションに通知します -+Comment[kk]=Желі интерфейстерінің күйін бақылап, желіні қолданатын бағдарламаларын құлақтандыру қызметі. -+Comment[km]=តាមដាន​ស្ថានភាព​របស់​ចំណុច​ប្រទាក់​បណ្ដាញ ព្រម​ទាំង​ផ្ដល់​នូវ​ការ​ជូនដំណឹង​ទៅ​កម្មវិធី ដែល​ប្រើ​បណ្ដាញ ។ -+Comment[lt]=Seka tinklo sąsajų būseną ir informuoja apie jas programas, naudojančias tinklą -+Comment[mk]=Го следи статусот на мрежните интерфејси и дава известувања на апликациите што ја користат мрежата. -+Comment[ms]=Menjejak status antara muka rangkaian dan memberitahu aplikasi yang menggunakan rangkaian tersebut. -+Comment[nb]=Overvåker status for nettverksgrensesnitt og varsler programmer som bruker nettverket. -+Comment[nds]=Överwacht den Tostand vun Nettwark-Koppelsteden un sendt Narichten na Programmen, de dat Nettwark bruukt. -+Comment[ne]=सञ्जाल इन्टरफेसको स्थिति ट्र्याक गर्दछ र सञ्जाल प्रयोग गरेर अनुप्रयोगमा जानकारी उपलब्ध गराउछ । -+Comment[nl]=Houdt de status bij van de netwerkinterfaces en houdt daar de toepassingen van op de hoogte. -+Comment[nn]=Overvakar status for nettverksgrensesnitt og varslar program som brukar nettverket. -+Comment[pl]=Śledzi stan interfejsów sieciowych i powiadamia programy używające sieci. -+Comment[pt]=Vigia o estado das interfaces de rede e avisa as aplicações que utilizam a rede. -+Comment[pt_BR]=Controla o status das interfaces de rede e fornece notificações para aplicativos utilizando a rede. -+Comment[ru]=Служба отслеживания состояния сетевых интерфейсов и обращения приложений к сети. -+Comment[sk]=Sleduje stav sieťových rozhraní a poskytuje upozornenia aplikáciám používajúcim sieť. -+Comment[sl]=Sledi stanju omrežnim vmesnikom in omogoča obvestila programom, ki uporabljajo omrežje -+Comment[sr]=Прати статус мрежних интерфејса и пружа обавештења програмима који користе мрежу. -+Comment[sr@Latn]=Prati status mrežnih interfejsa i pruža obaveštenja programima koji koriste mrežu. -+Comment[sv]=Bevakar status för nätverksgränssnitt och tillhandahåller underrättelser till program som använder nätverket. -+Comment[ta]=வலைப்பின்னலைப் பயன்படுத்தி வலைப்பின்னல் இடைமுகங்களின் நிலையை கண்காணிக்கிறது மற்றும் பயன்பாடுகளுக்கு அறிவிப்பை வழங்குகிறது. -+Comment[uk]=Слідкує за станом інтерфейсів мережі і сповіщає програми, які користуються мережею. -+Comment[zh_CN]=跟踪网卡的状态并为应用程序提供使用网络的通知。 -+Comment[zh_TW]=追蹤網路介面的狀態,並提供使用網路的應用程式的通知。 -+Type=Service -+ServiceTypes=KDEDModule -+X-KDE-ModuleType=Library -+X-KDE-Library=networkstatus -+X-KDE-FactoryName=networkstatus -+X-KDE-Kded-autoload=true -+X-KDE-Kded-load-on-demand=true -+ -Index: networkstatus/.svn/text-base/networkstatus.h.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/networkstatus.h.svn-base -@@ -0,0 +1,66 @@ -+/* This file is part of kdepim -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef KDED_NETWORKSTATUS_H -+#define KDED_NETWORKSTATUS_H -+ -+#include -+ -+#include "networkstatuscommon.h" -+#include "network.h" -+ -+class NetworkStatusModule : virtual public KDEDModule -+{ -+Q_OBJECT -+K_DCOP -+public: -+ NetworkStatusModule( const QCString& obj ); -+ ~NetworkStatusModule(); -+k_dcop: -+ // Client interface -+ QStringList networks(); -+ int status(); -+ // Service interface -+ void setNetworkStatus( const QString & networkName, int status ); -+ void registerNetwork( NetworkStatus::Properties properties ); -+ void unregisterNetwork( const QString & networkName ); -+k_dcop_signals: -+ /** -+ * A status change occurred affecting the overall connectivity -+ * @param status The new status -+ */ -+ void statusChange( int status ); -+protected slots: -+ //void registeredToDCOP( const QCString& appId ); -+ void unregisteredFromDCOP( const QCString& appId ); -+ -+protected: -+ // recalculate cached status -+ void updateStatus(); -+ -+private: -+ class Private; -+ Private *d; -+}; -+ -+#endif -+// vim: sw=4 ts=4 -Index: networkstatus/.svn/text-base/networkstatusiface.h.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/networkstatusiface.h.svn-base -@@ -0,0 +1,50 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef KDED_NETWORKSTATUSIFACE_H -+#define KDED_NETWORKSTATUSIFACE_H -+ -+#include -+#include -+ -+#include "networkstatuscommon.h" -+ -+class NetworkStatusIface : virtual public DCOPObject -+{ -+K_DCOP -+k_dcop: -+ // Client interface -+ virtual QStringList networks() = 0; -+ virtual int status() = 0; -+ // Service interface -+ virtual void setNetworkStatus( const QString & networkName, int status ) = 0; -+ virtual void registerNetwork( NetworkStatus::Properties properties ) = 0; -+ virtual void unregisterNetwork( const QString & networkName ) = 0 ; -+k_dcop_signals: -+ /** -+ * A status change occurred affecting the overall connectivity -+ * @param status The new status -+ */ -+ virtual void statusChange( int status ) = 0; -+}; -+#endif -+// vim: sw=4 ts=4 -Index: networkstatus/.svn/text-base/networkstatusindicator.cpp.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/networkstatusindicator.cpp.svn-base -@@ -0,0 +1,64 @@ -+/* This file is part of the KDE project -+ Copyright (C) 2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#include -+#include -+#include -+#include -+ -+#include "connectionmanager.h" -+ -+#include "networkstatusindicator.h" -+ -+StatusBarNetworkStatusIndicator::StatusBarNetworkStatusIndicator( -+ QWidget * parent, const char * name ) : QHBox( parent, name )/*, d( new StatusBarNetworkStatusIndicatorPrivate )*/ -+{ -+ setMargin( 2 ); -+ setSpacing( 1 ); -+ QLabel * label = new QLabel( this, "offlinemodelabel" ); -+ label->setPixmap( SmallIcon("connect_no") ); -+ QToolTip::add( label, i18n( "The desktop is offline" ) ); -+ -+ connect( ConnectionManager::self(), SIGNAL( statusChanged( NetworkStatus::Status ) ), -+ SLOT( networkStatusChanged( NetworkStatus::Status) ) ); -+ -+} -+ -+void StatusBarNetworkStatusIndicator::init() -+{ -+ networkStatusChanged( ConnectionManager::self()->status()); -+} -+ -+StatusBarNetworkStatusIndicator::~StatusBarNetworkStatusIndicator() -+{ -+} -+ -+void StatusBarNetworkStatusIndicator::networkStatusChanged( NetworkStatus::Status status ) -+{ -+ if ( status == NetworkStatus::Online || status == NetworkStatus::NoNetworks ) { -+ hide(); -+ } else { -+ show(); -+ } -+} -+ -+#include "networkstatusindicator.moc" -Index: networkstatus/.svn/text-base/networkstatusindicator.h.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/networkstatusindicator.h.svn-base -@@ -0,0 +1,42 @@ -+/* This file is part of the KDE project -+ Copyright (C) 2007 Will Stephenson -+ -+ This library is free software; you can redistribute it and/or -+ modify it under the terms of the GNU Library General Public -+ License version 2 as published by the Free Software Foundation. -+ -+ 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. If not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this library -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef KDE_NETWORKSTATUS_INDICATOR_H -+#define KDE_NETWORKSTATUS_INDICATOR_H -+ -+#include -+#include -+#include -+ -+class StatusBarNetworkStatusIndicator : public QHBox -+{ -+Q_OBJECT -+public: -+ StatusBarNetworkStatusIndicator( QWidget * parent, const char * name ); -+ virtual ~StatusBarNetworkStatusIndicator(); -+ void init(); -+protected slots: -+ void networkStatusChanged( NetworkStatus::Status status ); -+}; -+ -+#endif -+ -Index: networkstatus/.svn/text-base/networkstatus.kdevelop.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/networkstatus.kdevelop.svn-base -@@ -0,0 +1,108 @@ -+ -+ -+ -+ Will Stephenson -+ wstephenson@suse.de -+ $VERSION$ -+ KDevKDEAutoProject -+ C++ -+ -+ Qt -+ KDE -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ false -+ false -+ -+ -+ *.o,*.lo,CVS -+ false -+ -+ -+ -+ -+ ada -+ ada_bugs_gcc -+ bash -+ bash_bugs -+ clanlib -+ fortran_bugs_gcc -+ gnome1 -+ gnustep -+ gtk -+ gtk_bugs -+ haskell -+ haskell_bugs_ghc -+ java_bugs_gcc -+ java_bugs_sun -+ opengl -+ pascal_bugs_fp -+ php -+ php_bugs -+ perl -+ perl_bugs -+ python -+ python_bugs -+ ruby -+ ruby_bugs -+ sdl -+ stl -+ sw -+ w3c-dom-level2-html -+ w3c-svg -+ w3c-uaag10 -+ wxwidgets_bugs -+ -+ -+ qmake User Guide -+ -+ -+ -+ -+ libtool -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ executable -+ -+ -+ kded_networkstatus.la -+ -+ -+ -+ -+ -+ true -+ true -+ true -+ false -+ true -+ true -+ true -+ 250 -+ 400 -+ 250 -+ -+ -+ -Index: networkstatus/.svn/text-base/README.statetransition.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/README.statetransition.svn-base -@@ -0,0 +1,29 @@ -+This table defines the actions to be taken on state transition. -+ -+TODO: potentially add extra states OnlineReading and OnlineWriting -+ -+ NEW -+ |Offline | Online | -+---+---+----------------+---------------+ -+ | | |N|set online | -+ | | |L|reload | -+ | O | |C|resources | -+ | F | +---------------+ -+ | F | |L|set online | -+O | | |C|reload res. | -+L | | | |write res. | -+D +---+----------------+---------------+ -+ | |N|set offline | | -+ | |C| | | -+ | | | | | -+ | O +---------------+| | -+ | N |U|set offline | | -+ | |W|write locally | | -+ | |C|(subject to | | -+ | | | save policy)| | -+---+---+----------------+---------------+ -+LC = Local changes exist -+NLC = No local changes exist -+UWC = Unsaved changes exist -+NC = no changes exist -+ -Index: networkstatus/.svn/text-base/testclient2.cpp.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/testclient2.cpp.svn-base -@@ -0,0 +1,222 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2007 Will Stephenson -+ -+ This program is free software; you can redistribute it and/or modify -+ it under the terms of the GNU General Public License version 2 -+ as published by the Free Software Foundation. -+ -+ This program is distributed in the hope that it will be useful, -+ but WITHOUT ANY WARRANTY; without even the implied warranty of -+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+ GNU General Public License for more details. -+ -+ You should have received a copy of the GNU General Public License -+ along with this program; if not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this program -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#include -+#include -+#include -+ -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+ -+#include -+#include -+ -+#include "testclientview.h" -+#include "testclient2.h" -+ -+TestClient::TestClient() -+ : KMainWindow( 0, "ktestnetworkstatus" ), -+ m_layout( new QVBox( 0, "layout" ) ), -+ m_status( AppDisconnected ) -+{ -+ m_view = new TestClientView( this ); -+ new StatusBarNetworkStatusIndicator( m_view, "statusindicator" ); -+ // tell the KMainWindow that this is indeed the main widget -+ setCentralWidget(m_view); -+ -+ networkStatusChanged( ConnectionManager::self()->status() ); -+ appDisconnected(); -+ -+ connect( ConnectionManager::self(), SIGNAL( statusChanged( NetworkStatus::Status ) ), SLOT( networkStatusChanged( NetworkStatus::Status ) ) ); -+ ConnectionManager::self()->registerConnectSlot( this, SLOT( doConnect() ) ); -+ ConnectionManager::self()->registerDisconnectSlot( this, SLOT( doDisconnect() ) ); -+ -+ connect( m_view->connectButton, SIGNAL( clicked() ), SLOT( connectButtonClicked() ) ); -+} -+ -+TestClient::~TestClient() -+{ -+} -+ -+void TestClient::networkStatusChanged( NetworkStatus::Status status ) -+{ -+ kdDebug() << k_funcinfo << endl; -+ kdDebug() << "Networking is now: " << NetworkStatus::toString( status ) << " (" << status << ")" << endl; -+ m_view->netStatusLabel->setText( NetworkStatus::toString( status ) ); -+ m_view->netStatusLabel->setPaletteBackgroundColor( toQColor( status ) ); -+} -+ -+void TestClient::doConnect() -+{ -+ Q_ASSERT( ConnectionManager::self()->status() == NetworkStatus::Online ); -+ if ( m_status != AppConnected ) { -+ appIsConnected(); -+ } -+} -+ -+void TestClient::doDisconnect() -+{ -+ Q_ASSERT( ConnectionManager::self()->status() != NetworkStatus::Online ); -+ if ( m_status == AppConnected ) { -+ appDisconnected(); -+ } -+} -+ -+void TestClient::connectButtonClicked() -+{ -+ kdDebug() << k_funcinfo << endl; -+ if ( m_status == AppDisconnected ) { -+ switch ( ConnectionManager::self()->status() ) -+ { -+ case NetworkStatus::NoNetworks: -+ case NetworkStatus::Online: -+ appIsConnected(); -+ break; -+ default: -+ appWaiting(); -+ break; -+ } -+ } -+ else if ( m_status == AppConnected || m_status == AppWaitingForConnect ) { -+ appDisconnected(); -+ } -+} -+ -+void TestClient::appWaiting() -+{ -+ kdDebug() << k_funcinfo << endl; -+ //m_status = AppWaitingForConnect; -+ m_view->appStatusLabel->setText( "Waiting" ); -+} -+ -+void TestClient::appIsConnected() -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_view->connectButton->setEnabled( true ); -+ m_view->connectButton->setText( "Disconnect" ); -+ m_view->appStatusLabel->setText( "Connected" ); -+ m_status = AppConnected; -+} -+ -+void TestClient::appEstablishing() -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_view->netStatusLabel->setText( "Establishing" ); -+ m_view->connectButton->setEnabled( false ); -+} -+ -+void TestClient::appDisestablishing( ) -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_view->connectButton->setEnabled( false ); -+ m_view->appStatusLabel->setText( "Disconnected" ); -+} -+ -+void TestClient::appDisconnected( ) -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_view->connectButton->setEnabled( true ); -+ m_view->connectButton->setText( "Start Connect" ); -+ m_view->appStatusLabel->setText( "Disconnected" ); -+ m_status = AppDisconnected; -+} -+ -+QColor TestClient::toQColor( NetworkStatus::Status st ) -+{ -+ QColor col; -+ switch ( st ) { -+ case NetworkStatus::NoNetworks: -+ col = Qt::darkGray; -+ break; -+ case NetworkStatus::Unreachable: -+ col = Qt::darkMagenta; -+ break; -+ case NetworkStatus::OfflineDisconnected: -+ col = Qt::blue; -+ break; -+ case NetworkStatus::OfflineFailed: -+ col = Qt::darkRed; -+ break; -+ case NetworkStatus::ShuttingDown: -+ col = Qt::darkYellow; -+ break; -+ case NetworkStatus::Offline: -+ col = Qt::blue; -+ break; -+ case NetworkStatus::Establishing: -+ col = Qt::yellow; -+ break; -+ case NetworkStatus::Online: -+ col = Qt::green; -+ break; -+ } -+ return col; -+} -+//main -+static const char description[] = -+ I18N_NOOP("Test Client for Network Status kded module"); -+ -+static const char version[] = "v0.1"; -+ -+static KCmdLineOptions options[] = -+{ -+ KCmdLineLastOption -+}; -+ -+int main(int argc, char **argv) -+{ -+ KAboutData about("KNetworkStatusTestClient", I18N_NOOP("knetworkstatustestclient"), version, description, KAboutData::License_GPL, "(C) 2007 Will Stephenson", 0, 0, "wstephenson@kde.org"); -+ about.addAuthor( "Will Stephenson", 0, "wstephenson@kde.org" ); -+ KCmdLineArgs::init(argc, argv, &about); -+ KCmdLineArgs::addCmdLineOptions(options); -+ KApplication app; -+ -+ // register ourselves as a dcop client -+ app.dcopClient()->registerAs(app.name(), false); -+ -+ KCmdLineArgs *args = KCmdLineArgs::parsedArgs(); -+ if (args->count() == 0) -+ { -+ TestClient *widget = new TestClient; -+ widget->show(); -+ } -+ else -+ { -+ int i = 0; -+ for (; i < args->count(); i++) -+ { -+ TestClient *widget = new TestClient; -+ widget->show(); -+ } -+ } -+ args->clear(); -+ -+ return app.exec(); -+} -+ -+#include "testclient2.moc" -+ -Index: networkstatus/.svn/text-base/testclient2.h.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/testclient2.h.svn-base -@@ -0,0 +1,82 @@ -+/* This file is part of kdepim. -+ -+ Copyright (C) 2007 Will Stephenson -+ -+ This program is free software; you can redistribute it and/or modify -+ it under the terms of the GNU General Public License as published by -+ the Free Software Foundation; either version 2 of the License, or -+ (at your option) any later version. -+ -+ This program is distributed in the hope that it will be useful, -+ but WITHOUT ANY WARRANTY; without even the implied warranty of -+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+ GNU General Public License for more details. -+ -+ You should have received a copy of the GNU General Public License -+ along with this program; if not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this program -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef KTESTNETWORKSTATUS_H -+#define KTESTNETWORKSTATUS_H -+ -+#ifdef HAVE_CONFIG_H -+#include -+#endif -+ -+#include -+#include -+#include -+#include -+ -+#include "networkstatusiface_stub.h" -+ -+class TestClientView; -+ -+/** -+ * Test client that uses a ConnectionManager to change its state -+ * -+ * @short Main window class -+ * @author Will Stephenson -+ * @version 0.1 -+ */ -+class TestClient : public KMainWindow -+{ -+Q_OBJECT -+public: -+ enum AppStatus{ AppDisconnected, AppWaitingForConnect, AppConnected }; -+ /** -+ * Default Constructor -+ */ -+ TestClient(); -+ -+ /** -+ * Default Destructor -+ */ -+ virtual ~TestClient(); -+ -+private slots: -+ void networkStatusChanged( NetworkStatus::Status status ); -+ void connectButtonClicked(); -+ void doConnect(); -+ void doDisconnect(); -+private: -+ void appWaiting(); -+ void appEstablishing(); -+ void appIsConnected(); -+ void appDisestablishing(); -+ void appDisconnected(); -+ static QColor toQColor( NetworkStatus::Status ); -+private: -+ QHBox * m_layout; -+ NetworkStatusIface_stub *m_service; -+ TestClientView *m_view; -+ AppStatus m_status; // this represents the app's status not the network's status -+}; -+ -+#endif // KTESTNETWORKSTATUS_H -+ -Index: networkstatus/.svn/text-base/testclient.cpp.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/testclient.cpp.svn-base -@@ -0,0 +1,234 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2007 Will Stephenson -+ -+ This program is free software; you can redistribute it and/or modify -+ it under the terms of the GNU General Public License version 2 -+ as published by the Free Software Foundation. -+ -+ This program is distributed in the hope that it will be useful, -+ but WITHOUT ANY WARRANTY; without even the implied warranty of -+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+ GNU General Public License for more details. -+ -+ You should have received a copy of the GNU General Public License -+ along with this program; if not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this program -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#include -+#include -+ -+ -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+ -+#include "connectionmanager.h" -+#include "testclientview.h" -+#include "testclient.h" -+ -+TestClient::TestClient() -+ : KMainWindow( 0, "ktestnetworkstatus" ), -+ m_view(new TestClientView(this)), -+ m_status( AppDisconnected ) -+{ -+ // tell the KMainWindow that this is indeed the main widget -+ setCentralWidget(m_view); -+ -+ networkStatusChanged( ConnectionManager::self()->status() ); -+ appDisconnected(); -+ -+ connect( ConnectionManager::self(), SIGNAL( statusChanged( NetworkStatus::Status ) ), SLOT( networkStatusChanged( NetworkStatus::Status ) ) ); -+ -+ connect( m_view->connectButton, SIGNAL( toggled( bool ) ), SLOT( connectButtonToggled( bool ) ) ); -+} -+ -+TestClient::~TestClient() -+{ -+} -+ -+void TestClient::networkStatusChanged( NetworkStatus::Status status ) -+{ -+ kdDebug() << k_funcinfo << endl; -+//enum EnumStatus { NoNetworks = 1, Unreachable, OfflineDisconnected, OfflineFailed, ShuttingDown -+// , Offline, Establishing, Online }; -+ kdDebug() << "Networking is now: " << NetworkStatus::toString( status ) << " (" << status << ")" << endl; -+ m_view->netStatusLabel->setText( NetworkStatus::toString( status ) ); -+ m_view->netStatusLabel->setPaletteBackgroundColor( toQColor( status ) ); -+ switch ( status ) { -+ case NetworkStatus::NoNetworks: -+ break; -+ case NetworkStatus::Unreachable: -+ break; -+ case NetworkStatus::OfflineDisconnected: -+ break; -+ case NetworkStatus::OfflineFailed: -+ break; -+ case NetworkStatus::ShuttingDown: -+ if ( m_status == AppConnected ) { -+ appDisestablishing(); -+ } -+ break; -+ case NetworkStatus::Offline: -+ if ( m_status == AppConnected ) { -+ appDisconnected(); -+ } -+ break; -+ case NetworkStatus::Establishing: -+ if ( m_status == AppWaitingForConnect ) -+ appEstablishing(); -+ else if ( m_status == AppConnected ) -+ appDisconnected(); -+ break; -+ case NetworkStatus::Online: -+ if ( m_status == AppWaitingForConnect ) -+ appIsConnected(); -+ break; -+ default: -+ m_view->netStatusLabel->setText( "Unrecognised status code!" ); -+ } -+} -+ -+void TestClient::connectButtonToggled( bool on ) -+{ -+ kdDebug() << k_funcinfo << endl; -+ if ( on && m_status == AppDisconnected ) { -+ switch ( ConnectionManager::self()->status() ) -+ { -+ case NetworkStatus::NoNetworks: -+ case NetworkStatus::Online: -+ appIsConnected(); -+ break; -+ default: -+ appWaiting(); -+ break; -+ } -+ } -+ else if ( !on && m_status == AppConnected ) { -+ appDisconnected(); -+ } -+} -+ -+void TestClient::appWaiting() -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_status = AppWaitingForConnect; -+ m_view->appStatusLabel->setText( "Waiting" ); -+} -+ -+void TestClient::appIsConnected() -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_view->connectButton->setEnabled( true ); -+ m_view->connectButton->setText( "Disconnect" ); -+ m_view->appStatusLabel->setText( "Connected" ); -+ m_status = AppConnected; -+} -+ -+void TestClient::appEstablishing() -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_view->netStatusLabel->setText( "Establishing" ); -+ m_view->connectButton->setEnabled( false ); -+} -+ -+void TestClient::appDisestablishing( ) -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_view->connectButton->setEnabled( false ); -+ m_view->appStatusLabel->setText( "Disconnected" ); -+} -+ -+void TestClient::appDisconnected( ) -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_view->connectButton->setEnabled( true ); -+ m_view->connectButton->setText( "Start Connect" ); -+ m_view->appStatusLabel->setText( "Disconnected" ); -+ m_status = AppDisconnected; -+} -+ -+QColor TestClient::toQColor( NetworkStatus::Status st ) -+{ -+ QColor col; -+ switch ( st ) { -+ case NetworkStatus::NoNetworks: -+ col = Qt::darkGray; -+ break; -+ case NetworkStatus::Unreachable: -+ col = Qt::darkMagenta; -+ break; -+ case NetworkStatus::OfflineDisconnected: -+ col = Qt::blue; -+ break; -+ case NetworkStatus::OfflineFailed: -+ col = Qt::darkRed; -+ break; -+ case NetworkStatus::ShuttingDown: -+ col = Qt::darkYellow; -+ break; -+ case NetworkStatus::Offline: -+ col = Qt::blue; -+ break; -+ case NetworkStatus::Establishing: -+ col = Qt::yellow; -+ break; -+ case NetworkStatus::Online: -+ col = Qt::green; -+ break; -+ } -+ return col; -+} -+//main -+static const char description[] = -+ I18N_NOOP("Test Client for Network Status kded module"); -+ -+static const char version[] = "v0.1"; -+ -+static KCmdLineOptions options[] = -+{ -+ KCmdLineLastOption -+}; -+ -+int main(int argc, char **argv) -+{ -+ KAboutData about("KNetworkStatusTestClient", I18N_NOOP("knetworkstatustestclient"), version, description, KAboutData::License_GPL, "(C) 2007 Will Stephenson", 0, 0, "wstephenson@kde.org"); -+ about.addAuthor( "Will Stephenson", 0, "wstephenson@kde.org" ); -+ KCmdLineArgs::init(argc, argv, &about); -+ KCmdLineArgs::addCmdLineOptions(options); -+ KApplication app; -+ -+ // register ourselves as a dcop client -+ app.dcopClient()->registerAs(app.name(), false); -+ -+ KCmdLineArgs *args = KCmdLineArgs::parsedArgs(); -+ if (args->count() == 0) -+ { -+ TestClient *widget = new TestClient; -+ widget->show(); -+ } -+ else -+ { -+ int i = 0; -+ for (; i < args->count(); i++) -+ { -+ TestClient *widget = new TestClient; -+ widget->show(); -+ } -+ } -+ args->clear(); -+ -+ return app.exec(); -+} -+ -+#include "testclient.moc" -+ -Index: networkstatus/.svn/text-base/testclient.h.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/testclient.h.svn-base -@@ -0,0 +1,80 @@ -+/* This file is part of kdepim. -+ -+ Copyright (C) 2007 Will Stephenson -+ -+ This program is free software; you can redistribute it and/or modify -+ it under the terms of the GNU General Public License as published by -+ the Free Software Foundation; either version 2 of the License, or -+ (at your option) any later version. -+ -+ This program is distributed in the hope that it will be useful, -+ but WITHOUT ANY WARRANTY; without even the implied warranty of -+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+ GNU General Public License for more details. -+ -+ You should have received a copy of the GNU General Public License -+ along with this program; if not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this program -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef KTESTNETWORKSTATUS_H -+#define KTESTNETWORKSTATUS_H -+ -+#ifdef HAVE_CONFIG_H -+#include -+#endif -+ -+#include -+#include -+#include -+#include -+ -+#include "networkstatusiface_stub.h" -+ -+class TestClientView; -+ -+/** -+ * This class serves as the main window for ktestnetworkstatus. It handles the -+ * menus, toolbars, and status bars. -+ * -+ * @short Main window class -+ * @author Will Stephenson -+ * @version 0.1 -+ */ -+class TestClient : public KMainWindow -+{ -+Q_OBJECT -+public: -+ enum AppStatus{ AppDisconnected, AppWaitingForConnect, AppConnected }; -+ /** -+ * Default Constructor -+ */ -+ TestClient(); -+ -+ /** -+ * Default Destructor -+ */ -+ virtual ~TestClient(); -+ -+private slots: -+ void networkStatusChanged( NetworkStatus::Status status ); -+ void connectButtonToggled( bool on ); -+private: -+ void appWaiting(); -+ void appEstablishing(); -+ void appIsConnected(); -+ void appDisestablishing(); -+ void appDisconnected(); -+ static QColor toQColor( NetworkStatus::Status ); -+private: -+ NetworkStatusIface_stub *m_service; -+ TestClientView *m_view; -+ AppStatus m_status; // this represents the app's status not the network's status -+}; -+ -+#endif // KTESTNETWORKSTATUS_H -+ -Index: networkstatus/.svn/text-base/testclientview.ui.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/testclientview.ui.svn-base -@@ -0,0 +1,177 @@ -+ -+TestClientView -+ -+ -+ TestClientView -+ -+ -+ -+ 0 -+ 0 -+ 356 -+ 127 -+ -+ -+ -+ Form1 -+ -+ -+ -+ unnamed -+ -+ -+ -+ textLabel4 -+ -+ -+ -+ 5 -+ 5 -+ 0 -+ 0 -+ -+ -+ -+ <font size="+2"><b>Client for KDE 3 Offline Mode</b></font> -+ -+ -+ AlignVCenter -+ -+ -+ -+ -+ layout1 -+ -+ -+ -+ unnamed -+ -+ -+ -+ textLabel1 -+ -+ -+ Network status: -+ -+ -+ -+ -+ netStatusLabel -+ -+ -+ -+ 0 -+ 255 -+ 0 -+ -+ -+ -+ Panel -+ -+ -+ STATUS -+ -+ -+ AlignCenter -+ -+ -+ -+ -+ -+ -+ layout1_2 -+ -+ -+ -+ unnamed -+ -+ -+ -+ textLabel1_2 -+ -+ -+ App status: -+ -+ -+ -+ -+ appStatusLabel -+ -+ -+ -+ 0 -+ 255 -+ 0 -+ -+ -+ -+ Panel -+ -+ -+ STATUS -+ -+ -+ AlignCenter -+ -+ -+ -+ -+ -+ -+ layout2 -+ -+ -+ -+ unnamed -+ -+ -+ -+ spacer1 -+ -+ -+ Horizontal -+ -+ -+ Expanding -+ -+ -+ -+ 31 -+ 20 -+ -+ -+ -+ -+ -+ connectButton -+ -+ -+ Start Connect -+ -+ -+ false -+ -+ -+ -+ -+ spacer2 -+ -+ -+ Horizontal -+ -+ -+ Expanding -+ -+ -+ -+ 61 -+ 20 -+ -+ -+ -+ -+ -+ -+ -+ -+ -Index: networkstatus/.svn/text-base/testservice.cpp.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/testservice.cpp.svn-base -@@ -0,0 +1,219 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This program is free software; you can redistribute it and/or modify -+ it under the terms of the GNU General Public License version 2 -+ as published by the Free Software Foundation. -+ -+ This program is distributed in the hope that it will be useful, -+ but WITHOUT ANY WARRANTY; without even the implied warranty of -+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+ GNU General Public License for more details. -+ -+ You should have received a copy of the GNU General Public License -+ along with this program; if not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this program -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#include -+#include -+#include -+#include -+ -+#include -+#include -+#include -+#include -+#include -+#include -+ -+#include "testservice.h" -+#include "testserviceview.h" -+#include "networkstatusiface_stub.h" -+ -+TestService::TestService() : KMainWindow( 0, "testservice" ), -+ m_service( new NetworkStatusIface_stub( "kded", "networkstatus" ) ), -+ m_status ( NetworkStatus::Offline ), -+ m_nextStatus( NetworkStatus::OfflineDisconnected ), -+ m_view( new TestServiceView( this ) ) -+{ -+ setCentralWidget( m_view ); -+ kapp->dcopClient()->registerAs("testservice" ); -+ -+ connect( m_view->changeCombo, SIGNAL( activated( int ) ), SLOT( changeComboActivated( int ) ) ); -+ connect( m_view->changeButton, SIGNAL( clicked() ), SLOT( changeButtonClicked() ) ); -+ -+ connect( kapp->dcopClient(), SIGNAL( applicationRegistered( const QCString& ) ), this, SLOT( registeredToDCOP( const QCString& ) ) ); -+ kapp->dcopClient()->setNotifications( true ); -+ -+ m_view->statusLabel->setText( NetworkStatus::toString( m_status ) ); -+ m_view->statusLabel->setPaletteBackgroundColor( toQColor( m_status ) ); -+ setCaption( NetworkStatus::toString( m_status ) ); -+ -+ registerService(); -+} -+ -+TestService::~TestService() -+{ -+ delete m_service; -+ delete m_view; -+} -+ -+void TestService::registerService() -+{ -+ NetworkStatus::Properties nsp; -+ nsp.name = "test_net"; -+ nsp.service = kapp->dcopClient()->appId(); -+ nsp.status = m_status; -+ m_service->registerNetwork( nsp ); -+} -+ -+void TestService::registeredToDCOP( const QCString & appId ) -+{ -+ if ( appId == "kded" ) -+ registerService(); -+} -+ -+int TestService::status( const QString & network ) -+{ -+ Q_UNUSED( network ); -+ return (int)m_status; -+} -+ -+void TestService::changeComboActivated( int index ) -+{ -+ switch ( index ) { -+ case 0 /*NetworkStatus::OfflineDisconnected*/: -+ m_nextStatus = NetworkStatus::OfflineDisconnected; -+ break; -+ case 1 /*NetworkStatus::OfflineFailed*/: -+ m_nextStatus = NetworkStatus::OfflineFailed; -+ break; -+ case 2 /*NetworkStatus::ShuttingDown*/: -+ m_nextStatus = NetworkStatus::ShuttingDown; -+ break; -+ case 3 /*NetworkStatus::Offline*/: -+ m_nextStatus = NetworkStatus::Offline; -+ break; -+ case 4 /*NetworkStatus::Establishing*/: -+ m_nextStatus = NetworkStatus::Establishing; -+ break; -+ case 5 /*NetworkStatus::Online*/: -+ m_nextStatus = NetworkStatus::Online; -+ break; -+ default: -+ kdDebug() << "Unrecognised status!" << endl; -+ Q_ASSERT( false ); -+ } -+ m_view->changeButton->setEnabled( true ); -+} -+ -+void TestService::changeButtonClicked() -+{ -+ m_view->changeButton->setEnabled( false ); -+ m_status = m_nextStatus; -+ m_service->setNetworkStatus( "test_net", ( int )m_status ); -+ m_view->statusLabel->setText( NetworkStatus::toString( m_status ) ); -+ m_view->statusLabel->setPaletteBackgroundColor( toQColor( m_status ) ); -+ setCaption( NetworkStatus::toString( m_status ) ); -+} -+ -+int TestService::establish( const QString & network ) -+{ -+ Q_UNUSED( network ); -+ m_status = NetworkStatus::Establishing; -+ m_service->setNetworkStatus( "test_net", (int)m_status ); -+ m_nextStatus = NetworkStatus::Online; -+ QTimer::singleShot( 5000, this, SLOT( slotStatusChange() ) ); -+ return (int)NetworkStatus::RequestAccepted; -+} -+ -+int TestService::shutdown( const QString & network ) -+{ -+ Q_UNUSED( network ); -+ m_status = NetworkStatus::ShuttingDown; -+ m_service->setNetworkStatus( "test_net", (int)m_status ); -+ m_nextStatus = NetworkStatus::Offline; -+ QTimer::singleShot( 5000, this, SLOT( slotStatusChange() ) ); -+ return (int)NetworkStatus::RequestAccepted; -+} -+ -+void TestService::simulateFailure() -+{ -+ m_status = NetworkStatus::OfflineFailed; -+ m_service->setNetworkStatus( "test_net", (int)m_status ); -+} -+ -+void TestService::simulateDisconnect() -+{ -+ m_status = NetworkStatus::OfflineDisconnected; -+ m_service->setNetworkStatus( "test_net", (int)m_status ); -+} -+ -+void TestService::slotStatusChange() -+{ -+ m_status = m_nextStatus; -+ m_service->setNetworkStatus( "test_net", (int)m_status ); -+} -+ -+QColor TestService::toQColor( NetworkStatus::Status st ) -+{ -+ QColor col; -+ switch ( st ) { -+ case NetworkStatus::NoNetworks: -+ col = Qt::darkGray; -+ break; -+ case NetworkStatus::Unreachable: -+ col = Qt::darkMagenta; -+ break; -+ case NetworkStatus::OfflineDisconnected: -+ col = Qt::blue; -+ break; -+ case NetworkStatus::OfflineFailed: -+ col = Qt::darkRed; -+ break; -+ case NetworkStatus::ShuttingDown: -+ col = Qt::darkYellow; -+ break; -+ case NetworkStatus::Offline: -+ col = Qt::blue; -+ break; -+ case NetworkStatus::Establishing: -+ col = Qt::yellow; -+ break; -+ case NetworkStatus::Online: -+ col = Qt::green; -+ break; -+ } -+ return col; -+} -+ -+static const char description[] = -+ I18N_NOOP("Test Service for Network Status kded module"); -+ -+static const char version[] = "v0.1"; -+ -+static KCmdLineOptions options[] = -+{ -+ KCmdLineLastOption -+}; -+ -+int main( int argc, char** argv ) -+{ -+ KAboutData about("KNetworkStatusTestService", I18N_NOOP("knetworkstatustestservice"), version, description, KAboutData::License_GPL, "(C) 2007 Will Stephenson", 0, 0, "wstephenson@kde.org"); -+ about.addAuthor( "Will Stephenson", 0, "wstephenson@kde.org" ); -+ KCmdLineArgs::init(argc, argv, &about); -+ KCmdLineArgs::addCmdLineOptions(options); -+ KApplication app; -+ -+ TestService * test = new TestService; -+ test->show(); -+ return app.exec(); -+} -+ -+#include "testservice.moc" -Index: networkstatus/.svn/text-base/testservice.h.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/testservice.h.svn-base -@@ -0,0 +1,60 @@ -+/* This file is part of kdepim. -+ -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This program is free software; you can redistribute it and/or modify -+ it under the terms of the GNU General Public License as published by -+ the Free Software Foundation; either version 2 of the License, or -+ (at your option) any later version. -+ -+ This program is distributed in the hope that it will be useful, -+ but WITHOUT ANY WARRANTY; without even the implied warranty of -+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+ GNU General Public License for more details. -+ -+ You should have received a copy of the GNU General Public License -+ along with this program; if not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this program -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef _TEST_NETWORKSTATUS_SERVICE_H -+#define _TEST_NETWORKSTATUS_SERVICE_H -+ -+#include -+ -+#include "networkstatuscommon.h" -+ -+class NetworkStatusIface_stub; -+class TestServiceView; -+ -+class TestService : public KMainWindow { -+Q_OBJECT -+public: -+ TestService(); -+ virtual ~TestService(); -+ int status( const QString & network ); -+ int establish( const QString & network ); -+ int shutdown( const QString & network ); -+ void simulateFailure(); -+ void simulateDisconnect(); -+protected slots: -+ void changeComboActivated( int index ); -+ void registeredToDCOP( const QCString& appId ); -+ -+ void changeButtonClicked(); -+ -+ void slotStatusChange(); -+private: -+ void registerService(); -+ static QColor toQColor( NetworkStatus::Status ); -+ NetworkStatusIface_stub * m_service; -+ NetworkStatus::Status m_status; -+ NetworkStatus::Status m_nextStatus; -+ TestServiceView * m_view; -+}; -+ -+#endif -Index: networkstatus/.svn/text-base/testserviceview.ui.svn-base -=================================================================== ---- /dev/null -+++ networkstatus/.svn/text-base/testserviceview.ui.svn-base -@@ -0,0 +1,181 @@ -+ -+TestServiceView -+ -+ -+ TestServiceView -+ -+ -+ -+ 0 -+ 0 -+ 367 -+ 132 -+ -+ -+ -+ Form1 -+ -+ -+ -+ unnamed -+ -+ -+ -+ textLabel4 -+ -+ -+ <font size="+2"><b>Service for KDE 3 Offline Mode</b></font> -+ -+ -+ AlignVCenter -+ -+ -+ -+ -+ layout2 -+ -+ -+ -+ unnamed -+ -+ -+ -+ textLabel1 -+ -+ -+ Status: -+ -+ -+ -+ -+ statusLabel -+ -+ -+ -+ 0 -+ 255 -+ 0 -+ -+ -+ -+ StyledPanel -+ -+ -+ STATUS -+ -+ -+ AlignCenter -+ -+ -+ -+ -+ -+ -+ layout3 -+ -+ -+ -+ unnamed -+ -+ -+ -+ textLabel3 -+ -+ -+ Change to: -+ -+ -+ -+ -+ -+ Offline Disconnected -+ -+ -+ -+ -+ Offline Failed -+ -+ -+ -+ -+ Shutting Down -+ -+ -+ -+ -+ Offline -+ -+ -+ -+ -+ Establishing -+ -+ -+ -+ -+ Online -+ -+ -+ -+ changeCombo -+ -+ -+ -+ -+ -+ -+ layout1 -+ -+ -+ -+ unnamed -+ -+ -+ -+ spacer1 -+ -+ -+ Horizontal -+ -+ -+ Expanding -+ -+ -+ -+ 51 -+ 20 -+ -+ -+ -+ -+ -+ changeButton -+ -+ -+ Do change -+ -+ -+ -+ -+ spacer2 -+ -+ -+ Horizontal -+ -+ -+ Expanding -+ -+ -+ -+ 41 -+ 20 -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -Index: networkstatus/testclient2.cpp -=================================================================== ---- /dev/null -+++ networkstatus/testclient2.cpp -@@ -0,0 +1,222 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2007 Will Stephenson -+ -+ This program is free software; you can redistribute it and/or modify -+ it under the terms of the GNU General Public License version 2 -+ as published by the Free Software Foundation. -+ -+ This program is distributed in the hope that it will be useful, -+ but WITHOUT ANY WARRANTY; without even the implied warranty of -+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+ GNU General Public License for more details. -+ -+ You should have received a copy of the GNU General Public License -+ along with this program; if not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this program -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#include -+#include -+#include -+ -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+ -+#include -+#include -+ -+#include "testclientview.h" -+#include "testclient2.h" -+ -+TestClient::TestClient() -+ : KMainWindow( 0, "ktestnetworkstatus" ), -+ m_layout( new QVBox( 0, "layout" ) ), -+ m_status( AppDisconnected ) -+{ -+ m_view = new TestClientView( this ); -+ new StatusBarNetworkStatusIndicator( m_view, "statusindicator" ); -+ // tell the KMainWindow that this is indeed the main widget -+ setCentralWidget(m_view); -+ -+ networkStatusChanged( ConnectionManager::self()->status() ); -+ appDisconnected(); -+ -+ connect( ConnectionManager::self(), SIGNAL( statusChanged( NetworkStatus::Status ) ), SLOT( networkStatusChanged( NetworkStatus::Status ) ) ); -+ ConnectionManager::self()->registerConnectSlot( this, SLOT( doConnect() ) ); -+ ConnectionManager::self()->registerDisconnectSlot( this, SLOT( doDisconnect() ) ); -+ -+ connect( m_view->connectButton, SIGNAL( clicked() ), SLOT( connectButtonClicked() ) ); -+} -+ -+TestClient::~TestClient() -+{ -+} -+ -+void TestClient::networkStatusChanged( NetworkStatus::Status status ) -+{ -+ kdDebug() << k_funcinfo << endl; -+ kdDebug() << "Networking is now: " << NetworkStatus::toString( status ) << " (" << status << ")" << endl; -+ m_view->netStatusLabel->setText( NetworkStatus::toString( status ) ); -+ m_view->netStatusLabel->setPaletteBackgroundColor( toQColor( status ) ); -+} -+ -+void TestClient::doConnect() -+{ -+ Q_ASSERT( ConnectionManager::self()->status() == NetworkStatus::Online ); -+ if ( m_status != AppConnected ) { -+ appIsConnected(); -+ } -+} -+ -+void TestClient::doDisconnect() -+{ -+ Q_ASSERT( ConnectionManager::self()->status() != NetworkStatus::Online ); -+ if ( m_status == AppConnected ) { -+ appDisconnected(); -+ } -+} -+ -+void TestClient::connectButtonClicked() -+{ -+ kdDebug() << k_funcinfo << endl; -+ if ( m_status == AppDisconnected ) { -+ switch ( ConnectionManager::self()->status() ) -+ { -+ case NetworkStatus::NoNetworks: -+ case NetworkStatus::Online: -+ appIsConnected(); -+ break; -+ default: -+ appWaiting(); -+ break; -+ } -+ } -+ else if ( m_status == AppConnected || m_status == AppWaitingForConnect ) { -+ appDisconnected(); -+ } -+} -+ -+void TestClient::appWaiting() -+{ -+ kdDebug() << k_funcinfo << endl; -+ //m_status = AppWaitingForConnect; -+ m_view->appStatusLabel->setText( "Waiting" ); -+} -+ -+void TestClient::appIsConnected() -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_view->connectButton->setEnabled( true ); -+ m_view->connectButton->setText( "Disconnect" ); -+ m_view->appStatusLabel->setText( "Connected" ); -+ m_status = AppConnected; -+} -+ -+void TestClient::appEstablishing() -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_view->netStatusLabel->setText( "Establishing" ); -+ m_view->connectButton->setEnabled( false ); -+} -+ -+void TestClient::appDisestablishing( ) -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_view->connectButton->setEnabled( false ); -+ m_view->appStatusLabel->setText( "Disconnected" ); -+} -+ -+void TestClient::appDisconnected( ) -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_view->connectButton->setEnabled( true ); -+ m_view->connectButton->setText( "Start Connect" ); -+ m_view->appStatusLabel->setText( "Disconnected" ); -+ m_status = AppDisconnected; -+} -+ -+QColor TestClient::toQColor( NetworkStatus::Status st ) -+{ -+ QColor col; -+ switch ( st ) { -+ case NetworkStatus::NoNetworks: -+ col = Qt::darkGray; -+ break; -+ case NetworkStatus::Unreachable: -+ col = Qt::darkMagenta; -+ break; -+ case NetworkStatus::OfflineDisconnected: -+ col = Qt::blue; -+ break; -+ case NetworkStatus::OfflineFailed: -+ col = Qt::darkRed; -+ break; -+ case NetworkStatus::ShuttingDown: -+ col = Qt::darkYellow; -+ break; -+ case NetworkStatus::Offline: -+ col = Qt::blue; -+ break; -+ case NetworkStatus::Establishing: -+ col = Qt::yellow; -+ break; -+ case NetworkStatus::Online: -+ col = Qt::green; -+ break; -+ } -+ return col; -+} -+//main -+static const char description[] = -+ I18N_NOOP("Test Client for Network Status kded module"); -+ -+static const char version[] = "v0.1"; -+ -+static KCmdLineOptions options[] = -+{ -+ KCmdLineLastOption -+}; -+ -+int main(int argc, char **argv) -+{ -+ KAboutData about("KNetworkStatusTestClient", I18N_NOOP("knetworkstatustestclient"), version, description, KAboutData::License_GPL, "(C) 2007 Will Stephenson", 0, 0, "wstephenson@kde.org"); -+ about.addAuthor( "Will Stephenson", 0, "wstephenson@kde.org" ); -+ KCmdLineArgs::init(argc, argv, &about); -+ KCmdLineArgs::addCmdLineOptions(options); -+ KApplication app; -+ -+ // register ourselves as a dcop client -+ app.dcopClient()->registerAs(app.name(), false); -+ -+ KCmdLineArgs *args = KCmdLineArgs::parsedArgs(); -+ if (args->count() == 0) -+ { -+ TestClient *widget = new TestClient; -+ widget->show(); -+ } -+ else -+ { -+ int i = 0; -+ for (; i < args->count(); i++) -+ { -+ TestClient *widget = new TestClient; -+ widget->show(); -+ } -+ } -+ args->clear(); -+ -+ return app.exec(); -+} -+ -+#include "testclient2.moc" -+ -Index: networkstatus/testclient2.h -=================================================================== ---- /dev/null -+++ networkstatus/testclient2.h -@@ -0,0 +1,82 @@ -+/* This file is part of kdepim. -+ -+ Copyright (C) 2007 Will Stephenson -+ -+ This program is free software; you can redistribute it and/or modify -+ it under the terms of the GNU General Public License as published by -+ the Free Software Foundation; either version 2 of the License, or -+ (at your option) any later version. -+ -+ This program is distributed in the hope that it will be useful, -+ but WITHOUT ANY WARRANTY; without even the implied warranty of -+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+ GNU General Public License for more details. -+ -+ You should have received a copy of the GNU General Public License -+ along with this program; if not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this program -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef KTESTNETWORKSTATUS_H -+#define KTESTNETWORKSTATUS_H -+ -+#ifdef HAVE_CONFIG_H -+#include -+#endif -+ -+#include -+#include -+#include -+#include -+ -+#include "networkstatusiface_stub.h" -+ -+class TestClientView; -+ -+/** -+ * Test client that uses a ConnectionManager to change its state -+ * -+ * @short Main window class -+ * @author Will Stephenson -+ * @version 0.1 -+ */ -+class TestClient : public KMainWindow -+{ -+Q_OBJECT -+public: -+ enum AppStatus{ AppDisconnected, AppWaitingForConnect, AppConnected }; -+ /** -+ * Default Constructor -+ */ -+ TestClient(); -+ -+ /** -+ * Default Destructor -+ */ -+ virtual ~TestClient(); -+ -+private slots: -+ void networkStatusChanged( NetworkStatus::Status status ); -+ void connectButtonClicked(); -+ void doConnect(); -+ void doDisconnect(); -+private: -+ void appWaiting(); -+ void appEstablishing(); -+ void appIsConnected(); -+ void appDisestablishing(); -+ void appDisconnected(); -+ static QColor toQColor( NetworkStatus::Status ); -+private: -+ QHBox * m_layout; -+ NetworkStatusIface_stub *m_service; -+ TestClientView *m_view; -+ AppStatus m_status; // this represents the app's status not the network's status -+}; -+ -+#endif // KTESTNETWORKSTATUS_H -+ -Index: networkstatus/testclient.cpp -=================================================================== ---- /dev/null -+++ networkstatus/testclient.cpp -@@ -0,0 +1,234 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2007 Will Stephenson -+ -+ This program is free software; you can redistribute it and/or modify -+ it under the terms of the GNU General Public License version 2 -+ as published by the Free Software Foundation. -+ -+ This program is distributed in the hope that it will be useful, -+ but WITHOUT ANY WARRANTY; without even the implied warranty of -+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+ GNU General Public License for more details. -+ -+ You should have received a copy of the GNU General Public License -+ along with this program; if not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this program -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#include -+#include -+ -+ -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+ -+#include "connectionmanager.h" -+#include "testclientview.h" -+#include "testclient.h" -+ -+TestClient::TestClient() -+ : KMainWindow( 0, "ktestnetworkstatus" ), -+ m_view(new TestClientView(this)), -+ m_status( AppDisconnected ) -+{ -+ // tell the KMainWindow that this is indeed the main widget -+ setCentralWidget(m_view); -+ -+ networkStatusChanged( ConnectionManager::self()->status() ); -+ appDisconnected(); -+ -+ connect( ConnectionManager::self(), SIGNAL( statusChanged( NetworkStatus::Status ) ), SLOT( networkStatusChanged( NetworkStatus::Status ) ) ); -+ -+ connect( m_view->connectButton, SIGNAL( toggled( bool ) ), SLOT( connectButtonToggled( bool ) ) ); -+} -+ -+TestClient::~TestClient() -+{ -+} -+ -+void TestClient::networkStatusChanged( NetworkStatus::Status status ) -+{ -+ kdDebug() << k_funcinfo << endl; -+//enum EnumStatus { NoNetworks = 1, Unreachable, OfflineDisconnected, OfflineFailed, ShuttingDown -+// , Offline, Establishing, Online }; -+ kdDebug() << "Networking is now: " << NetworkStatus::toString( status ) << " (" << status << ")" << endl; -+ m_view->netStatusLabel->setText( NetworkStatus::toString( status ) ); -+ m_view->netStatusLabel->setPaletteBackgroundColor( toQColor( status ) ); -+ switch ( status ) { -+ case NetworkStatus::NoNetworks: -+ break; -+ case NetworkStatus::Unreachable: -+ break; -+ case NetworkStatus::OfflineDisconnected: -+ break; -+ case NetworkStatus::OfflineFailed: -+ break; -+ case NetworkStatus::ShuttingDown: -+ if ( m_status == AppConnected ) { -+ appDisestablishing(); -+ } -+ break; -+ case NetworkStatus::Offline: -+ if ( m_status == AppConnected ) { -+ appDisconnected(); -+ } -+ break; -+ case NetworkStatus::Establishing: -+ if ( m_status == AppWaitingForConnect ) -+ appEstablishing(); -+ else if ( m_status == AppConnected ) -+ appDisconnected(); -+ break; -+ case NetworkStatus::Online: -+ if ( m_status == AppWaitingForConnect ) -+ appIsConnected(); -+ break; -+ default: -+ m_view->netStatusLabel->setText( "Unrecognised status code!" ); -+ } -+} -+ -+void TestClient::connectButtonToggled( bool on ) -+{ -+ kdDebug() << k_funcinfo << endl; -+ if ( on && m_status == AppDisconnected ) { -+ switch ( ConnectionManager::self()->status() ) -+ { -+ case NetworkStatus::NoNetworks: -+ case NetworkStatus::Online: -+ appIsConnected(); -+ break; -+ default: -+ appWaiting(); -+ break; -+ } -+ } -+ else if ( !on && m_status == AppConnected ) { -+ appDisconnected(); -+ } -+} -+ -+void TestClient::appWaiting() -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_status = AppWaitingForConnect; -+ m_view->appStatusLabel->setText( "Waiting" ); -+} -+ -+void TestClient::appIsConnected() -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_view->connectButton->setEnabled( true ); -+ m_view->connectButton->setText( "Disconnect" ); -+ m_view->appStatusLabel->setText( "Connected" ); -+ m_status = AppConnected; -+} -+ -+void TestClient::appEstablishing() -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_view->netStatusLabel->setText( "Establishing" ); -+ m_view->connectButton->setEnabled( false ); -+} -+ -+void TestClient::appDisestablishing( ) -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_view->connectButton->setEnabled( false ); -+ m_view->appStatusLabel->setText( "Disconnected" ); -+} -+ -+void TestClient::appDisconnected( ) -+{ -+ kdDebug() << k_funcinfo << endl; -+ m_view->connectButton->setEnabled( true ); -+ m_view->connectButton->setText( "Start Connect" ); -+ m_view->appStatusLabel->setText( "Disconnected" ); -+ m_status = AppDisconnected; -+} -+ -+QColor TestClient::toQColor( NetworkStatus::Status st ) -+{ -+ QColor col; -+ switch ( st ) { -+ case NetworkStatus::NoNetworks: -+ col = Qt::darkGray; -+ break; -+ case NetworkStatus::Unreachable: -+ col = Qt::darkMagenta; -+ break; -+ case NetworkStatus::OfflineDisconnected: -+ col = Qt::blue; -+ break; -+ case NetworkStatus::OfflineFailed: -+ col = Qt::darkRed; -+ break; -+ case NetworkStatus::ShuttingDown: -+ col = Qt::darkYellow; -+ break; -+ case NetworkStatus::Offline: -+ col = Qt::blue; -+ break; -+ case NetworkStatus::Establishing: -+ col = Qt::yellow; -+ break; -+ case NetworkStatus::Online: -+ col = Qt::green; -+ break; -+ } -+ return col; -+} -+//main -+static const char description[] = -+ I18N_NOOP("Test Client for Network Status kded module"); -+ -+static const char version[] = "v0.1"; -+ -+static KCmdLineOptions options[] = -+{ -+ KCmdLineLastOption -+}; -+ -+int main(int argc, char **argv) -+{ -+ KAboutData about("KNetworkStatusTestClient", I18N_NOOP("knetworkstatustestclient"), version, description, KAboutData::License_GPL, "(C) 2007 Will Stephenson", 0, 0, "wstephenson@kde.org"); -+ about.addAuthor( "Will Stephenson", 0, "wstephenson@kde.org" ); -+ KCmdLineArgs::init(argc, argv, &about); -+ KCmdLineArgs::addCmdLineOptions(options); -+ KApplication app; -+ -+ // register ourselves as a dcop client -+ app.dcopClient()->registerAs(app.name(), false); -+ -+ KCmdLineArgs *args = KCmdLineArgs::parsedArgs(); -+ if (args->count() == 0) -+ { -+ TestClient *widget = new TestClient; -+ widget->show(); -+ } -+ else -+ { -+ int i = 0; -+ for (; i < args->count(); i++) -+ { -+ TestClient *widget = new TestClient; -+ widget->show(); -+ } -+ } -+ args->clear(); -+ -+ return app.exec(); -+} -+ -+#include "testclient.moc" -+ -Index: networkstatus/testclient.h -=================================================================== ---- /dev/null -+++ networkstatus/testclient.h -@@ -0,0 +1,80 @@ -+/* This file is part of kdepim. -+ -+ Copyright (C) 2007 Will Stephenson -+ -+ This program is free software; you can redistribute it and/or modify -+ it under the terms of the GNU General Public License as published by -+ the Free Software Foundation; either version 2 of the License, or -+ (at your option) any later version. -+ -+ This program is distributed in the hope that it will be useful, -+ but WITHOUT ANY WARRANTY; without even the implied warranty of -+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+ GNU General Public License for more details. -+ -+ You should have received a copy of the GNU General Public License -+ along with this program; if not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this program -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef KTESTNETWORKSTATUS_H -+#define KTESTNETWORKSTATUS_H -+ -+#ifdef HAVE_CONFIG_H -+#include -+#endif -+ -+#include -+#include -+#include -+#include -+ -+#include "networkstatusiface_stub.h" -+ -+class TestClientView; -+ -+/** -+ * This class serves as the main window for ktestnetworkstatus. It handles the -+ * menus, toolbars, and status bars. -+ * -+ * @short Main window class -+ * @author Will Stephenson -+ * @version 0.1 -+ */ -+class TestClient : public KMainWindow -+{ -+Q_OBJECT -+public: -+ enum AppStatus{ AppDisconnected, AppWaitingForConnect, AppConnected }; -+ /** -+ * Default Constructor -+ */ -+ TestClient(); -+ -+ /** -+ * Default Destructor -+ */ -+ virtual ~TestClient(); -+ -+private slots: -+ void networkStatusChanged( NetworkStatus::Status status ); -+ void connectButtonToggled( bool on ); -+private: -+ void appWaiting(); -+ void appEstablishing(); -+ void appIsConnected(); -+ void appDisestablishing(); -+ void appDisconnected(); -+ static QColor toQColor( NetworkStatus::Status ); -+private: -+ NetworkStatusIface_stub *m_service; -+ TestClientView *m_view; -+ AppStatus m_status; // this represents the app's status not the network's status -+}; -+ -+#endif // KTESTNETWORKSTATUS_H -+ -Index: networkstatus/testclientview.ui -=================================================================== ---- /dev/null -+++ networkstatus/testclientview.ui -@@ -0,0 +1,177 @@ -+ -+TestClientView -+ -+ -+ TestClientView -+ -+ -+ -+ 0 -+ 0 -+ 356 -+ 127 -+ -+ -+ -+ Form1 -+ -+ -+ -+ unnamed -+ -+ -+ -+ textLabel4 -+ -+ -+ -+ 5 -+ 5 -+ 0 -+ 0 -+ -+ -+ -+ <font size="+2"><b>Client for KDE 3 Offline Mode</b></font> -+ -+ -+ AlignVCenter -+ -+ -+ -+ -+ layout1 -+ -+ -+ -+ unnamed -+ -+ -+ -+ textLabel1 -+ -+ -+ Network status: -+ -+ -+ -+ -+ netStatusLabel -+ -+ -+ -+ 0 -+ 255 -+ 0 -+ -+ -+ -+ Panel -+ -+ -+ STATUS -+ -+ -+ AlignCenter -+ -+ -+ -+ -+ -+ -+ layout1_2 -+ -+ -+ -+ unnamed -+ -+ -+ -+ textLabel1_2 -+ -+ -+ App status: -+ -+ -+ -+ -+ appStatusLabel -+ -+ -+ -+ 0 -+ 255 -+ 0 -+ -+ -+ -+ Panel -+ -+ -+ STATUS -+ -+ -+ AlignCenter -+ -+ -+ -+ -+ -+ -+ layout2 -+ -+ -+ -+ unnamed -+ -+ -+ -+ spacer1 -+ -+ -+ Horizontal -+ -+ -+ Expanding -+ -+ -+ -+ 31 -+ 20 -+ -+ -+ -+ -+ -+ connectButton -+ -+ -+ Start Connect -+ -+ -+ false -+ -+ -+ -+ -+ spacer2 -+ -+ -+ Horizontal -+ -+ -+ Expanding -+ -+ -+ -+ 61 -+ 20 -+ -+ -+ -+ -+ -+ -+ -+ -+ -Index: networkstatus/testservice.cpp -=================================================================== ---- /dev/null -+++ networkstatus/testservice.cpp -@@ -0,0 +1,219 @@ -+/* This file is part of kdepim. -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This program is free software; you can redistribute it and/or modify -+ it under the terms of the GNU General Public License version 2 -+ as published by the Free Software Foundation. -+ -+ This program is distributed in the hope that it will be useful, -+ but WITHOUT ANY WARRANTY; without even the implied warranty of -+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+ GNU General Public License for more details. -+ -+ You should have received a copy of the GNU General Public License -+ along with this program; if not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, -+ Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this program -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#include -+#include -+#include -+#include -+ -+#include -+#include -+#include -+#include -+#include -+#include -+ -+#include "testservice.h" -+#include "testserviceview.h" -+#include "networkstatusiface_stub.h" -+ -+TestService::TestService() : KMainWindow( 0, "testservice" ), -+ m_service( new NetworkStatusIface_stub( "kded", "networkstatus" ) ), -+ m_status ( NetworkStatus::Offline ), -+ m_nextStatus( NetworkStatus::OfflineDisconnected ), -+ m_view( new TestServiceView( this ) ) -+{ -+ setCentralWidget( m_view ); -+ kapp->dcopClient()->registerAs("testservice" ); -+ -+ connect( m_view->changeCombo, SIGNAL( activated( int ) ), SLOT( changeComboActivated( int ) ) ); -+ connect( m_view->changeButton, SIGNAL( clicked() ), SLOT( changeButtonClicked() ) ); -+ -+ connect( kapp->dcopClient(), SIGNAL( applicationRegistered( const QCString& ) ), this, SLOT( registeredToDCOP( const QCString& ) ) ); -+ kapp->dcopClient()->setNotifications( true ); -+ -+ m_view->statusLabel->setText( NetworkStatus::toString( m_status ) ); -+ m_view->statusLabel->setPaletteBackgroundColor( toQColor( m_status ) ); -+ setCaption( NetworkStatus::toString( m_status ) ); -+ -+ registerService(); -+} -+ -+TestService::~TestService() -+{ -+ delete m_service; -+ delete m_view; -+} -+ -+void TestService::registerService() -+{ -+ NetworkStatus::Properties nsp; -+ nsp.name = "test_net"; -+ nsp.service = kapp->dcopClient()->appId(); -+ nsp.status = m_status; -+ m_service->registerNetwork( nsp ); -+} -+ -+void TestService::registeredToDCOP( const QCString & appId ) -+{ -+ if ( appId == "kded" ) -+ registerService(); -+} -+ -+int TestService::status( const QString & network ) -+{ -+ Q_UNUSED( network ); -+ return (int)m_status; -+} -+ -+void TestService::changeComboActivated( int index ) -+{ -+ switch ( index ) { -+ case 0 /*NetworkStatus::OfflineDisconnected*/: -+ m_nextStatus = NetworkStatus::OfflineDisconnected; -+ break; -+ case 1 /*NetworkStatus::OfflineFailed*/: -+ m_nextStatus = NetworkStatus::OfflineFailed; -+ break; -+ case 2 /*NetworkStatus::ShuttingDown*/: -+ m_nextStatus = NetworkStatus::ShuttingDown; -+ break; -+ case 3 /*NetworkStatus::Offline*/: -+ m_nextStatus = NetworkStatus::Offline; -+ break; -+ case 4 /*NetworkStatus::Establishing*/: -+ m_nextStatus = NetworkStatus::Establishing; -+ break; -+ case 5 /*NetworkStatus::Online*/: -+ m_nextStatus = NetworkStatus::Online; -+ break; -+ default: -+ kdDebug() << "Unrecognised status!" << endl; -+ Q_ASSERT( false ); -+ } -+ m_view->changeButton->setEnabled( true ); -+} -+ -+void TestService::changeButtonClicked() -+{ -+ m_view->changeButton->setEnabled( false ); -+ m_status = m_nextStatus; -+ m_service->setNetworkStatus( "test_net", ( int )m_status ); -+ m_view->statusLabel->setText( NetworkStatus::toString( m_status ) ); -+ m_view->statusLabel->setPaletteBackgroundColor( toQColor( m_status ) ); -+ setCaption( NetworkStatus::toString( m_status ) ); -+} -+ -+int TestService::establish( const QString & network ) -+{ -+ Q_UNUSED( network ); -+ m_status = NetworkStatus::Establishing; -+ m_service->setNetworkStatus( "test_net", (int)m_status ); -+ m_nextStatus = NetworkStatus::Online; -+ QTimer::singleShot( 5000, this, SLOT( slotStatusChange() ) ); -+ return (int)NetworkStatus::RequestAccepted; -+} -+ -+int TestService::shutdown( const QString & network ) -+{ -+ Q_UNUSED( network ); -+ m_status = NetworkStatus::ShuttingDown; -+ m_service->setNetworkStatus( "test_net", (int)m_status ); -+ m_nextStatus = NetworkStatus::Offline; -+ QTimer::singleShot( 5000, this, SLOT( slotStatusChange() ) ); -+ return (int)NetworkStatus::RequestAccepted; -+} -+ -+void TestService::simulateFailure() -+{ -+ m_status = NetworkStatus::OfflineFailed; -+ m_service->setNetworkStatus( "test_net", (int)m_status ); -+} -+ -+void TestService::simulateDisconnect() -+{ -+ m_status = NetworkStatus::OfflineDisconnected; -+ m_service->setNetworkStatus( "test_net", (int)m_status ); -+} -+ -+void TestService::slotStatusChange() -+{ -+ m_status = m_nextStatus; -+ m_service->setNetworkStatus( "test_net", (int)m_status ); -+} -+ -+QColor TestService::toQColor( NetworkStatus::Status st ) -+{ -+ QColor col; -+ switch ( st ) { -+ case NetworkStatus::NoNetworks: -+ col = Qt::darkGray; -+ break; -+ case NetworkStatus::Unreachable: -+ col = Qt::darkMagenta; -+ break; -+ case NetworkStatus::OfflineDisconnected: -+ col = Qt::blue; -+ break; -+ case NetworkStatus::OfflineFailed: -+ col = Qt::darkRed; -+ break; -+ case NetworkStatus::ShuttingDown: -+ col = Qt::darkYellow; -+ break; -+ case NetworkStatus::Offline: -+ col = Qt::blue; -+ break; -+ case NetworkStatus::Establishing: -+ col = Qt::yellow; -+ break; -+ case NetworkStatus::Online: -+ col = Qt::green; -+ break; -+ } -+ return col; -+} -+ -+static const char description[] = -+ I18N_NOOP("Test Service for Network Status kded module"); -+ -+static const char version[] = "v0.1"; -+ -+static KCmdLineOptions options[] = -+{ -+ KCmdLineLastOption -+}; -+ -+int main( int argc, char** argv ) -+{ -+ KAboutData about("KNetworkStatusTestService", I18N_NOOP("knetworkstatustestservice"), version, description, KAboutData::License_GPL, "(C) 2007 Will Stephenson", 0, 0, "wstephenson@kde.org"); -+ about.addAuthor( "Will Stephenson", 0, "wstephenson@kde.org" ); -+ KCmdLineArgs::init(argc, argv, &about); -+ KCmdLineArgs::addCmdLineOptions(options); -+ KApplication app; -+ -+ TestService * test = new TestService; -+ test->show(); -+ return app.exec(); -+} -+ -+#include "testservice.moc" -Index: networkstatus/testservice.h -=================================================================== ---- /dev/null -+++ networkstatus/testservice.h -@@ -0,0 +1,60 @@ -+/* This file is part of kdepim. -+ -+ Copyright (C) 2005,2007 Will Stephenson -+ -+ This program is free software; you can redistribute it and/or modify -+ it under the terms of the GNU General Public License as published by -+ the Free Software Foundation; either version 2 of the License, or -+ (at your option) any later version. -+ -+ This program is distributed in the hope that it will be useful, -+ but WITHOUT ANY WARRANTY; without even the implied warranty of -+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -+ GNU General Public License for more details. -+ -+ You should have received a copy of the GNU General Public License -+ along with this program; if not, write to the Free Software -+ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -+ -+ As a special exception, permission is given to link this program -+ with any edition of Qt, and distribute the resulting executable, -+ without including the source code for Qt in the source distribution. -+*/ -+ -+#ifndef _TEST_NETWORKSTATUS_SERVICE_H -+#define _TEST_NETWORKSTATUS_SERVICE_H -+ -+#include -+ -+#include "networkstatuscommon.h" -+ -+class NetworkStatusIface_stub; -+class TestServiceView; -+ -+class TestService : public KMainWindow { -+Q_OBJECT -+public: -+ TestService(); -+ virtual ~TestService(); -+ int status( const QString & network ); -+ int establish( const QString & network ); -+ int shutdown( const QString & network ); -+ void simulateFailure(); -+ void simulateDisconnect(); -+protected slots: -+ void changeComboActivated( int index ); -+ void registeredToDCOP( const QCString& appId ); -+ -+ void changeButtonClicked(); -+ -+ void slotStatusChange(); -+private: -+ void registerService(); -+ static QColor toQColor( NetworkStatus::Status ); -+ NetworkStatusIface_stub * m_service; -+ NetworkStatus::Status m_status; -+ NetworkStatus::Status m_nextStatus; -+ TestServiceView * m_view; -+}; -+ -+#endif -Index: networkstatus/testserviceview.ui -=================================================================== ---- /dev/null -+++ networkstatus/testserviceview.ui -@@ -0,0 +1,181 @@ -+ -+TestServiceView -+ -+ -+ TestServiceView -+ -+ -+ -+ 0 -+ 0 -+ 367 -+ 132 -+ -+ -+ -+ Form1 -+ -+ -+ -+ unnamed -+ -+ -+ -+ textLabel4 -+ -+ -+ <font size="+2"><b>Service for KDE 3 Offline Mode</b></font> -+ -+ -+ AlignVCenter -+ -+ -+ -+ -+ layout2 -+ -+ -+ -+ unnamed -+ -+ -+ -+ textLabel1 -+ -+ -+ Status: -+ -+ -+ -+ -+ statusLabel -+ -+ -+ -+ 0 -+ 255 -+ 0 -+ -+ -+ -+ StyledPanel -+ -+ -+ STATUS -+ -+ -+ AlignCenter -+ -+ -+ -+ -+ -+ -+ layout3 -+ -+ -+ -+ unnamed -+ -+ -+ -+ textLabel3 -+ -+ -+ Change to: -+ -+ -+ -+ -+ -+ Offline Disconnected -+ -+ -+ -+ -+ Offline Failed -+ -+ -+ -+ -+ Shutting Down -+ -+ -+ -+ -+ Offline -+ -+ -+ -+ -+ Establishing -+ -+ -+ -+ -+ Online -+ -+ -+ -+ changeCombo -+ -+ -+ -+ -+ -+ -+ layout1 -+ -+ -+ -+ unnamed -+ -+ -+ -+ spacer1 -+ -+ -+ Horizontal -+ -+ -+ Expanding -+ -+ -+ -+ 51 -+ 20 -+ -+ -+ -+ -+ -+ changeButton -+ -+ -+ Do change -+ -+ -+ -+ -+ spacer2 -+ -+ -+ Horizontal -+ -+ -+ Expanding -+ -+ -+ -+ 41 -+ 20 -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ diff --git a/opensuse/core/tdelibs/no-debug-by-default.diff b/opensuse/core/tdelibs/no-debug-by-default.diff index 5b1440970..75aed886d 100644 --- a/opensuse/core/tdelibs/no-debug-by-default.diff +++ b/opensuse/core/tdelibs/no-debug-by-default.diff @@ -1,8 +1,6 @@ -Index: kdecore/kdebug.cpp -=================================================================== ---- kdecore/kdebug.cpp.orig -+++ kdecore/kdebug.cpp -@@ -170,7 +170,7 @@ static KStaticDeleter pcd +--- tdecore/kdebug.cpp.orig 2011-12-11 18:54:28.986987249 +0100 ++++ tdecore/kdebug.cpp 2011-12-11 19:00:22.478987207 +0100 +@@ -170,7 +170,7 @@ static KStaticDeleter dcopsd; static KDebugDCOPIface* kDebugDCOPIface = 0; @@ -11,22 +9,23 @@ Index: kdecore/kdebug.cpp { if ( !kDebug_data ) { -@@ -205,40 +205,46 @@ static void kDebugBackend( unsigned shor +@@ -205,41 +205,46 @@ if ( KGlobal::_instance ) kDebug_data->aAreaName = KGlobal::instance()->instanceName(); } +} - int nPriority = 0; -- QString aCaption; +- TQString aCaption; - - /* Determine output */ +- +static short kDebugAreaOutput(unsigned short nLevel, unsigned int nArea) +{ + kDebugInitBackend (nArea); - ++ + /* Determine output */ - QString key; + TQString key; switch( nLevel ) { case KDEBUG_INFO: @@ -53,7 +52,8 @@ Index: kdecore/kdebug.cpp 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; + return kDebug_data->config ? kDebug_data->config->readNumEntry(key, 4) : 4; +} + @@ -69,14 +69,14 @@ Index: kdecore/kdebug.cpp + + short nOutput = kDebugAreaOutput(nLevel, nArea); - // If the application doesn't have a QApplication object it can't use + // If the application doesn't have a TQApplication object it can't use // a messagebox. -@@ -247,6 +253,32 @@ static void kDebugBackend( unsigned shor +@@ -248,6 +253,32 @@ else if ( nOutput == 4 && nLevel != KDEBUG_FATAL ) return; + int nPriority = 0; -+ QString aCaption; ++ TQString aCaption; + switch( nLevel ) + { + case KDEBUG_INFO: @@ -104,10 +104,10 @@ Index: kdecore/kdebug.cpp const int BUFSIZE = 4096; char buf[BUFSIZE]; if ( !kDebug_data->aAreaName.isEmpty() ) { -@@ -314,13 +346,25 @@ static void kDebugBackend( unsigned shor +@@ -315,13 +346,25 @@ } - kdbgstream &perror( kdbgstream &s) { return s << QString::fromLocal8Bit(strerror(errno)); } + kdbgstream &perror( kdbgstream &s) { return s << TQString(TQString::fromLocal8Bit(strerror(errno))); } -kdbgstream kdDebug(int area) { return kdbgstream(area, KDEBUG_INFO); } -kdbgstream kdDebug(bool cond, int area) { if (cond) return kdbgstream(area, KDEBUG_INFO); else return kdbgstream(0, 0, false); } +kdbgstream kdDebug(int area) { return kdbgstream(area, KDEBUG_INFO, kDebugAreaEnabled(KDEBUG_INFO, area)); } @@ -134,7 +134,7 @@ Index: kdecore/kdebug.cpp kdbgstream kdFatal(int area) { return kdbgstream("FATAL: ", area, KDEBUG_FATAL); } kdbgstream kdFatal(bool cond, int area) { if (cond) return kdbgstream("FATAL: ", area, KDEBUG_FATAL); else return kdbgstream(0,0,false); } -@@ -331,9 +375,10 @@ kdbgstream::kdbgstream(kdbgstream &str) +@@ -332,9 +375,10 @@ } void kdbgstream::flush() { @@ -144,15 +144,15 @@ Index: kdecore/kdebug.cpp - kDebugBackend( level, area, output.local8Bit().data() ); + if (print) + kDebugBackend( level, area, output.local8Bit().data() ); - output = QString::null; + output = TQString::null; } -@@ -349,7 +394,7 @@ kdbgstream &kdbgstream::form(const char +@@ -350,7 +394,7 @@ } kdbgstream::~kdbgstream() { - if (!output.isEmpty()) { + if (print && !output.isEmpty()) { fprintf(stderr, "ASSERT: debug output not ended with \\n\n"); - fprintf(stderr, "%s", kdBacktrace().latin1()); - *this << "\n"; + TQString backtrace = kdBacktrace(); + if (backtrace.ascii() != NULL) { diff --git a/opensuse/core/tdelibs/no-progress-for-beagle-status-query.diff b/opensuse/core/tdelibs/no-progress-for-beagle-status-query.diff deleted file mode 100644 index 4d9ae1a84..000000000 --- a/opensuse/core/tdelibs/no-progress-for-beagle-status-query.diff +++ /dev/null @@ -1,13 +0,0 @@ -Index: kio/kio/netaccess.cpp -=================================================================== ---- kio/kio/netaccess.cpp.orig -+++ kio/kio/netaccess.cpp -@@ -337,7 +337,7 @@ bool NetAccess::statInternal( const KURL - QWidget* window ) - { - bJobOK = true; // success unless further error occurs -- KIO::StatJob * job = KIO::stat( url, !url.isLocalFile() ); -+ KIO::StatJob * job = KIO::stat( url, !url.isLocalFile() && !url.url().startsWith("beagle:?") ); - job->setWindow (window); - job->setDetails( details ); - job->setSide( source ); diff --git a/opensuse/core/tdelibs/noauto-package.diff b/opensuse/core/tdelibs/noauto-package.diff index 9eec14ab3..78ec57da5 100644 --- a/opensuse/core/tdelibs/noauto-package.diff +++ b/opensuse/core/tdelibs/noauto-package.diff @@ -9,5 +9,5 @@ Index: configure.in.in -AM_INIT_AUTOMAKE(@MODULENAME@, @VERSION@) dnl searches for some needed programs +AM_INIT_AUTOMAKE("kdelibs", @VERSION@) dnl searches for some needed programs - AC_PROG_INSTALL + AM_MAINTAINER_MODE diff --git a/opensuse/core/tdelibs/oom_score_adj.patch b/opensuse/core/tdelibs/oom_score_adj.patch deleted file mode 100644 index f7a929f3f..000000000 --- a/opensuse/core/tdelibs/oom_score_adj.patch +++ /dev/null @@ -1,36 +0,0 @@ -Index: kdelibs-3.5.10/kinit/start_kdeinit.c -=================================================================== ---- kdelibs-3.5.10.orig/kinit/start_kdeinit.c -+++ kdelibs-3.5.10/kinit/start_kdeinit.c -@@ -44,11 +44,30 @@ static int set_protection( pid_t pid, in - { - char buf[ 1024 ]; - int procfile; -+ struct stat st; -+ -+ /* Newer kernels (noticed in 2.6.36) */ -+ sprintf( buf, "/proc/%d/oom_score_adj", pid ); -+ if ( lstat (buf, &st) == 0) { -+ if( !enable ) { -+ /* Be paranoid and check that the pid we got from the pipe -+ belongs to this user. */ -+ if( st.st_uid != getuid()) -+ return 0; -+ } -+ procfile = open(buf, O_WRONLY); -+ if( enable ) -+ write( procfile, "-300", sizeof( "-300" )); -+ else -+ write( procfile, "0", sizeof( "0" )); -+ close( procfile ); -+ return 1; -+ } -+ - sprintf( buf, "/proc/%d/stat", pid ); - if( !enable ) { - /* Be paranoid and check that the pid we got from the pipe - belongs to this user. */ -- struct stat st; - if( lstat( buf, &st ) < 0 || st.st_uid != getuid()) - return 0; - } diff --git a/opensuse/core/tdelibs/patch-mimetype-iconnames.diff b/opensuse/core/tdelibs/patch-mimetype-iconnames.diff deleted file mode 100644 index 6874162ae..000000000 --- a/opensuse/core/tdelibs/patch-mimetype-iconnames.diff +++ /dev/null @@ -1,39 +0,0 @@ -Index: mimetypes/application/vnd.oasis.opendocument.formula.desktop -=================================================================== ---- mimetypes/application/vnd.oasis.opendocument.formula.desktop.orig -+++ mimetypes/application/vnd.oasis.opendocument.formula.desktop -@@ -2,7 +2,7 @@ - Type=MimeType - MimeType=application/vnd.oasis.opendocument.formula - Patterns=*.odf;*.ODF --Icon=formula -+Icon=kformula_kfo - Comment=OASIS OpenDocument Formula - Comment[af]=OASIS Oop Dokument formule - Comment[be]=Формула OASIS OpenDocument -Index: mimetypes/application/vnd.sun.xml.base.desktop -=================================================================== ---- mimetypes/application/vnd.sun.xml.base.desktop.orig -+++ mimetypes/application/vnd.sun.xml.base.desktop -@@ -67,7 +67,7 @@ Comment[vi]=Cơ sở dữ liệu OpenOff - Comment[zh_CN]=OpenOffice.org 数据库 - Comment[zh_HK]=OpenOffice.org 資料庫 - Comment[zh_TW]=OpenOffice.org 資料庫 --Icon=spreadsheet -+Icon=database - Type=MimeType - Patterns=*.odb;*.ODB; - MimeType=application/vnd.sun.xml.base -Index: mimetypes/text/rtf.desktop -=================================================================== ---- mimetypes/text/rtf.desktop.orig -+++ mimetypes/text/rtf.desktop -@@ -77,7 +77,7 @@ Comment[wa]=Documint RTF - Comment[zh_CN]=RTF 文档 - Comment[zh_HK]=RTF 文件 - Comment[zh_TW]=RTF 文件 --Icon=wordprocessing -+Icon=rtf - Type=MimeType - Patterns=*.rtf;*.RTF; - [Property::X-KDE-text] diff --git a/opensuse/core/tdelibs/prefer_distribution_settings.dif b/opensuse/core/tdelibs/prefer_distribution_settings.dif index 655788807..ecea91d8f 100644 --- a/opensuse/core/tdelibs/prefer_distribution_settings.dif +++ b/opensuse/core/tdelibs/prefer_distribution_settings.dif @@ -1,13 +1,13 @@ -Index: kdecore/kstandarddirs.cpp +Index: tdecore/kstandarddirs.cpp =================================================================== ---- kdecore/kstandarddirs.cpp.orig -+++ kdecore/kstandarddirs.cpp -@@ -1290,6 +1290,8 @@ void KStandardDirs::addKDEDefaults() +--- tdecore/kstandarddirs.cpp.orig ++++ tdecore/kstandarddirs.cpp +@@ -1303,6 +1303,8 @@ void KStandardDirs::addKDEDefaults() } } -+ kdedirList.append("/etc/opt/kde3"); ++ tdedirList.append("/etc/opt/tde"); + - #ifndef Q_OS_WIN //no default KDEDIR on win32 defined - kdedirList.append(KDEDIR); + #ifndef Q_OS_WIN //no default TDEDIR on win32 defined + tdedirList.append(TDEDIR); #endif diff --git a/opensuse/core/tdelibs/printpreview.patch b/opensuse/core/tdelibs/printpreview.patch deleted file mode 100644 index ef3de21a4..000000000 --- a/opensuse/core/tdelibs/printpreview.patch +++ /dev/null @@ -1,14 +0,0 @@ -Index: kdeprint/kprintpreview.cpp -=================================================================== ---- kdeprint/kprintpreview.cpp.orig -+++ kdeprint/kprintpreview.cpp -@@ -108,6 +108,9 @@ static KLibFactory* componentFactory() - { - kdDebug(500) << "kdeprint: querying trader for 'application/postscript' service" << endl; - KLibFactory *factory(0); -+ factory = KLibLoader::self()->factory("libkghostviewpart"); -+ if( factory ) -+ return factory; - KTrader::OfferList offers = KTrader::self()->query(QString::fromLatin1("application/postscript"), QString::fromLatin1("KParts/ReadOnlyPart"), QString::null, QString::null); - for (KTrader::OfferList::ConstIterator it = offers.begin(); it != offers.end(); ++it) - { diff --git a/opensuse/core/tdelibs/r874968-ebay-crash.diff b/opensuse/core/tdelibs/r874968-ebay-crash.diff deleted file mode 100644 index 44dfb6eb4..000000000 --- a/opensuse/core/tdelibs/r874968-ebay-crash.diff +++ /dev/null @@ -1,24 +0,0 @@ -Index: khtml/rendering/table_layout.cpp -=================================================================== ---- khtml/rendering/table_layout.cpp.orig -+++ khtml/rendering/table_layout.cpp -@@ -297,7 +297,8 @@ void FixedTableLayout::layout() - #endif - for ( int i = 0; available > 0 && i < nEffCols; i++ ) { - if ( width[i].isPercent() ) { -- int w = base * width[i].value() / totalPercent; -+ // totalPercent may be 0 below if all %-width specifed are 0%. (#172557) -+ int w = totalPercent ? base * width[i].value() / totalPercent : 0; - available -= w; - calcWidth[i] = w; - } -@@ -313,7 +314,8 @@ void FixedTableLayout::layout() - - for ( int i = 0; available > 0 && i < nEffCols; i++ ) { - if ( width[i].isVariable() ) { -- int w = available / totalVariable; -+ // totalVariable may be 0 below if all the variable widths specified are 0. -+ int w = totalVariable ? available / totalVariable : 0; - available -= w; - calcWidth[i] = w; - totalVariable--; diff --git a/opensuse/core/tdelibs/rubberband-selection.diff b/opensuse/core/tdelibs/rubberband-selection.diff deleted file mode 100644 index d2b75f17c..000000000 --- a/opensuse/core/tdelibs/rubberband-selection.diff +++ /dev/null @@ -1,380 +0,0 @@ -Index: kdefx/kstyle.cpp -=================================================================== ---- kdefx/kstyle.cpp.orig -+++ kdefx/kstyle.cpp -@@ -154,6 +154,7 @@ struct KStylePrivate - bool menuAltKeyNavigation : 1; - bool menuDropShadow : 1; - bool sloppySubMenus : 1; -+ bool semiTransparentRubberband : 1; - int popupMenuDelay; - float menuOpacity; - -@@ -187,6 +188,7 @@ KStyle::KStyle( KStyleFlags flags, KStyl - d->menuAltKeyNavigation = settings.readBoolEntry("/KStyle/Settings/MenuAltKeyNavigation", true); - d->scrollablePopupmenus = settings.readBoolEntry("/KStyle/Settings/ScrollablePopupMenus", false); - d->menuDropShadow = settings.readBoolEntry("/KStyle/Settings/MenuDropShadow", false); -+ d->semiTransparentRubberband = settings.readBoolEntry("/KStyle/Settings/SemiTransparentRubberband", false); - d->menuHandler = NULL; - - if (useMenuTransparency) { -@@ -553,7 +555,57 @@ void KStyle::drawPrimitive( PrimitiveEle - else - // General handle, probably a kicker applet handle. - 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 - QCommonStyle::drawPrimitive( pe, p, r, cg, flags, opt ); - } -Index: kdeui/kiconview.cpp -=================================================================== ---- kdeui/kiconview.cpp.orig -+++ kdeui/kiconview.cpp -@@ -548,7 +548,7 @@ void KIconViewItem::calcRect( const QStr - r = m_wordWrap->boundingRect(); - - int realWidth = QMAX( QMIN( r.width() + 4, tw ), fm->width( "X" ) ); -- itemTextRect.setWidth( realWidth ); -+ itemTextRect.setWidth( realWidth + 4 ); - itemTextRect.setHeight( r.height() ); - - int w = 0; int h = 0; int y = 0; -@@ -699,11 +699,13 @@ void KIconViewItem::paintPixmap( QPainte - - 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(); - - 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() ) ); - } else { - if ( iconView()->itemTextBackground() != NoBrush ) -Index: kdeui/kjanuswidget.cpp -=================================================================== ---- kdeui/kjanuswidget.cpp.orig -+++ kdeui/kjanuswidget.cpp -@@ -49,16 +49,19 @@ class KJanusWidget::IconListItem : publi - { - public: - IconListItem( QListBox *listbox, const QPixmap &pixmap, -- const QString &text ); -+ const QString &text ); - virtual int height( const QListBox *lb ) const; - virtual int width( const QListBox *lb ) const; - int expandMinimumWidth( int width ); -+ void highlight( bool erase ); - - protected: - const QPixmap &defaultPixmap(); - void paint( QPainter *painter ); -- -+ - private: -+ void paintContents( QPainter *painter ); -+ - QPixmap mPixmap; - int mMinimumWidth; - }; -@@ -141,6 +144,8 @@ KJanusWidget::KJanusWidget( QWidget *par - - mIconList->verticalScrollBar()->installEventFilter( this ); - connect( mIconList, SIGNAL(selectionChanged()), SLOT(slotShowPage())); -+ connect( mIconList, SIGNAL(onItem(QListBoxItem *)), SLOT(slotOnItem(QListBoxItem *))); -+ - hbox->addSpacing( KDialog::marginHint() ); - page = new QFrame( this ); - hbox->addWidget( page, 10 ); -@@ -259,7 +264,7 @@ void KJanusWidget::slotReopen( QListView - } - - QFrame *KJanusWidget::addPage( const QString &itemName, const QString &header, -- const QPixmap &pixmap ) -+ const QPixmap &pixmap ) - { - QStringList items; - items << itemName; -@@ -269,8 +274,8 @@ QFrame *KJanusWidget::addPage( const QSt - - - QVBox *KJanusWidget::addVBoxPage( const QStringList &items, -- const QString &header, -- const QPixmap &pixmap ) -+ const QString &header, -+ const QPixmap &pixmap ) - { - if( !mValid ) - { -@@ -721,6 +726,12 @@ void KJanusWidget::slotItemClicked(QList - it->setOpen(!it->isOpen()); - } - -+// hack because qt does not support Q_OBJECT in nested classes -+void KJanusWidget::slotOnItem(QListBoxItem *qitem) -+{ -+ mIconList->slotOnItem( qitem ); -+} -+ - void KJanusWidget::setFocus() - { - if( !mValid ) { return; } -@@ -929,11 +940,11 @@ bool KJanusWidget::eventFilter( QObject - KJanusWidget::IconListBox::IconListBox( QWidget *parent, const char *name, - WFlags f ) - :KListBox( parent, name, f ), mShowAll(false), mHeightValid(false), -- mWidthValid(false) -+ mWidthValid(false), -+ mOldItem(0) - { - } - -- - void KJanusWidget::IconListBox::updateMinimumHeight() - { - if( mShowAll && !mHeightValid ) -@@ -995,6 +1006,45 @@ void KJanusWidget::IconListBox::setShowA - } - - -+void KJanusWidget::IconListBox::leaveEvent( QEvent *ev ) -+{ -+ KListBox::leaveEvent( ev ); -+ -+ if ( mOldItem && !mOldItem->isSelected() ) -+ { -+ ((KJanusWidget::IconListItem *) mOldItem)->highlight( true ); -+ mOldItem = 0; -+ } -+} -+ -+// hack because qt does not support Q_OBJECT in nested classes -+void KJanusWidget::IconListBox::slotOnItem(QListBoxItem *qitem) -+{ -+ KListBox::slotOnItem( qitem ); -+ -+ if ( qitem == mOldItem ) -+ { -+ return; -+ } -+ -+ if ( mOldItem && !mOldItem->isSelected() ) -+ { -+ ((KJanusWidget::IconListItem *) mOldItem)->highlight( true ); -+ } -+ -+ KJanusWidget::IconListItem *item = dynamic_cast< KJanusWidget::IconListItem * >( qitem ); -+ if ( item && !item->isSelected() ) -+ { -+ item->highlight( false ); -+ mOldItem = item; -+ } -+ else -+ { -+ mOldItem = 0; -+ } -+} -+ -+ - - KJanusWidget::IconListItem::IconListItem( QListBox *listbox, const QPixmap &pixmap, - const QString &text ) -@@ -1006,6 +1056,7 @@ KJanusWidget::IconListItem::IconListItem - mPixmap = defaultPixmap(); - } - setText( text ); -+ setCustomHighlighting( true ); - mMinimumWidth = 0; - } - -@@ -1017,6 +1068,36 @@ int KJanusWidget::IconListItem::expandMi - } - - -+void KJanusWidget::IconListItem::highlight( bool erase ) -+{ -+ QRect r = listBox()->itemRect( this ); -+ r.addCoords( 1, 1, -1, -1 ); -+ -+ QPainter p( listBox()->viewport() ); -+ p.setClipRegion( r ); -+ -+ const QColorGroup &cg = listBox()->colorGroup(); -+ if ( erase ) -+ { -+ p.setPen( cg.base() ); -+ p.setBrush( cg.base() ); -+ p.drawRect( r ); -+ } -+ else -+ { -+ p.setBrush( cg.highlight().light( 120 ) ); -+ p.drawRect( r ); -+ -+ p.setPen( cg.highlight().dark( 140 ) ); -+ p.drawRect( r ); -+ } -+ -+ p.setPen( cg.foreground() ); -+ p.translate( r.x() - 1, r.y() - 1 ); -+ paintContents( &p ); -+} -+ -+ - const QPixmap &KJanusWidget::IconListItem::defaultPixmap() - { - static QPixmap *pix=0; -@@ -1044,15 +1125,34 @@ const QPixmap &KJanusWidget::IconListIte - - void KJanusWidget::IconListItem::paint( QPainter *painter ) - { -+ QRect itemPaintRegion( listBox()->itemRect( this ) ); -+ QRect r( 1, 1, itemPaintRegion.width() - 2, itemPaintRegion.height() - 2); -+ -+ if ( isSelected() ) -+ { -+ painter->eraseRect( r ); -+ -+ painter->save(); -+ painter->setPen( listBox()->colorGroup().highlight().dark( 160 ) ); -+ painter->drawRect( r ); -+ painter->restore(); -+ } -+ -+ paintContents( painter ); -+} -+ -+ -+void KJanusWidget::IconListItem::paintContents( QPainter *painter ) -+{ - QFontMetrics fm = painter->fontMetrics(); - int ht = fm.boundingRect( 0, 0, 0, 0, Qt::AlignCenter, text() ).height(); - int wp = mPixmap.width(); - int hp = mPixmap.height(); -+ painter->drawPixmap( (mMinimumWidth - wp) / 2, 5, mPixmap ); - -- painter->drawPixmap( (mMinimumWidth-wp)/2, 5, mPixmap ); - if( !text().isEmpty() ) - { -- painter->drawText( 0, hp+7, mMinimumWidth, ht, Qt::AlignCenter, text() ); -+ painter->drawText( 1, hp + 7, mMinimumWidth - 2, ht, Qt::AlignCenter, text() ); - } - } - -@@ -1082,6 +1182,7 @@ int KJanusWidget::IconListItem::width( c - void KJanusWidget::virtual_hook( int, void* ) - { /*BASE::virtual_hook( id, data );*/ } - -+ - // TODO: In TreeList, if the last child of a node is removed, and there is no corrsponding widget for that node, allow the caller to - // delete the node. - void KJanusWidget::removePage( QWidget *page ) -@@ -1129,6 +1230,7 @@ void KJanusWidget::removePage( QWidget * - } - } - -+ - QString KJanusWidget::pageTitle(int index) const - { - if (!d || !d->mIntToTitle.contains(index)) -@@ -1137,6 +1239,7 @@ QString KJanusWidget::pageTitle(int inde - return d->mIntToTitle[index]; - } - -+ - QWidget *KJanusWidget::pageWidget(int index) const - { - if (!d || !d->mIntToPage.contains(index)) -Index: kdeui/kjanuswidget.h -=================================================================== ---- kdeui/kjanuswidget.h.orig -+++ kdeui/kjanuswidget.h -@@ -71,6 +71,8 @@ class KDEUI_EXPORT KJanusWidget : public - private: - class IconListBox : public KListBox - { -+ friend class KJanusWidget; -+ - public: - IconListBox( QWidget *parent=0, const char *name=0, WFlags f=0 ); - void updateMinimumHeight(); -@@ -79,10 +81,15 @@ class KDEUI_EXPORT KJanusWidget : public - void invalidateWidth(); - void setShowAll( bool showAll ); - -+ protected: -+ void slotOnItem( QListBoxItem *item ); -+ virtual void leaveEvent( QEvent * ); -+ - private: - bool mShowAll; - bool mHeightValid; - bool mWidthValid; -+ QListBoxItem *mOldItem; - }; - - public: -@@ -558,6 +565,8 @@ class KDEUI_EXPORT KJanusWidget : public - private slots: - bool slotShowPage(); - void slotFontChanged(); -+ -+ void slotOnItem(QListBoxItem *item); - void slotItemClicked(QListViewItem *it); - void pageGone(QObject *obj); // signal from the added page's "destroyed" signal - void slotReopen(QListViewItem *item); diff --git a/opensuse/core/tdelibs/show-distribution.diff b/opensuse/core/tdelibs/show-distribution.diff deleted file mode 100644 index 6906ed0a4..000000000 --- a/opensuse/core/tdelibs/show-distribution.diff +++ /dev/null @@ -1,21 +0,0 @@ -Index: kdeui/kaboutdialog.cpp -=================================================================== ---- kdeui/kaboutdialog.cpp.orig -+++ kdeui/kaboutdialog.cpp -@@ -40,6 +40,7 @@ - #include - #include - #include -+#include - - //MOC_SKIP_BEGIN - template class QPtrList; -@@ -702,7 +703,7 @@ void KAboutContainerBase::setProduct( co - kdDebug(291) << "no kapp" << endl; - - const QString msg1 = i18n("%1 %2 (Using KDE %3)").arg(appName).arg(version). -- arg(QString::fromLatin1(KDE_VERSION_STRING)); -+ arg(QString::fromLatin1(KDE_VERSION_STRING) + " " + QString::fromLatin1(KDE_DISTRIBUTION_TEXT)); - const QString msg2 = !year.isEmpty() ? i18n("%1 %2, %3").arg('').arg(year). - arg(author) : QString::fromLatin1(""); - diff --git a/opensuse/core/tdelibs/silence.diff b/opensuse/core/tdelibs/silence.diff deleted file mode 100644 index 7dbbbb997..000000000 --- a/opensuse/core/tdelibs/silence.diff +++ /dev/null @@ -1,13 +0,0 @@ -Index: kded/kbuildservicefactory.cpp -=================================================================== ---- kded/kbuildservicefactory.cpp.orig -+++ kded/kbuildservicefactory.cpp -@@ -158,7 +158,7 @@ KBuildServiceFactory::saveOfferList(QDat - KServiceType::Ptr serviceType = KServiceType::serviceType(*it); - if (!serviceType) - { -- kdWarning() << "'"<< service->desktopEntryPath() << "' specifies undefined mimetype/servicetype '"<< (*it) << "'" << endl; -+ kdDebug() << "'"<< service->desktopEntryPath() << "' specifies undefined mimetype/servicetype '"<< (*it) << "'" << endl; - continue; - } - serviceTypes.append(serviceType); diff --git a/opensuse/core/tdelibs/smooth-scrolling.diff b/opensuse/core/tdelibs/smooth-scrolling.diff deleted file mode 100644 index b369a6146..000000000 --- a/opensuse/core/tdelibs/smooth-scrolling.diff +++ /dev/null @@ -1,267 +0,0 @@ -Index: khtml/khtmlview.cpp -=================================================================== ---- khtml/khtmlview.cpp.orig -+++ khtml/khtmlview.cpp -@@ -151,6 +151,9 @@ public: - - KHTMLViewPrivate() - : underMouse( 0 ), underMouseNonShared( 0 ), visibleWidgets( 107 ) -+#ifndef NO_SMOOTH_SCROLL_HACK -+ , dx(0), dy(0), ddx(0), ddy(0), rdx(0), rdy(0), scrolling(false) -+#endif - { - #ifndef KHTML_NO_CARET - m_caretViewContext = 0; -@@ -396,6 +399,17 @@ public: - short m_mouseScroll_byY; - QTimer *m_mouseScrollTimer; - QWidget *m_mouseScrollIndicator; -+#ifndef NO_SMOOTH_SCROLL_HACK -+ QTimer timer2; -+ int dx; -+ int dy; -+ // Step size * 16 and residual to avoid huge difference between 1px/step and 2px/step -+ int ddx; -+ int ddy; -+ int rdx; -+ int rdy; -+ bool scrolling; -+#endif - }; - - #ifndef QT_NO_TOOLTIP -@@ -504,6 +518,11 @@ KHTMLView::KHTMLView( KHTMLPart *part, Q - init(); - - viewport()->show(); -+#ifndef NO_SMOOTH_SCROLL_HACK -+#define timer timer2 -+ connect(&d->timer, SIGNAL(timeout()), this, SLOT(scrollTick())); -+#undef timer -+#endif - } - - KHTMLView::~KHTMLView() -@@ -1544,7 +1563,7 @@ void KHTMLView::keyPressEvent( QKeyEvent - case Key_Down: - case Key_J: - if (!d->scrollTimerId || d->scrollSuspended) -- scrollBy( 0, 10 ); -+ scrollBy( 0, 10 * _ke->count() ); - if (d->scrollTimerId) - d->newScrollTimer(this, 0); - break; -@@ -1559,7 +1578,7 @@ void KHTMLView::keyPressEvent( QKeyEvent - case Key_Up: - case Key_K: - if (!d->scrollTimerId || d->scrollSuspended) -- scrollBy( 0, -10 ); -+ scrollBy( 0, -10 * _ke->count()); - if (d->scrollTimerId) - d->newScrollTimer(this, 0); - break; -@@ -1572,14 +1591,14 @@ void KHTMLView::keyPressEvent( QKeyEvent - case Key_Right: - case Key_L: - if (!d->scrollTimerId || d->scrollSuspended) -- scrollBy( 10, 0 ); -+ scrollBy( 10 * _ke->count(), 0 ); - if (d->scrollTimerId) - d->newScrollTimer(this, 0); - break; - case Key_Left: - case Key_H: - if (!d->scrollTimerId || d->scrollSuspended) -- scrollBy( -10, 0 ); -+ scrollBy( -10 * _ke->count(), 0 ); - if (d->scrollTimerId) - d->newScrollTimer(this, 0); - break; -@@ -1712,8 +1731,16 @@ void KHTMLView::keyReleaseEvent(QKeyEven - d->scrollSuspendPreActivate = false; - if( _ke->key() == Key_Shift && d->scrollSuspendPreActivate && _ke->state() == Qt::ShiftButton - && !(KApplication::keyboardMouseState() & Qt::ShiftButton)) -+ { - if (d->scrollTimerId) -- d->scrollSuspended = !d->scrollSuspended; -+ { -+ d->scrollSuspended = !d->scrollSuspended; -+#ifndef NO_SMOOTH_SCROLL_HACK -+ if( d->scrollSuspended ) -+ stopScrolling(); -+#endif -+ } -+ } - - if (d->accessKeysEnabled) - { -@@ -3259,7 +3286,11 @@ void KHTMLView::viewportWheelEvent(QWhee - else - { - d->scrollBarMoved = true; -+#ifndef NO_SMOOTH_SCROLL_HACK -+ scrollViewWheelEvent( e ); -+#else - QScrollView::viewportWheelEvent( e ); -+#endif - - QMouseEvent *tempEvent = new QMouseEvent( QEvent::MouseMove, QPoint(-1,-1), QPoint(-1,-1), Qt::NoButton, e->state() ); - emit viewportMouseMoveEvent ( tempEvent ); -@@ -4462,4 +4493,117 @@ void KHTMLView::moveCaretToLineEnd() - - #endif // KHTML_NO_CARET - -+#ifndef NO_SMOOTH_SCROLL_HACK -+#define timer timer2 -+ -+// All scrolls must be completed within 240ms of last keypress -+static const int SCROLL_TIME = 240; -+// Each step is 20 ms == 50 frames/second -+static const int SCROLL_TICK = 20; -+ -+void KHTMLView::scrollBy(int dx, int dy) -+{ -+ KConfigGroup cfg( KGlobal::config(), "KDE" ); -+ if( !cfg.readBoolEntry( "SmoothScrolling", true )) { -+ QScrollView::scrollBy( dx, dy ); -+ return; -+ } -+ // scrolling destination -+ int full_dx = d->dx + dx; -+ int full_dy = d->dy + dy; -+ -+ // scrolling speed -+ int ddx = 0; -+ int ddy = 0; -+ -+ int steps = SCROLL_TIME/SCROLL_TICK; -+ -+ ddx = (full_dx*16)/steps; -+ ddy = (full_dy*16)/steps; -+ -+ // don't go under 1px/step -+ if (ddx > 0 && ddx < 16) ddx = 16; -+ if (ddy > 0 && ddy < 16) ddy = 16; -+ if (ddx < 0 && ddx > -16) ddx = -16; -+ if (ddy < 0 && ddy > -16) ddy = -16; -+ -+ d->dx = full_dx; -+ d->dy = full_dy; -+ d->ddx = ddx; -+ d->ddy = ddy; -+ -+ if (!d->scrolling) { -+ scrollTick(); -+ startScrolling(); -+ } -+} -+ -+void KHTMLView::scrollTick() { -+ if (d->dx == 0 && d->dy == 0) { -+ stopScrolling(); -+ return; -+ } -+ -+ int tddx = d->ddx + d->rdx; -+ int tddy = d->ddy + d->rdy; -+ -+ int ddx = tddx / 16; -+ int ddy = tddy / 16; -+ d->rdx = tddx % 16; -+ d->rdy = tddy % 16; -+ -+ if (d->dx > 0 && ddx > d->dx) ddx = d->dx; -+ else -+ if (d->dx < 0 && ddx < d->dx) ddx = d->dx; -+ -+ if (d->dy > 0 && ddy > d->dy) ddy = d->dy; -+ else -+ if (d->dy < 0 && ddy < d->dy) ddy = d->dy; -+ -+ d->dx -= ddx; -+ d->dy -= ddy; -+ -+// QScrollView::setContentsPos( contentsX() + ddx, contentsY() + ddy); -+ kapp->syncX(); -+ QScrollView::scrollBy(ddx, ddy); -+// Unaccelerated X can get seriously overloaded by scrolling and for some reason -+// will send KeyPress events only infrequently. This should help to reduce -+// the load. -+ kapp->syncX(); -+} -+ -+void KHTMLView::startScrolling() -+{ -+ d->scrolling = true; -+ d->timer.start(SCROLL_TICK, false); -+} -+ -+void KHTMLView::stopScrolling() -+{ -+ d->timer.stop(); -+ d->dx = d->dy = 0; -+ d->scrolling = false; -+} -+ -+// Overloaded from QScrollView and QScrollBar -+void KHTMLView::scrollViewWheelEvent( QWheelEvent *e ) -+{ -+ int pageStep = verticalScrollBar()->pageStep(); -+ int lineStep = verticalScrollBar()->lineStep(); -+ int step = QMIN( QApplication::wheelScrollLines()*lineStep, pageStep ); -+ if ( ( e->state() & ControlButton ) || ( e->state() & ShiftButton ) ) -+ step = pageStep; -+ -+ if(e->orientation() == Horizontal) -+ scrollBy(-((e->delta()*step)/120), 0); -+ else if(e->orientation() == Vertical) -+ scrollBy(0,-((e->delta()*step)/120)); -+ -+ e->accept(); -+} -+ -+#undef timer -+ -+#endif // NO_SMOOTH_SCROLL_HACK -+ - #undef DEBUG_CARETMODE -Index: khtml/khtmlview.h -=================================================================== ---- khtml/khtmlview.h.orig -+++ khtml/khtmlview.h -@@ -181,6 +181,11 @@ signals: - void hideAccessKeys(); - void repaintAccessKeys(); - void findAheadActive( bool ); -+//#define NO_SMOOTH_SCROLL_HACK -+#ifndef NO_SMOOTH_SCROLL_HACK -+public slots: -+ void scrollBy(int dx, int dy); -+#endif - - protected: - void clear(); -@@ -211,9 +216,23 @@ protected: - void contentsContextMenuEvent ( QContextMenuEvent *_ce ); - void doAutoScroll(); - void timerEvent ( QTimerEvent * ); -+ -+#ifndef NO_SMOOTH_SCROLL_HACK -+ void startScrolling(); -+ void stopScrolling(); -+#ifndef QT_NO_WHEELEVENT -+ void scrollViewWheelEvent( QWheelEvent* e ); -+#endif -+#endif -+ - protected slots: - void slotPaletteChanged(); - void slotScrollBarMoved(); -+#ifndef NO_SMOOTH_SCROLL_HACK -+ void scrollTick(); -+#else -+ void scrollTick() {}; // moc cannot handle #if -+#endif - - private slots: - void tripleClickTimeout(); diff --git a/opensuse/core/tdelibs/spellcheck-default-utf8.diff b/opensuse/core/tdelibs/spellcheck-default-utf8.diff deleted file mode 100644 index e663bdc69..000000000 --- a/opensuse/core/tdelibs/spellcheck-default-utf8.diff +++ /dev/null @@ -1,26 +0,0 @@ -Index: kdeui/ksconfig.cpp -=================================================================== ---- kdeui/ksconfig.cpp.orig -+++ kdeui/ksconfig.cpp -@@ -187,7 +187,7 @@ KSpellConfig::readGlobalSettings() - setRunTogether ( kc->readNumEntry("KSpell_RunTogether", 0) ); - setDictionary ( kc->readEntry("KSpell_Dictionary") ); - setDictFromList ( kc->readNumEntry("KSpell_DictFromList", false) ); -- setEncoding ( kc->readNumEntry ("KSpell_Encoding", KS_E_ASCII) ); -+ setEncoding ( kc->readNumEntry ("KSpell_Encoding", KS_E_UTF8) ); - setClient ( kc->readNumEntry ("KSpell_Client", KS_CLIENT_ISPELL) ); - - return true; -Index: kdeui/ksyntaxhighlighter.cpp -=================================================================== ---- kdeui/ksyntaxhighlighter.cpp.orig -+++ kdeui/ksyntaxhighlighter.cpp -@@ -551,7 +551,7 @@ QString KDictSpellingHighlighter::spellK - key += '/'; - key += QString::number( config->readNumEntry( "KSpell_DictFromList", false )); - key += '/'; -- key += QString::number( config->readNumEntry( "KSpell_Encoding", KS_E_ASCII )); -+ key += QString::number( config->readNumEntry( "KSpell_Encoding", KS_E_UTF8 )); - key += '/'; - key += QString::number( config->readNumEntry( "KSpell_Client", KS_CLIENT_ISPELL )); - return key; diff --git a/opensuse/core/tdelibs/stat-on-media.diff b/opensuse/core/tdelibs/stat-on-media.diff deleted file mode 100644 index c8f25a9c8..000000000 --- a/opensuse/core/tdelibs/stat-on-media.diff +++ /dev/null @@ -1,14 +0,0 @@ -Index: kio/kio/kdirwatch.cpp -=================================================================== ---- kio/kio/kdirwatch.cpp.orig -+++ kio/kio/kdirwatch.cpp -@@ -743,7 +743,8 @@ bool KDirWatchPrivate::useINotify( Entry - - bool KDirWatchPrivate::useStat(Entry* e) - { -- if (KIO::probably_slow_mounted(e->path)) -+ if ( e->path.startsWith("/media/") || (e->path == "/media") -+ || (KIO::probably_slow_mounted(e->path)) ) - useFreq(e, m_nfsPollInterval); - else - useFreq(e, m_PollInterval); diff --git a/opensuse/core/tdelibs/tdelibs-devel-doc.spec b/opensuse/core/tdelibs/tdelibs-devel-doc.spec index f92476488..cef0e454a 100644 --- a/opensuse/core/tdelibs/tdelibs-devel-doc.spec +++ b/opensuse/core/tdelibs/tdelibs-devel-doc.spec @@ -26,12 +26,12 @@ License: GPLv2+ Group: Documentation/HTML BuildRoot: %{_tmppath}/%{name}-%{version}-build Summary: Additional Package Documentation -Version: R13.99 +Version: 3.5.12.99 Release: 1 %define tdelibs_patch_level b BuildArch: noarch Requires: tdelibs qt3-devel-doc -Source0: tdelibs-%{version}.tar.bz2 +Source0: kdelibs-%{version}.tar.bz2 Source1: create-kdeapi Source4: api_docu_description @@ -50,7 +50,7 @@ Authors: %prep echo %suse_version -%setup -q -n tdelibs-%{version} +%setup -q -n kdelibs-%{version} %build %if %is_plus diff --git a/opensuse/core/tdelibs/tdelibs.spec b/opensuse/core/tdelibs/tdelibs.spec index 314ae8d5d..074343f57 100644 --- a/opensuse/core/tdelibs/tdelibs.spec +++ b/opensuse/core/tdelibs/tdelibs.spec @@ -19,7 +19,7 @@ Name: tdelibs -BuildRequires: OpenEXR-devel arts arts-devel aspell-devel cups-devel fam-devel flac-devel krb5-devel +BuildRequires: OpenEXR-devel arts-devel aspell-devel cups-devel fam-devel flac-devel krb5-devel BuildRequires: libart_lgpl-devel libidn-devel libsndfile libtiff-devel BuildRequires: libxslt-devel openldap2-devel pcre-devel libtqt4-devel sgml-skel BuildRequires: db-devel libacl-devel libattr-devel unsermake update-desktop-files utempter @@ -34,7 +34,7 @@ Summary: Trinity Base Libraries Version: R13.99 Release: 1 Provides: kups keramik tdelibs-cups tdelibs-33addons tdepim-networkstatus -Provides: kdelibs3_base = 3.3 +Provides: kdelibs3_base = 3.5.13 Requires: libtqt4 >= %( echo `rpm -q --queryformat '%{VERSION}' libtqt4`) Requires: openssl tdelibs-default-style Requires: hicolor-icon-theme @@ -44,15 +44,35 @@ Source0: %{name}-%{version}.tar.bz2 Source3: baselibs.conf Source4: api_docu_description Source6: tderc -# svn export svn://anonsvn.kde.org/home/kde/branches/KDE/3.5/kde-common/admin -Source8: admin.tar.bz2 Source9: cr16-filesys-file_broken.png -Source10: kdemm-20050330.tar.bz2 Source11: 10888-bt.tar.gz Source12: mimetype-icons.tar.bz2 Source14: vnd.openxmlformats-officedocument.wordprocessingml.document.desktop Source15: vnd.openxmlformats-officedocument.presentationml.presentation.desktop Source16: vnd.openxmlformats-officedocument.spreadsheetml.sheet.desktop +Patch1: kdeversion.diff +Patch5: applications.menu-fallback.diff +Patch10: disable-idn-support.diff +Patch15: add-suse-translations.diff +Patch16: kde3rc.dif +Patch27: noauto-package.diff +Patch29: prefer_distribution_settings.dif +Patch50: fix-gnome-help-support.diff +Patch950: fix-gnome-help-support_legacy.diff +Patch52: kdeprint-restart-cupsd.diff +Patch56: fix-dcopidlng-within-kdelibs-build.diff +Patch65: integrate-global-pixmaps-new.diff +Patch66: integrate-global-pixmaps-10.1.diff +Patch105: kdelibs3-hicolor-scalable-sizes.patch +Patch127: x-jar-desktop.diff +Patch129: default-useragent.diff +Patch132: no-debug-by-default.diff +Patch133: flash-player-non-oss.diff +Patch153: bug-382959_kabc_fix_vcardparser.patch +Patch157: ignore-inline-menu.diff +Patch162: arts-acinclude.patch +Patch205: kdelibs-3.5.10-cve-2009-2537-select-length.patch +Patch210: kdelibs-3.5.10-kio.patch %description This package contains tdelibs, one of the basic packages of the Trinity @@ -118,9 +138,45 @@ to develop applications that require these. %prep echo %suse_version %setup -q -tar xfvj %SOURCE10 -rm -rf admin -bunzip2 -cd %{SOURCE8} | tar xfv - --exclude=.cvsignore --exclude=CVS +%patch1 +%patch5 +#%patch10 +%patch15 +#%patch16 +%patch27 +%patch29 +%if %suse_version > 1020 +%patch50 +%else +%patch950 +%endif +%patch52 +%patch56 +%if %suse_version > 1010 +%patch65 +%else +%if %suse_version > 1000 +%patch66 +%else +%patch65 +%endif +%endif +%if %suse_version < 1030 +%patch105 -p 1 +%endif +%patch127 +%patch129 +#%patch132 +%if %suse_version > 1020 +%patch133 +%endif +%patch153 +%if %suse_version > 1110 +%patch157 +%endif +%patch162 -p1 +%patch205 -p1 +%patch210 -p1 tar xfvj %SOURCE12 # @@ -134,7 +190,7 @@ sed 's,#define KDE_VERSION_STRING "\(.*\)",#define KDE_VERSION_STRING "\1 \\"rel #UNSERMAKE=yes make -f admin/Makefile.common cvs %build -export PATH=$PWD/admin/:$PATH +#export PATH=$PWD/admin/:$PATH FINAL="--enable-final" CFLAGS="$CFLAGS -fno-strict-aliasing" CXXFLAGS="$CXXFLAGS -fno-strict-aliasing" @@ -160,12 +216,6 @@ CXXFLAGS="$CXXFLAGS -fno-strict-aliasing" EXTRA_FLAGS="-DCMAKE_SKIP_RPATH=OFF -DKDE_MALLOC_FULL=OFF -DKDE_MALLOC=OFF -DSSL_INSTALL_DIR=/usr/ssl -DPCSC_INSTALL_DIR=/usr -DENABLE_DNOFIFY=ON" -# -DKDE_DISTRIBUTION=\"$DISTRI\" - -# %if %is_plus -# -DENABLE_DNOFIFY=ON \ -# %endif - %cmake_tde -d build -- $EXTRA_FLAGS %make_tde -d build @@ -371,6 +421,7 @@ mv -v %{buildroot}/%{_tde_sharedir}/cmake/tdelibs.cmake %{buildroot}/%{_datadir} %dir %{_tde_includedir} %dir %{_tde_sharedir} %dir %{_tde_configkcfgdir} +%_mandir/man*/* %{_tde_bindir}/checkXML %{_tde_bindir}/dcop %{_tde_bindir}/dcopclient @@ -390,7 +441,7 @@ mv -v %{buildroot}/%{_tde_sharedir}/cmake/tdelibs.cmake %{buildroot}/%{_datadir} %{_tde_bindir}/tdeinit* %{_tde_bindir}/start_tdeinit %{_tde_bindir}/start_tdeinit_wrapper -%{_tde_bindir}/kde-config +%{_tde_bindir}/tde-config %{_tde_bindir}/kde-menu %{_tde_bindir}/tdesu_stub %{_tde_bindir}/kdontchangethehostname @@ -400,6 +451,7 @@ mv -v %{buildroot}/%{_tde_sharedir}/cmake/tdelibs.cmake %{buildroot}/%{_datadir} %{_tde_bindir}/klauncher %{_tde_bindir}/kmailservice %{_tde_bindir}/ktradertest +%{_tde_bindir}/knotify %{_tde_bindir}/kstartupconfig %{_tde_bindir}/kdostartupconfig %verify(not mode) %{_tde_bindir}/kpac_dhcp_helper @@ -522,6 +574,8 @@ mv -v %{buildroot}/%{_tde_sharedir}/cmake/tdelibs.cmake %{buildroot}/%{_datadir} %dir %{_tde_sharedir} %dir %{_tde_applicationsdir} %ghost %{_tde_applicationsdir}/mimeinfo.cache +%dir %{_tde_datadir}/konqueror +%dir %{_tde_datadir}/konqueror/servicemenus %{_tde_datadir}/konqueror/servicemenus/isoservice.desktop %files arts @@ -542,10 +596,12 @@ mv -v %{buildroot}/%{_tde_sharedir}/cmake/tdelibs.cmake %{buildroot}/%{_datadir} %{_tde_bindir}/dcopidl* %{_tde_bindir}/kmimelist %{_tde_bindir}/preparetips +%{_tde_bindir}/ksvgtopng %{_tde_bindir}/kunittestmodrunner #%{_tde_bindir}/MISC %{_tde_includedir}/* %{_tde_datadir}/dcopidlng +%{_tde_datadir}/kdelibs/admin %{_tde_libdir}/libartskde.la %{_tde_libdir}/libkunittest.la %{_tde_libdir}/libkunittest.so @@ -562,8 +618,6 @@ mv -v %{buildroot}/%{_tde_sharedir}/cmake/tdelibs.cmake %{buildroot}/%{_datadir} %{_tde_libdir}/libkabc.la %{_tde_libdir}/libkabc_ldapkio.la %{_tde_libdir}/libkabc_ldapkio.so -%{_tde_libdir}/libkabc_net.la -%{_tde_libdir}/libkabc_net.so %{_tde_libdir}/libkabc.so %{_tde_libdir}/libkatepartinterfaces.la %{_tde_libdir}/libkatepartinterfaces.so diff --git a/opensuse/core/tdelibs/tdelibs.spec.old b/opensuse/core/tdelibs/tdelibs.spec.old deleted file mode 100644 index ca1a72b7b..000000000 --- a/opensuse/core/tdelibs/tdelibs.spec.old +++ /dev/null @@ -1,826 +0,0 @@ -# -# spec file for package tdelibs -# -# Copyright (c) 2011 the Trinity Project (opensuse). -# -# All modifications and additions to the file contributed by third parties -# remain the property of their copyright owners, unless otherwise agreed -# upon. The license for this file, and modifications and additions to the -# file, is the same license as for the pristine package itself (unless the -# license for the pristine package is not an Open Source License, in which -# case the license is the MIT License). An "Open Source License" is a -# license that conforms to the Open Source Definition (Version 1.9) -# published by the Open Source Initiative. - -# Please submit bugfixes or comments via http://bugs.trinitydesktop.org/ -# - -# norootforbuild - - -Name: tdelibs -BuildRequires: OpenEXR-devel arts-devel aspell-devel cups-devel fam-devel flac-devel krb5-devel -BuildRequires: libart_lgpl-devel libidn-devel libsndfile libtiff-devel -BuildRequires: libxslt-devel openldap2-devel pcre-devel libtqt4-devel sgml-skel -BuildRequires: db-devel libacl-devel libattr-devel unsermake update-desktop-files utempter -BuildRequires: unzip -BuildRequires: avahi-compat-mDNSResponder-devel fdupes libbz2-devel libjasper-devel -BuildRequires: libdrm-devel tde-filesystem cmake -URL: http://www.trinitydesktop.org/ -License: BSD3c(or similar) ; GPLv2+ ; LGPLv2.1+ -Group: System/GUI/TDE -BuildRoot: %{_tmppath}/%{name}-%{version}-build -Summary: Trinity Base Libraries -Version: R13.99 -Release: 1 -Provides: kups keramik tdelibs-cups tdelibs-33addons tdepim-networkstatus -Provides: kdelibs3_base = 3.3 -Requires: libtqt4 >= %( echo `rpm -q --queryformat '%{VERSION}' libtqt4`) -Requires: openssl tdelibs-default-style -Requires: hicolor-icon-theme -Recommends: ispell enscript -Requires: sudo -Source0: %{name}-%{version}.tar.bz2 -Source3: baselibs.conf -Source4: api_docu_description -Source6: tderc -# svn export svn://anonsvn.kde.org/home/kde/branches/KDE/3.5/kde-common/admin -Source8: admin.tar.bz2 -Source9: cr16-filesys-file_broken.png -Source10: kdemm-20050330.tar.bz2 -Source11: 10888-bt.tar.gz -Source12: mimetype-icons.tar.bz2 -Source14: vnd.openxmlformats-officedocument.wordprocessingml.document.desktop -Source15: vnd.openxmlformats-officedocument.presentationml.presentation.desktop -Source16: vnd.openxmlformats-officedocument.spreadsheetml.sheet.desktop -Patch0: 3_5_BRANCH.diff -Patch1: kdeversion.diff -Patch2: admin.diff -Patch3: show-distribution.diff -Patch5: applications.menu-fallback.diff -Patch7: stat-on-media.diff -Patch8: kmimelist.diff -Patch9: x-kde-InitialPreference.diff -Patch10: disable-idn-support.diff -Patch11: silence.diff -Patch12: smooth-scrolling.diff -Patch13: rubberband-selection.diff -Patch15: add-suse-translations.diff -Patch16: kde3rc.dif -Patch17: artwork.diff -Patch26: mimetype-changes.diff -Patch27: noauto-package.diff -Patch29: prefer_distribution_settings.dif -Patch34: allow-man-setgid.diff -Patch40: clever-menu.diff -Patch43: fileshare.diff -Patch44: fontconfig-reverse-lookup.diff -Patch45: limit-max-image-size.diff -Patch50: fix-gnome-help-support.diff -Patch950: fix-gnome-help-support_legacy.diff -Patch52: kdeprint-restart-cupsd.diff -Patch54: kdemm.diff -Patch55: fix-kdemm-build.diff -Patch56: fix-dcopidlng-within-kdelibs-build.diff -Patch57: kdemm-filepreview.diff -Patch60: fix-qxembed.diff -Patch65: integrate-global-pixmaps-new.diff -Patch66: integrate-global-pixmaps-10.1.diff -Patch70: ktip-icon-hack.diff -Patch80: CATALOG.kdelibs3.diff -Patch81: xml-catalog.diff -Patch83: kdelibs3-gcc-4.1-miscompile.diff -Patch85: desktop-translations.diff -Patch86: use-xauthlocalhostname.diff -Patch88: mozilla-sliders.patch -Patch89: kdeprint-utf8.diff -Patch90: kimproxy-warning.diff -Patch95: kdelibs_networkstatus_branch2.diff -Patch97: autostart-spec.diff -Patch105: kdelibs3-hicolor-scalable-sizes.patch -Patch106: use-mediamanager.diff -Patch108: patch-mimetype-iconnames.diff -Patch109: fix-kerberos-printing.diff -Patch110: printpreview.patch -Patch111: kfile-beagle.diff -Patch112: xinerama.patch -Patch113: kremoteencoding-utf8.diff -Patch114: no-progress-for-beagle-status-query.diff -Patch117: kickoff-drop-shadow.diff -Patch122: disable-samba-dialog-without-smb.diff -Patch123: lpoptions-cups-1.2.diff -Patch124: spellcheck-default-utf8.diff -Patch125: kde4-applications.diff -Patch126: avahi-pidfile.diff -Patch127: x-jar-desktop.diff -Patch128: google-mail.diff -Patch129: default-useragent.diff -Patch130: kwalletd-try-open.diff -Patch131: textcompletion-editor.diff -Patch132: no-debug-by-default.diff -Patch133: flash-player-non-oss.diff -Patch134: bundle-locale-help.diff -Patch149: networkstatus.diff -Patch150: kdesu-settings.diff -Patch152: bug-399296_ftphandling-fix.diff -Patch153: bug-382959_kabc_fix_vcardparser.patch -Patch154: r874968-ebay-crash.diff -Patch155: gcc44.diff -Patch156: fix-macmenu.patch -Patch157: ignore-inline-menu.diff -Patch158: bnc557126.diff -Patch159: xmlhttprequest_3.x.diff -Patch160: kdecode_fakes_include.diff -Patch161: gcc45.diff -Patch162: arts-acinclude.patch -Patch163: kdelibs-3.5.10-ossl-1.x.patch -Patch164: light_v_2_scrollbar_patch.patch - -Patch201: kdelibs-3.5.4-CVE-2009-1690.patch -Patch203: kdelibs-3.5.10-latex-syntax-kile-2.0.3.patch -Patch204: kdelibs-3.5.10-CVE-2009-2702.patch -Patch205: kdelibs-3.5.10-cve-2009-2537-select-length.patch -Patch206: kdelibs-3.5.10-cve-2009-1725.patch -Patch207: kdelibs-3.5.10-cve-2009-1698.patch - -Patch210: kdelibs-3.5.10-kio.patch -Patch211: oom_score_adj.patch -Patch212: kcontrol_crash_patch.diff - -%description -This package contains tdelibs, one of the basic packages of the Trinity -Desktop Environment. It contains the necessary libraries for the Trinity -desktop. - -This package is absolutely necessary for using TDE. - -%package arts -License: BSD3c(or similar) ; GPLv2+ ; LGPLv2.1+ -Summary: TDE aRts support -Group: System/GUI/TDE -Provides: tdelibs:/opt/tde/bin/artsmessage -Requires: arts >= %( echo `rpm -q --queryformat '%{VERSION}' arts`) -Recommends: tdemultimedia-arts - -%description arts -This package contains bindings and gui elements for using aRts sound -daemon. - -%package default-style -License: BSD3c(or similar) ; GPLv2+ ; LGPLv2.1+ -Summary: The default TDE style -Group: System/GUI/TDE -Provides: tdelibs:/opt/tde/%_lib/libkdefx.so.4 - -%description default-style -This package contains the Plastik widget style and libkdefx. It only -depends on TQt, not the KDE libraries. - -%package doc -License: BSD3c(or similar) ; GPLv2+ ; LGPLv2.1+ -Summary: Documentation for TDE Base Libraries -Group: System/GUI/TDE -Provides: tdelibs:/opt/tde/share/apps/ksgmltools2 -Provides: tdelibs_doc -Requires: sgml-skel libxml2 -%define regcat /usr/bin/sgml-register-catalog -PreReq: %{regcat} /usr/bin/xmlcatalog /usr/bin/edit-xml-catalog -PreReq: sed grep awk - -%description doc -This package contains the core environment and templates for the Trinity -help system. - -%package devel -License: BSD3c(or similar) ; GPLv2+ ; LGPLv2.1+ -# usefiles /opt/tde/bin/dcopidl /opt/tde/bin/dcopidl2cpp /opt/tde/bin/kdb2html /opt/tde/bin/preparetips -Requires: libtqt4-devel libvorbis-devel tdelibs = %version autoconf automake libxslt-devel libxml2-devel libart_lgpl-devel libjpeg-devel tde-filesystem -# next line from tde-devel-packages macro -Requires: tdelibs-doc libtiff-devel openssl-devel update-desktop-files -Requires: libdrm-devel dbus-1-tqt-devel -Requires: libattr-devel libacl-devel -Requires: tdelibs-arts -Summary: Trinity Base Package: Build Environment -Group: System/GUI/TDE -Requires: fam-devel pcre-devel libidn-devel arts-devel - -%description devel -This package contains all necessary include files and libraries needed -to develop applications that require these. - -%prep - echo %suse_version -%setup -q -%patch0 -%patch1 -%patch3 -%patch5 -%patch7 -%patch10 -%patch11 -%patch12 -%patch13 -%patch15 -%patch16 -%patch17 -%patch26 -%patch27 -%patch29 -#%patch43 -#disable it because of BIC -#%patch45 -%if %suse_version > 1020 -%patch50 -%else -%patch950 -%endif -%patch52 -%patch34 -%patch44 -%patch40 -%patch8 -%patch9 -tar xfvj %SOURCE10 -# TODO! -%patch54 -%patch55 -%patch56 -%patch57 -%patch60 -# 10.2 goes back to the version without suseadds -%if %suse_version > 1010 -%patch65 -%else -%if %suse_version > 1000 -%patch66 -%else -%patch65 -%endif -%endif -%patch70 -rm -rf admin -bunzip2 -cd %{SOURCE8} | tar xfv - --exclude=.cvsignore --exclude=CVS -install -m 755 %{SOURCE2} admin -%patch2 -%patch80 -p 1 -%patch81 -%if %suse_version > 1000 -%patch83 -%endif -%patch85 -%patch86 -%patch88 -%patch89 -%patch90 -%patch95 -%patch97 -%if %suse_version < 1030 -%patch105 -p 1 -%endif -%patch106 -%patch108 -%patch109 -%patch110 -%patch111 -%patch112 -%patch113 -%patch114 -%patch117 -%patch122 -%if %suse_version > 1010 -%patch123 -%endif -%patch124 -%patch125 -%patch126 -%patch127 -%patch128 -%patch129 -%patch130 -%patch131 -%patch132 -%if %suse_version > 1020 -%patch133 -%patch134 -%endif -%patch149 -%patch150 -%patch152 -%patch153 -%patch154 -%patch155 -%patch156 -%if %suse_version > 1110 -%patch157 -%endif -%patch158 -%patch159 -%patch160 -%patch161 -%patch162 -p1 -%patch163 -p1 -%patch164 -p1 -%patch201 -p1 -%patch203 -p1 -%patch204 -p1 -%patch205 -p1 -%patch206 -%patch207 -p1 -%patch210 -p1 -%patch211 -p1 -%patch212 - -tar xfvj %SOURCE12 -# -# define KDE version exactly -# -myrelease=$(echo %release | cut -d. -f-1) -sed 's,#define KDE_VERSION_STRING "\(.*\)",#define KDE_VERSION_STRING "\1 \\"release '$myrelease'\\"",' kdecore/kdeversion.h > kdecore/kdeversion.h_ && mv kdecore/kdeversion.h_ kdecore/kdeversion.h -# -# create build enviroment -# -#UNSERMAKE=yes make -f admin/Makefile.common cvs - -%build -export PATH=$PWD/admin/:$PATH -FINAL="--enable-final" -CFLAGS="$CFLAGS -fno-strict-aliasing" -CXXFLAGS="$CXXFLAGS -fno-strict-aliasing" - -# common_options and do_make have been obsoleted by tde-filesystem - - export path_sudo=/usr/bin/sudo - # - # define the distribution exactly - # - test -e /.buildenv && . /.buildenv -%if %is_plus - # supplementary package - DISTRI="openSUSE $BUILD_DISTRIBUTION_VERSION UNSUPPORTED" -%else - # official build on released and maintained products - DISTRI="openSUSE $BUILD_DISTRIBUTION_VERSION" -%endif - sed 's,#define KDE_VERSION_STRING "\(.*\)",#define KDE_VERSION_STRING "\1 '"$ADD_VERSION"'",' kdecore/kdeversion.h > kdecore/kdeversion.h_ && mv kdecore/kdeversion.h_ kdecore/kdeversion.h - # find MIT kerberos - export PATH=/usr/lib/mit/bin:$PATH - # fast-malloc is not needed anymore - -%cmake_tde -d build -- \ - -DCMAKE_SKIP_RPATH=OFF \ - -DKDE_MALLOC_FULL=OFF \ - -DKDE_MALLOC=OFF \ - -DKDE_DISTRIBUTION="$DISTRI" \ - -DSSL_INSTALL_DIR=/usr/ssl \ - -DPCSC_INSTALL_DIR=/usr \ - %if %is_plus - -DENABLE_DNOFIFY=ON \ - %endif - -%make_tde -d build - -# -xmlcatbin=/usr/bin/xmlcatalog -# CATALOG=docbook-simple.xml -# $xmlcatbin --noout --create $CATALOG -# $xmlcatbin --noout --add "public" \ -# "-//OASIS//DTD Simplified DocBook XML V1.0//EN" \ -# "file://%{xml_mod_dtd_dir}/sdocbook.dtd" $CATALOG -# $xmlcatbin --noout --add "system" \ -# "http://www.oasis-open.org/docbook/xml/simple/1.0/sdocbook.dtd" \ -# "file://%{xml_mod_dtd_dir}/sdocbook.dtd" $CATALOG -%define FOR_ROOT_CAT for-catalog-%{name}-%{version}.xml -CATALOG=%{_tde_prefix}/share/apps/ksgmltools2/customization/catalog.xml -rm -f %{FOR_ROOT_CAT}.tmp -$xmlcatbin --noout --create %{FOR_ROOT_CAT}.tmp -# $xmlcatbin --noout --add "delegateSystem" \ -# "http://www.oasis-open.org/docbook/xml/simple/" \ -# "file:///$CATALOG" %{FOR_ROOT_CAT}.tmp -$xmlcatbin --noout --add "delegatePublic" \ - "-//KDE//DTD DocBook XML V4.2" \ - "file://$CATALOG" %{FOR_ROOT_CAT}.tmp -$xmlcatbin --noout --add "delegatePublic" \ - "-//KDE//ELEMENTS" \ - "file://$CATALOG" %{FOR_ROOT_CAT}.tmp -$xmlcatbin --noout --add "delegatePublic" \ - "-//KDE//ENTITIES" \ - "file://$CATALOG" %{FOR_ROOT_CAT}.tmp -# Create tag -sed '/ -/<\/catalog/i\ - ' \ - %{FOR_ROOT_CAT}.tmp > %{FOR_ROOT_CAT} - -%install - %makeinstall_tde -d build - mkdir -p $RPM_BUILD_ROOT/%{_tde_configkcfgdir} - install -D %SOURCE9 $RPM_BUILD_ROOT/%{_tde_icondir}/crystalsvg/16x16/filesystems/file_broken.png - mv $RPM_BUILD_ROOT/etc/xdg/menus/applications.menu \ - $RPM_BUILD_ROOT/etc/xdg/menus/applications.menu.kde - # - # lib64 compatibility symlink - # -%ifarch x86_64 ppc64 s390x mips64 sparc64 - mkdir -p $RPM_BUILD_ROOT/%{_tde_prefix}/lib/kde3/ - ln -sf ../../lib64/kde3/plugins \ - $RPM_BUILD_ROOT/%{_tde_prefix}/lib/kde3/plugins-lib64 -%endif - # - # add missing directories - # - for i in Applications Development Editors Edutainment Games Graphics Internet Multimedia Office Settings System Toys Utilities WordProcessing; do - install -d -m 0755 $RPM_BUILD_ROOT/%{_tde_appsdir}/$i - done - rm -f locale.list - for i in $(find /usr/share/locale -mindepth 1 -maxdepth 1 -type d | sed 's:/usr/share/locale/::'); do - install -d -m 755 $RPM_BUILD_ROOT/%{_tde_locale}/$i - install -d -m 755 $RPM_BUILD_ROOT/%{_tde_locale}/$i/LC_MESSAGES - install -d -m 755 $RPM_BUILD_ROOT/%{_tde_htmldir}/$i - echo "%lang($i) %doc %{_tde_locale}/$i" >> locale.list - done - %suse_update_desktop_file kresources X-KDE-settings-desktop - # unlike with other modules, tde_post_install shouldn't - # be put at the end of %install - %tde_post_install - # now create a filesystem layer - for theme in hicolor locolor; do - for j in actions apps filesystems mimetypes; do - for i in 16 22 32 48 64 128; do - install -d -m 0755 $RPM_BUILD_ROOT/%{_tde_icondir}/${theme}/${i}x${i}/${j} - done - install -d -m 0755 $RPM_BUILD_ROOT/%{_tde_icondir}/${theme}/scalable/${j} - done - done - install -d -m 0755 $RPM_BUILD_ROOT/etc/%{_tde_libdir} - install -d -m 0755 $RPM_BUILD_ROOT/etc/%{_tde_configdir} - install -d -m 0755 $RPM_BUILD_ROOT/%{_tde_datadir}/kdelibs/ - install -m 0644 %SOURCE6 $RPM_BUILD_ROOT/etc/ - rm -f $RPM_BUILD_ROOT/%{_tde_libdir}/libkdeinit_*.la - # - # add additional icon path (not needed anymore? we use cmake) - # - #mkdir -p ${RPM_BUILD_ROOT}/%{_tde_datadir}/kdelibs - #rm -f admin/*.orig - #cp -a admin ${RPM_BUILD_ROOT}/%{_tde_datadir}/kdelibs/ - # This is not needed on SUSE Linux! - Marcus Meissner - rm $RPM_BUILD_ROOT/%{_tde_bindir}/kgrantpty - # - # our version is in kdebase3 - # - rm -f $RPM_BUILD_ROOT/%{_tde_bindir}/fileshare* - # - # no sources for man pages - # - rm -f $RPM_BUILD_ROOT/%{_tde_htmldir}/en/kdelibs/man-* - # - # install BitTorrent icons - # - tar xfvz %SOURCE11 - for i in 16x16 22x22 32x32 48x48 64x64 128x128 ; do - install -m 0644 bt/$i/mimetypes/bt.png \ - $RPM_BUILD_ROOT/%{_tde_icondir}/crystalsvg/$i/mimetypes/torrent.png - done - cp CATALOG.%{name} catalog.xml ${RPM_BUILD_ROOT}/%{_tde_datadir}/ksgmltools2/customization/ - mkdir -p ${RPM_BUILD_ROOT}%{_sysconfdir}/xml - cp %{FOR_ROOT_CAT} ${RPM_BUILD_ROOT}%{_sysconfdir}/xml -# rm -f $RPM_BUILD_ROOT/%{_tde_libdir}/libkdefakes.la -# rm -f $RPM_BUILD_ROOT/%{_tde_libdir}/libkjava.la -rm -f $RPM_BUILD_ROOT/%{_tde_icondir}/hicolor/index.theme - # .desktop files in kdeaccessibility3 require the kttsd icon - for i in {16x16,22x22,32x32,48x48,64x64,128x128,scalable}; do mv $RPM_BUILD_ROOT/%{_tde_icondir}/crystalsvg/$i/apps/kttsd.* $RPM_BUILD_ROOT/%{_tde_icondir}/hicolor/$i/apps/;done - install -m 0644 %SOURCE14 $RPM_BUILD_ROOT/%{_tde_mimedir}/application/ - install -m 0644 %SOURCE15 $RPM_BUILD_ROOT/%{_tde_mimedir}/application/ - install -m 0644 %SOURCE16 $RPM_BUILD_ROOT/%{_tde_mimedir}/application/ - # fix bnc#396153 - for i in 16x16 22x22 32x32 48x48 64x64 128x128; do - ln -s %{_tde_icondir}/crystalsvg/$i/filesystems/network.png $RPM_BUILD_ROOT/%{_tde_icondir}/crystalsvg/$i/filesystems/preferences-system-network.png - ln -s %{_tde_icondir}/crystalsvg/$i/filesystems/desktop.png $RPM_BUILD_ROOT/%{_tde_icondir}/crystalsvg/$i/filesystems/preferences-desktop.png - done - chmod a-x $RPM_BUILD_ROOT/%{_tde_icondir}/crystalsvg/16x16/filesystems/file_broken.png - %fdupes -s $RPM_BUILD_ROOT - mkdir -p $RPM_BUILD_ROOT/etc/%{_tde_applicationsdir} - touch $RPM_BUILD_ROOT/etc/%{_tde_applicationsdir}/mimeinfo.cache - mkdir -p $RPM_BUILD_ROOT/%{_tde_applicationsdir} - touch $RPM_BUILD_ROOT/%{_tde_applicationsdir}/mimeinfo.cache -# Create /etc/ld.so.conf.d/kdelibs3.conf -mkdir -p $RPM_BUILD_ROOT/etc/ld.so.conf.d -cat > $RPM_BUILD_ROOT/etc/ld.so.conf.d/tdelibs.conf </dev/null 2>&1 - fi - if [ -x /usr/bin/edit-xml-catalog ]; then - edit-xml-catalog --group --catalog /etc/xml/suse-catalog.xml \ - --add /etc/xml/%{FOR_ROOT_CAT} - fi - -%postun doc - if [ "$1" = "0" -a -x %{regcat} ]; then - %{regcat} -r %{_tde_datadir}/ksgmltools2/customization/CATALOG.%{name} >/dev/null 2>&1 - fi - # remove entries only on removal of file - if [ ! -f %{xml_sysconf_dir}/%{FOR_ROOT_CAT} -a -x /usr/bin/edit-xml-catalog ] ; then - edit-xml-catalog --group --catalog /etc/xml/suse-catalog.xml \ - --del %{name}-%{version} - fi - exit 0 - -%clean - rm -rf ${RPM_BUILD_ROOT} - -%files default-style -%defattr(-,root,root) -%doc AUTHORS COPYING COPYING.BSD COPYING.LIB NAMING README -%{_tde_libdir}/libkdefx.so.* -%{_tde_libdir}/kde3/plugins/styles/plastik.* - -%files -%defattr(-,root,root) -%doc AUTHORS COPYING COPYING.BSD COPYING.LIB NAMING README -/etc/ld.so.conf.d/tdelibs.conf -%dir /etc/%{_tde_prefix} -%dir %{_tde_prefix} -%dir %{_tde_bindir} -%dir %{_tde_includedir} -%dir %{_tde_sharedir} -%dir %{_tde_configkcfgdir} -%_mandir/man*/* -%{_tde_bindir}/checkXML -%{_tde_bindir}/dcop -%{_tde_bindir}/dcopclient -%{_tde_bindir}/dcopfind -%{_tde_bindir}/dcopobject -%{_tde_bindir}/dcopref -%{_tde_bindir}/dcops* -%{_tde_bindir}/dcopquit -%{_tde_bindir}/imagetops -%{_tde_bindir}/ka* -%{_tde_bindir}/kbuildsycoca -%{_tde_bindir}/kco* -%{_tde_bindir}/kcmshell -%{_tde_bindir}/kded -%{_tde_bindir}/kdeinit* -%{_tde_bindir}/start_kdeinit -%{_tde_bindir}/start_kdeinit_wrapper -%{_tde_bindir}/kde-config -%{_tde_bindir}/kde-menu -%{_tde_bindir}/kdesu_stub -%{_tde_bindir}/kdontchangethehostname -%{_tde_bindir}/kfile -%{_tde_bindir}/ki* -%{_tde_bindir}/kfmexec -%{_tde_bindir}/klauncher -%{_tde_bindir}/kmailservice -%{_tde_bindir}/ktradertest -%{_tde_bindir}/knotify -%{_tde_bindir}/kstartupconfig -%{_tde_bindir}/kdostartupconfig -%verify(not mode) %{_tde_bindir}/kpac_dhcp_helper -%{_tde_bindir}/ksendbugmail -%{_tde_bindir}/kshell -%{_tde_bindir}/ktelnetservice -%{_tde_bindir}/kwrapper -%{_tde_bindir}/lnusertemp -%{_tde_bindir}/make_driver_db_lpr -%{_tde_bindir}/khotnewstuff -%{_tde_bindir}/makekdewidgets -%dir %{_tde_libdir} -%dir %{_tde_libdir}/kde3 -%{_tde_libdir}/kde3/dcopserver.* -%{_tde_libdir}/kde3/kaddprinterwizard.* -%{_tde_libdir}/kde3/kbuildsycoca.* -%{_tde_libdir}/kde3/kcmshell.* -%{_tde_libdir}/kde3/kcm_kresources.* -%{_tde_libdir}/kde3/kconf_update.* -%{_tde_libdir}/kde3/kcookiejar.* -%{_tde_libdir}/kde3/kded.* -%{_tde_libdir}/kde3/kded_proxyscout.* -%{_tde_libdir}/kde3/kfileaudiopreview.* -%{_tde_libdir}/kde3/klauncher.* -%{_tde_libdir}/kde3/knotify.* -%{_tde_libdir}/kde3/kabc* -%{_tde_libdir}/kde3/kbzip2filter.* -%{_tde_libdir}/kde3/kded_k* -%{_tde_libdir}/kde3/kdeprint_ext.* -%{_tde_libdir}/kde3/kdeprint_lp* -%{_tde_libdir}/kde3/kdeprint_rlpr.* -%{_tde_libdir}/kde3/kdeprint_tool_escputil.* -%{_tde_libdir}/kde3/kgzipfilter.* -%{_tde_libdir}/kde3/khtmlimagepart.* -%{_tde_libdir}/kde3/ki* -%{_tde_libdir}/kde3/kjavaappletviewer.* -%{_tde_libdir}/kde3/ktexteditor_* -%{_tde_libdir}/kde3/libk* -%{_tde_libdir}/kde3/kspell_* -%{_tde_libdir}/kde3/kstyle_plastik_config.* -%{_tde_libdir}/kde3/kstyle_highcontrast_config.* -%{_tde_libdir}/kde3/libshellscript.* -%exclude %{_tde_libdir}/kde3/plugins/styles/plastik.* -%{_tde_libdir}/kde3/plugins -%{_tde_libdir}/libDCOP.so.* -%exclude %{_tde_libdir}/libkdefx.so.* -%{_tde_libdir}/libk*.so.* -%{_tde_libdir}/libvcard.so.* -%{_tde_libdir}/libkdeinit*.so -%{_tde_libdir}/libnetworkstatus.so.* -%{_tde_libdir}/libconnectionmanager.so.* -%{_tde_libdir}/kde3/kded_networkstatus.* -%{_tde_appsdir} -%dir %{_tde_datadir} -%{_tde_datadir}/LICENSES -%{_tde_datadir}/ka* -%{_tde_datadir}/kc* -%dir %{_tde_datadir}/kdeprint -%{_tde_datadir}/kdeprint/apsdriver* -%{_tde_datadir}/kdeprint/filters -%{_tde_datadir}/kdeprint/icons -%{_tde_datadir}/kdeprint/lprngtooldriver1 -%{_tde_datadir}/kdeprint/pics -%dir %{_tde_datadir}/kdeprint/plugins -%{_tde_datadir}/kdeprint/plugins/ext.print -%{_tde_datadir}/kdeprint/plugins/lp*.print -%{_tde_datadir}/kdeprint/plugins/rlpr.print -%{_tde_datadir}/kdeprint/s* -%{_tde_datadir}/kdeprint/t* -%{_tde_datadir}/kdeui -%{_tde_datadir}/kdewidgets -%{_tde_datadir}/khtml -%{_tde_datadir}/kio_uiserver -%{_tde_datadir}/kjava -%{_tde_datadir}/knotify -%{_tde_datadir}/kssl -%{_tde_datadir}/kstyle -%{_tde_datadir}/ktexteditor_* -%{_tde_datadir}/proxyscout -%{_tde_datadir}/knewstuff -%{_tde_sharedir}/autostart -%{_tde_configdir} -%{_tde_sharedir}/emoticons -%{_tde_icondir}/icons -%{_tde_locale}/locale -%{_tde_mimedir}/mimelnk -%{_tde_sharedir}/service* -%config /etc/tderc -%{_tde_applicationsdir} -%{_tde_bindir}/cupsd* -%{_tde_bindir}/make_driver_db_cups -%{_tde_libdir}/kde3/kdeprint_cups.* -%{_tde_libdir}/kde3/cupsdconf.* -%{_tde_datadir}/kdeprint/cups* -%{_tde_datadir}/kdeprint/kde_logo.png -%{_tde_datadir}/kdeprint/plugins/cups.print -%{_tde_datadir}/kdeprint/preview* -%ifarch x86_64 ppc64 s390x mips64 sparc64 -%dir %{_tde_prefix}/lib -%dir %{_tde_prefix}/lib/kde3 -%{_tde_prefix}/lib/kde3/plugins-lib64 -%endif -/etc/xdg/menus -%dir /etc/%{_tde_prefix} -%dir /etc/%{_tde_sharedir} -%dir /etc/%{_tde_applicationsdir} -%ghost /etc/%{_tde_applicationsdir}/mimeinfo.cache -%dir %{_tde_prefix} -%dir %{_tde_sharedir} -%dir %{_tde_applicationsdir} -%ghost %{_tde_applicationsdir}/mimeinfo.cache - - -%files arts -%defattr(-,root,root) -%{_tde_bindir}/artsmessage -%{_tde_libdir}/libartskde.so.* - -%files doc -%defattr(-,root,root) -%doc %{_tde_docdir} -%{_tde_bindir}/meinproc -%{_tde_datadir}/ksgmltools2 -%config %{_sysconfdir}/xml/%{FOR_ROOT_CAT} - -%files devel -%defattr(-,root,root) -%dir %{_tde_datadir}/kdelibs -%{_tde_bindir}/dcopidl* -%{_tde_bindir}/kmimelist -%{_tde_bindir}/preparetips -%{_tde_bindir}/ksvgtopng -%{_tde_bindir}/kunittestmodrunner -#%{_tde_bindir}/MISC -%{_tde_includedir}/* -%{_tde_datadir}/dcopidlng -%{_tde_datadir}/kdelibs/admin -%{_tde_libdir}/libartskde.la -%{_tde_libdir}/libkunittest.la -%{_tde_libdir}/libkunittest.so -%{_tde_libdir}/libartskde.so -%{_tde_libdir}/libDCOP.so -%{_tde_libdir}/libvcard.so -%{_tde_libdir}/libvcard.la -%{_tde_libdir}/libDCOP.la -%{_tde_libdir}/lib*.a -%{_tde_libdir}/libkabc_dir.la -%{_tde_libdir}/libkabc_dir.so -%{_tde_libdir}/libkabc_file.la -%{_tde_libdir}/libkabc_file.so -%{_tde_libdir}/libkabc.la -%{_tde_libdir}/libkabc_ldapkio.la -%{_tde_libdir}/libkabc_ldapkio.so -%{_tde_libdir}/libkabc.so -%{_tde_libdir}/libkatepartinterfaces.la -%{_tde_libdir}/libkatepartinterfaces.so -%{_tde_libdir}/libkdecore.la -%{_tde_libdir}/libkdecore.so -%{_tde_libdir}/libkdefakes.la -%{_tde_libdir}/libkdefakes.so -%{_tde_libdir}/libkdefx.la -%{_tde_libdir}/libkdefx.so -%{_tde_libdir}/libkdemm.la -%{_tde_libdir}/libkdemm.so -%{_tde_libdir}/libkdeprint.la -%{_tde_libdir}/libkdeprint_management.la -%{_tde_libdir}/libkdeprint_management.so -%{_tde_libdir}/libkdeprint.so -%{_tde_libdir}/libkdesasl.la -%{_tde_libdir}/libkdesasl.so -%{_tde_libdir}/libkdesu.la -%{_tde_libdir}/libkdesu.so -%{_tde_libdir}/libkdeui.la -%{_tde_libdir}/libkdeui.so -%{_tde_libdir}/libkdnssd.la -%{_tde_libdir}/libkdnssd.so -%{_tde_libdir}/libkhtml.la -%{_tde_libdir}/libkhtml.so -%{_tde_libdir}/libkimproxy.la -%{_tde_libdir}/libkimproxy.so -%{_tde_libdir}/libkio.la -%{_tde_libdir}/libkio.so -%{_tde_libdir}/libkjava.la -%{_tde_libdir}/libkjava.so -%{_tde_libdir}/libkjs.la -%{_tde_libdir}/libkjs.so -%{_tde_libdir}/libkmdi2.la -%{_tde_libdir}/libkmdi2.so -%{_tde_libdir}/libkmdi.la -%{_tde_libdir}/libkmdi.so -%{_tde_libdir}/libkmediaplayer.la -%{_tde_libdir}/libkmediaplayer.so -%{_tde_libdir}/libkmid.la -%{_tde_libdir}/libkmid.so -%{_tde_libdir}/libknewstuff.la -%{_tde_libdir}/libknewstuff.so -%{_tde_libdir}/libkntlm.la -%{_tde_libdir}/libkntlm.so -%{_tde_libdir}/libkparts.la -%{_tde_libdir}/libkparts.so -%{_tde_libdir}/libkresources.la -%{_tde_libdir}/libkresources.so -%{_tde_libdir}/libkscreensaver.la -%{_tde_libdir}/libkscreensaver.so -%{_tde_libdir}/libkscript.la -%{_tde_libdir}/libkscript.so -%{_tde_libdir}/libkspell2.la -%{_tde_libdir}/libkspell2.so -%{_tde_libdir}/libkspell.la -%{_tde_libdir}/libkspell.so -%{_tde_libdir}/libktexteditor.la -%{_tde_libdir}/libktexteditor.so -%{_tde_libdir}/libkutils.la -%{_tde_libdir}/libkutils.so -%{_tde_libdir}/libkwalletbackend.la -%{_tde_libdir}/libkwalletbackend.so -%{_tde_libdir}/libkwalletclient.la -%{_tde_libdir}/libkwalletclient.so -%{_tde_libdir}/libnetworkstatus.la -%{_tde_libdir}/libnetworkstatus.so -%{_tde_libdir}/libconnectionmanager.la -%{_tde_libdir}/libconnectionmanager.so - -%changelog diff --git a/opensuse/core/tdelibs/textcompletion-editor.diff b/opensuse/core/tdelibs/textcompletion-editor.diff deleted file mode 100644 index d14776149..000000000 --- a/opensuse/core/tdelibs/textcompletion-editor.diff +++ /dev/null @@ -1,344 +0,0 @@ -Index: khtml/khtmlview.h -=================================================================== ---- khtml/khtmlview.h.orig -+++ khtml/khtmlview.h -@@ -314,6 +314,7 @@ private: - QStringList formCompletionItems(const QString &name) const; - void clearCompletionHistory(const QString& name); - void addFormCompletionItem(const QString &name, const QString &value); -+ void removeFormCompletionItem(const QString &name, const QString &value); - - void addNonPasswordStorableSite( const QString& host ); - bool nonPasswordStorableSite( const QString& host ) const; -Index: khtml/khtmlview.cpp -=================================================================== ---- khtml/khtmlview.cpp.orig -+++ khtml/khtmlview.cpp -@@ -3088,6 +3088,16 @@ void KHTMLView::addFormCompletionItem(co - d->formCompletions->writeEntry(name, items); - } - -+void KHTMLView::removeFormCompletionItem(const QString &name, const QString &value) -+{ -+ if (!m_part->settings()->isFormCompletionEnabled()) -+ return; -+ -+ QStringList items = formCompletionItems(name); -+ if (items.remove(value)) -+ d->formCompletions->writeEntry(name, items); -+} -+ - void KHTMLView::addNonPasswordStorableSite(const QString& host) - { - if (!d->formCompletions) { -Index: khtml/rendering/render_form.h -=================================================================== ---- khtml/rendering/render_form.h.orig -+++ khtml/rendering/render_form.h -@@ -272,10 +272,12 @@ private slots: - void spellCheckerMisspelling( const QString &text, const QStringList &, unsigned int pos); - void spellCheckerCorrected( const QString &, const QString &, unsigned int ); - void spellCheckerFinished(); -+ void slotRemoveFromHistory( const QString & ); - - private: - enum LineEditMenuID { -- ClearHistory -+ ClearHistory, -+ EditHistory - }; - DOM::HTMLInputElementImpl* m_input; - KHTMLView* m_view; -Index: khtml/rendering/render_form.cpp -=================================================================== ---- khtml/rendering/render_form.cpp.orig -+++ khtml/rendering/render_form.cpp -@@ -385,7 +385,9 @@ QPopupMenu *LineEditWidget::createPopupM - - if (m_input->autoComplete()) { - popup->insertSeparator(); -- int id = popup->insertItem( SmallIconSet("history_clear"), i18n("Clear &History"), ClearHistory ); -+ int id = popup->insertItem( SmallIconSet("edit"), i18n("&Edit History..."), EditHistory ); -+ popup->setItemEnabled( id, (compObj() && !compObj()->isEmpty()) ); -+ id = popup->insertItem( SmallIconSet("history_clear"), i18n("Clear &History"), ClearHistory ); - popup->setItemEnabled( id, (compObj() && !compObj()->isEmpty()) ); - } - -@@ -409,11 +411,25 @@ void LineEditWidget::extendedMenuActivat - m_view->clearCompletionHistory(m_input->name().string()); - if (compObj()) - compObj()->clear(); -+ case EditHistory: -+ { -+ KHistoryComboEditor dlg( compObj() ? compObj()->items() : QStringList(), this ); -+ connect( &dlg, SIGNAL( removeFromHistory(const QString&) ), SLOT( slotRemoveFromHistory(const QString&)) ); -+ dlg.exec(); -+ } - default: - break; - } - } - -+void LineEditWidget::slotRemoveFromHistory(const QString &entry) -+{ -+ m_view->removeFormCompletionItem(m_input->name().string(), entry); -+ if (compObj()) -+ compObj()->removeItem(entry); -+} -+ -+ - bool LineEditWidget::event( QEvent *e ) - { - if (KLineEdit::event(e)) -Index: kdeui/kcombobox.h -=================================================================== ---- kdeui/kcombobox.h.orig -+++ kdeui/kcombobox.h -@@ -24,8 +24,15 @@ - - #include - #include -+#include -+#include -+#include -+#include -+#include - - #include -+#include -+#include - - class QListBoxItem; - class QPopupMenu; -@@ -669,6 +676,12 @@ public: - */ - void reset() { slotReset(); } - -+ /** -+ * When enabling it you have to connect to "removed" signal and save changes -+ */ -+ void setHistoryEditorEnabled( bool enable ); -+ bool isHistoryEditorEnabled() const; -+ - public slots: - /** - * Adds an item to the end of the history list and to the completion list. -@@ -702,6 +715,8 @@ signals: - */ - void cleared(); - -+ void removed( const QString& item ); -+ - protected: - /** - * Handling key-events, the shortcuts to rotate the items. -@@ -741,10 +756,17 @@ private slots: - void slotClear(); - - /** -+ * Called from the popupmenu, -+ */ -+ void slotEdit(); -+ -+ /** - * Appends our own context menu entry. - */ - void addContextMenuItems( QPopupMenu* ); - -+ void slotRemoveFromHistory( const QString & ); -+ - private: - void init( bool useCompletion ); - void rotateUp(); -@@ -774,6 +796,30 @@ private: - KHistoryComboPrivate* const d; - }; - -+class KDEUI_EXPORT KHistoryComboEditor : public KDialogBase -+{ -+ Q_OBJECT -+ -+public: -+ KHistoryComboEditor( const QStringList& entries, QWidget *parent = 0L ); -+ ~KHistoryComboEditor(); -+ -+signals: -+ void removeFromHistory( const QString& ); -+ -+protected slots: -+ virtual void slotUser1(); // User1 is "Delete Entry" button -+ void slotSelectionChanged( QListViewItem * item ); -+ -+protected: -+ virtual void virtual_hook( int id, void* data ); -+ -+private: -+ KListView *m_pListView; -+ -+ class KHistoryComboEditorPrivate; -+ KHistoryComboEditorPrivate* const d; -+}; - - #endif - -Index: kdeui/kcombobox.cpp -=================================================================== ---- kdeui/kcombobox.cpp.orig -+++ kdeui/kcombobox.cpp -@@ -29,6 +29,7 @@ - #include - #include - #include -+#include - #include - #include - #include -@@ -343,10 +344,22 @@ void KComboBox::lineEditDeleted() - // ********************************************************************* - // ********************************************************************* - -+class KHistoryCombo::KHistoryComboPrivate -+{ -+public: -+ KHistoryComboPrivate() : bHistoryEditorEnabled(false) -+ { -+ } -+ ~KHistoryComboPrivate() -+ { -+ } -+ -+ bool bHistoryEditorEnabled; -+}; - - // we are always read-write - KHistoryCombo::KHistoryCombo( QWidget *parent, const char *name ) -- : KComboBox( true, parent, name ), d(0) -+ : KComboBox( true, parent, name ), d(new KHistoryComboPrivate) - { - init( true ); // using completion - } -@@ -354,7 +367,7 @@ KHistoryCombo::KHistoryCombo( QWidget *p - // we are always read-write - KHistoryCombo::KHistoryCombo( bool useCompletion, - QWidget *parent, const char *name ) -- : KComboBox( true, parent, name ), d(0) -+ : KComboBox( true, parent, name ), d(new KHistoryComboPrivate) - { - init( useCompletion ); - } -@@ -441,6 +454,10 @@ void KHistoryCombo::addContextMenuItems( - if ( menu ) - { - menu->insertSeparator(); -+ if (d->bHistoryEditorEnabled) { -+ int idedit = menu->insertItem( SmallIconSet("edit"), i18n("&Edit History..."), this, SLOT( slotEdit()) ); -+ menu->setItemEnabled(idedit, count()); -+ } - int id = menu->insertItem( SmallIconSet("history_clear"), i18n("Clear &History"), this, SLOT( slotClear())); - if (!count()) - menu->setItemEnabled(id, false); -@@ -677,10 +694,104 @@ void KHistoryCombo::slotClear() - emit cleared(); - } - -+void KHistoryCombo::slotEdit() -+{ -+ KHistoryComboEditor dlg( historyItems(), this ); -+ connect( &dlg, SIGNAL( removeFromHistory(const QString&) ), SLOT( slotRemoveFromHistory(const QString&)) ); -+ dlg.exec(); -+} -+ -+void KHistoryCombo::slotRemoveFromHistory(const QString &entry) -+{ -+ removeFromHistory(entry); -+ emit removed(entry); -+} -+ -+void KHistoryCombo::setHistoryEditorEnabled( bool enable ) -+{ -+ d->bHistoryEditorEnabled = enable; -+} -+ -+bool KHistoryCombo::isHistoryEditorEnabled() const -+{ -+ return d->bHistoryEditorEnabled; -+} -+ - void KComboBox::virtual_hook( int id, void* data ) - { KCompletionBase::virtual_hook( id, data ); } - - void KHistoryCombo::virtual_hook( int id, void* data ) - { KComboBox::virtual_hook( id, data ); } - -+void KHistoryComboEditor::virtual_hook( int id, void* data ) -+{ KDialogBase::virtual_hook( id, data ); } -+ -+KHistoryComboEditor::KHistoryComboEditor( const QStringList& entries, QWidget *parent ) -+: KDialogBase( parent, "khistorycomboeditor", true, i18n( "History Editor" ), -+ KDialogBase::Close | KDialogBase::User1, KDialogBase::User1, true, -+ KGuiItem( i18n( "&Delete Entry" ), "editdelete") ), d(0) -+{ -+ QVBox* box = new QVBox( this ); -+ box->setSpacing( KDialog::spacingHint() ); -+ setMainWidget( box ); -+ -+ new QLabel( i18n( "This dialog allows you to delete unwanted history items." ), box ); -+ -+ // Add searchline -+ QHBox* searchbox = new QHBox( box ); -+ searchbox->setSpacing( KDialog::spacingHint() ); -+ -+ QToolButton *clearSearch = new QToolButton(searchbox); -+ clearSearch->setTextLabel(i18n("Clear Search"), true); -+ clearSearch->setIconSet(SmallIconSet(QApplication::reverseLayout() ? "clear_left" : "locationbar_erase")); -+ QLabel* slbl = new QLabel(i18n("&Search:"), searchbox); -+ KListViewSearchLine* listViewSearch = new KListViewSearchLine(searchbox); -+ slbl->setBuddy(listViewSearch); -+ connect(clearSearch, SIGNAL(pressed()), listViewSearch, SLOT(clear())); -+ -+ // Add ListView -+ m_pListView = new KListView( box ); -+ listViewSearch->setListView(m_pListView); -+ m_pListView->setAllColumnsShowFocus(true); -+ m_pListView->header()->hide(); -+ m_pListView->addColumn(""); -+ m_pListView->setRenameable( 0 ); -+ -+ box->setStretchFactor( m_pListView, 1 ); -+ -+ QStringList newlist = entries; -+ for ( QStringList::Iterator it = newlist.begin(); it != newlist.end(); ++it ) { -+ new QListViewItem( m_pListView, *it ); -+ } -+ -+ m_pListView->setMinimumSize( m_pListView->sizeHint() ); -+ -+ connect( m_pListView, SIGNAL( selectionChanged( QListViewItem * ) ), -+ this, SLOT( slotSelectionChanged( QListViewItem * ) ) ); -+ -+ enableButton( KDialogBase::User1, false ); -+ -+ resize( sizeHint() ); -+} -+ -+KHistoryComboEditor::~KHistoryComboEditor() -+{ -+} -+ -+void KHistoryComboEditor::slotUser1() // Delete button -+{ -+ QListViewItem *item = m_pListView->selectedItem(); -+ -+ if ( item ) { -+ emit removeFromHistory( item->text(0) ); -+ m_pListView->takeItem( item ); -+ enableButton( KDialogBase::User1, false ); -+ } -+} -+ -+void KHistoryComboEditor::slotSelectionChanged( QListViewItem * item ) -+{ -+ enableButton( KDialogBase::User1, item ); -+} -+ - #include "kcombobox.moc" diff --git a/opensuse/core/tdelibs/use-mediamanager.diff b/opensuse/core/tdelibs/use-mediamanager.diff deleted file mode 100644 index 007c40bd0..000000000 --- a/opensuse/core/tdelibs/use-mediamanager.diff +++ /dev/null @@ -1,44 +0,0 @@ -Index: kioslave/file/file.cc -=================================================================== ---- kioslave/file/file.cc.orig -+++ kioslave/file/file.cc -@@ -69,6 +69,7 @@ - #include - #include - -+#include - #include - #include - #include -@@ -1609,6 +1610,31 @@ void FileProtocol::unmount( const QStrin - #endif /* HAVE_VOLMGT */ - - err = testLogFile( tmp ); -+ -+ if (err.contains("fstab") || err.contains("root")) { -+ QString olderr; -+ err = QString::null; -+ -+ DCOPRef d("kded", "mediamanager"); -+ d.setDCOPClient ( dcopClient() ); -+ DCOPReply reply = d.call("properties", _point); -+ QString udi; -+ -+ if ( reply.isValid() ) { -+ QStringList list = reply; -+ if (list.size()) -+ udi = list[0]; -+ } -+ -+ if (!udi.isEmpty()) -+ reply = d.call("unmount", udi); -+ -+ if (udi.isEmpty() || !reply.isValid()) -+ err = olderr; -+ else if (reply.isValid()) -+ reply.get(err); -+ } -+ - if ( err.isEmpty() ) - finished(); - else diff --git a/opensuse/core/tdelibs/use-xauthlocalhostname.diff b/opensuse/core/tdelibs/use-xauthlocalhostname.diff deleted file mode 100644 index 42ef39b9c..000000000 --- a/opensuse/core/tdelibs/use-xauthlocalhostname.diff +++ /dev/null @@ -1,240 +0,0 @@ -Index: kinit/wrapper.c -=================================================================== ---- kinit/wrapper.c.orig -+++ kinit/wrapper.c -@@ -164,7 +164,9 @@ static int openSocket() - sock_file[strlen(sock_file)-1] = 0; - - strncat(sock_file, "/socket-", MAX_SOCK_FILE - strlen(sock_file)); -- if (gethostname(sock_file+strlen(sock_file), MAX_SOCK_FILE - strlen(sock_file) - 1) != 0) -+ if( getenv("XAUTHLOCALHOSTNAME")) -+ strncat(sock_file, getenv("XAUTHLOCALHOSTNAME"), MAX_SOCK_FILE - strlen(sock_file) - 1); -+ else if (gethostname(sock_file+strlen(sock_file), MAX_SOCK_FILE - strlen(sock_file) - 1) != 0) - { - perror("Warning: Could not determine hostname: "); - return -1; -Index: kinit/lnusertemp.c -=================================================================== ---- kinit/lnusertemp.c.orig -+++ kinit/lnusertemp.c -@@ -39,7 +39,7 @@ - - int check_tmp_dir(const char *tmp_dir); - int create_link(const char *file, const char *tmp_dir); --int build_link(const char *tmp_prefix, const char *kde_prefix); -+int build_link(const char *tmp_prefix, const char *kde_prefix, int kdehostname); - - int check_tmp_dir(const char *tmp_dir) - { -@@ -89,7 +89,7 @@ int create_link(const char *file, const - } - - --int build_link(const char *tmp_prefix, const char *kde_prefix) -+int build_link(const char *tmp_prefix, const char *kde_prefix, int kdehostname) - { - struct passwd *pw_ent; - char kde_tmp_dir[PATH_MAX+1]; -@@ -157,10 +157,21 @@ int build_link(const char *tmp_prefix, c - } - - strncat(kde_tmp_dir, kde_prefix, PATH_MAX - strlen(kde_tmp_dir)); -- if (gethostname(kde_tmp_dir+strlen(kde_tmp_dir), PATH_MAX - strlen(kde_tmp_dir) - 1) != 0) -+ -+ if( kdehostname ) -+ { -+ if( getenv("XAUTHLOCALHOSTNAME")) -+ strncat(kde_tmp_dir+strlen(kde_tmp_dir), getenv("XAUTHLOCALHOSTNAME"), PATH_MAX - strlen(kde_tmp_dir) - 1); -+ else -+ return 0; -+ } -+ else - { -- perror("Aborting. Could not determine hostname: "); -- exit(255); -+ if (gethostname(kde_tmp_dir+strlen(kde_tmp_dir), PATH_MAX - strlen(kde_tmp_dir) - 1) != 0) -+ { -+ perror("Could not determine hostname: "); -+ return 1; -+ } - } - kde_tmp_dir[sizeof(kde_tmp_dir)-1] = '\0'; - -@@ -266,7 +277,9 @@ int main(int argc, char **argv) - kde_prefix = "/cache-"; - } - -- res = build_link(tmp_prefix, kde_prefix); -+ res = build_link(tmp_prefix, kde_prefix, 1); -+ if( build_link(tmp_prefix, kde_prefix, 0)) -+ res = 1; - - free(tmp_prefix); - -Index: kdecore/kstandarddirs.cpp -=================================================================== ---- kdecore/kstandarddirs.cpp.orig -+++ kdecore/kstandarddirs.cpp -@@ -719,7 +719,10 @@ void KStandardDirs::createSpecialResourc - { - char hostname[256]; - hostname[0] = 0; -- gethostname(hostname, 255); -+ if( getenv("XAUTHLOCALHOSTNAME")) -+ strlcpy(hostname, getenv("XAUTHLOCALHOSTNAME"), 255 ); -+ else -+ gethostname(hostname, 255); - QString dir = QString("%1%2-%3").arg(localkdedir()).arg(type).arg(hostname); - char link[1024]; - link[1023] = 0; -Index: kdecore/kcrash.cpp -=================================================================== ---- kdecore/kcrash.cpp.orig -+++ kdecore/kcrash.cpp -@@ -466,7 +466,9 @@ static int openSocket() - sock_file[strlen(sock_file)-1] = 0; - - strncat(sock_file, "/socket-", MAX_SOCK_FILE - strlen(sock_file)); -- if (gethostname(sock_file+strlen(sock_file), MAX_SOCK_FILE - strlen(sock_file) - 1) != 0) -+ if( getenv("XAUTHLOCALHOSTNAME")) -+ strncat(sock_file, getenv("XAUTHLOCALHOSTNAME"), MAX_SOCK_FILE - strlen(sock_file) - 1); -+ else if (gethostname(sock_file+strlen(sock_file), MAX_SOCK_FILE - strlen(sock_file) - 1) != 0) - { - perror("Warning: Could not determine hostname: "); - return -1; -Index: dcop/dcopserver_shutdown.c -=================================================================== ---- dcop/dcopserver_shutdown.c.orig -+++ dcop/dcopserver_shutdown.c -@@ -95,7 +95,9 @@ static void getDCOPFile(char *dcop_file, - strncat(dcop_file, "/.DCOPserver_", n); - n -= strlen("/.DCOPserver_"); - -- if (gethostname(dcop_file+strlen(dcop_file), n) != 0) -+ if (getenv("XAUTHLOCALHOSTNAME")) -+ strncat(dcop_file+strlen(dcop_file), getenv("XAUTHLOCALHOSTNAME"), n); -+ else if (gethostname(dcop_file+strlen(dcop_file), n) != 0) - { - perror("Error. Could not determine hostname: "); - dcop_file[0] = '\0'; -Index: dcop/dcopc.c -=================================================================== ---- dcop/dcopc.c.orig -+++ dcop/dcopc.c -@@ -684,7 +684,9 @@ dcop_connect() - } - - hostName[0] = '\0'; -- if (gethostname(hostName, sizeof(hostName))) -+ if (getenv("XAUTHLOCALHOSTNAME")) -+ strlcpy(hostName, getenv("XAUTHLOCALHOSTNAME"),sizeof(hostName)-1); -+ else if (gethostname(hostName, sizeof(hostName))) - strcpy(hostName, "localhost"); - else - hostName[sizeof(hostName)-1] = '\0'; -Index: dcop/dcopclient.cpp -=================================================================== ---- dcop/dcopclient.cpp.orig -+++ dcop/dcopclient.cpp -@@ -277,7 +277,9 @@ static QCString dcopServerFile(const QCS - { - char hostName[256]; - hostName[0] = '\0'; -- if (gethostname(hostName, sizeof(hostName))) -+ if (getenv("XAUTHLOCALHOSTNAME")) -+ fName += getenv("XAUTHLOCALHOSTNAME"); -+ else if (gethostname(hostName, sizeof(hostName))) - { - fName += "localhost"; - } -Index: dcop/KDE-ICE/Xtranssock.c -=================================================================== ---- dcop/KDE-ICE/Xtranssock.c.orig -+++ dcop/KDE-ICE/Xtranssock.c -@@ -1444,6 +1444,7 @@ UnixHostReallyLocal (char *host) - - { - char hostnamebuf[256]; -+ char* xauthlocalname = getenv("XAUTHLOCALHOSTNAME"); - - TRANS(GetHostname) (hostnamebuf, sizeof (hostnamebuf)); - -@@ -1451,6 +1452,10 @@ UnixHostReallyLocal (char *host) - { - return (1); - } -+ else if(xauthlocalname && strcmp (xauthlocalname, host) == 0) -+ { -+ return (1); -+ } - else - { - /* -Index: kded/khostname.cpp -=================================================================== ---- kded/khostname.cpp.orig -+++ kded/khostname.cpp -@@ -111,7 +111,8 @@ static QCStringList split(const QCString - - void KHostName::changeX() - { -- QString cmd = "xauth list"; -+ const char* xauthlocalhostname = getenv("XAUTHLOCALHOSTNAME"); -+ QString cmd = "xauth -n list"; - FILE *xFile = popen(QFile::encodeName(cmd), "r"); - if (!xFile) - { -@@ -123,6 +124,7 @@ void KHostName::changeX() - char buf[1024+1]; - while (!feof(xFile)) - { -+ buf[1024]='\0'; - QCString line = fgets(buf, 1024, xFile); - if (line.length()) - line.truncate(line.length()-1); // Strip LF. -@@ -157,12 +159,17 @@ void KHostName::changeX() - QCString newNetId = newName+netId.mid(i); - QCString oldNetId = netId.left(i); - -- if(oldNetId != oldName) -- continue; -+ if(oldNetId != oldName -+ && (!xauthlocalhostname || strcmp(xauthlocalhostname, oldNetId.data()) != 0)) -+ continue; - -- cmd = "xauth remove "+KProcess::quote(netId); -- system(QFile::encodeName(cmd)); -- cmd = "xauth add "; -+ // don't nuke the xauth when XAUTHLOCALHOSTNAME points to it -+ if (!xauthlocalhostname || oldNetId != xauthlocalhostname) -+ { -+ cmd = "xauth -n remove "+KProcess::quote(netId); -+ system(QFile::encodeName(cmd)); -+ } -+ cmd = "xauth -n add "; - cmd += KProcess::quote(newNetId); - cmd += " "; - cmd += KProcess::quote(authName); -@@ -276,7 +283,10 @@ void KHostName::changeDcop() - } - } - -- // Remove old entries -+ // Remove old entries, but only if XAUTHLOCALHOSTNAME doesn't point -+ // to it -+ char* xauthlocalhostname = getenv("XAUTHLOCALHOSTNAME"); -+ if (!xauthlocalhostname || !oldNetId.contains(xauthlocalhostname)) - { - QString cmd = "iceauth remove "+KProcess::quote("netid="+oldNetId); - system(QFile::encodeName(cmd)); -@@ -368,9 +378,7 @@ int main(int argc, char **argv) - - KHostName hn; - -- if(!getenv("XAUTHLOCALHOSTNAME")) -- hn.changeX(); -- -+ hn.changeX(); - hn.changeDcop(); - hn.changeStdDirs("socket"); - hn.changeStdDirs("tmp"); diff --git a/opensuse/core/tdelibs/x-kde-InitialPreference.diff b/opensuse/core/tdelibs/x-kde-InitialPreference.diff deleted file mode 100644 index d95df7a2c..000000000 --- a/opensuse/core/tdelibs/x-kde-InitialPreference.diff +++ /dev/null @@ -1,16 +0,0 @@ -Index: kio/kio/kservice.cpp -=================================================================== ---- kio/kio/kservice.cpp.orig -+++ kio/kio/kservice.cpp -@@ -249,7 +249,10 @@ KService::init( KDesktopFile *config ) - m_bAllowAsDefault = config->readBoolEntry( "AllowDefault", true ); - entryMap.remove("AllowDefault"); - -- m_initialPreference = config->readNumEntry( "InitialPreference", 1 ); -+ m_initialPreference = config->readNumEntry( "X-KDE-InitialPreference", 1 ); -+ entryMap.remove("X-KDE-InitialPreference"); -+ if ( m_initialPreference == 1 ) -+ m_initialPreference = config->readNumEntry( "InitialPreference", 1 ); - entryMap.remove("InitialPreference"); - - // Store all additional entries in the property map. diff --git a/opensuse/core/tdelibs/xinerama.patch b/opensuse/core/tdelibs/xinerama.patch deleted file mode 100644 index dec878b40..000000000 --- a/opensuse/core/tdelibs/xinerama.patch +++ /dev/null @@ -1,543 +0,0 @@ -Index: kio/kio/krun.h -=================================================================== ---- kio/kio/krun.h.orig -+++ kio/kio/krun.h -@@ -111,6 +111,8 @@ public: - */ - KRun( const KURL& url, QWidget* window, mode_t mode = 0, - 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 -@@ -210,6 +212,8 @@ public: - * @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, -+ const QCString& asn, bool tempFiles = false ); - /** - * Open a list of URLs with a certain service (application). - * -@@ -226,6 +230,8 @@ public: - /// @since 3.5.3 - /// @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, -+ const QCString& asn, bool tempFiles, const QString& suggestedFileName ); - - /** - * Open a list of URLs with. -@@ -269,6 +275,7 @@ public: - static pid_t runURL( const KURL& _url, const QString& _mimetype ); - /// @since 3.5.3 - /// @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 ); - - /** -@@ -299,6 +306,8 @@ public: - * 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, -+ QWidget* window, const QCString& asn ); - - /** - * 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 ); - - 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); - private: - class KRunPrivate; -Index: kio/kio/krun.cpp -=================================================================== ---- kio/kio/krun.cpp.orig -+++ kio/kio/krun.cpp -@@ -77,6 +77,7 @@ public: - QString m_localPath; - QString m_suggestedFileName; - QGuardedPtr m_window; -+ QCString m_asn; - }; - - pid_t KRun::runURL( const KURL& u, const QString& _mimetype ) -@@ -109,14 +110,20 @@ bool KRun::isExecutableFile( const KURL& - 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 ) - { -+ 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 noAuth = false; - if ( _mimetype == "inode/directory-locked" ) - { -- KMessageBoxWrapper::error( 0L, -+ KMessageBoxWrapper::error( window, - i18n("Unable to enter %1.\nYou do not have access rights to this location.").arg(u.htmlURL()) ); - return 0; - } -@@ -133,7 +140,7 @@ pid_t KRun::runURL( const KURL& u, const - { - QString path = u.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 - } - else -@@ -155,14 +162,14 @@ pid_t KRun::runURL( const KURL& u, const - - if ( noRun ) - { -- KMessageBox::sorry( 0L, -+ KMessageBox::sorry( window, - i18n("The file %1 is an executable program. " - "For safety it will not be started.").arg(u.htmlURL())); - return 0; - } - if ( noAuth ) - { -- KMessageBoxWrapper::error( 0L, -+ KMessageBoxWrapper::error( window, - i18n("You do not have permission to run %1.").arg(u.htmlURL()) ); - return 0; - } -@@ -182,7 +189,7 @@ pid_t KRun::runURL( const KURL& u, const - 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 ) -@@ -536,13 +543,13 @@ QString KRun::binaryName( const QString - } - - 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() - && !KDesktopFile::isAuthorizedDesktopFile( service->desktopEntryPath() )) - { - 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; - } - QString bin = KRun::binaryName( binName, true ); -@@ -550,10 +557,10 @@ static pid_t runCommandInternal( KProces - bool silent; - QCString wmclass; - 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 ) - { -- id.initId(); -+ id.initId( asn ); - id.setupStartupEnv(); - KStartupInfoData data; - data.setHostname(); -@@ -572,6 +579,8 @@ static pid_t runCommandInternal( KProces - if( silent ) - data.setSilent( KStartupInfoData::Yes ); - data.setDesktop( KWin::currentDesktop()); -+ if( window ) -+ data.setLaunchedBy( window->winId()); - KStartupInfo::sendStartup( id, data ); - } - pid_t pid = KProcessRunner::run( proc, binName, id ); -@@ -635,7 +644,8 @@ bool KRun::checkStartupNotify( const QSt - 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()) { - kdDebug(7010) << "runTempService: first url " << _urls.first().url() << endl; -@@ -654,7 +664,7 @@ static pid_t runTempService( const KServ - { - KURL::List singleUrl; - singleUrl.append(*it); -- runTempService( _service, singleUrl, tempFiles, suggestedFileName ); -+ runTempService( _service, singleUrl, window, "", tempFiles, suggestedFileName ); - } - KURL::List singleUrl; - singleUrl.append(_urls.first()); -@@ -673,7 +683,7 @@ static pid_t runTempService( const KServ - proc->setWorkingDirectory(_service.path()); - - 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... -@@ -734,11 +744,22 @@ pid_t KRun::run( const KService& _servic - - 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 ) - { -+ 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() && - !KDesktopFile::isAuthorizedDesktopFile( _service.desktopEntryPath())) - { -@@ -759,7 +780,7 @@ pid_t KRun::run( const KService& _servic - - 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; -@@ -773,9 +794,25 @@ pid_t KRun::run( const KService& _servic - - QString error; - 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( -- _service.desktopEntryPath(), urls.toStringList(), &error, 0L, &pid -+ _service.desktopEntryPath(), urls.toStringList(), &error, 0L, &pid, myasn - ); - - if (i != 0) -@@ -800,33 +837,47 @@ pid_t KRun::run( const QString& _exec, c - - 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 ) - { -+ 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; - KProcess * proc = new KProcess; - proc->setUseShell(true); - *proc << cmd; - 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 ) - :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, - bool showProgressInfo ) - :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 ) - { - m_bFault = false; -@@ -842,6 +893,7 @@ void KRun::init ( const KURL& url, QWidg - d = new KRunPrivate; - d->m_runExecutables = true; - d->m_window = window; -+ d->m_asn = asn; - setEnableExternalBrowser(true); - - // Start the timer. This means we will return to the event -@@ -942,7 +994,7 @@ void KRun::init() - KService::Ptr service = KService::serviceByStorageId( exec ); - if (service) - { -- run( *service, urls ); -+ run( *service, urls, d->m_window, d->m_asn ); - ok = true; - } - } -@@ -1235,7 +1287,7 @@ void KRun::foundMimeType( const QString& - { - KURL::List lst; - 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 - /// go to runURL to maybe find another service, even though a dialog - /// box was displayed. That's good if runURL tries another service, -@@ -1250,7 +1302,7 @@ void KRun::foundMimeType( const QString& - 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; - } - else{ -Index: kdecore/kstartupinfo.cpp -=================================================================== ---- kdecore/kstartupinfo.cpp.orig -+++ kdecore/kstartupinfo.cpp -@@ -1109,7 +1109,7 @@ unsigned long KStartupInfoId::timestamp( - struct KStartupInfoDataPrivate - { - 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 name; - QString description; -@@ -1121,6 +1121,8 @@ struct KStartupInfoDataPrivate - KStartupInfoData::TriState silent; - unsigned long timestamp; - int screen; -+ int xinerama; -+ WId launched_by; - }; - - QString KStartupInfoData::to_text() const -@@ -1151,6 +1153,10 @@ QString KStartupInfoData::to_text() cons - ret += QString::fromLatin1( " TIMESTAMP=%1" ).arg( d->timestamp ); - if( d->screen != -1 ) - 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; - } - -@@ -1169,6 +1175,8 @@ KStartupInfoData::KStartupInfoData( cons - const QString silent_str = QString::fromLatin1( "SILENT=" ); - const QString timestamp_str = QString::fromLatin1( "TIMESTAMP=" ); - 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(); - it != items.end(); - ++it ) -@@ -1199,6 +1207,10 @@ KStartupInfoData::KStartupInfoData( cons - d->timestamp = get_unum( *it ); - else if( ( *it ).startsWith( screen_str )) - 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 KSt - d->timestamp = data_P.timestamp(); - if( data_P.screen() != -1 ) - 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() -@@ -1412,6 +1428,26 @@ int KStartupInfoData::screen() const - 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 - long get_num( const QString& item_P ) - { -Index: kdecore/netwm_def.h -=================================================================== ---- kdecore/netwm_def.h.orig -+++ kdecore/netwm_def.h -@@ -610,6 +610,7 @@ public: - WM2WindowRole = 1<<11, ///< @since 3.3 - WM2ClientMachine = 1<<12, ///< @since 3.3 - WM2ShowingDesktop = 1<<13, ///< @since 3.5 -+ WM2FullPlacement = 1<<14, - WM2DesktopLayout = 1<<15 ///< @since 3.5.8 - }; - -Index: kdecore/netwm.cpp -=================================================================== ---- kdecore/netwm.cpp.orig -+++ kdecore/netwm.cpp -@@ -145,6 +145,9 @@ static Atom net_wm_state_stays_on_top = - // used to determine whether application window is managed or not - static Atom xa_wm_state = 0; - -+// ability flags -+static Atom net_wm_full_placement = 0; -+ - static Bool netwm_atoms_created = False; - const unsigned long netwm_sendevent_mask = (SubstructureRedirectMask| - SubstructureNotifyMask); -@@ -236,7 +239,7 @@ static int wcmp(const void *a, const voi - } - - --static const int netAtomCount = 84; -+static const int netAtomCount = 85; - static void create_atoms(Display *d) { - static const char * const names[netAtomCount] = - { -@@ -330,7 +333,9 @@ static void create_atoms(Display *d) { - "_KDE_NET_WM_TEMPORARY_RULES", - - "WM_STATE", -- "WM_PROTOCOLS" -+ "WM_PROTOCOLS", -+ -+ "_NET_WM_FULL_PLACEMENT" - }; - - Atom atoms[netAtomCount], *atomsp[netAtomCount] = -@@ -425,7 +430,9 @@ static void create_atoms(Display *d) { - &kde_net_wm_temporary_rules, - - &xa_wm_state, -- &wm_protocols -+ &wm_protocols, -+ -+ &net_wm_full_placement - }; - - assert( !netwm_atoms_created ); -@@ -1355,6 +1362,8 @@ void NETRootInfo::setSupported() { - - if (p->properties[ PROTOCOLS2 ] & WM2KDETemporaryRules) - 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, - PropModeReplace, (unsigned char *) atoms, pnum); -@@ -1587,6 +1596,8 @@ void NETRootInfo::updateSupportedPropert - - else if( atom == kde_net_wm_temporary_rules ) - p->properties[ PROTOCOLS2 ] |= WM2KDETemporaryRules; -+ else if( atom == net_wm_full_placement ) -+ p->properties[ PROTOCOLS2 ] |= WM2FullPlacement; - } - - extern Time qt_x_user_time; -Index: kdecore/kstartupinfo.h -=================================================================== ---- kdecore/kstartupinfo.h.orig -+++ kdecore/kstartupinfo.h -@@ -635,6 +635,30 @@ class KDECORE_EXPORT KStartupInfoData - * This is usually not necessary to set, as it's set by default to qt_xscreen(). - */ - 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 diff --git a/opensuse/core/tdelibs/xml-catalog.diff b/opensuse/core/tdelibs/xml-catalog.diff deleted file mode 100644 index 0abaefec2..000000000 --- a/opensuse/core/tdelibs/xml-catalog.diff +++ /dev/null @@ -1,44 +0,0 @@ -Index: catalog.xml -=================================================================== ---- /dev/null -+++ catalog.xml -@@ -0,0 +1,39 @@ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ -+ diff --git a/opensuse/core/tdelibs/xmlhttprequest_3.x.diff b/opensuse/core/tdelibs/xmlhttprequest_3.x.diff deleted file mode 100644 index 822a8870b..000000000 --- a/opensuse/core/tdelibs/xmlhttprequest_3.x.diff +++ /dev/null @@ -1,47 +0,0 @@ -http://www.kde.org/info/security/advisory-20091027-1.txt - -Index: xmlhttprequest.cpp -=================================================================== ---- khtml/ecma/xmlhttprequest.cpp (revision 954808) -+++ khtml/ecma/xmlhttprequest.cpp (working copy) -@@ -342,17 +342,17 @@ - { - aborted = false; - -+ const QString protocol = url.protocol().lower(); -+ // Abandon the request when the protocol is other than "http", -+ // instead of blindly doing a KIO::get on other protocols like file:/. -+ if (!protocol.startsWith("http") && !protocol.startsWith("webdav")) -+ { -+ abort(); -+ return; -+ } -+ - if (method == "post") { -- QString protocol = url.protocol().lower(); - -- // Abondon the request when the protocol is other than "http", -- // instead of blindly changing it to a "get" request. -- if (!protocol.startsWith("http") && !protocol.startsWith("webdav")) -- { -- abort(); -- return; -- } -- - // FIXME: determine post encoding correctly by looking in headers - // for charset. - QByteArray buf; -@@ -763,11 +763,11 @@ - if (obj.isValid() && obj.inherits(&DOMDocument::info)) { - DOM::Node docNode = static_cast(obj.imp())->toNode(); - DOM::DocumentImpl *doc = static_cast(docNode.handle()); -- -+ - try { - body = doc->toString().string(); - // FIXME: also need to set content type, including encoding! -- -+ - } catch(DOM::DOMException& e) { - Object err = Error::create(exec, GeneralError, "Exception serializing document"); - exec->setException(err); -- cgit v1.2.3