diff options
author | Michele Calgaro <michele.calgaro@yahoo.it> | 2023-07-12 11:39:51 +0900 |
---|---|---|
committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2023-07-13 20:55:05 +0900 |
commit | 14334c54280493270f175de52c28170cf14f50a3 (patch) | |
tree | 776cb15e2cb1c8171dd8bc56a204eb3b57653056 /kdevdesigner/shared/ui2uib.cpp | |
parent | d45e5727ef2f1eb5abeb42b6e97cf0911703b001 (diff) | |
download | tdevelop-14334c54280493270f175de52c28170cf14f50a3.tar.gz tdevelop-14334c54280493270f175de52c28170cf14f50a3.zip |
Replace _OBJECT_NAME_STRING defines with actual strings. This relates to the merging of tqtinterface with tqt3.
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
(cherry picked from commit b8cc513c5e875739c6790da651f6a3f47ed8f657)
Diffstat (limited to 'kdevdesigner/shared/ui2uib.cpp')
-rw-r--r-- | kdevdesigner/shared/ui2uib.cpp | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/kdevdesigner/shared/ui2uib.cpp b/kdevdesigner/shared/ui2uib.cpp index 5cff46e0..e2b8665f 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"; } } @@ -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(); } } |