From 2fa036d5898ffd3dee5f4c396b09c7d904c49b5e Mon Sep 17 00:00:00 2001 From: tpearson Date: Thu, 27 Jan 2011 19:26:26 +0000 Subject: Aviod conflicts with Qt4 namespace members git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1217530 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kate/part/kateviewinternal.cpp | 40 ++++++++++++++++++++-------------------- kate/part/kateviewinternal.h | 6 +++--- khtml/Makefile.am | 4 ++-- kimgio/psd.cpp | 2 +- kinit/Makefile.am | 4 ++-- kio/kio/kfilterdev.cpp | 4 ++-- kio/kio/kfilterdev.h | 2 +- 7 files changed, 31 insertions(+), 31 deletions(-) diff --git a/kate/part/kateviewinternal.cpp b/kate/part/kateviewinternal.cpp index 34b098fb4..831866ef0 100644 --- a/kate/part/kateviewinternal.cpp +++ b/kate/part/kateviewinternal.cpp @@ -976,17 +976,17 @@ public: } void toEdge( Bias bias ) { - if( bias == left ) m_col = 0; - else if( bias == right ) m_col = m_vi->m_doc->lineLength( line() ); + if( bias == left_b ) m_col = 0; + else if( bias == right_b ) m_col = m_vi->m_doc->lineLength( line() ); } - bool atEdge() const { return atEdge( left ) || atEdge( right ); } + bool atEdge() const { return atEdge( left_b ) || atEdge( right_b ); } bool atEdge( Bias bias ) const { switch( bias ) { - case left: return col() == 0; - case none: return atEdge(); - case right: return col() == m_vi->m_doc->lineLength( line() ); + case left_b: return col() == 0; + case none: return atEdge(); + case right_b: return col() == m_vi->m_doc->lineLength( line() ); default: Q_ASSERT(false); return false; } } @@ -1107,7 +1107,7 @@ void KateViewInternal::cursorLeft( bool sel ) if ( ! m_view->wrapCursor() && cursor.col() == 0 ) return; - moveChar( left, sel ); + moveChar( left_b, sel ); if (m_view->m_codeCompletion->codeCompletionVisible()) { m_view->m_codeCompletion->updateBox(); } @@ -1115,7 +1115,7 @@ void KateViewInternal::cursorLeft( bool sel ) void KateViewInternal::cursorRight( bool sel ) { - moveChar( right, sel ); + moveChar( right_b, sel ); if (m_view->m_codeCompletion->codeCompletionVisible()) { m_view->m_codeCompletion->updateBox(); } @@ -1134,23 +1134,23 @@ void KateViewInternal::wordLeft ( bool sel ) // The code assumes that space is never part of the word character class. KateHighlighting* h = m_doc->highlight(); - if( !c.atEdge( left ) ) { + if( !c.atEdge( left_b ) ) { - while( !c.atEdge( left ) && m_doc->textLine( c.line() )[ c.col() - 1 ].isSpace() ) + while( !c.atEdge( left_b ) && m_doc->textLine( c.line() )[ c.col() - 1 ].isSpace() ) --c; } - if( c.atEdge( left ) ) + if( c.atEdge( left_b ) ) { --c; } else if( h->isInWord( m_doc->textLine( c.line() )[ c.col() - 1 ] ) ) { - while( !c.atEdge( left ) && h->isInWord( m_doc->textLine( c.line() )[ c.col() - 1 ] ) ) + while( !c.atEdge( left_b ) && h->isInWord( m_doc->textLine( c.line() )[ c.col() - 1 ] ) ) --c; } else { - while( !c.atEdge( left ) + while( !c.atEdge( left_b ) && !h->isInWord( m_doc->textLine( c.line() )[ c.col() - 1 ] ) // in order to stay symmetric to wordLeft() // we must not skip space preceding a non-word sequence @@ -1177,18 +1177,18 @@ void KateViewInternal::wordRight( bool sel ) // The code assumes that space is never part of the word character class. KateHighlighting* h = m_doc->highlight(); - if( c.atEdge( right ) ) + if( c.atEdge( right_b ) ) { ++c; } else if( h->isInWord( m_doc->textLine( c.line() )[ c.col() ] ) ) { - while( !c.atEdge( right ) && h->isInWord( m_doc->textLine( c.line() )[ c.col() ] ) ) + while( !c.atEdge( right_b ) && h->isInWord( m_doc->textLine( c.line() )[ c.col() ] ) ) ++c; } else { - while( !c.atEdge( right ) + while( !c.atEdge( right_b ) && !h->isInWord( m_doc->textLine( c.line() )[ c.col() ] ) // we must not skip space, because if that space is followed // by more non-word characters, we would skip them, too @@ -1198,7 +1198,7 @@ void KateViewInternal::wordRight( bool sel ) } } - while( !c.atEdge( right ) && m_doc->textLine( c.line() )[ c.col() ].isSpace() ) + while( !c.atEdge( right_b ) && m_doc->textLine( c.line() )[ c.col() ].isSpace() ) ++c; updateSelection( c, sel ); @@ -1232,7 +1232,7 @@ void KateViewInternal::home( bool sel ) } if( !(m_doc->configFlags() & KateDocument::cfSmartHome) ) { - moveEdge( left, sel ); + moveEdge( left_b, sel ); return; } @@ -1275,7 +1275,7 @@ void KateViewInternal::end( bool sel ) } if( !(m_doc->configFlags() & KateDocument::cfSmartHome) ) { - moveEdge( right, sel ); + moveEdge( right_b, sel ); return; } @@ -1294,7 +1294,7 @@ void KateViewInternal::end( bool sel ) updateSelection(c, sel); updateCursor(c, true); } else { - moveEdge(right, sel); + moveEdge(right_b, sel); } } diff --git a/kate/part/kateviewinternal.h b/kate/part/kateviewinternal.h index 6c765978e..0d706ffc3 100644 --- a/kate/part/kateviewinternal.h +++ b/kate/part/kateviewinternal.h @@ -45,9 +45,9 @@ class TQScrollBar; enum Bias { - left = -1, - none = 0, - right = 1 + left_b = -1, + none = 0, + right_b = 1 }; class KateViewInternal : public TQWidget diff --git a/khtml/Makefile.am b/khtml/Makefile.am index 82eca8120..6892ef0c9 100644 --- a/khtml/Makefile.am +++ b/khtml/Makefile.am @@ -67,7 +67,7 @@ dummy.cpp: $(srcdir)/Makefile.am libkhtmlpart_la_SOURCES = dummy.cpp libkhtmlpart_la_LDFLAGS = -no-undefined -module $(KDE_PLUGIN) $(all_libraries) -libkhtmlpart_la_LIBADD = libkhtml.la +libkhtmlpart_la_LIBADD = libkhtml.la $(LIB_QT) # init_khtmlimagefactory is in libkhtml.so; init_khtmlimagepart needs to be in the part imgdummy.cpp: $(srcdir)/Makefile.am @@ -77,7 +77,7 @@ imgdummy.cpp: $(srcdir)/Makefile.am khtmlimagepart_la_SOURCES = imgdummy.cpp khtmlimagepart_la_LDFLAGS = -no-undefined -module $(KDE_PLUGIN) $(all_libraries) -khtmlimagepart_la_LIBADD = libkhtml.la +khtmlimagepart_la_LIBADD = libkhtml.la $(LIB_QT) INCLUDES = -I$(top_srcdir)/kjs -I$(top_builddir)/kjs -I$(top_srcdir)/kimgio \ -I$(srcdir)/java -I$(top_srcdir)/dcop -I$(srcdir)/misc \ diff --git a/kimgio/psd.cpp b/kimgio/psd.cpp index 2374b6a97..d1b93b853 100644 --- a/kimgio/psd.cpp +++ b/kimgio/psd.cpp @@ -70,7 +70,7 @@ namespace { // Private. { char buf[4096]; while (bytes) { - unsigned int num= QMIN(bytes,sizeof(buf)); + unsigned int num= TQMIN(bytes,sizeof(buf)); unsigned int l = num; s.readRawBytes(buf, l); if(l != num) diff --git a/kinit/Makefile.am b/kinit/Makefile.am index 4328af871..1f887538a 100644 --- a/kinit/Makefile.am +++ b/kinit/Makefile.am @@ -33,7 +33,7 @@ AM_LDFLAGS = $(LDFLAGS_AS_NEEDED) $(LDFLAGS_NEW_DTAGS) kdeinit_LDFLAGS = $(KDE_MT_LDFLAGS) $(QT_LDFLAGS) $(X_LDFLAGS) $(USER_LDFLAGS) \ $(KDE_RPATH) -kdeinit_LDADD = $(LIB_KPARTS) +kdeinit_LDADD = $(LIB_KPARTS) -lXft $(LIB_QT) kioslave_SOURCES = kioslave.cpp kioslave_LDFLAGS = $(KDE_MT_LDFLAGS) $(QT_LDFLAGS) $(X_LDFLAGS) $(USER_LDFLAGS) \ @@ -60,7 +60,7 @@ klauncher_la_LIBADD = $(LIB_KIO) $(LIB_QT) $(LIB_KDECORE) $(top_builddir)/dcop/l klauncher_la_SOURCES = klauncher.cpp klauncher_main.cpp autostart.cpp kstartupconfig_SOURCES = kstartupconfig.cpp -kstartupconfig_LDADD = $(top_builddir)/kdecore/libkdefakes.la +kstartupconfig_LDADD = $(top_builddir)/kdecore/libkdefakes.la $(LIB_QT) kdostartupconfig_SOURCES = kdostartupconfig.cpp kdostartupconfig_LDFLAGS = $(KDE_MT_LDFLAGS) $(QT_LDFLAGS) $(X_LDFLAGS) $(USER_LDFLAGS) \ $(KDE_RPATH) diff --git a/kio/kio/kfilterdev.cpp b/kio/kio/kfilterdev.cpp index c1f4d7953..f6af06ae2 100644 --- a/kio/kio/kfilterdev.cpp +++ b/kio/kio/kfilterdev.cpp @@ -116,7 +116,7 @@ TQIODevice * KFilterDev::device( TQIODevice* inDevice, const TQString & mimetype return 0; } -bool KFilterDev::open( int mode ) +bool KFilterDev::open( OpenMode mode ) { //kdDebug(7005) << "KFilterDev::open " << mode << endl; if ( mode == IO_ReadOnly ) @@ -132,7 +132,7 @@ bool KFilterDev::open( int mode ) d->bNeedHeader = !d->bSkipHeaders; filter->init( mode ); d->bOpenedUnderlyingDevice = !filter->device()->isOpen(); - bool ret = d->bOpenedUnderlyingDevice ? filter->device()->open( (TQIODevice_OpenModeFlag)mode ) : true; + bool ret = d->bOpenedUnderlyingDevice ? filter->device()->open( (OpenMode)mode ) : true; d->result = KFilterBase::OK; if ( !ret ) diff --git a/kio/kio/kfilterdev.h b/kio/kio/kfilterdev.h index edd180ad8..cf730636a 100644 --- a/kio/kio/kfilterdev.h +++ b/kio/kio/kfilterdev.h @@ -53,7 +53,7 @@ public: * Open for reading or writing. * If the KFilterBase's device is not opened, it will be opened. */ - virtual bool open( int mode ); + virtual bool open( OpenMode mode ); /** * Close after reading or writing. * If the KFilterBase's device was opened by open(), it will be closed. -- cgit v1.2.1