@ -189,8 +189,8 @@ bool KdesvnFileListPrivate::reReadSettings()
_unknown ! = mdisp_unknown_files ) ;
}
kdesvnfilelist : : kdesvnfilelist ( KActionCollection * aCollect , TQWidget * tq parent, const char * name )
: KListView ( tq parent, name ) , ItemDisplay ( ) , m_SvnWrapper ( new SvnActions ( this ) )
kdesvnfilelist : : kdesvnfilelist ( KActionCollection * aCollect , TQWidget * parent, const char * name )
: KListView ( parent, name ) , ItemDisplay ( ) , m_SvnWrapper ( new SvnActions ( this ) )
{
m_SelectedItems = 0 ;
m_pList = new KdesvnFileListPrivate ;
@ -646,7 +646,7 @@ void kdesvnfilelist::closeMe()
m_pList - > m_fileTip - > setItem ( 0 ) ;
}
bool kdesvnfilelist : : checkDirs ( const TQString & _what , FileListViewItem * _ tq parent)
bool kdesvnfilelist : : checkDirs ( const TQString & _what , FileListViewItem * _ parent)
{
TQString what = _what ;
svn : : StatusEntries dlist ;
@ -654,13 +654,13 @@ bool kdesvnfilelist::checkDirs(const TQString&_what,FileListViewItem * _tqparent
what . truncate ( what . length ( ) - 1 ) ;
}
// prevent this from checking unversioned folder. FIXME: what happen when we do open url on a non-working-copy folder??
if ( ! isWorkingCopy ( ) | | ( ! _ tq parent) | | ( ( _ tq parent) & & ( _ tq parent- > isVersioned ( ) ) ) ) {
if ( ! isWorkingCopy ( ) | | ( ! _ parent) | | ( ( _ parent) & & ( _ parent- > isVersioned ( ) ) ) ) {
if ( ! m_SvnWrapper - > maketqStatus ( what , dlist , m_pList - > m_remoteRevision ) ) {
kdDebug ( ) < < " unable maketqStatus " < < endl ;
return false ;
}
} else {
checkUnversionedDirs ( _ tq parent) ;
checkUnversionedDirs ( _ parent) ;
return true ;
}
svn : : StatusEntries neweritems ;
@ -682,15 +682,15 @@ bool kdesvnfilelist::checkDirs(const TQString&_what,FileListViewItem * _tqparent
// current item is not versioned
if ( ! ( * it ) - > isVersioned ( ) & & ! filterOut ( ( * it ) ) ) {
// if empty, we may want to create a default svn::tqStatus for each folder inside this _ tq parent
// if empty, we may want to create a default svn::tqStatus for each folder inside this _ parent
// iterate over TQDir and create new filelistviewitem
checkUnversionedDirs ( _ tq parent) ;
checkUnversionedDirs ( _ parent) ;
}
if ( ( * it ) - > path ( ) = = what | | TQString : : compare ( ( * it ) - > entry ( ) . url ( ) , what ) = = 0 ) {
if ( ! _ tq parent) {
if ( ! _ parent) {
pitem = new FileListViewItem ( this , * it ) ;
//kdDebug()<< "CheckDirs::creating new FileListViewitem as tq parent " + (*it)->path() << endl;
//kdDebug()<< "CheckDirs::creating new FileListViewitem as parent " + (*it)->path() << endl;
m_Dirsread [ pitem - > fullName ( ) ] = true ;
pitem - > setDropEnabled ( true ) ;
}
@ -699,8 +699,8 @@ bool kdesvnfilelist::checkDirs(const TQString&_what,FileListViewItem * _tqparent
break ;
}
}
if ( _ tq parent) {
pitem = _ tq parent;
if ( _ parent) {
pitem = _ parent;
}
insertDirs ( pitem , dlist ) ;
if ( ownupdates ) {
@ -711,7 +711,7 @@ bool kdesvnfilelist::checkDirs(const TQString&_what,FileListViewItem * _tqparent
return true ;
}
void kdesvnfilelist : : insertDirs ( FileListViewItem * _ tq parent, svn : : StatusEntries & dlist )
void kdesvnfilelist : : insertDirs ( FileListViewItem * _ parent, svn : : StatusEntries & dlist )
{
svn : : StatusEntries : : iterator it ;
#if 0
@ -732,13 +732,13 @@ void kdesvnfilelist::insertDirs(FileListViewItem * _tqparent,svn::StatusEntries&
continue ;
}
FileListViewItem * item ;
if ( ! _ tq parent) {
if ( ! _ parent) {
item = new FileListViewItem ( this , * it ) ;
} else {
if ( ( item = _ tq parent- > findChild ( ( * it ) - > path ( ) ) ) ) {
if ( ( item = _ parent- > findChild ( ( * it ) - > path ( ) ) ) ) {
delete item ;
}
item = new FileListViewItem ( this , _ tq parent, * it ) ;
item = new FileListViewItem ( this , _ parent, * it ) ;
}
if ( item - > isDir ( ) ) {
m_Dirsread [ item - > fullName ( ) ] = false ;
@ -912,7 +912,7 @@ void kdesvnfilelist::enableActions()
m_DelCurrent - > setEnabled ( ( multi | | single ) ) ;
m_LockAction - > setEnabled ( ( multi | | single ) ) ;
m_UnlockAction - > setEnabled ( ( multi | | single ) ) ;
m_IgnoreAction - > setEnabled ( ( single ) & & singleSelected ( ) - > tq parent( ) ! = 0 & & ! singleSelected ( ) - > isRealVersioned ( ) ) ;
m_IgnoreAction - > setEnabled ( ( single ) & & singleSelected ( ) - > parent( ) ! = 0 & & ! singleSelected ( ) - > isRealVersioned ( ) ) ;
m_RenameAction - > setEnabled ( single & & ( ! isWorkingCopy ( ) | | singleSelected ( ) ! = firstChild ( ) ) ) ;
m_CopyAction - > setEnabled ( single & & ( ! isWorkingCopy ( ) | | singleSelected ( ) ! = firstChild ( ) ) ) ;
@ -1304,11 +1304,11 @@ void kdesvnfilelist::refreshCurrent(SvnItem*cur)
viewport ( ) - > tqrepaint ( ) ;
}
bool kdesvnfilelist : : refreshRecursive ( FileListViewItem * _ tq parent, bool down )
bool kdesvnfilelist : : refreshRecursive ( FileListViewItem * _ parent, bool down )
{
FileListViewItem * item ;
if ( _ tq parent) {
item = static_cast < FileListViewItem * > ( _ tq parent- > firstChild ( ) ) ;
if ( _ parent) {
item = static_cast < FileListViewItem * > ( _ parent- > firstChild ( ) ) ;
} else {
item = static_cast < FileListViewItem * > ( firstChild ( ) ) ;
}
@ -1324,7 +1324,7 @@ bool kdesvnfilelist::refreshRecursive(FileListViewItem*_tqparent,bool down)
item = static_cast < FileListViewItem * > ( item - > nextSibling ( ) ) ;
}
TQString what = ( _ tq parent! = 0 ? _ tq parent- > fullName ( ) : baseUri ( ) ) ;
TQString what = ( _ parent! = 0 ? _ parent- > fullName ( ) : baseUri ( ) ) ;
svn : : StatusEntries dlist ;
if ( ! m_SvnWrapper - > maketqStatus ( what , dlist , m_pList - > m_remoteRevision ) ) {
@ -1363,10 +1363,10 @@ bool kdesvnfilelist::refreshRecursive(FileListViewItem*_tqparent,bool down)
if ( ! gotit & & ! filterOut ( ( * it ) ) ) {
dispchanged = true ;
FileListViewItem * item ;
if ( ! _ tq parent) {
if ( ! _ parent) {
item = new FileListViewItem ( this , * it ) ;
} else {
item = new FileListViewItem ( this , _ tq parent, * it ) ;
item = new FileListViewItem ( this , _ parent, * it ) ;
}
if ( item - > isDir ( ) ) {
m_Dirsread [ item - > fullName ( ) ] = false ;
@ -1400,8 +1400,8 @@ bool kdesvnfilelist::refreshRecursive(FileListViewItem*_tqparent,bool down)
kdDebug ( ) < < " Selected items " < < m_SelectedItems - > count ( ) < < endl ;
# endif
}
if ( _ tq parent) {
item = static_cast < FileListViewItem * > ( _ tq parent- > firstChild ( ) ) ;
if ( _ parent) {
item = static_cast < FileListViewItem * > ( _ parent- > firstChild ( ) ) ;
} else {
item = static_cast < FileListViewItem * > ( firstChild ( ) ) ;
}
@ -2486,8 +2486,8 @@ void kdesvnfilelist::slotDirItemCreated(const TQString&what)
void kdesvnfilelist : : updateParents ( FileListViewItem * item )
{
if ( ! item | | ! item - > tq parent( ) ) return ;
FileListViewItem * it = static_cast < FileListViewItem * > ( item - > tq parent( ) ) ;
if ( ! item | | ! item - > parent( ) ) return ;
FileListViewItem * it = static_cast < FileListViewItem * > ( item - > parent( ) ) ;
it - > update ( ) ;
updateParents ( it ) ;
}
@ -2564,7 +2564,7 @@ void kdesvnfilelist::_dirwatchTimeout()
checkUnversionedDirs ( item ) ;
}
}
updateParents ( static_cast < FileListViewItem * > ( item - > tq parent( ) ) ) ;
updateParents ( static_cast < FileListViewItem * > ( item - > parent( ) ) ) ;
} else if ( c = = ' D ' ) {
if ( item - > isDir ( ) ) {
m_pList - > m_DirWatch - > removeDir ( what ) ;
@ -2576,7 +2576,7 @@ void kdesvnfilelist::_dirwatchTimeout()
} else if ( ! item - > isMissing ( ) ) {
TQFileInfo fi ( what ) ;
if ( ! fi . exists ( ) ) {
FileListViewItem * p = static_cast < FileListViewItem * > ( item - > tq parent( ) ) ;
FileListViewItem * p = static_cast < FileListViewItem * > ( item - > parent( ) ) ;
delete item ;
repaintit = true ;
item = 0 ;
@ -2804,11 +2804,11 @@ void kdesvnfilelist::slotRelocate()
refreshItem ( k - > fItem ( ) ) ;
}
void kdesvnfilelist : : checkUnversionedDirs ( FileListViewItem * _ tq parent )
void kdesvnfilelist : : checkUnversionedDirs ( FileListViewItem * _ parent )
{
TQDir d ;
if ( _ tq parent)
d . setPath ( _ tq parent- > fullName ( ) ) ; //FIXME: this one is not reliable, what if _ tq parent == 0??
if ( _ parent)
d . setPath ( _ parent- > fullName ( ) ) ; //FIXME: this one is not reliable, what if _ parent == 0??
// else
// d.setPath(this->firstChild()->fullName());
@ -2845,12 +2845,12 @@ void kdesvnfilelist::checkUnversionedDirs( FileListViewItem * _tqparent )
// start copying insertDirs
FileListViewItem * item ;
if ( ! _ tq parent) {
if ( ! _ parent) {
item = new FileListViewItem ( this , stat ) ;
kdDebug ( ) < < " creating new FileListViewitem " + item - > fullName ( ) < < endl ;
} else {
item = new FileListViewItem ( this , _ tq parent, stat ) ;
kdDebug ( ) < < " creating new FileListViewitem (with tq parent) " + item - > fullName ( ) < < endl ;
item = new FileListViewItem ( this , _ parent, stat ) ;
kdDebug ( ) < < " creating new FileListViewitem (with parent) " + item - > fullName ( ) < < endl ;
}
if ( fi - > isDir ( ) ) {
m_Dirsread [ item - > fullName ( ) ] = false ;
@ -2872,7 +2872,7 @@ void kdesvnfilelist::checkUnversionedDirs( FileListViewItem * _tqparent )
}
// uncomment this if you've ben able to set svn_node_kind (see above)
//this->insertDirs(_ tq parent, nonversioned_list);
//this->insertDirs(_ parent, nonversioned_list);
}
void kdesvnfilelist : : rescanIconsRec ( FileListViewItem * startAt , bool checkNewer , bool no_update )
@ -3098,7 +3098,7 @@ void kdesvnfilelist::slotFoldTree()
while ( TQListViewItem * item = it . current ( ) )
{
// don't close the top level directory
if ( item - > isExpandable ( ) & & item - > tq parent( ) )
if ( item - > isExpandable ( ) & & item - > parent( ) )
item - > setOpen ( false ) ;
+ + it ;