From 232dd26c834e430364fcdd3d4962225a892127fe Mon Sep 17 00:00:00 2001 From: Michele Calgaro Date: Wed, 18 Sep 2024 13:33:26 +0900 Subject: Remove temporary code required for the tqinterface migration phase introduced in commit 8ac0e970 Signed-off-by: Michele Calgaro --- tools/designer/shared/widgetdatabase.cpp | 39 ++++---------------------------- 1 file changed, 5 insertions(+), 34 deletions(-) (limited to 'tools/designer') diff --git a/tools/designer/shared/widgetdatabase.cpp b/tools/designer/shared/widgetdatabase.cpp index f3174378..4fd0d79b 100644 --- a/tools/designer/shared/widgetdatabase.cpp +++ b/tools/designer/shared/widgetdatabase.cpp @@ -60,28 +60,6 @@ static TQPluginManager *widgetPluginManager = 0; static bool plugins_set_up = FALSE; static bool was_in_setup = FALSE; -// This is temporary code required till the integration of tqtinterface into tqt3 is completed. -// It will be removed afterwards -static TQString converted_widgets[] = -{ - "TQButton", "TQButtonGroup", - "TQCheckBox", "TQColorDialog", "TQComboBox", - "TQDateTimeEdit", "TQDesktopWidget", "TQDial", "TQDialog", "TQDockArea", "TQDockWindow", - "TQFileDialog", "TQFrame", - "TQGrid", "TQGridView", "TQGroupBox", - "TQHBox", "TQHButtonGroup", "TQHeader", "TQHGroupBox", - "TQIconView", "TQInputDialog", - "TQLabel", "TQLCDNumber", "TQLineEdit", "TQListBox", "TQListView", - "TQMainWindow", "TQMenuBar", "TQMessageBox", "TQMultiLineEdit", - "TQPopupMenu", "TQPrintDialog", "TQProgressBar", "TQProgressDialog", "TQPushButton", - "TQRadioButton", - "TQScrollBar", "TQScrollView", "TQSizeGrip", "TQSlider", "TQSpinBox", "TQStatusBar", - "TQTabBar", "TQTabDialog", "TQTabWidget", "TQTable", "TQTextBrowser", "TQTextEdit", "TQTextView", "TQToolBar", "TQToolBox", "TQToolButton", "TQToolTip", - "TQVBox", "TQVButtonGroup", "TQVGroupBox", - "TQWidget", "TQWidgetStack", "TQWizard", "TQWorkspace" -}; -size_t converted_widgets_size = sizeof(converted_widgets) / sizeof(TQString); - TQCleanupHandler > cleanup_manager; WidgetDatabaseRecord::WidgetDatabaseRecord() @@ -741,18 +719,11 @@ TQString WidgetDatabase::includeFile( int id ) WidgetDatabaseRecord *r = at( id ); if ( !r ) return TQString::null; - if ( r->includeFile.isNull() ) { - TQString rq = r->name; - for (size_t i = 0; i < converted_widgets_size; ++i) - { - if (rq == converted_widgets[i]) - { - return rq.lower() + ".h"; - } - } - if ( rq[ 0 ] == 'T' && rq[ 1 ] == 'Q') - rq = rq.mid(1); - return "nt" + rq.lower() + ".h"; + // Must use 'isNull()' and not 'isEmpty()' here, otherwise the code + // will FTBFS due to the 'TQLayoutWidget' class + if ( r->includeFile.isNull() ) + { + return r->name.lower() + ".h"; } return r->includeFile; } -- cgit v1.2.1