summaryrefslogtreecommitdiffstats
path: root/doc/html/dirview-example.html
diff options
context:
space:
mode:
Diffstat (limited to 'doc/html/dirview-example.html')
-rw-r--r--doc/html/dirview-example.html38
1 files changed, 19 insertions, 19 deletions
diff --git a/doc/html/dirview-example.html b/doc/html/dirview-example.html
index 93386e7b0..59487ce6c 100644
--- a/doc/html/dirview-example.html
+++ b/doc/html/dirview-example.html
@@ -116,7 +116,7 @@ class DirectoryView : public <a href="ntqlistview.html">TQListView</a>
<a href="metaobjects.html#TQ_OBJECT">TQ_OBJECT</a>
public:
- DirectoryView( <a href="ntqwidget.html">TQWidget</a> *parent = 0, const char *name = 0, bool sdo = FALSE );
+ DirectoryView( <a href="ntqwidget.html">TQWidget</a> *parent = 0, const char *name = 0, bool sdo = false );
bool showDirsOnly() { return dirsOnly; }
public slots:
@@ -360,12 +360,12 @@ Directory::Directory( <a href="ntqlistview.html">TQListView</a> * parent, const
<a href="ntqstring.html">TQString</a> s( fullName() );
<a href="ntqdir.html">TQDir</a> thisDir( s );
<a name="x1667"></a> if ( !thisDir.<a href="ntqdir.html#isReadable">isReadable</a>() ) {
- readable = FALSE;
- <a href="qlistviewitem.html#setExpandable">setExpandable</a>( FALSE );
+ readable = false;
+ <a href="qlistviewitem.html#setExpandable">setExpandable</a>( false );
return;
}
- <a href="qlistviewitem.html#listView">listView</a>()-&gt;setUpdatesEnabled( FALSE );
+ <a href="qlistviewitem.html#listView">listView</a>()-&gt;setUpdatesEnabled( false );
<a name="x1666"></a> const TQFileInfoList * files = thisDir.<a href="ntqdir.html#entryInfoList">entryInfoList</a>();
if ( files ) {
TQFileInfoListIterator it( *files );
@@ -389,7 +389,7 @@ Directory::Directory( <a href="ntqlistview.html">TQListView</a> * parent, const
}
}
}
- listView()-&gt;setUpdatesEnabled( TRUE );
+ listView()-&gt;setUpdatesEnabled( true );
}
TQListViewItem::<a href="qlistviewitem.html#setOpen">setOpen</a>( o );
}
@@ -397,7 +397,7 @@ Directory::Directory( <a href="ntqlistview.html">TQListView</a> * parent, const
<a name="x1692"></a>void Directory::<a href="qlistviewitem.html#setup">setup</a>()
{
- setExpandable( TRUE );
+ setExpandable( true );
TQListViewItem::<a href="qlistviewitem.html#setup">setup</a>();
}
@@ -434,7 +434,7 @@ TQString <a name="f477"></a>Directory::fullName()
<a name="f478"></a>DirectoryView::DirectoryView( <a href="ntqwidget.html">TQWidget</a> *parent, const char *name, bool sdo )
: <a href="ntqlistview.html">TQListView</a>( parent, name ), dirsOnly( sdo ), oldCurrent( 0 ),
- dropItem( 0 ), mousePressed( FALSE )
+ dropItem( 0 ), mousePressed( false )
{
autoopen_timer = new <a href="ntqtimer.html">TQTimer</a>( this );
if ( !folderLocked ) {
@@ -449,8 +449,8 @@ TQString <a name="f477"></a>Directory::fullName()
<a href="ntqobject.html#connect">connect</a>( this, TQ_SIGNAL( <a href="ntqlistview.html#returnPressed">returnPressed</a>( <a href="qlistviewitem.html">TQListViewItem</a> * ) ),
this, TQ_SLOT( slotFolderSelected( <a href="qlistviewitem.html">TQListViewItem</a> * ) ) );
- <a href="ntqwidget.html#setAcceptDrops">setAcceptDrops</a>( TRUE );
- <a href="ntqscrollview.html#viewport">viewport</a>()-&gt;setAcceptDrops( TRUE );
+ <a href="ntqwidget.html#setAcceptDrops">setAcceptDrops</a>( true );
+ <a href="ntqscrollview.html#viewport">viewport</a>()-&gt;setAcceptDrops( true );
<a name="x1706"></a> <a href="ntqobject.html#connect">connect</a>( autoopen_timer, TQ_SIGNAL( <a href="ntqtimer.html#timeout">timeout</a>() ),
this, TQ_SLOT( openFolder() ) );
@@ -469,7 +469,7 @@ void <a name="f480"></a>DirectoryView::openFolder()
{
<a name="x1705"></a> autoopen_timer-&gt;<a href="ntqtimer.html#stop">stop</a>();
if ( dropItem &amp;&amp; !dropItem-&gt;isOpen() ) {
- dropItem-&gt;setOpen( TRUE );
+ dropItem-&gt;setOpen( true );
dropItem-&gt;repaint();
}
}
@@ -504,7 +504,7 @@ static const int autoopenTime = 750;
<a href="ntqpoint.html">TQPoint</a> vp = <a href="ntqscrollview.html#contentsToViewport">contentsToViewport</a>( ( (TQDragMoveEvent*)e )-&gt;pos() );
<a href="qlistviewitem.html">TQListViewItem</a> *i = <a href="ntqlistview.html#itemAt">itemAt</a>( vp );
if ( i ) {
- <a href="ntqlistview.html#setSelected">setSelected</a>( i, TRUE );
+ <a href="ntqlistview.html#setSelected">setSelected</a>( i, true );
<a name="x1668"></a> e-&gt;<a href="qdragmoveevent.html#accept">accept</a>();
if ( i != dropItem ) {
autoopen_timer-&gt;<a href="ntqtimer.html#stop">stop</a>();
@@ -536,7 +536,7 @@ static const int autoopenTime = 750;
dropItem = 0;
<a href="ntqlistview.html#setCurrentItem">setCurrentItem</a>( oldCurrent );
- <a href="ntqlistview.html#setSelected">setSelected</a>( oldCurrent, TRUE );
+ <a href="ntqlistview.html#setSelected">setSelected</a>( oldCurrent, true );
}
<a name="x1682"></a>void DirectoryView::<a href="ntqscrollview.html#contentsDropEvent">contentsDropEvent</a>( <a href="qdropevent.html">TQDropEvent</a> *e )
@@ -621,7 +621,7 @@ TQString <a name="f481"></a>DirectoryView::fullPath(TQListViewItem* item)
<a name="x1686"></a> treeStepSize() * ( i-&gt;<a href="qlistviewitem.html#depth">depth</a>() + ( rootIsDecorated() ? 1 : 0) ) + itemMargin() ||
p.<a href="ntqpoint.html#x">x</a>() &lt; header()-&gt;cellPos( header()-&gt;mapToActual( 0 ) ) ) {
presspos = e-&gt;<a href="qdropevent.html#pos">pos</a>();
- mousePressed = TRUE;
+ mousePressed = true;
}
}
}
@@ -629,7 +629,7 @@ TQString <a name="f481"></a>DirectoryView::fullPath(TQListViewItem* item)
<a name="x1683"></a>void DirectoryView::<a href="ntqlistview.html#contentsMouseMoveEvent">contentsMouseMoveEvent</a>( <a href="qmouseevent.html">TQMouseEvent</a>* e )
{
if ( mousePressed &amp;&amp; ( presspos - e-&gt;<a href="qdropevent.html#pos">pos</a>() ).manhattanLength() &gt; TQApplication::<a href="ntqapplication.html#startDragDistance">startDragDistance</a>() ) {
- mousePressed = FALSE;
+ mousePressed = false;
<a href="qlistviewitem.html">TQListViewItem</a> *item = itemAt( contentsToViewport(presspos) );
if ( item ) {
<a href="ntqstring.html">TQString</a> source = fullPath(item);
@@ -646,7 +646,7 @@ TQString <a name="f481"></a>DirectoryView::fullPath(TQListViewItem* item)
<a name="x1685"></a>void DirectoryView::<a href="ntqlistview.html#contentsMouseReleaseEvent">contentsMouseReleaseEvent</a>( <a href="qmouseevent.html">TQMouseEvent</a> * )
{
- mousePressed = FALSE;
+ mousePressed = false;
}
void <a name="f482"></a>DirectoryView::setDir( const <a href="ntqstring.html">TQString</a> &amp;s )
@@ -654,7 +654,7 @@ void <a name="f482"></a>DirectoryView::setDir( const <a href="ntqstring.html">TQ
<a href="qlistviewitemiterator.html">TQListViewItemIterator</a> it( this );
++it;
for ( ; it.<a href="qlistviewitemiterator.html#current">current</a>(); ++it ) {
- it.<a href="qlistviewitemiterator.html#current">current</a>()-&gt;setOpen( FALSE );
+ it.<a href="qlistviewitemiterator.html#current">current</a>()-&gt;setOpen( false );
}
<a name="x1703"></a> <a href="ntqstringlist.html">TQStringList</a> lst( TQStringList::<a href="ntqstringlist.html#split">split</a>( "/", s ) );
@@ -663,7 +663,7 @@ void <a name="f482"></a>DirectoryView::setDir( const <a href="ntqstring.html">TQ
<a name="x1700"></a> for ( ; it2 != lst.<a href="ntqvaluelist.html#end">end</a>(); ++it2 ) {
while ( item ) {
if ( item-&gt;<a href="qlistviewitem.html#text">text</a>( 0 ) == *it2 ) {
- item-&gt;<a href="qlistviewitem.html#setOpen">setOpen</a>( TRUE );
+ item-&gt;<a href="qlistviewitem.html#setOpen">setOpen</a>( true );
break;
}
<a name="x1687"></a> item = item-&gt;<a href="qlistviewitem.html#itemBelow">itemBelow</a>();
@@ -726,12 +726,12 @@ int main( int argc, char ** argv )
++i;
<a name="x1713"></a> Directory * root = new Directory( &amp;mw, fi-&gt;<a href="ntqfileinfo.html#filePath">filePath</a>() );
if ( roots-&gt;count() &lt;= 1 )
-<a name="x1718"></a> root-&gt;<a href="qlistviewitem.html#setOpen">setOpen</a>( TRUE ); // be interesting
+<a name="x1718"></a> root-&gt;<a href="qlistviewitem.html#setOpen">setOpen</a>( true ); // be interesting
}
<a name="x1719"></a> mw.<a href="ntqwidget.html#resize">resize</a>( 400, 400 );
mw.<a href="ntqwidget.html#setCaption">setCaption</a>( "TQt Example - Directory Browser" );
-<a name="x1715"></a> mw.<a href="ntqlistview.html#setAllColumnsShowFocus">setAllColumnsShowFocus</a>( TRUE );
+<a name="x1715"></a> mw.<a href="ntqlistview.html#setAllColumnsShowFocus">setAllColumnsShowFocus</a>( true );
a.<a href="ntqapplication.html#setMainWidget">setMainWidget</a>( &amp;mw );
<a name="x1717"></a> mw.<a href="ntqwidget.html#show">show</a>();