summaryrefslogtreecommitdiffstats
path: root/kdevdesigner/shared
diff options
context:
space:
mode:
Diffstat (limited to 'kdevdesigner/shared')
-rw-r--r--kdevdesigner/shared/domtool.cpp10
-rw-r--r--kdevdesigner/shared/ui2uib.cpp30
-rw-r--r--kdevdesigner/shared/widgetdatabase.cpp190
-rw-r--r--kdevdesigner/shared/widgetdatabase.h2
4 files changed, 116 insertions, 116 deletions
diff --git a/kdevdesigner/shared/domtool.cpp b/kdevdesigner/shared/domtool.cpp
index ec79ffad..828d9d70 100644
--- a/kdevdesigner/shared/domtool.cpp
+++ b/kdevdesigner/shared/domtool.cpp
@@ -86,10 +86,10 @@ bool DomTool::hasProperty( const TQDomElement& e, const TQString& name )
if ( n.tagName() == "property" ) {
if ( n.attribute( "name" ) != name )
continue;
- return TRUE;
+ return true;
}
}
- return FALSE;
+ return false;
}
TQStringList DomTool::propertiesOfType( const TQDomElement& e, const TQString& type )
@@ -186,7 +186,7 @@ TQVariant DomTool::elementToVariant( const TQDomElement& e, const TQVariant& def
} else if ( e.tagName() == "cstring" ) {
v = TQVariant( TQCString( e.firstChild().toText().data().ascii() ) );
} else if ( e.tagName() == "number" ) {
- bool ok = TRUE;
+ bool ok = true;
v = TQVariant( e.firstChild().toText().data().toInt( &ok ) );
if ( !ok )
v = TQVariant( e.firstChild().toText().data().toDouble() );
@@ -340,10 +340,10 @@ bool DomTool::hasAttribute( const TQDomElement& e, const TQString& name )
if ( n.tagName() == "attribute" ) {
if ( n.attribute( "name" ) != name )
continue;
- return TRUE;
+ return true;
}
}
- return FALSE;
+ return false;
}
static bool toBool( const TQString& s )
diff --git a/kdevdesigner/shared/ui2uib.cpp b/kdevdesigner/shared/ui2uib.cpp
index 5cff46e0..94a6bcb4 100644
--- a/kdevdesigner/shared/ui2uib.cpp
+++ b/kdevdesigner/shared/ui2uib.cpp
@@ -137,13 +137,13 @@
static TQCString layoutForTag( const TQString& tag )
{
if ( tag == "grid" ) {
- return TQGRIDLAYOUT_OBJECT_NAME_STRING;
+ return "TQGridLayout";
} else if ( tag == "hbox" ) {
- return TQHBOXLAYOUT_OBJECT_NAME_STRING;
+ return "TQHBoxLayout";
} else if ( tag == "vbox" ) {
- return TQVBOXLAYOUT_OBJECT_NAME_STRING;
+ return "TQVBoxLayout";
} else {
- return TQLAYOUT_OBJECT_NAME_STRING;
+ return "TQLayout";
}
}
@@ -176,7 +176,7 @@ private:
void UibIndexMap::setName( int no, const TQString& name )
{
if ( !name.isEmpty() ) {
- if ( *nameMap.insert(name, no, FALSE) != no )
+ if ( *nameMap.insert(name, no, false) != no )
conflicts.insert( name, 0 );
}
}
@@ -490,9 +490,9 @@ static int outputObject( TQMap<int, TQStringList>& buddies,
{
bool isTQObject = !className.isEmpty();
- if ( className == TQTOOLBAR_OBJECT_NAME_STRING )
+ if ( className == "TQToolBar" )
out << (TQ_UINT8) elem.attribute( "dock", "0" ).toInt();
- if ( className == TQWIDGET_OBJECT_NAME_STRING )
+ if ( className == "TQWidget" )
className = elem.attribute( "class", className ).latin1();
int objectNo = -1;
@@ -504,7 +504,7 @@ static int outputObject( TQMap<int, TQStringList>& buddies,
outputGridCell( out, elem );
// optimization: insert '&Foo' into string-table before 'Foo'
- if ( className == TQACTION_OBJECT_NAME_STRING || className == TQACTIONGROUP_OBJECT_NAME_STRING ) {
+ if ( className == "TQAction" || className == "TQActionGroup" ) {
TQVariant value = DomTool::readProperty( elem, "menuText", TQVariant() );
if ( value.asString().startsWith("&") )
strings.insertString( value.asString() );
@@ -523,11 +523,11 @@ static int outputObject( TQMap<int, TQStringList>& buddies,
}
} else {
out << (TQ_UINT8) Object_SubAction;
- outputObject( buddies, objects, strings, out, f, TQACTION_OBJECT_NAME_STRING );
+ outputObject( buddies, objects, strings, out, f, "TQAction" );
}
} else if ( tag == "actiongroup" ) {
out << (TQ_UINT8) Object_SubAction;
- outputObject( buddies, objects, strings, out, f, TQACTIONGROUP_OBJECT_NAME_STRING );
+ outputObject( buddies, objects, strings, out, f, "TQActionGroup" );
} else if ( tag == "attribute" ) {
out << (TQ_UINT8) Object_Attribute;
outputProperty( buddies, objectNo, strings, out, f );
@@ -564,13 +564,13 @@ static int outputObject( TQMap<int, TQStringList>& buddies,
out << (TQ_UINT8) Object_Spacer;
outputObject( buddies, objects, strings, out, f );
} else if ( tag == "widget" ) {
- if ( f.attribute("class") == TQLAYOUTWIDGET_OBJECT_NAME_STRING &&
+ if ( f.attribute("class") == "TQLayoutWidget" &&
elem.tagName() != "widget" ) {
outputLayoutWidgetsSubLayout( buddies, objects, strings, out,
f );
} else {
out << (TQ_UINT8) Object_SubWidget;
- outputObject( buddies, objects, strings, out, f, TQWIDGET_OBJECT_NAME_STRING );
+ outputObject( buddies, objects, strings, out, f, "TQWidget" );
}
}
f = f.nextSibling().toElement();
@@ -747,7 +747,7 @@ void convertUiToUib( TQDomDocument& doc, TQDataStream& out )
{
TQDataStream out2( widgetBlock, IO_WriteOnly );
widgetNo = outputObject( buddies, objects, strings, out2, widgetElem,
- TQWIDGET_OBJECT_NAME_STRING );
+ "TQWidget" );
}
if ( !tabstopsElem.isNull() ) {
@@ -772,7 +772,7 @@ void convertUiToUib( TQDomDocument& doc, TQDataStream& out )
if ( !menubarElem.isNull() ) {
TQDataStream out2( menubarBlock, IO_WriteOnly );
outputObject( buddies, objects, strings, out2, menubarElem,
- TQMENUBAR_OBJECT_NAME_STRING );
+ "TQMenuBar" );
}
if ( !toolbarsElem.isNull() ) {
@@ -780,7 +780,7 @@ void convertUiToUib( TQDomDocument& doc, TQDataStream& out )
TQDomElement f = toolbarsElem.firstChild().toElement();
while ( !f.isNull() ) {
if ( f.tagName() == "toolbar" )
- outputObject( buddies, objects, strings, out2, f, TQTOOLBAR_OBJECT_NAME_STRING );
+ outputObject( buddies, objects, strings, out2, f, "TQToolBar" );
f = f.nextSibling().toElement();
}
}
diff --git a/kdevdesigner/shared/widgetdatabase.cpp b/kdevdesigner/shared/widgetdatabase.cpp
index be4b6091..8541b21e 100644
--- a/kdevdesigner/shared/widgetdatabase.cpp
+++ b/kdevdesigner/shared/widgetdatabase.cpp
@@ -55,21 +55,21 @@ static int dbcount = 0;
static int dbcustomcount = 200;
static TQStrList *wGroups;
static TQStrList *invisibleGroups;
-static bool whatsThisLoaded = FALSE;
+static bool whatsThisLoaded = false;
static TQPluginManager<WidgetInterface> *widgetPluginManager = 0;
-static bool plugins_set_up = FALSE;
-static bool was_in_setup = FALSE;
+static bool plugins_set_up = false;
+static bool was_in_setup = false;
TQCleanupHandler<TQPluginManager<WidgetInterface> > cleanup_manager;
WidgetDatabaseRecord::WidgetDatabaseRecord()
{
- isForm = FALSE;
- isContainer = FALSE;
+ isForm = false;
+ isContainer = false;
icon = 0;
nameCounter = 0;
- isCommon = FALSE;
- isPlugin = FALSE;
+ isCommon = false;
+ isPlugin = false;
}
WidgetDatabaseRecord::~WidgetDatabaseRecord()
@@ -108,7 +108,7 @@ WidgetDatabase::WidgetDatabase()
void WidgetDatabase::setupDataBase( int id )
{
- was_in_setup = TRUE;
+ was_in_setup = true;
#ifndef UIC
Q_UNUSED( id )
if ( dbcount )
@@ -129,22 +129,22 @@ void WidgetDatabase::setupDataBase( int id )
invisibleGroups->append( "Forms" );
invisibleGroups->append( "Temp" );
className2Id = new TQDict<int>( dbdictsize );
- className2Id->setAutoDelete( TRUE );
+ className2Id->setAutoDelete( true );
WidgetDatabaseRecord *r = 0;
r = new WidgetDatabaseRecord;
r->iconSet = "designer_pushbutton.png";
- r->name = TQPUSHBUTTON_OBJECT_NAME_STRING;
+ r->name = "TQPushButton";
r->group = widgetGroup( "Buttons" );
r->toolTip = "Push Button";
- r->isCommon = TRUE;
+ r->isCommon = true;
append( r );
r = new WidgetDatabaseRecord;
r->iconSet = "designer_toolbutton.png";
- r->name = TQTOOLBUTTON_OBJECT_NAME_STRING;
+ r->name = "TQToolButton";
r->group = widgetGroup( "Buttons" );
r->toolTip = "Tool Button";
@@ -152,89 +152,89 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "designer_radiobutton.png";
- r->name = TQRADIOBUTTON_OBJECT_NAME_STRING;
+ r->name = "TQRadioButton";
r->group = widgetGroup( "Buttons" );
r->toolTip = "Radio Button";
- r->isCommon = TRUE;
+ r->isCommon = true;
append( r );
r = new WidgetDatabaseRecord;
r->iconSet = "designer_checkbox.png";
- r->name = TQCHECKBOX_OBJECT_NAME_STRING;
+ r->name = "TQCheckBox";
r->group = widgetGroup( "Buttons" );
r->toolTip = "Check Box";
- r->isCommon = TRUE;
+ r->isCommon = true;
append( r );
r = new WidgetDatabaseRecord;
r->iconSet = "designer_groupbox.png";
- r->name = TQGROUPBOX_OBJECT_NAME_STRING;
+ r->name = "TQGroupBox";
r->group = widgetGroup( "Containers" );
r->toolTip = "Group Box";
- r->isContainer = TRUE;
+ r->isContainer = true;
append( r );
r = new WidgetDatabaseRecord;
r->iconSet = "designer_buttongroup.png";
- r->name = TQBUTTONGROUP_OBJECT_NAME_STRING;
+ r->name = "TQButtonGroup";
r->group = widgetGroup( "Containers" );
r->toolTip = "Button Group";
- r->isContainer = TRUE;
- r->isCommon = TRUE;
+ r->isContainer = true;
+ r->isCommon = true;
append( r );
r = new WidgetDatabaseRecord;
r->iconSet = "designer_frame.png";
- r->name = TQFRAME_OBJECT_NAME_STRING;
+ r->name = "TQFrame";
r->group = widgetGroup( "Containers" );
r->toolTip = "Frame";
- r->isContainer = TRUE;
+ r->isContainer = true;
append( r );
r = new WidgetDatabaseRecord;
r->iconSet = "designer_tabwidget.png";
- r->name = TQTABWIDGET_OBJECT_NAME_STRING;
+ r->name = "TQTabWidget";
r->group = widgetGroup( "Containers" );
r->toolTip = "Tabwidget";
- r->isContainer = TRUE;
+ r->isContainer = true;
append( r );
r = new WidgetDatabaseRecord;
r->iconSet = "designer_widgetstack.png";
- r->name = TQWIDGETSTACK_OBJECT_NAME_STRING;
+ r->name = "TQWidgetStack";
r->group = widgetGroup( "Containers" );
r->toolTip = "Widget Stack";
- r->isContainer = TRUE;
+ r->isContainer = true;
append( r );
r = new WidgetDatabaseRecord;
r->iconSet = "designer_toolbox.png";
- r->name = TQTOOLBOX_OBJECT_NAME_STRING;
+ r->name = "TQToolBox";
r->group = widgetGroup( "Containers" );
r->toolTip = "Tool Box";
- r->isContainer = TRUE;
+ r->isContainer = true;
append( r );
r = new WidgetDatabaseRecord;
r->iconSet = "designer_listbox.png";
- r->name = TQLISTBOX_OBJECT_NAME_STRING;
+ r->name = "TQListBox";
r->group = widgetGroup( "Views" );
r->toolTip = "List Box";
- r->isCommon = TRUE;
+ r->isCommon = true;
append( r );
r = new WidgetDatabaseRecord;
r->iconSet = "designer_listview.png";
- r->name = TQLISTVIEW_OBJECT_NAME_STRING;
+ r->name = "TQListView";
r->group = widgetGroup( "Views" );
r->toolTip = "List View";
@@ -243,7 +243,7 @@ void WidgetDatabase::setupDataBase( int id )
#if !defined(TQT_NO_ICONVIEW) || defined(UIC)
r = new WidgetDatabaseRecord;
r->iconSet = "designer_iconview.png";
- r->name = TQICONVIEW_OBJECT_NAME_STRING;
+ r->name = "TQIconView";
r->group = widgetGroup( "Views" );
r->toolTip = "Icon View";
@@ -253,7 +253,7 @@ void WidgetDatabase::setupDataBase( int id )
#if !defined(TQT_NO_TABLE)
r = new WidgetDatabaseRecord;
r->iconSet = "designer_table.png";
- r->name = TQTABLE_OBJECT_NAME_STRING;
+ r->name = "TQTable";
r->group = widgetGroup( "Views" );
r->toolTip = "Table";
@@ -264,7 +264,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "designer_datatable.png";
r->includeFile = "tqdatatable.h";
- r->name = TQDATATABLE_OBJECT_NAME_STRING;
+ r->name = "TQDataTable";
r->group = widgetGroup( "Database" );
r->toolTip = "Data Table";
@@ -273,25 +273,25 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "designer_lineedit.png";
- r->name = TQLINEEDIT_OBJECT_NAME_STRING;
+ r->name = "TQLineEdit";
r->group = widgetGroup( "Input" );
r->toolTip = "Line Edit";
- r->isCommon = TRUE;
+ r->isCommon = true;
append( r );
r = new WidgetDatabaseRecord;
r->iconSet = "designer_spinbox.png";
- r->name = TQSPINBOX_OBJECT_NAME_STRING;
+ r->name = "TQSpinBox";
r->group = widgetGroup( "Input" );
r->toolTip = "Spin Box";
- r->isCommon = TRUE;
+ r->isCommon = true;
append( r );
r = new WidgetDatabaseRecord;
r->iconSet = "designer_dateedit.png";
- r->name = TQDATEEDIT_OBJECT_NAME_STRING;
+ r->name = "TQDateEdit";
r->group = widgetGroup( "Input" );
r->toolTip = "Date Edit";
r->includeFile = "tqdatetimeedit.h";
@@ -300,7 +300,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "designer_timeedit.png";
- r->name = TQTIMEEDIT_OBJECT_NAME_STRING;
+ r->name = "TQTimeEdit";
r->group = widgetGroup( "Input" );
r->toolTip = "Time Edit";
r->includeFile = "tqdatetimeedit.h";
@@ -309,7 +309,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "designer_datetimeedit.png";
- r->name = TQDATETIMEEDIT_OBJECT_NAME_STRING;
+ r->name = "TQDateTimeEdit";
r->group = widgetGroup( "Input" );
r->toolTip = "Date-Time Edit";
r->includeFile = "tqdatetimeedit.h";
@@ -318,7 +318,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "designer_multilineedit.png";
- r->name = TQMULTILINEEDIT_OBJECT_NAME_STRING;
+ r->name = "TQMultiLineEdit";
r->group = widgetGroup( "Temp" );
r->toolTip = "Multi Line Edit";
@@ -326,25 +326,25 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "designer_richtextedit.png";
- r->name = TQTEXTEDIT_OBJECT_NAME_STRING;
+ r->name = "TQTextEdit";
r->group = widgetGroup( "Input" );
r->toolTip = "Rich Text Edit";
- r->isCommon = TRUE;
+ r->isCommon = true;
append( r );
r = new WidgetDatabaseRecord;
r->iconSet = "designer_combobox.png";
- r->name = TQCOMBOBOX_OBJECT_NAME_STRING;
+ r->name = "TQComboBox";
r->group = widgetGroup( "Input" );
r->toolTip = "Combo Box";
- r->isCommon = TRUE;
+ r->isCommon = true;
append( r );
r = new WidgetDatabaseRecord;
r->iconSet = "designer_slider.png";
- r->name = TQSLIDER_OBJECT_NAME_STRING;
+ r->name = "TQSlider";
r->group = widgetGroup( "Input" );
r->toolTip = "Slider";
@@ -352,7 +352,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "designer_scrollbar.png";
- r->name = TQSCROLLBAR_OBJECT_NAME_STRING;
+ r->name = "TQScrollBar";
r->group = widgetGroup( "Input" );
r->toolTip = "Scrollbar";
@@ -360,7 +360,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "designer_dial.png";
- r->name = TQDIAL_OBJECT_NAME_STRING;
+ r->name = "TQDial";
r->group = widgetGroup( "Input" );
r->toolTip = "Dial";
@@ -368,7 +368,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "designer_label.png";
- r->name = TQLABEL_OBJECT_NAME_STRING;
+ r->name = "TQLabel";
r->group = widgetGroup( "Temp" );
r->toolTip = "Label";
@@ -380,7 +380,7 @@ void WidgetDatabase::setupDataBase( int id )
r->group = widgetGroup( "Display" );
r->toolTip = "Text Label";
r->whatsThis = "The Text Label provides a widget to display static text.";
- r->isCommon = TRUE;
+ r->isCommon = true;
append( r );
@@ -395,7 +395,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "designer_lcdnumber.png";
- r->name = TQLCDNUMBER_OBJECT_NAME_STRING;
+ r->name = "TQLCDNumber";
r->group = widgetGroup( "Display" );
r->toolTip = "LCD Number";
@@ -413,7 +413,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "designer_progress.png";
- r->name = TQPROGRESSBAR_OBJECT_NAME_STRING;
+ r->name = "TQProgressBar";
r->group = widgetGroup( "Display" );
r->toolTip = "Progress Bar";
@@ -421,7 +421,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "designer_textview.png";
- r->name = TQTEXTVIEW_OBJECT_NAME_STRING;
+ r->name = "TQTextView";
r->group = widgetGroup( "Temp" );
r->toolTip = "Text View";
@@ -429,7 +429,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconSet = "designer_textbrowser.png";
- r->name = TQTEXTBROWSER_OBJECT_NAME_STRING;
+ r->name = "TQTextBrowser";
r->group = widgetGroup( "Display" );
r->toolTip = "Text Browser";
@@ -445,46 +445,46 @@ void WidgetDatabase::setupDataBase( int id )
append( r );
r = new WidgetDatabaseRecord;
- r->name = TQWIDGET_OBJECT_NAME_STRING;
- r->isForm = TRUE;
+ r->name = "TQWidget";
+ r->isForm = true;
r->group = widgetGroup( "Forms" );
append( r );
r = new WidgetDatabaseRecord;
- r->name = TQDIALOG_OBJECT_NAME_STRING;
+ r->name = "TQDialog";
r->group = widgetGroup( "Forms" );
- r->isForm = TRUE;
+ r->isForm = true;
append( r );
r = new WidgetDatabaseRecord;
- r->name = TQWIZARD_OBJECT_NAME_STRING;
+ r->name = "TQWizard";
r->group = widgetGroup( "Forms" );
- r->isContainer = TRUE;
+ r->isContainer = true;
append( r );
r = new WidgetDatabaseRecord;
r->name = "TQDesignerWizard";
r->group = widgetGroup( "Forms" );
- r->isContainer = TRUE;
+ r->isContainer = true;
append( r );
r = new WidgetDatabaseRecord;
- r->name = TQLAYOUTWIDGET_OBJECT_NAME_STRING;
+ r->name = "TQLayoutWidget";
r->group = widgetGroup( "Temp" );
r->includeFile = "";
- r->isContainer = TRUE;
+ r->isContainer = true;
append( r );
r = new WidgetDatabaseRecord;
- r->name = TQSPLITTER_OBJECT_NAME_STRING;
+ r->name = "TQSplitter";
r->group = widgetGroup( "Temp" );
r->includeFile = "tqsplitter.h";
- r->isContainer = TRUE;
+ r->isContainer = true;
append( r );
@@ -492,7 +492,7 @@ void WidgetDatabase::setupDataBase( int id )
r->iconSet = "designer_tabwidget.png";
r->name = "TQDesignerTabWidget";
r->group = widgetGroup( "Temp" );
- r->isContainer = TRUE;
+ r->isContainer = true;
append( r );
@@ -500,7 +500,7 @@ void WidgetDatabase::setupDataBase( int id )
r->iconSet = "designer_tabwidget.png";
r->name = "TQDesignerWidget";
r->group = widgetGroup( "Temp" );
- r->isContainer = TRUE;
+ r->isContainer = true;
append( r );
@@ -508,16 +508,16 @@ void WidgetDatabase::setupDataBase( int id )
r->iconSet = "designer_tabwidget.png";
r->name = "TQDesignerDialog";
r->group = widgetGroup( "Temp" );
- r->isContainer = TRUE;
+ r->isContainer = true;
append( r );
r = new WidgetDatabaseRecord;
r->iconSet = "";
- r->name = TQMAINWINDOW_OBJECT_NAME_STRING;
+ r->name = "TQMainWindow";
r->includeFile = "tqmainwindow.h";
r->group = widgetGroup( "Temp" );
- r->isContainer = TRUE;
+ r->isContainer = true;
append( r );
@@ -526,7 +526,7 @@ void WidgetDatabase::setupDataBase( int id )
r->name = "TQDesignerAction";
r->includeFile = "tqaction.h";
r->group = widgetGroup( "Temp" );
- r->isContainer = FALSE;
+ r->isContainer = false;
append( r );
@@ -535,39 +535,39 @@ void WidgetDatabase::setupDataBase( int id )
r->name = "TQDesignerActionGroup";
r->includeFile = "tqaction.h";
r->group = widgetGroup( "Temp" );
- r->isContainer = FALSE;
+ r->isContainer = false;
append( r );
r = new WidgetDatabaseRecord;
r->iconSet = "";
- r->name = TQSCROLLVIEW_OBJECT_NAME_STRING;
+ r->name = "TQScrollView";
r->includeFile = "tqscrollview.h";
r->group = widgetGroup( "Temp" );
- r->isContainer = TRUE;
+ r->isContainer = true;
append( r );
#ifndef TQT_NO_SQL
r = new WidgetDatabaseRecord;
r->iconSet = "";
- r->name = TQDATABROWSER_OBJECT_NAME_STRING;
+ r->name = "TQDataBrowser";
r->includeFile = "tqdatabrowser.h";
r->group = widgetGroup( "Database" );
r->toolTip = "Data Browser";
r->iconSet = "designer_databrowser.png";
- r->isContainer = TRUE;
+ r->isContainer = true;
append( r );
r = new WidgetDatabaseRecord;
r->iconSet = "";
- r->name = TQDATAVIEW_OBJECT_NAME_STRING;
+ r->name = "TQDataView";
r->includeFile = "tqdataview.h";
r->group = widgetGroup( "Database" );
r->toolTip = "Data View";
r->iconSet = "designer_dataview.png";
- r->isContainer = TRUE;
+ r->isContainer = true;
append( r );
#endif
@@ -581,7 +581,7 @@ void WidgetDatabase::setupPlugins()
{
if ( plugins_set_up )
return;
- plugins_set_up = TRUE;
+ plugins_set_up = true;
TQStringList widgets = widgetManager()->featureList();
for ( TQStringList::Iterator it = widgets.begin(); it != widgets.end(); ++it ) {
if ( hasWidget( *it ) )
@@ -606,7 +606,7 @@ void WidgetDatabase::setupPlugins()
r->includeFile = iface->includeFile( *it );
r->isContainer = iface->isContainer( *it );
r->name = *it;
- r->isPlugin = TRUE;
+ r->isPlugin = true;
append( r );
iface->release();
}
@@ -731,7 +731,7 @@ bool WidgetDatabase::isForm( int id )
setupDataBase( id );
WidgetDatabaseRecord *r = at( id );
if ( !r )
- return FALSE;
+ return false;
return r->isForm;
}
@@ -743,7 +743,7 @@ bool WidgetDatabase::isContainer( int id )
setupDataBase( id );
WidgetDatabaseRecord *r = at( id );
if ( !r )
- return FALSE;
+ return false;
return r->isContainer || r->isForm;
}
@@ -752,7 +752,7 @@ bool WidgetDatabase::isCommon( int id )
setupDataBase( id );
WidgetDatabaseRecord *r = at( id );
if ( !r )
- return FALSE;
+ return false;
return r->isCommon;
}
@@ -760,7 +760,7 @@ TQString WidgetDatabase::createWidgetName( int id )
{
setupDataBase( id );
TQString n = className( id );
- if ( n == TQLAYOUTWIDGET_OBJECT_NAME_STRING )
+ if ( n == "TQLayoutWidget" )
n = "Layout";
if ( n[ 0 ] == 'Q' && n[ 1 ].lower() != n[ 1 ] )
n = n.mid( 1 );
@@ -787,7 +787,7 @@ int WidgetDatabase::idFromClassName( const TQString &name )
if ( i )
return *i;
if ( name == "FormWindow" )
- return idFromClassName( TQLAYOUTWIDGET_OBJECT_NAME_STRING );
+ return idFromClassName( "TQLayoutWidget" );
#ifdef UIC
setupDataBase( -2 );
i = className2Id->find( name );
@@ -844,9 +844,9 @@ bool WidgetDatabase::isGroupEmpty( const TQString &grp )
if ( !( r = db[ i ] ) )
continue;
if ( r->group == grp )
- return FALSE;
+ return false;
}
- return TRUE;
+ return true;
}
TQString WidgetDatabase::widgetGroup( int i )
@@ -890,8 +890,8 @@ void WidgetDatabase::customWidgetClassNameChanged( const TQString &oldName,
bool WidgetDatabase::isCustomWidget( int id )
{
if ( id >= dbcustom && id < dbcustomcount )
- return TRUE;
- return FALSE;
+ return true;
+ return false;
}
bool WidgetDatabase::isCustomPluginWidget( int id )
@@ -899,7 +899,7 @@ bool WidgetDatabase::isCustomPluginWidget( int id )
setupDataBase( id );
WidgetDatabaseRecord *r = at( id );
if ( !r )
- return FALSE;
+ return false;
return r->isPlugin;
}
@@ -923,13 +923,13 @@ void WidgetDatabase::loadWhatsThis( const TQString &docPath )
if ( r )
r->whatsThis = l[ 0 ];
}
- whatsThisLoaded = TRUE;
+ whatsThisLoaded = true;
}
// ### TQt 3.1: make these publically accessible via TQWidgetDatabase API
#if defined(UIC)
-bool dbnounload = FALSE;
+bool dbnounload = false;
TQStringList *dbpaths = 0;
#else
extern TQString *qwf_plugin_dir;
@@ -948,7 +948,7 @@ TQPluginManager<WidgetInterface> *widgetManager()
cleanup_manager.add( &widgetPluginManager );
#if defined(UIC)
if ( dbnounload )
- widgetPluginManager->setAutoUnload( FALSE );
+ widgetPluginManager->setAutoUnload( false );
if ( dbpaths ) {
TQStringList::ConstIterator it = dbpaths->begin();
for ( ; it != dbpaths->end(); ++it )
diff --git a/kdevdesigner/shared/widgetdatabase.h b/kdevdesigner/shared/widgetdatabase.h
index 5395f2ef..e64e4fae 100644
--- a/kdevdesigner/shared/widgetdatabase.h
+++ b/kdevdesigner/shared/widgetdatabase.h
@@ -30,7 +30,7 @@
#include <tqiconset.h>
#include <tqstring.h>
#include "../interfaces/widgetinterface.h" // up here for GCC 2.7.* compatibility
-#include <tqpluginmanager_p.h>
+#include <private/tqpluginmanager_p.h>
extern TQPluginManager<WidgetInterface> *widgetManager();