diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2012-07-28 15:51:58 -0500 |
---|---|---|
committer | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2012-07-28 15:51:58 -0500 |
commit | fe7969ef886d7287fa959929ddd33fbad8407884 (patch) | |
tree | 589aacc109d27561a5188bb46bce27c78bad8f5b /tools/designer | |
parent | dba8a853b65e5707e48450e5085e0ff0513b4203 (diff) | |
download | tqt3-fe7969ef886d7287fa959929ddd33fbad8407884.tar.gz tqt3-fe7969ef886d7287fa959929ddd33fbad8407884.zip |
Automated update from Qt3
Diffstat (limited to 'tools/designer')
-rw-r--r-- | tools/designer/designer/command.cpp | 4 | ||||
-rw-r--r-- | tools/designer/designer/formwindow.cpp | 2 | ||||
-rw-r--r-- | tools/designer/designer/layout.cpp | 3 | ||||
-rw-r--r-- | tools/designer/designer/mainwindow.cpp | 14 | ||||
-rw-r--r-- | tools/designer/designer/mainwindowactions.cpp | 8 | ||||
-rw-r--r-- | tools/designer/designer/metadatabase.cpp | 2 | ||||
-rw-r--r-- | tools/designer/designer/project.cpp | 2 | ||||
-rw-r--r-- | tools/designer/designer/propertyeditor.cpp | 12 | ||||
-rw-r--r-- | tools/designer/designer/qcompletionedit.cpp | 4 | ||||
-rw-r--r-- | tools/designer/designer/resource.cpp | 10 | ||||
-rw-r--r-- | tools/designer/designer/widgetfactory.cpp | 12 | ||||
-rw-r--r-- | tools/designer/editor/completion.cpp | 14 | ||||
-rw-r--r-- | tools/designer/editor/parenmatcher.cpp | 12 | ||||
-rw-r--r-- | tools/designer/plugins/wizards/mainwindowwizard.ui.h | 6 | ||||
-rw-r--r-- | tools/designer/plugins/wizards/sqlformwizardimpl.cpp | 4 |
15 files changed, 55 insertions, 54 deletions
diff --git a/tools/designer/designer/command.cpp b/tools/designer/designer/command.cpp index 5271e9ffe..1a39ce846 100644 --- a/tools/designer/designer/command.cpp +++ b/tools/designer/designer/command.cpp @@ -511,8 +511,8 @@ bool SetPropertyCommand::canMerge( Command *c ) return FALSE; } TQVariant::Type t = TQVariant::nameToType( p->type() ); - return ( cmd->propName == propName && - t == TQVariant::String || t == TQVariant::CString || t == TQVariant::Int || t == TQVariant::UInt ); + return ( ( cmd->propName == propName && + t == TQVariant::String ) || t == TQVariant::CString || t == TQVariant::Int || t == TQVariant::UInt ); } void SetPropertyCommand::merge( Command *c ) diff --git a/tools/designer/designer/formwindow.cpp b/tools/designer/designer/formwindow.cpp index 405968be0..f092f8d22 100644 --- a/tools/designer/designer/formwindow.cpp +++ b/tools/designer/designer/formwindow.cpp @@ -1632,7 +1632,7 @@ TQWidget *FormWindow::designerWidget( TQObject *o ) const if ( !o || !o->isWidgetType() ) return 0; TQWidget *w = (TQWidget*)o; - while ( w && !isMainContainer( w ) && !insertedWidgets[ (void*)w ] || isCentralWidget( w ) ) + while ( ( w && !isMainContainer( w ) && !insertedWidgets[ (void*)w ] ) || isCentralWidget( w ) ) w = (TQWidget*)w->parent(); return w; } diff --git a/tools/designer/designer/layout.cpp b/tools/designer/designer/layout.cpp index 49e2c442a..a0f6d1c41 100644 --- a/tools/designer/designer/layout.cpp +++ b/tools/designer/designer/layout.cpp @@ -964,11 +964,12 @@ int Spacer::alignment() const TQSize Spacer::minimumSize() const { TQSize s = TQSize( 20,20 ); - if ( sizeType() == Expanding ) + if ( sizeType() == Expanding ) { if ( orient == Vertical ) s.rheight() = 0; else s.rwidth() = 0; + } return s; } diff --git a/tools/designer/designer/mainwindow.cpp b/tools/designer/designer/mainwindow.cpp index 4ae7c7a55..7603148f6 100644 --- a/tools/designer/designer/mainwindow.cpp +++ b/tools/designer/designer/mainwindow.cpp @@ -989,12 +989,12 @@ bool MainWindow::eventFilter( TQObject *o, TQEvent *e ) ( ::tqt_cast<MenuBarEditor*>(o) || ::tqt_cast<PopupMenuEditor*>(o) || ::tqt_cast<TQDesignerToolBar*>(o) || - ( ::tqt_cast<TQComboBox*>(o) || + ( ( ::tqt_cast<TQComboBox*>(o) || ::tqt_cast<TQToolButton*>(o) || ::tqt_cast<TQDesignerToolBarSeparator*>(o) ) && o->parent() && ( ::tqt_cast<TQDesignerToolBar*>(o->parent()) - || ::tqt_cast<TQDesignerWidgetStack*>(o->parent())) ) ) { + || ::tqt_cast<TQDesignerWidgetStack*>(o->parent())) ) ) ) { TQWidget *w = (TQWidget*)o; if ( ::tqt_cast<TQToolButton*>(w) || ::tqt_cast<TQComboBox*>(w) || @@ -1570,10 +1570,10 @@ void MainWindow::setupRMBProperties( TQValueList<uint> &ids, TQMap<TQString, int if ( pixmap && qstrcmp( pixmap->type(), "TQPixmap") != 0 ) pixmap = 0; - if ( text && text->designable(w) || - title && title->designable(w) || - pagetitle && pagetitle->designable(w) || - pixmap && pixmap->designable(w) ) { + if ( ( text && text->designable(w) ) || + ( title && title->designable(w) ) || + ( pagetitle && pagetitle->designable(w) ) || + ( pixmap && pixmap->designable(w) ) ) { int id = 0; if ( ids.isEmpty() ) ids << rmbWidgets->insertSeparator(0); @@ -3337,7 +3337,7 @@ void MainWindow::showSourceLine( TQObject *o, int line, LineMode lm ) if ( fw->project() != currentProject ) continue; if ( qstrcmp( fw->name(), o->name() ) == 0 || - fw->isFake() && currentProject->objectForFakeForm( fw ) == o ) { + ( fw->isFake() && currentProject->objectForFakeForm( fw ) == o ) ) { if ( se ) { switch ( lm ) { case Error: diff --git a/tools/designer/designer/mainwindowactions.cpp b/tools/designer/designer/mainwindowactions.cpp index 7228e29fc..07d9c3c2f 100644 --- a/tools/designer/designer/mainwindowactions.cpp +++ b/tools/designer/designer/mainwindowactions.cpp @@ -1248,7 +1248,7 @@ void MainWindow::fileOpen( const TQString &filter, const TQString &extension, co setCurrentProject( eProject ); openFormWindow( filename ); addRecentlyOpened( filename, recentlyFiles ); - } else if ( !extension.isEmpty() && extension.find( ";" + fi.extension( FALSE ) ) != -1 || + } else if ( ( !extension.isEmpty() && extension.find( ";" + fi.extension( FALSE ) ) != -1 ) || additionalSources.find( fi.extension( FALSE ) ) != additionalSources.end() ) { SourceFile *sf = project->findSourceFile( project->makeRelative( filename ) ); if ( !sf ) @@ -1687,14 +1687,14 @@ void MainWindow::editBreakLayout() if ( formWindow()->currentWidget() ) w = formWindow()->currentWidget(); if ( WidgetFactory::layoutType( w ) != WidgetFactory::NoLayout || - w->parentWidget() && WidgetFactory::layoutType( w->parentWidget() ) != WidgetFactory::NoLayout ) { + ( w->parentWidget() && WidgetFactory::layoutType( w->parentWidget() ) != WidgetFactory::NoLayout ) ) { formWindow()->breakLayout( w ); return; } else { TQWidgetList widgets = formWindow()->selectedWidgets(); for ( w = widgets.first(); w; w = widgets.next() ) { if ( WidgetFactory::layoutType( w ) != WidgetFactory::NoLayout || - w->parentWidget() && WidgetFactory::layoutType( w->parentWidget() ) != WidgetFactory::NoLayout ) + ( w->parentWidget() && WidgetFactory::layoutType( w->parentWidget() ) != WidgetFactory::NoLayout ) ) break; } if ( w ) { @@ -1705,7 +1705,7 @@ void MainWindow::editBreakLayout() w = formWindow()->mainContainer(); if ( WidgetFactory::layoutType( w ) != WidgetFactory::NoLayout || - w->parentWidget() && WidgetFactory::layoutType( w->parentWidget() ) != WidgetFactory::NoLayout ) + ( w->parentWidget() && WidgetFactory::layoutType( w->parentWidget() ) != WidgetFactory::NoLayout ) ) formWindow()->breakLayout( w ); } diff --git a/tools/designer/designer/metadatabase.cpp b/tools/designer/designer/metadatabase.cpp index 81be8ccf8..0afd4b428 100644 --- a/tools/designer/designer/metadatabase.cpp +++ b/tools/designer/designer/metadatabase.cpp @@ -355,7 +355,7 @@ void MetaDataBase::setMargin( TQObject *o, int margin ) TQWidget *widget = (TQWidget*)o; if ( widget && !::tqt_cast<TQLayoutWidget*>(widget) && ( WidgetDatabase::isContainer( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( widget ) ) ) || - widget && widget->parentWidget() && ::tqt_cast<FormWindow*>(widget->parentWidget()) ) ) + ( widget && widget->parentWidget() && ::tqt_cast<FormWindow*>(widget->parentWidget()) ) ) ) isInnerLayout = FALSE; diff --git a/tools/designer/designer/project.cpp b/tools/designer/designer/project.cpp index 560231bd8..ec322f13e 100644 --- a/tools/designer/designer/project.cpp +++ b/tools/designer/designer/project.cpp @@ -628,7 +628,7 @@ static void remove_multiline_contents( TQString &contents, const TQString &s, in if ( contents[ i ] == '\n' && !lastWasBackspash ) break; lastWasBackspash = ( contents[ i ] == '\\' || - lastWasBackspash && ( contents[ i ] == ' ' || contents[ i ] == '\t' ) ); + ( lastWasBackspash && ( contents[ i ] == ' ' || contents[ i ] == '\t' ) ) ); } contents.remove( start, i - start + 1 ); } diff --git a/tools/designer/designer/propertyeditor.cpp b/tools/designer/designer/propertyeditor.cpp index a4bc629e5..cfb20c47e 100644 --- a/tools/designer/designer/propertyeditor.cpp +++ b/tools/designer/designer/propertyeditor.cpp @@ -553,9 +553,9 @@ TQString PropertyItem::currentItemFromObject() const void PropertyItem::setFocus( TQWidget *w ) { if ( !tqApp->focusWidget() || - listview->propertyEditor()->formWindow() && + ( listview->propertyEditor()->formWindow() && ( !MainWindow::self->isAFormWindowChild( tqApp->focusWidget() ) && - !tqApp->focusWidget()->inherits( "Editor" ) ) ) + !tqApp->focusWidget()->inherits( "Editor" ) ) ) ) w->setFocus(); } @@ -3151,7 +3151,7 @@ void PropertyList::setupProperties() bool isPropertyObject = w->isA( "PropertyObject" ); if ( ( p->designable(w) || - isPropertyObject && p->designable( ( (PropertyObject*)w )->widgetList().first() ) ) && + ( isPropertyObject && p->designable( ( (PropertyObject*)w )->widgetList().first() ) ) ) && ( !isPropertyObject || qstrcmp( p->name(), "name" ) != 0 ) ) { if ( p->isSetType() ) { if ( TQString( p->name() ) == "alignment" ) { @@ -3733,9 +3733,9 @@ void PropertyList::setPropertyValue( PropertyItem *i ) void PropertyList::setCurrentProperty( const TQString &n ) { - if ( currentItem() && currentItem()->text( 0 ) == n || - currentItem() && ( (PropertyItem*)currentItem() )->propertyParent() && - ( (PropertyItem*)currentItem() )->propertyParent()->text( 0 ) == n ) + if ( ( currentItem() && currentItem()->text( 0 ) == n ) || + ( currentItem() && ( (PropertyItem*)currentItem() )->propertyParent() && + ( (PropertyItem*)currentItem() )->propertyParent()->text( 0 ) == n ) ) return; TQListViewItemIterator it( this ); diff --git a/tools/designer/designer/qcompletionedit.cpp b/tools/designer/designer/qcompletionedit.cpp index b403e5715..febde1052 100644 --- a/tools/designer/designer/qcompletionedit.cpp +++ b/tools/designer/designer/qcompletionedit.cpp @@ -115,8 +115,8 @@ void TQCompletionEdit::updateListBox() if ( compList.isEmpty() ) return; for ( TQStringList::Iterator it = compList.begin(); it != compList.end(); ++it ) { - if ( caseSensitive && (*it).left( text().length() ) == text() || - !caseSensitive && (*it).left( text().length() ).lower() == text().lower() ) + if ( ( caseSensitive && (*it).left( text().length() ) == text() ) || + ( !caseSensitive && (*it).left( text().length() ).lower() == text().lower() ) ) listbox->insertItem( *it ); } } diff --git a/tools/designer/designer/resource.cpp b/tools/designer/designer/resource.cpp index 3a689f453..01d5f3410 100644 --- a/tools/designer/designer/resource.cpp +++ b/tools/designer/designer/resource.cpp @@ -1220,8 +1220,8 @@ void Resource::saveItems( TQObject *obj, TQTextStream &ts, int indent ) bool isDataTable = false; # endif for ( i = 0; i < table->horizontalHeader()->count(); ++i ) { - if ( !table->horizontalHeader()->label( i ).isNull() && - table->horizontalHeader()->label( i ).toInt() != i + 1 || + if ( ( !table->horizontalHeader()->label( i ).isNull() && + table->horizontalHeader()->label( i ).toInt() != i + 1 ) || table->horizontalHeader()->iconSet( i ) || isDataTable ) { ts << makeIndent( indent ) << "<column>" << endl; @@ -1245,8 +1245,8 @@ void Resource::saveItems( TQObject *obj, TQTextStream &ts, int indent ) } } for ( i = 0; i < table->verticalHeader()->count(); ++i ) { - if ( !table->verticalHeader()->label( i ).isNull() && - table->verticalHeader()->label( i ).toInt() != i + 1 || + if ( ( !table->verticalHeader()->label( i ).isNull() && + table->verticalHeader()->label( i ).toInt() != i + 1 ) || table->verticalHeader()->iconSet( i ) ) { ts << makeIndent( indent ) << "<row>" << endl; indent++; @@ -1547,7 +1547,7 @@ void Resource::saveProperty( TQObject *w, const TQString &name, const TQVariant uint unum; double dob; TQString comment; - if ( w && formwindow->widgets()->find( (TQWidget*)w ) || formwindow->actionList().find( (TQAction*)w ) ) + if ( ( w && formwindow->widgets()->find( (TQWidget*)w ) ) || formwindow->actionList().find( (TQAction*)w ) ) comment = MetaDataBase::propertyComment( w, name ); switch ( t ) { case TQVariant::String: diff --git a/tools/designer/designer/widgetfactory.cpp b/tools/designer/designer/widgetfactory.cpp index cf8d9a7a0..97f3332e0 100644 --- a/tools/designer/designer/widgetfactory.cpp +++ b/tools/designer/designer/widgetfactory.cpp @@ -568,7 +568,7 @@ TQLayout *WidgetFactory::createLayout( TQWidget *widget, TQLayout *layout, Layou if ( ::tqt_cast<TQLayoutWidget*>(widget) && ( WidgetDatabase::isContainer( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( widget ) ) ) || - widget && ::tqt_cast<FormWindow*>(widget->parentWidget()) ) ) + ( widget && ::tqt_cast<FormWindow*>(widget->parentWidget()) ) ) ) margin = MainWindow::self->currentLayoutDefaultMargin(); if ( !layout && ::tqt_cast<TQTabWidget*>(widget) ) @@ -883,7 +883,7 @@ TQWidget *WidgetFactory::createWidget( const TQString &className, TQWidget *pare MetaDataBase::setPropertyChanged( s, "sizeType", TRUE ); if ( !r ) return s; - if ( !r->isValid() || r->width() < 2 && r->height() < 2 ) + if ( !r->isValid() || ( r->width() < 2 && r->height() < 2 ) ) s->setOrientation( orient ); else if ( r->width() < r->height() ) s->setOrientation( TQt::Vertical ); @@ -904,7 +904,7 @@ TQWidget *WidgetFactory::createWidget( const TQString &className, TQWidget *pare TQSlider *s = new TQSlider( parent, name ); if ( !r ) return s; - if ( !r->isValid() || r->width() < 2 && r->height() < 2 ) + if ( !r->isValid() || ( r->width() < 2 && r->height() < 2 ) ) s->setOrientation( orient ); else if ( r->width() > r->height() ) s->setOrientation( TQt::Horizontal ); @@ -915,7 +915,7 @@ TQWidget *WidgetFactory::createWidget( const TQString &className, TQWidget *pare TQScrollBar *s = new TQScrollBar( parent, name ); if ( !r ) return s; - if ( !r->isValid() || r->width() < 2 && r->height() < 2 ) + if ( !r->isValid() || ( r->width() < 2 && r->height() < 2 ) ) s->setOrientation( orient ); else if ( r->width() > r->height() ) s->setOrientation( TQt::Horizontal ); @@ -936,7 +936,7 @@ TQWidget *WidgetFactory::createWidget( const TQString &className, TQWidget *pare MetaDataBase::setPropertyChanged( l, "frameShape", TRUE ); if ( !r ) return l; - if ( !r->isValid() || r->width() < 2 && r->height() < 2 ) + if ( !r->isValid() || ( r->width() < 2 && r->height() < 2 ) ) l->setOrientation( orient ); else if ( r->width() < r->height() ) l->setOrientation( TQt::Vertical ); @@ -1143,7 +1143,7 @@ TQWidget* WidgetFactory::widgetOfContainer( TQWidget *w ) while ( w ) { int id = WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( w ) ); if ( WidgetDatabase::isContainer( id ) || - w && ::tqt_cast<FormWindow*>(w->parentWidget()) ) + ( w && ::tqt_cast<FormWindow*>(w->parentWidget()) ) ) return w; w = w->parentWidget(); } diff --git a/tools/designer/editor/completion.cpp b/tools/designer/editor/completion.cpp index ecd1e73be..77499c8d2 100644 --- a/tools/designer/editor/completion.cpp +++ b/tools/designer/editor/completion.cpp @@ -363,8 +363,8 @@ bool EditorCompletion::eventFilter( TQObject *o, TQEvent *e ) } } - if ( ke->text().length() && !( ke->state() & AltButton ) && - ( !ke->ascii() || ke->ascii() >= 32 ) || + if ( ( ke->text().length() && !( ke->state() & AltButton ) && + ( !ke->ascii() || ke->ascii() >= 32 ) ) || ( ke->text() == "\t" && !( ke->state() & ControlButton ) ) ) { if ( ke->key() == Key_Tab ) { if ( curEditor->textCursor()->index() == 0 && @@ -372,13 +372,13 @@ bool EditorCompletion::eventFilter( TQObject *o, TQEvent *e ) return FALSE; if ( doCompletion() ) return TRUE; - } else if ( ke->key() == Key_Period && + } else if ( ( ke->key() == Key_Period && ( curEditor->textCursor()->index() == 0 || - curEditor->textCursor()->paragraph()->at( curEditor->textCursor()->index() - 1 )->c != '.' ) + curEditor->textCursor()->paragraph()->at( curEditor->textCursor()->index() - 1 )->c != '.' ) ) || - ke->key() == Key_Greater && + ( ke->key() == Key_Greater && curEditor->textCursor()->index() > 0 && - curEditor->textCursor()->paragraph()->at( curEditor->textCursor()->index() - 1 )->c == '-' ) { + curEditor->textCursor()->paragraph()->at( curEditor->textCursor()->index() - 1 )->c == '-' ) ) { doObjectCompletion(); } else { if ( !doArgumentHint( ke->text() == "(" ) ) @@ -423,7 +423,7 @@ bool EditorCompletion::eventFilter( TQObject *o, TQEvent *e ) return TRUE; } } - if ( o == functionLabel || ::tqt_cast<Editor*>(o) && functionLabel->isVisible() ) { + if ( o == functionLabel || ( ::tqt_cast<Editor*>(o) && functionLabel->isVisible() ) ) { if ( e->type() == TQEvent::KeyPress ) { TQKeyEvent *ke = (TQKeyEvent*)e; if ( ke->key() == Key_Escape ) { diff --git a/tools/designer/editor/parenmatcher.cpp b/tools/designer/editor/parenmatcher.cpp index 8cd6ffcb9..ddc4b8838 100644 --- a/tools/designer/editor/parenmatcher.cpp +++ b/tools/designer/editor/parenmatcher.cpp @@ -120,9 +120,9 @@ bool ParenMatcher::checkOpenParen( TQTextCursor *cursor ) } int id = Match; - if ( c == '{' && closedParen.chr != '}' || - c == '(' && closedParen.chr != ')' || - c == '[' && closedParen.chr != ']' ) + if ( ( c == '{' && closedParen.chr != '}' ) || + ( c == '(' && closedParen.chr != ')' ) || + ( c == '[' && closedParen.chr != ']' ) ) id = Mismatch; cursor->document()->setSelectionStart( id, *cursor ); int tidx = cursor->index(); @@ -194,9 +194,9 @@ bool ParenMatcher::checkClosedParen( TQTextCursor *cursor ) } int id = Match; - if ( c == '}' && openParen.chr != '{' || - c == ')' && openParen.chr != '(' || - c == ']' && openParen.chr != '[' ) + if ( ( c == '}' && openParen.chr != '{' ) || + ( c == ')' && openParen.chr != '(' ) || + ( c == ']' && openParen.chr != '[' ) ) id = Mismatch; cursor->document()->setSelectionStart( id, *cursor ); int tidx = cursor->index(); diff --git a/tools/designer/plugins/wizards/mainwindowwizard.ui.h b/tools/designer/plugins/wizards/mainwindowwizard.ui.h index ce694b94b..888141006 100644 --- a/tools/designer/plugins/wizards/mainwindowwizard.ui.h +++ b/tools/designer/plugins/wizards/mainwindowwizard.ui.h @@ -246,9 +246,9 @@ void MainWindowWizardBase::accept() } } for ( TQAction *ac = usedActions.first(); ac; ac = usedActions.next() ) { - if ( TQString( ac->name() ).find( "file" ) != -1 && checkCreateConnectionsFile->isChecked() || - TQString( ac->name() ).find( "edit" ) != -1 && checkCreateConnectionsEdit->isChecked() || - TQString( ac->name() ).find( "help" ) != -1 && checkCreateConnectionsHelp->isChecked() ) { + if ( ( TQString( ac->name() ).find( "file" ) != -1 && checkCreateConnectionsFile->isChecked() ) || + ( TQString( ac->name() ).find( "edit" ) != -1 && checkCreateConnectionsEdit->isChecked() ) || + ( TQString( ac->name() ).find( "help" ) != -1 && checkCreateConnectionsHelp->isChecked() ) ) { TQString slot = ac->name(); slot.remove( slot.length() - 6, 6 ); slot += "()"; diff --git a/tools/designer/plugins/wizards/sqlformwizardimpl.cpp b/tools/designer/plugins/wizards/sqlformwizardimpl.cpp index a89cb8d38..40c54e04d 100644 --- a/tools/designer/plugins/wizards/sqlformwizardimpl.cpp +++ b/tools/designer/plugins/wizards/sqlformwizardimpl.cpp @@ -120,7 +120,7 @@ void SqlFormWizard::connectionSelected( const TQString &c ) listBoxTable->clear(); TQPtrList<DesignerDatabase> databases = proIface->databaseConnections(); for ( DesignerDatabase *d = databases.first(); d; d = databases.next() ) { - if ( d->name() == c || ( d->name() == "(default)" || d->name().isEmpty() ) && c == "(default)") + if ( d->name() == c || ( ( d->name() == "(default)" || d->name().isEmpty() ) && c == "(default)") ) listBoxTable->insertStringList( d->tables() ); } setNextEnabled( databasePage, ( listBoxTable->currentItem() >= 0 ) ); @@ -356,7 +356,7 @@ void SqlFormWizard::accept() TQPtrList<DesignerDatabase> databases = proIface->databaseConnections(); DesignerDatabase *database = 0; for ( DesignerDatabase *d = databases.first(); d; d = databases.next() ) { - if ( d->name() == listBoxConnection->currentText() || ( d->name() == "(default)" || d->name().isEmpty() ) && listBoxConnection->currentText() == "(default)" ) { + if ( d->name() == listBoxConnection->currentText() || ( ( d->name() == "(default)" || d->name().isEmpty() ) && listBoxConnection->currentText() == "(default)" ) ) { database = d; d->open( FALSE ); break; |