Rename KCModule, KConfig, KIO, KServer, and KSocket to avoid conflicts with KDE4

r14.0.x
Timothy Pearson 11 years ago
parent 124cd4e9ef
commit a19285d794

@ -8693,14 +8693,14 @@ diff -urN libreoffice-build/patches/dev300/trinity-modules.diff libreoffice-buil
++KURL TDEFileDialog::mostLocalURL( const KURL &rURL ) const
++{
++#if KDE_IS_VERSION(3,5,0)
++ KURL qMostLocalURL( KIO::NetAccess::mostLocalURL( rURL, const_cast<TDEFileDialog*>( this ) ) );
++ KURL qMostLocalURL( TDEIO::NetAccess::mostLocalURL( rURL, const_cast<TDEFileDialog*>( this ) ) );
++ if ( qMostLocalURL.isLocalFile() )
++ return qMostLocalURL;
++ else
++ {
++ // Terrible hack to get even non-existing media:// files right
++ qMostLocalURL.cd( ".." );
++ KURL qMostLocalPath( KIO::NetAccess::mostLocalURL( qMostLocalURL, const_cast<TDEFileDialog*>( this ) ) );
++ KURL qMostLocalPath( TDEIO::NetAccess::mostLocalURL( qMostLocalURL, const_cast<TDEFileDialog*>( this ) ) );
++ if ( qMostLocalPath.isLocalFile() )
++ {
++ qMostLocalPath.addPath( rURL.fileName() );
@ -8729,9 +8729,9 @@ diff -urN libreoffice-build/patches/dev300/trinity-modules.diff libreoffice-buil
++ KURL qDestURL;
++ qDestURL.setPath( qTempFile.name() );
++
++ if ( !KIO::NetAccess::file_copy( rFileName, qDestURL, 0600, true, false, NULL ) )
++ if ( !TDEIO::NetAccess::file_copy( rFileName, qDestURL, 0600, true, false, NULL ) )
++ {
++ KMessageBox::error( 0, KIO::NetAccess::lastErrorString() );
++ KMessageBox::error( 0, TDEIO::NetAccess::lastErrorString() );
++ return TQString::null;
++ }
++
@ -14751,16 +14751,16 @@ diff -urN libreoffice-build/patches/dev300/trinity-modules.diff libreoffice-buil
++ return Color( rColor.red(), rColor.green(), rColor.blue() );
++}
++
++/** Helper function to read untranslated text entry from KConfig configuration repository.
++/** Helper function to read untranslated text entry from TDEConfig configuration repository.
++*/
++static OUString readEntryUntranslated( KConfig *pConfig, const char *pKey )
++static OUString readEntryUntranslated( TDEConfig *pConfig, const char *pKey )
++{
++ return OUString::createFromAscii( pConfig->readEntryUntranslated( pKey ).ascii() );
++}
++
++/** Helper function to read color from KConfig configuration repository.
++/** Helper function to read color from TDEConfig configuration repository.
++*/
++static Color readColor( KConfig *pConfig, const char *pKey )
++static Color readColor( TDEConfig *pConfig, const char *pKey )
++{
++ return toColor( pConfig->readColorEntry( pKey ) );
++}
@ -14856,7 +14856,7 @@ diff -urN libreoffice-build/patches/dev300/trinity-modules.diff libreoffice-buil
++ aStyleSettings.SetToolbarIconSize( STYLE_TOOLBAR_ICONSIZE_LARGE );
++
++ // WM settings
++ KConfig *pConfig = TDEGlobal::config();
++ TDEConfig *pConfig = TDEGlobal::config();
++ if ( pConfig )
++ {
++ pConfig->setGroup( "WM" );

@ -8693,14 +8693,14 @@ diff -urN libreoffice-build/patches/dev300/trinity-modules.diff libreoffice-buil
++KURL TDEFileDialog::mostLocalURL( const KURL &rURL ) const
++{
++#if KDE_IS_VERSION(3,5,0)
++ KURL qMostLocalURL( KIO::NetAccess::mostLocalURL( rURL, const_cast<TDEFileDialog*>( this ) ) );
++ KURL qMostLocalURL( TDEIO::NetAccess::mostLocalURL( rURL, const_cast<TDEFileDialog*>( this ) ) );
++ if ( qMostLocalURL.isLocalFile() )
++ return qMostLocalURL;
++ else
++ {
++ // Terrible hack to get even non-existing media:// files right
++ qMostLocalURL.cd( ".." );
++ KURL qMostLocalPath( KIO::NetAccess::mostLocalURL( qMostLocalURL, const_cast<TDEFileDialog*>( this ) ) );
++ KURL qMostLocalPath( TDEIO::NetAccess::mostLocalURL( qMostLocalURL, const_cast<TDEFileDialog*>( this ) ) );
++ if ( qMostLocalPath.isLocalFile() )
++ {
++ qMostLocalPath.addPath( rURL.fileName() );
@ -8729,9 +8729,9 @@ diff -urN libreoffice-build/patches/dev300/trinity-modules.diff libreoffice-buil
++ KURL qDestURL;
++ qDestURL.setPath( qTempFile.name() );
++
++ if ( !KIO::NetAccess::file_copy( rFileName, qDestURL, 0600, true, false, NULL ) )
++ if ( !TDEIO::NetAccess::file_copy( rFileName, qDestURL, 0600, true, false, NULL ) )
++ {
++ KMessageBox::error( 0, KIO::NetAccess::lastErrorString() );
++ KMessageBox::error( 0, TDEIO::NetAccess::lastErrorString() );
++ return TQString::null;
++ }
++
@ -14751,16 +14751,16 @@ diff -urN libreoffice-build/patches/dev300/trinity-modules.diff libreoffice-buil
++ return Color( rColor.red(), rColor.green(), rColor.blue() );
++}
++
++/** Helper function to read untranslated text entry from KConfig configuration repository.
++/** Helper function to read untranslated text entry from TDEConfig configuration repository.
++*/
++static OUString readEntryUntranslated( KConfig *pConfig, const char *pKey )
++static OUString readEntryUntranslated( TDEConfig *pConfig, const char *pKey )
++{
++ return OUString::createFromAscii( pConfig->readEntryUntranslated( pKey ).ascii() );
++}
++
++/** Helper function to read color from KConfig configuration repository.
++/** Helper function to read color from TDEConfig configuration repository.
++*/
++static Color readColor( KConfig *pConfig, const char *pKey )
++static Color readColor( TDEConfig *pConfig, const char *pKey )
++{
++ return toColor( pConfig->readColorEntry( pKey ) );
++}
@ -14856,7 +14856,7 @@ diff -urN libreoffice-build/patches/dev300/trinity-modules.diff libreoffice-buil
++ aStyleSettings.SetToolbarIconSize( STYLE_TOOLBAR_ICONSIZE_LARGE );
++
++ // WM settings
++ KConfig *pConfig = TDEGlobal::config();
++ TDEConfig *pConfig = TDEGlobal::config();
++ if ( pConfig )
++ {
++ pConfig->setGroup( "WM" );

@ -9012,14 +9012,14 @@ index 0000000..46ab20d
+KURL TDEFileDialog::mostLocalURL( const KURL &rURL ) const
+{
+#if KDE_IS_VERSION(3,5,0)
+ KURL qMostLocalURL( KIO::NetAccess::mostLocalURL( rURL, const_cast<TDEFileDialog*>( this ) ) );
+ KURL qMostLocalURL( TDEIO::NetAccess::mostLocalURL( rURL, const_cast<TDEFileDialog*>( this ) ) );
+ if ( qMostLocalURL.isLocalFile() )
+ return qMostLocalURL;
+ else
+ {
+ // Terrible hack to get even non-existing media:// files right
+ qMostLocalURL.cd( ".." );
+ KURL qMostLocalPath( KIO::NetAccess::mostLocalURL( qMostLocalURL, const_cast<TDEFileDialog*>( this ) ) );
+ KURL qMostLocalPath( TDEIO::NetAccess::mostLocalURL( qMostLocalURL, const_cast<TDEFileDialog*>( this ) ) );
+ if ( qMostLocalPath.isLocalFile() )
+ {
+ qMostLocalPath.addPath( rURL.fileName() );
@ -9048,9 +9048,9 @@ index 0000000..46ab20d
+ KURL qDestURL;
+ qDestURL.setPath( qTempFile.name() );
+
+ if ( !KIO::NetAccess::file_copy( rFileName, qDestURL, 0600, true, false, NULL ) )
+ if ( !TDEIO::NetAccess::file_copy( rFileName, qDestURL, 0600, true, false, NULL ) )
+ {
+ KMessageBox::error( 0, KIO::NetAccess::lastErrorString() );
+ KMessageBox::error( 0, TDEIO::NetAccess::lastErrorString() );
+ return TQString::null;
+ }
+
@ -15509,16 +15509,16 @@ index 0000000..7c173cc
+ return Color( rColor.red(), rColor.green(), rColor.blue() );
+}
+
+/** Helper function to read untranslated text entry from KConfig configuration repository.
+/** Helper function to read untranslated text entry from TDEConfig configuration repository.
+*/
+static OUString readEntryUntranslated( KConfig *pConfig, const char *pKey )
+static OUString readEntryUntranslated( TDEConfig *pConfig, const char *pKey )
+{
+ return OUString::createFromAscii( pConfig->readEntryUntranslated( pKey ).ascii() );
+}
+
+/** Helper function to read color from KConfig configuration repository.
+/** Helper function to read color from TDEConfig configuration repository.
+*/
+static Color readColor( KConfig *pConfig, const char *pKey )
+static Color readColor( TDEConfig *pConfig, const char *pKey )
+{
+ return toColor( pConfig->readColorEntry( pKey ) );
+}
@ -15614,7 +15614,7 @@ index 0000000..7c173cc
+ aStyleSettings.SetToolbarIconSize( STYLE_TOOLBAR_ICONSIZE_LARGE );
+
+ // WM settings
+ KConfig *pConfig = TDEGlobal::config();
+ TDEConfig *pConfig = TDEGlobal::config();
+ if ( pConfig )
+ {
+ pConfig->setGroup( "WM" );

Loading…
Cancel
Save