diff options
author | Michele Calgaro <michele.calgaro@yahoo.it> | 2023-07-12 11:09:49 +0900 |
---|---|---|
committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2023-07-13 10:04:24 +0900 |
commit | 707310036113d2d0ae9da1cc7f85d0e642bf9686 (patch) | |
tree | afa9b616af366f63e0418df74b2287299d8572a3 /tdestyles/highcolor/highcolor.cpp | |
parent | 08eacf589a6ee0358c49f177fca34a29e0515164 (diff) | |
download | tdelibs-707310036113d2d0ae9da1cc7f85d0e642bf9686.tar.gz tdelibs-707310036113d2d0ae9da1cc7f85d0e642bf9686.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 36c049e135b0cec7cf97b41888860186813df5f0)
Diffstat (limited to 'tdestyles/highcolor/highcolor.cpp')
-rw-r--r-- | tdestyles/highcolor/highcolor.cpp | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/tdestyles/highcolor/highcolor.cpp b/tdestyles/highcolor/highcolor.cpp index d1666406f..6f06a18e4 100644 --- a/tdestyles/highcolor/highcolor.cpp +++ b/tdestyles/highcolor/highcolor.cpp @@ -190,19 +190,19 @@ HighColorStyle::~HighColorStyle() void HighColorStyle::polish(const TQStyleControlElementData &ceData, ControlElementFlags elementFlags, void *ptr) { - if (ceData.widgetObjectTypes.contains(TQWIDGET_OBJECT_NAME_STRING)) { + if (ceData.widgetObjectTypes.contains("TQWidget")) { TQWidget *widget = reinterpret_cast<TQWidget*>(ptr); // Put in order of highest occurrence to maximise hit rate - if (widget->inherits(TQPUSHBUTTON_OBJECT_NAME_STRING)) { + if (widget->inherits("TQPushButton")) { installObjectEventHandler(ceData, elementFlags, ptr, this); - } else if (widget->inherits(TQMENUBAR_OBJECT_NAME_STRING) || widget->inherits(TQPOPUPMENU_OBJECT_NAME_STRING)) { + } else if (widget->inherits("TQMenuBar") || widget->inherits("TQPopupMenu")) { widget->setBackgroundMode(TQWidget::NoBackground); - } else if (type == HighColor && widget->inherits(TQTOOLBAREXTENSIONWIDGET_OBJECT_NAME_STRING)) { + } else if (type == HighColor && widget->inherits("TQToolBarExtensionWidget")) { installObjectEventHandler(ceData, elementFlags, ptr, this); } else if ( !qstrcmp( widget->name(), kdeToolbarWidget) ) { widget->setBackgroundMode( NoBackground ); // We paint the whole background. installObjectEventHandler(ceData, elementFlags, ptr, this); - } else if (widget->inherits(TQTOOLBOXBUTTON_OBJECT_NAME_STRING)) { + } else if (widget->inherits("TQToolBoxButton")) { TQFont font = widget->font(); font.setBold(true); widget->setFont(font); @@ -215,14 +215,14 @@ void HighColorStyle::polish(const TQStyleControlElementData &ceData, ControlElem void HighColorStyle::unPolish(const TQStyleControlElementData &ceData, ControlElementFlags elementFlags, void *ptr) { - if (ceData.widgetObjectTypes.contains(TQWIDGET_OBJECT_NAME_STRING)) { + if (ceData.widgetObjectTypes.contains("TQWidget")) { TQWidget *widget = reinterpret_cast<TQWidget*>(ptr); - if (widget->inherits(TQPUSHBUTTON_OBJECT_NAME_STRING)) { + if (widget->inherits("TQPushButton")) { removeObjectEventHandler(ceData, elementFlags, ptr, this); } - else if (widget->inherits(TQMENUBAR_OBJECT_NAME_STRING) || widget->inherits(TQPOPUPMENU_OBJECT_NAME_STRING)) { + else if (widget->inherits("TQMenuBar") || widget->inherits("TQPopupMenu")) { widget->setBackgroundMode(TQWidget::PaletteBackground); - } else if (type == HighColor && widget->inherits(TQTOOLBAREXTENSIONWIDGET_OBJECT_NAME_STRING)) { + } else if (type == HighColor && widget->inherits("TQToolBarExtensionWidget")) { removeObjectEventHandler(ceData, elementFlags, ptr, this); } else if ( !qstrcmp( widget->name(), kdeToolbarWidget) ) { removeObjectEventHandler(ceData, elementFlags, ptr, this); @@ -1683,7 +1683,7 @@ void HighColorStyle::drawComplexControl( TQ_ComplexControl control, } else if (!ceData.parentWidgetData.widgetObjectTypes.isEmpty()) { - if (ceData.parentWidgetData.widgetObjectTypes.contains(TQTOOLBAR_OBJECT_NAME_STRING)) + if (ceData.parentWidgetData.widgetObjectTypes.contains("TQToolBar")) { TQToolBar* parent = (TQToolBar*)widget->parent(); TQRect pr = parent->rect(); @@ -1692,7 +1692,7 @@ void HighColorStyle::drawComplexControl( TQ_ComplexControl control, parent->orientation() == Qt::Vertical, r.x(), r.y(), pr.width()-2, pr.height()-2); } - else if (ceData.parentWidgetData.widgetObjectTypes.contains(TQTOOLBAREXTENSIONWIDGET_OBJECT_NAME_STRING)) + else if (ceData.parentWidgetData.widgetObjectTypes.contains("TQToolBarExtensionWidget")) { TQWidget* parent = (TQWidget*)widget->parent(); TQToolBar* toolbar = (TQToolBar*)parent->parent(); @@ -2016,7 +2016,7 @@ bool HighColorStyle::objectEventHandler( const TQStyleControlElementData &ceData TQToolBar* toolbar; - if (ceData.widgetObjectTypes.contains(TQOBJECT_OBJECT_NAME_STRING)) + if (ceData.widgetObjectTypes.contains("TQObject")) { TQObject* object = reinterpret_cast<TQObject*>(source); |