summaryrefslogtreecommitdiffstats
path: root/kdevdesigner/designer/command.cpp
diff options
context:
space:
mode:
authorMichele Calgaro <michele.calgaro@yahoo.it>2025-04-08 12:59:07 +0900
committerMichele Calgaro <michele.calgaro@yahoo.it>2025-04-10 17:35:38 +0900
commitd2d30bfbef26707f9158cbc31d5763a9a1d4ab2d (patch)
tree6d2d4502d6fbe4d6810bfb7bcf297cbf995d3db8 /kdevdesigner/designer/command.cpp
parentb9618de13e8f38c3558e9ed393a75c1f13af665c (diff)
downloadtdevelop-r14.1.4.tar.gz
tdevelop-r14.1.4.zip
Replace TRUE/FALSE with boolean values true/falser14.1.4
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it> (cherry picked from commit 5198c9d3ac02aa9c7949f49e3cf374f683facb18)
Diffstat (limited to 'kdevdesigner/designer/command.cpp')
-rw-r--r--kdevdesigner/designer/command.cpp170
1 files changed, 85 insertions, 85 deletions
diff --git a/kdevdesigner/designer/command.cpp b/kdevdesigner/designer/command.cpp
index 4b3b3109..4e4eab06 100644
--- a/kdevdesigner/designer/command.cpp
+++ b/kdevdesigner/designer/command.cpp
@@ -63,8 +63,8 @@
CommandHistory::CommandHistory( int s )
: current( -1 ), steps( s ), savedAt( -1 )
{
- history.setAutoDelete( TRUE );
- modified = FALSE;
+ history.setAutoDelete( true );
+ modified = false;
compressedCommand = 0;
}
@@ -80,7 +80,7 @@ void CommandHistory::addCommand( Command *cmd, bool tryCompress )
if ( compressedCommand ) {
compressedCommand->merge( cmd );
- modified = TRUE;
+ modified = true;
modificationChanged( modified );
return;
}
@@ -94,7 +94,7 @@ void CommandHistory::addCommand( Command *cmd, bool tryCompress )
savedAt = -2;
TQPtrList<Command> commands;
- commands.setAutoDelete( FALSE );
+ commands.setAutoDelete( false );
for( int i = 0; i <= current; ++i ) {
commands.insert( i, history.at( 0 ) );
@@ -104,7 +104,7 @@ void CommandHistory::addCommand( Command *cmd, bool tryCompress )
commands.append( cmd );
history.clear();
history = commands;
- history.setAutoDelete( TRUE );
+ history.setAutoDelete( true );
} else {
history.append( cmd );
}
@@ -117,7 +117,7 @@ void CommandHistory::addCommand( Command *cmd, bool tryCompress )
}
emitUndoRedo();
- modified = TRUE;
+ modified = true;
modificationChanged( modified );
}
@@ -228,7 +228,7 @@ void Command::merge( Command * )
bool Command::canMerge( Command * )
{
- return FALSE;
+ return false;
}
// ------------------------------------------------------------
@@ -278,7 +278,7 @@ void InsertCommand::execute()
}
widget->show();
formWindow()->widgets()->insert( widget, widget );
- formWindow()->clearSelection( FALSE );
+ formWindow()->clearSelection( false );
formWindow()->selectWidget( widget );
formWindow()->mainWindow()->objectHierarchy()->widgetInserted( widget );
}
@@ -286,7 +286,7 @@ void InsertCommand::execute()
void InsertCommand::unexecute()
{
widget->hide();
- formWindow()->selectWidget( widget, FALSE );
+ formWindow()->selectWidget( widget, false );
formWindow()->widgets()->remove( widget );
formWindow()->mainWindow()->objectHierarchy()->widgetRemoved( widget );
}
@@ -301,7 +301,7 @@ MoveCommand::MoveCommand( const TQString &n, FormWindow *fw,
: Command( n, fw ), widgets( w ), oldPos( op ), newPos( np ),
oldParent( opr ), newParent( npr )
{
- widgets.setAutoDelete( FALSE );
+ widgets.setAutoDelete( false );
}
void MoveCommand::merge( Command *c )
@@ -323,7 +323,7 @@ void MoveCommand::execute()
if ( !w->parentWidget() || WidgetFactory::layoutType( w->parentWidget() ) == WidgetFactory::NoLayout ) {
if ( newParent && oldParent && newParent != oldParent ) {
TQPoint pos = newParent->mapFromGlobal( w->mapToGlobal( TQPoint( 0,0 ) ) );
- w->reparent( newParent, pos, TRUE );
+ w->reparent( newParent, pos, true );
formWindow()->raiseSelection( w );
formWindow()->raiseChildSelections( w );
formWindow()->widgetChanged( w );
@@ -344,7 +344,7 @@ void MoveCommand::unexecute()
if ( !w->parentWidget() || WidgetFactory::layoutType( w->parentWidget() ) == WidgetFactory::NoLayout ) {
if ( newParent && oldParent && newParent != oldParent ) {
TQPoint pos = oldParent->mapFromGlobal( w->mapToGlobal( TQPoint( 0,0 ) ) );
- w->reparent( oldParent, pos, TRUE );
+ w->reparent( oldParent, pos, true );
formWindow()->raiseSelection( w );
formWindow()->raiseChildSelections( w );
formWindow()->widgetChanged( w );
@@ -365,9 +365,9 @@ DeleteCommand::DeleteCommand( const TQString &n, FormWindow *fw,
const TQWidgetList &wl )
: Command( n, fw ), widgets( wl )
{
- widgets.setAutoDelete( FALSE );
+ widgets.setAutoDelete( false );
TQWidgetList copyOfWidgets = widgets;
- copyOfWidgets.setAutoDelete(FALSE);
+ copyOfWidgets.setAutoDelete(false);
// Include the children of the selected items when deleting
for ( TQWidget *w = widgets.first(); w; w = widgets.next() ) {
@@ -385,14 +385,14 @@ DeleteCommand::DeleteCommand( const TQString &n, FormWindow *fw,
void DeleteCommand::execute()
{
- formWindow()->setPropertyShowingBlocked( TRUE );
+ formWindow()->setPropertyShowingBlocked( true );
connections.clear();
for ( TQWidget *w = widgets.first(); w; w = widgets.next() ) {
w->hide();
TQString s = w->name();
s.prepend( "qt_dead_widget_" );
w->setName( s );
- formWindow()->selectWidget( w, FALSE );
+ formWindow()->selectWidget( w, false );
formWindow()->widgets()->remove( w );
TQValueList<MetaDataBase::Connection> conns = MetaDataBase::connections( formWindow(), w );
connections.insert( w, conns );
@@ -402,7 +402,7 @@ void DeleteCommand::execute()
(*it).signal, (*it).receiver, (*it).slot );
}
}
- formWindow()->setPropertyShowingBlocked( FALSE );
+ formWindow()->setPropertyShowingBlocked( false );
formWindow()->emitShowProperties();
formWindow()->mainWindow()->objectHierarchy()->widgetsRemoved( widgets );
@@ -410,8 +410,8 @@ void DeleteCommand::execute()
void DeleteCommand::unexecute()
{
- formWindow()->setPropertyShowingBlocked( TRUE );
- formWindow()->clearSelection( FALSE );
+ formWindow()->setPropertyShowingBlocked( true );
+ formWindow()->clearSelection( false );
for ( TQWidget *w = widgets.first(); w; w = widgets.next() ) {
w->show();
TQString s = w->name();
@@ -426,7 +426,7 @@ void DeleteCommand::unexecute()
(*it).signal, (*it).receiver, (*it).slot );
}
}
- formWindow()->setPropertyShowingBlocked( FALSE );
+ formWindow()->setPropertyShowingBlocked( false );
formWindow()->emitShowProperties();
formWindow()->mainWindow()->objectHierarchy()->widgetsInserted( widgets );
}
@@ -440,7 +440,7 @@ SetPropertyCommand::SetPropertyCommand( const TQString &n, FormWindow *fw,
const TQString &ocut, bool reset )
: Command( n, fw ), widget( w ), editor( e ), propName( pn ),
oldValue( ov ), newValue( nv ), oldCurrentItemText( ocut ), newCurrentItemText( ncut ),
- wasChanged( TRUE ), isResetCommand( reset )
+ wasChanged( true ), isResetCommand( reset )
{
wasChanged = MetaDataBase::isPropertyChanged( w, propName );
if ( oldCurrentItemText.isNull() )
@@ -453,9 +453,9 @@ SetPropertyCommand::SetPropertyCommand( const TQString &n, FormWindow *fw,
void SetPropertyCommand::execute()
{
if ( !wasChanged )
- MetaDataBase::setPropertyChanged( widget, propName, TRUE );
+ MetaDataBase::setPropertyChanged( widget, propName, true );
if ( isResetCommand ) {
- MetaDataBase::setPropertyChanged( widget, propName, FALSE );
+ MetaDataBase::setPropertyChanged( widget, propName, false );
if ( WidgetFactory::resetProperty( widget, propName ) ) {
if ( !formWindow()->isWidgetSelected( widget ) && formWindow() != widget )
formWindow()->selectWidget( widget );
@@ -466,7 +466,7 @@ void SetPropertyCommand::execute()
if ( !i )
return;
i->setValue( widget->property( propName ) );
- i->setChanged( FALSE );
+ i->setChanged( false );
editor->refetchData();
editor->emitWidgetChanged();
return;
@@ -478,9 +478,9 @@ void SetPropertyCommand::execute()
void SetPropertyCommand::unexecute()
{
if ( !wasChanged )
- MetaDataBase::setPropertyChanged( widget, propName, FALSE );
+ MetaDataBase::setPropertyChanged( widget, propName, false );
if ( isResetCommand )
- MetaDataBase::setPropertyChanged( widget, propName, TRUE );
+ MetaDataBase::setPropertyChanged( widget, propName, true );
setProperty( oldValue, oldCurrentItemText );
}
@@ -488,24 +488,24 @@ bool SetPropertyCommand::canMerge( Command *c )
{
SetPropertyCommand *cmd = (SetPropertyCommand*)c;
if ( !widget )
- return FALSE;
+ return false;
const TQMetaProperty *p =
- widget->metaObject()->property( widget->metaObject()->findProperty( propName, TRUE ), TRUE );
+ widget->metaObject()->property( widget->metaObject()->findProperty( propName, true ), true );
if ( !p ) {
if ( propName == "toolTip" || propName == "whatsThis" )
- return TRUE;
+ return true;
if ( ::tqt_cast<CustomWidget*>((TQObject *)widget) ) {
MetaDataBase::CustomWidget *cw = ((CustomWidget*)(TQObject*)widget)->customWidget();
if ( !cw )
- return FALSE;
+ return false;
for ( TQValueList<MetaDataBase::Property>::Iterator it = cw->lstProperties.begin(); it != cw->lstProperties.end(); ++it ) {
if ( TQString( (*it ).property ) == propName ) {
if ( (*it).type == "String" || (*it).type == "CString" || (*it).type == "Int" || (*it).type == "UInt" )
- return TRUE;
+ return true;
}
}
}
- return FALSE;
+ return false;
}
TQVariant::Type t = TQVariant::nameToType( p->type() );
return ( cmd->propName == propName &&
@@ -523,7 +523,7 @@ bool SetPropertyCommand::checkProperty()
{
if ( propName == "name" /*|| propName == "itemName"*/ ) { // ### fix that
TQString s = newValue.toString();
- if ( !formWindow()->unify( widget, s, FALSE ) ) {
+ if ( !formWindow()->unify( widget, s, false ) ) {
TQMessageBox::information( formWindow()->mainWindow(),
i18n( "Set 'name' Property" ),
i18n( "The name of a widget must be unique.\n"
@@ -532,8 +532,8 @@ bool SetPropertyCommand::checkProperty()
arg( newValue.toString() ).
arg( formWindow()->name() ).
arg( oldValue.toString() ));
- setProperty( oldValue, oldCurrentItemText, FALSE );
- return FALSE;
+ setProperty( oldValue, oldCurrentItemText, false );
+ return false;
}
if ( s.isEmpty() ) {
TQMessageBox::information( formWindow()->mainWindow(),
@@ -541,14 +541,14 @@ bool SetPropertyCommand::checkProperty()
i18n( "The name of a widget must not be null.\n"
"The name has been reverted to '%1'." ).
arg( oldValue.toString() ));
- setProperty( oldValue, oldCurrentItemText, FALSE );
- return FALSE;
+ setProperty( oldValue, oldCurrentItemText, false );
+ return false;
}
if ( ::tqt_cast<FormWindow*>(widget->parent()) )
formWindow()->mainWindow()->formNameChanged( (FormWindow*)((TQWidget*)(TQObject*)widget)->parentWidget() );
}
- return TRUE;
+ return true;
}
void SetPropertyCommand::setProperty( const TQVariant &v, const TQString &currentItemText, bool select )
@@ -563,16 +563,16 @@ void SetPropertyCommand::setProperty( const TQVariant &v, const TQString &curren
if ( select )
editor->propertyList()->setCurrentProperty( propName );
const TQMetaProperty *p =
- widget->metaObject()->property( widget->metaObject()->findProperty( propName, TRUE ), TRUE );
+ widget->metaObject()->property( widget->metaObject()->findProperty( propName, true ), true );
if ( !p ) {
if ( propName == "hAlign" ) {
- p = widget->metaObject()->property( widget->metaObject()->findProperty( "alignment", TRUE ), TRUE );
+ p = widget->metaObject()->property( widget->metaObject()->findProperty( "alignment", true ), true );
int align = widget->property( "alignment" ).toInt();
align &= ~( AlignHorizontal_Mask );
align |= p->keyToValue( currentItemText );
widget->setProperty( "alignment", TQVariant( align ) );
} else if ( propName == "vAlign" ) {
- p = widget->metaObject()->property( widget->metaObject()->findProperty( "alignment", TRUE ), TRUE );
+ p = widget->metaObject()->property( widget->metaObject()->findProperty( "alignment", true ), true );
int align = widget->property( "alignment" ).toInt();
align &= ~( AlignVertical_Mask );
align |= p->keyToValue( currentItemText );
@@ -680,14 +680,14 @@ LayoutHorizontalCommand::LayoutHorizontalCommand( const TQString &n, FormWindow
void LayoutHorizontalCommand::execute()
{
- formWindow()->clearSelection( FALSE );
+ formWindow()->clearSelection( false );
layout.doLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
void LayoutHorizontalCommand::unexecute()
{
- formWindow()->clearSelection( FALSE );
+ formWindow()->clearSelection( false );
layout.undoLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
@@ -697,20 +697,20 @@ void LayoutHorizontalCommand::unexecute()
LayoutHorizontalSplitCommand::LayoutHorizontalSplitCommand( const TQString &n, FormWindow *fw,
TQWidget *parent, TQWidget *layoutBase,
const TQWidgetList &wl )
- : Command( n, fw ), layout( wl, parent, fw, layoutBase, TRUE, TRUE )
+ : Command( n, fw ), layout( wl, parent, fw, layoutBase, true, true )
{
}
void LayoutHorizontalSplitCommand::execute()
{
- formWindow()->clearSelection( FALSE );
+ formWindow()->clearSelection( false );
layout.doLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
void LayoutHorizontalSplitCommand::unexecute()
{
- formWindow()->clearSelection( FALSE );
+ formWindow()->clearSelection( false );
layout.undoLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
@@ -726,14 +726,14 @@ LayoutVerticalCommand::LayoutVerticalCommand( const TQString &n, FormWindow *fw,
void LayoutVerticalCommand::execute()
{
- formWindow()->clearSelection( FALSE );
+ formWindow()->clearSelection( false );
layout.doLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
void LayoutVerticalCommand::unexecute()
{
- formWindow()->clearSelection( FALSE );
+ formWindow()->clearSelection( false );
layout.undoLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
@@ -743,20 +743,20 @@ void LayoutVerticalCommand::unexecute()
LayoutVerticalSplitCommand::LayoutVerticalSplitCommand( const TQString &n, FormWindow *fw,
TQWidget *parent, TQWidget *layoutBase,
const TQWidgetList &wl )
- : Command( n, fw ), layout( wl, parent, fw, layoutBase, TRUE, TRUE )
+ : Command( n, fw ), layout( wl, parent, fw, layoutBase, true, true )
{
}
void LayoutVerticalSplitCommand::execute()
{
- formWindow()->clearSelection( FALSE );
+ formWindow()->clearSelection( false );
layout.doLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
void LayoutVerticalSplitCommand::unexecute()
{
- formWindow()->clearSelection( FALSE );
+ formWindow()->clearSelection( false );
layout.undoLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
@@ -772,14 +772,14 @@ LayoutGridCommand::LayoutGridCommand( const TQString &n, FormWindow *fw,
void LayoutGridCommand::execute()
{
- formWindow()->clearSelection( FALSE );
+ formWindow()->clearSelection( false );
layout.doLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
void LayoutGridCommand::unexecute()
{
- formWindow()->clearSelection( FALSE );
+ formWindow()->clearSelection( false );
layout.undoLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
@@ -795,18 +795,18 @@ BreakLayoutCommand::BreakLayoutCommand( const TQString &n, FormWindow *fw,
margin = MetaDataBase::margin( layoutBase );
layout = 0;
if ( lay == WidgetFactory::HBox )
- layout = new HorizontalLayout( wl, layoutBase, fw, layoutBase, FALSE, ::tqt_cast<TQSplitter*>(layoutBase) != 0 );
+ layout = new HorizontalLayout( wl, layoutBase, fw, layoutBase, false, ::tqt_cast<TQSplitter*>(layoutBase) != 0 );
else if ( lay == WidgetFactory::VBox )
- layout = new VerticalLayout( wl, layoutBase, fw, layoutBase, FALSE, ::tqt_cast<TQSplitter*>(layoutBase) != 0 );
+ layout = new VerticalLayout( wl, layoutBase, fw, layoutBase, false, ::tqt_cast<TQSplitter*>(layoutBase) != 0 );
else if ( lay == WidgetFactory::Grid )
- layout = new GridLayout( wl, layoutBase, fw, layoutBase, TQSize( TQMAX( 5, fw->grid().x()), TQMAX( 5, fw->grid().y()) ), FALSE );
+ layout = new GridLayout( wl, layoutBase, fw, layoutBase, TQSize( TQMAX( 5, fw->grid().x()), TQMAX( 5, fw->grid().y()) ), false );
}
void BreakLayoutCommand::execute()
{
if ( !layout )
return;
- formWindow()->clearSelection( FALSE );
+ formWindow()->clearSelection( false );
layout->breakLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
for ( TQWidget *w = widgets.first(); w; w = widgets.next() )
@@ -817,7 +817,7 @@ void BreakLayoutCommand::unexecute()
{
if ( !layout )
return;
- formWindow()->clearSelection( FALSE );
+ formWindow()->clearSelection( false );
layout->doLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
MetaDataBase::setSpacing( WidgetFactory::containerOfWidget( lb ), spacing );
@@ -1190,7 +1190,7 @@ void AddFunctionCommand::execute()
formWindow()->mainWindow()->part()->emitAddedFunction(formWindow()->fileName(), f);
if ( formWindow()->formFile() )
- formWindow()->formFile()->setModified( TRUE );
+ formWindow()->formFile()->setModified( true );
}
void AddFunctionCommand::unexecute()
@@ -1208,7 +1208,7 @@ void AddFunctionCommand::unexecute()
formWindow()->mainWindow()->part()->emitRemovedFunction(formWindow()->fileName(), f);
if ( formWindow()->formFile() )
- formWindow()->formFile()->setModified( TRUE );
+ formWindow()->formFile()->setModified( true );
}
// ------------------------------------------------------------
@@ -1252,7 +1252,7 @@ void ChangeFunctionAttribCommand::execute()
formWindow()->mainWindow()->part()->emitEditedFunction(formWindow()->fileName(), of, f);
if ( formWindow()->formFile() )
- formWindow()->formFile()->setModified( TRUE );
+ formWindow()->formFile()->setModified( true );
}
void ChangeFunctionAttribCommand::unexecute()
@@ -1279,7 +1279,7 @@ void ChangeFunctionAttribCommand::unexecute()
formWindow()->mainWindow()->part()->emitEditedFunction(formWindow()->fileName(), f, of);
if ( formWindow()->formFile() )
- formWindow()->formFile()->setModified( TRUE );
+ formWindow()->formFile()->setModified( true );
}
// ------------------------------------------------------------
@@ -1321,7 +1321,7 @@ void RemoveFunctionCommand::execute()
formWindow()->mainWindow()->part()->emitRemovedFunction(formWindow()->fileName(), f);
if ( formWindow()->formFile() )
- formWindow()->formFile()->setModified( TRUE );
+ formWindow()->formFile()->setModified( true );
}
void RemoveFunctionCommand::unexecute()
@@ -1342,7 +1342,7 @@ void RemoveFunctionCommand::unexecute()
formWindow()->mainWindow()->part()->emitAddedFunction(formWindow()->fileName(), f);
if ( formWindow()->formFile() )
- formWindow()->formFile()->setModified( TRUE );
+ formWindow()->formFile()->setModified( true );
}
// ------------------------------------------------------------
@@ -1357,7 +1357,7 @@ void AddVariableCommand::execute()
MetaDataBase::addVariable( formWindow(), varName, access );
formWindow()->mainWindow()->objectHierarchy()->updateFormDefinitionView();
if ( formWindow()->formFile() )
- formWindow()->formFile()->setModified( TRUE );
+ formWindow()->formFile()->setModified( true );
}
void AddVariableCommand::unexecute()
@@ -1365,7 +1365,7 @@ void AddVariableCommand::unexecute()
MetaDataBase::removeVariable( formWindow(), varName );
formWindow()->mainWindow()->objectHierarchy()->updateFormDefinitionView();
if ( formWindow()->formFile() )
- formWindow()->formFile()->setModified( TRUE );
+ formWindow()->formFile()->setModified( true );
}
// ------------------------------------------------------------
@@ -1382,7 +1382,7 @@ void SetVariablesCommand::execute()
MetaDataBase::setVariables( formWindow(), newList );
formWindow()->mainWindow()->objectHierarchy()->updateFormDefinitionView();
if ( formWindow()->formFile() )
- formWindow()->formFile()->setModified( TRUE );
+ formWindow()->formFile()->setModified( true );
}
void SetVariablesCommand::unexecute()
@@ -1390,7 +1390,7 @@ void SetVariablesCommand::unexecute()
MetaDataBase::setVariables( formWindow(), oldList );
formWindow()->mainWindow()->objectHierarchy()->updateFormDefinitionView();
if ( formWindow()->formFile() )
- formWindow()->formFile()->setModified( TRUE );
+ formWindow()->formFile()->setModified( true );
}
// ------------------------------------------------------------
@@ -1412,7 +1412,7 @@ void RemoveVariableCommand::execute()
MetaDataBase::removeVariable( formWindow(), varName );
formWindow()->mainWindow()->objectHierarchy()->updateFormDefinitionView();
if ( formWindow()->formFile() )
- formWindow()->formFile()->setModified( TRUE );
+ formWindow()->formFile()->setModified( true );
}
void RemoveVariableCommand::unexecute()
@@ -1420,7 +1420,7 @@ void RemoveVariableCommand::unexecute()
MetaDataBase::addVariable( formWindow(), varName, access );
formWindow()->mainWindow()->objectHierarchy()->updateFormDefinitionView();
if ( formWindow()->formFile() )
- formWindow()->formFile()->setModified( TRUE );
+ formWindow()->formFile()->setModified( true );
}
// ------------------------------------------------------------
@@ -1438,7 +1438,7 @@ void EditDefinitionsCommand::execute()
lIface->release();
formWindow()->mainWindow()->objectHierarchy()->updateFormDefinitionView();
if ( formWindow()->formFile() )
- formWindow()->formFile()->setModified( TRUE );
+ formWindow()->formFile()->setModified( true );
}
void EditDefinitionsCommand::unexecute()
@@ -1447,7 +1447,7 @@ void EditDefinitionsCommand::unexecute()
lIface->release();
formWindow()->mainWindow()->objectHierarchy()->updateFormDefinitionView();
if ( formWindow()->formFile() )
- formWindow()->formFile()->setModified( TRUE );
+ formWindow()->formFile()->setModified( true );
}
// ------------------------------------------------------------
@@ -1520,7 +1520,7 @@ void PasteCommand::unexecute()
{
for ( TQWidget *w = widgets.first(); w; w = widgets.next() ) {
w->hide();
- formWindow()->selectWidget( w, FALSE );
+ formWindow()->selectWidget( w, false );
formWindow()->widgets()->remove( w );
formWindow()->mainWindow()->objectHierarchy()->widgetRemoved( w );
}
@@ -1542,7 +1542,7 @@ void TabOrderCommand::merge( Command *c )
bool TabOrderCommand::canMerge( Command * )
{
- return TRUE;
+ return true;
}
void TabOrderCommand::execute()
@@ -1704,7 +1704,7 @@ void PopulateListViewCommand::transferItems( TQListView *from, TQListView *to )
toLasts.pop();
toLasts.push( ni );
if ( pi )
- pi->setOpen( TRUE );
+ pi->setOpen( true );
} else {
if ( i->parent() == fromLast ) {
fromParents.push( fromLast );
@@ -1724,7 +1724,7 @@ void PopulateListViewCommand::transferItems( TQListView *from, TQListView *to )
toLasts.pop();
toLasts.push( ni );
if ( pi )
- pi->setOpen( TRUE );
+ pi->setOpen( true );
} else {
while ( fromParents.top() != i->parent() ) {
fromParents.pop();
@@ -1744,7 +1744,7 @@ void PopulateListViewCommand::transferItems( TQListView *from, TQListView *to )
ni->setPixmap( c, *i->pixmap( c ) );
}
if ( pi )
- pi->setOpen( TRUE );
+ pi->setOpen( true );
toLasts.pop();
toLasts.push( ni );
}
@@ -1768,7 +1768,7 @@ PopulateMultiLineEditCommand::PopulateMultiLineEditCommand( const TQString &n, F
void PopulateMultiLineEditCommand::execute()
{
mlined->setText( newText );
- MetaDataBase::setPropertyChanged( mlined, "text", TRUE );
+ MetaDataBase::setPropertyChanged( mlined, "text", true );
formWindow()->emitUpdateProperties( mlined );
}
@@ -1955,7 +1955,7 @@ void AddToolBarCommand::execute()
if ( !toolBar ) {
toolBar = new QDesignerToolBar( mainWindow );
TQString n = "Toolbar";
- formWindow()->unify( toolBar, n, TRUE );
+ formWindow()->unify( toolBar, n, true );
toolBar->setName( n );
mainWindow->addToolBar( toolBar, n );
} else {
@@ -2233,7 +2233,7 @@ void SetActionIconsCommand::execute()
ActionEditor *ae = actionEditor();
if ( ae )
ae->updateActionIcon( action );
- MetaDataBase::setPropertyChanged( action, "iconSet", TRUE );
+ MetaDataBase::setPropertyChanged( action, "iconSet", true );
}
void SetActionIconsCommand::unexecute()
@@ -2242,7 +2242,7 @@ void SetActionIconsCommand::unexecute()
ActionEditor *ae = actionEditor();
if ( ae )
ae->updateActionIcon( action );
- MetaDataBase::setPropertyChanged( action, "iconSet", TRUE );
+ MetaDataBase::setPropertyChanged( action, "iconSet", true );
}
// ------------------------------------------------------------
@@ -2272,19 +2272,19 @@ void AddMenuCommand::execute()
if ( !mb ) {
mb = new MenuBarEditor( formWindow(), mw );
mb->setName( "MenuBarEditor" );
- formWindow()->insertWidget( mb, TRUE );
+ formWindow()->insertWidget( mb, true );
}
if ( !item ) {
PopupMenuEditor *popup = new PopupMenuEditor( formWindow(), mw );
popup->setName( "PopupMenuEditor" );
- formWindow()->insertWidget( popup, TRUE );
+ formWindow()->insertWidget( popup, true );
mb->insertItem( name, popup, index );
index = mb->findItem( popup );
item = mb->item( index );
} else {
PopupMenuEditor *popup = item->menu();
popup->setName( item->menuText() );
- formWindow()->insertWidget( popup, TRUE );
+ formWindow()->insertWidget( popup, true );
mb->insertItem( item, index );
}
formWindow()->mainWindow()->objectHierarchy()->rebuild();
@@ -2407,7 +2407,7 @@ void RenameMenuCommand::execute()
PopupMenuEditor *popup = item->menu();
item->setMenuText( newName );
TQString legal = makeLegal( newName );
- formWindow()->unify( popup, legal, TRUE );
+ formWindow()->unify( popup, legal, true );
popup->setName( legal );
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}