summaryrefslogtreecommitdiffstats
path: root/kstyles
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-04-02 06:46:49 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-04-02 06:46:49 +0000
commitb5fb39eb73302856329affac603779129a545abd (patch)
treed07172449a51f48bbc62681653f71aa1287abd7d /kstyles
parent1c4e273a42588ec915cb94f7b1ceeed2468c9f07 (diff)
downloadtdelibs-b5fb39eb73302856329affac603779129a545abd.tar.gz
tdelibs-b5fb39eb73302856329affac603779129a545abd.zip
Change most kdelibs inherits() functions to use the new object name define system
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1226839 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kstyles')
-rw-r--r--kstyles/highcolor/highcolor.cpp12
-rw-r--r--kstyles/highcontrast/highcontrast.cpp30
-rw-r--r--kstyles/keramik/keramik.cpp32
-rw-r--r--kstyles/klegacy/klegacystyle.cpp42
-rw-r--r--kstyles/light/lightstyle-v2.cpp2
-rw-r--r--kstyles/light/lightstyle-v3.cpp2
-rw-r--r--kstyles/plastik/plastik.cpp6
-rw-r--r--kstyles/web/webstyle.cpp8
8 files changed, 67 insertions, 67 deletions
diff --git a/kstyles/highcolor/highcolor.cpp b/kstyles/highcolor/highcolor.cpp
index 09dd48d6c..4a32922d1 100644
--- a/kstyles/highcolor/highcolor.cpp
+++ b/kstyles/highcolor/highcolor.cpp
@@ -192,16 +192,16 @@ HighColorStyle::~HighColorStyle()
void HighColorStyle::polish(TQWidget* widget)
{
// Put in order of highest occurrence to maximise hit rate
- if (widget->inherits("QPushButton")) {
+ if (widget->inherits(TQPUSHBUTTON_OBJECT_NAME_STRING)) {
widget->installEventFilter(this);
- } else if (widget->inherits("QMenuBar") || widget->inherits("QPopupMenu")) {
+ } else if (widget->inherits(TQMENUBAR_OBJECT_NAME_STRING) || widget->inherits(TQPOPUPMENU_OBJECT_NAME_STRING)) {
widget->setBackgroundMode(TQWidget::NoBackground);
} else if (type == HighColor && widget->inherits("QToolBarExtensionWidget")) {
widget->installEventFilter(this);
} else if ( !qstrcmp( widget->name(), kdeToolbarWidget) ) {
widget->setBackgroundMode( NoBackground ); // We paint the whole background.
widget->installEventFilter(this);
- } else if (widget->inherits("QToolBoxButton")) {
+ } else if (widget->inherits(TQTOOLBOXBUTTON_OBJECT_NAME_STRING)) {
TQFont font = widget->font();
font.setBold(true);
widget->setFont(font);
@@ -213,10 +213,10 @@ void HighColorStyle::polish(TQWidget* widget)
void HighColorStyle::unPolish(TQWidget* widget)
{
- if (widget->inherits("QPushButton")) {
+ if (widget->inherits(TQPUSHBUTTON_OBJECT_NAME_STRING)) {
widget->removeEventFilter(this);
}
- else if (widget->inherits("QMenuBar") || widget->inherits("QPopupMenu")) {
+ else if (widget->inherits(TQMENUBAR_OBJECT_NAME_STRING) || widget->inherits(TQPOPUPMENU_OBJECT_NAME_STRING)) {
widget->setBackgroundMode(TQWidget::PaletteBackground);
} else if (type == HighColor && widget->inherits("QToolBarExtensionWidget")) {
widget->removeEventFilter(this);
@@ -1651,7 +1651,7 @@ void HighColorStyle::tqdrawComplexControl( TQ_ComplexControl control,
}
else if (widget->parent())
{
- if (widget->parent()->inherits("QToolBar"))
+ if (widget->parent()->inherits(TQTOOLBAR_OBJECT_NAME_STRING))
{
TQToolBar* parent = (TQToolBar*)widget->parent();
TQRect pr = parent->rect();
diff --git a/kstyles/highcontrast/highcontrast.cpp b/kstyles/highcontrast/highcontrast.cpp
index 9c80914c7..d3efc088b 100644
--- a/kstyles/highcontrast/highcontrast.cpp
+++ b/kstyles/highcontrast/highcontrast.cpp
@@ -155,11 +155,11 @@ void HighContrastStyle::polish( TQPalette& pal )
void HighContrastStyle::polish (TQWidget* widget)
{
- if (widget->inherits ("QButton")
- || widget->inherits ("QComboBox")
- || widget->inherits ("QSpinWidget")
- || widget->inherits ("QLineEdit")
- || widget->inherits ("QTextEdit"))
+ if (widget->inherits (TQBUTTON_OBJECT_NAME_STRING)
+ || widget->inherits (TQCOMBOBOX_OBJECT_NAME_STRING)
+ || widget->inherits (TQSPINWIDGET_OBJECT_NAME_STRING)
+ || widget->inherits (TQLINEEDIT_OBJECT_NAME_STRING)
+ || widget->inherits (TQTEXTEDIT_OBJECT_NAME_STRING))
{
widget->installEventFilter (this);
@@ -174,7 +174,7 @@ void HighContrastStyle::polish (TQWidget* widget)
void HighContrastStyle::unPolish (TQWidget* widget)
{
- if (widget->inherits ("QWidget") || widget->inherits ("QComboBox") || widget->inherits ("QSpinWidget") || widget->inherits ("QLineEdit") || widget->inherits ("QTextEdit"))
+ if (widget->inherits (TQWIDGET_OBJECT_NAME_STRING) || widget->inherits (TQCOMBOBOX_OBJECT_NAME_STRING) || widget->inherits (TQSPINWIDGET_OBJECT_NAME_STRING) || widget->inherits (TQLINEEDIT_OBJECT_NAME_STRING) || widget->inherits (TQTEXTEDIT_OBJECT_NAME_STRING))
widget->removeEventFilter (this);
KStyle::unPolish (widget);
}
@@ -1595,7 +1595,7 @@ int HighContrastStyle::tqpixelMetric(PixelMetric m, const TQWidget *widget) cons
}
case PM_DefaultFrameWidth: {
- if (widget && (widget->inherits ("QLineEdit") || widget->inherits ("QTextEdit")))
+ if (widget && (widget->inherits (TQLINEEDIT_OBJECT_NAME_STRING) || widget->inherits (TQTEXTEDIT_OBJECT_NAME_STRING)))
return 2*basicLineWidth;
else
return basicLineWidth;
@@ -1805,17 +1805,17 @@ bool HighContrastStyle::eventFilter (TQObject *object, TQEvent *event)
{
// Handle hover effects.
if (event->type() == TQEvent::Enter
- && (widget->inherits ("QButton")
- || widget->inherits ("QComboBox")
- || widget->inherits ("QSpinWidget")))
+ && (widget->inherits (TQBUTTON_OBJECT_NAME_STRING)
+ || widget->inherits (TQCOMBOBOX_OBJECT_NAME_STRING)
+ || widget->inherits (TQSPINWIDGET_OBJECT_NAME_STRING)))
{
hoverWidget = widget;
widget->tqrepaint (false);
}
else if (event->type() == TQEvent::Leave
- && (widget->inherits ("QButton")
- || widget->inherits ("QComboBox")
- || widget->inherits ("QSpinWidget")))
+ && (widget->inherits (TQBUTTON_OBJECT_NAME_STRING)
+ || widget->inherits (TQCOMBOBOX_OBJECT_NAME_STRING)
+ || widget->inherits (TQSPINWIDGET_OBJECT_NAME_STRING)))
{
if (TQT_BASE_OBJECT(object) == TQT_BASE_OBJECT(hoverWidget))
hoverWidget = 0L;
@@ -1826,8 +1826,8 @@ bool HighContrastStyle::eventFilter (TQObject *object, TQEvent *event)
{
TQWidget* widgetparent = dynamic_cast<TQWidget*>(widget->parent());
while (widgetparent
- && ! widgetparent->inherits ("QComboBox")
- && ! widgetparent->inherits ("QSpinWidget"))
+ && ! widgetparent->inherits (TQCOMBOBOX_OBJECT_NAME_STRING)
+ && ! widgetparent->inherits (TQSPINWIDGET_OBJECT_NAME_STRING))
{
widgetparent = dynamic_cast<TQWidget*>(widgetparent->parent());
}
diff --git a/kstyles/keramik/keramik.cpp b/kstyles/keramik/keramik.cpp
index 8b33c3afe..9f3133498 100644
--- a/kstyles/keramik/keramik.cpp
+++ b/kstyles/keramik/keramik.cpp
@@ -338,17 +338,17 @@ void KeramikStyle::polish(TQApplication* app)
void KeramikStyle::polish(TQWidget* widget)
{
// Put in order of highest occurrence to maximise hit rate
- if ( widget->inherits( "QPushButton" ) || widget->inherits( "QComboBox" ) || widget->inherits("QToolButton") )
+ if ( widget->inherits( TQPUSHBUTTON_OBJECT_NAME_STRING ) || widget->inherits( TQCOMBOBOX_OBJECT_NAME_STRING ) || widget->inherits(TQTOOLBUTTON_OBJECT_NAME_STRING) )
{
widget->installEventFilter(this);
- if ( widget->inherits( "QComboBox" ) )
+ if ( widget->inherits( TQCOMBOBOX_OBJECT_NAME_STRING ) )
widget->setBackgroundMode( NoBackground );
}
- else if ( widget->inherits( "QMenuBar" ) || widget->inherits( "QPopupMenu" ) )
+ else if ( widget->inherits( TQMENUBAR_OBJECT_NAME_STRING ) || widget->inherits( TQPOPUPMENU_OBJECT_NAME_STRING ) )
widget->setBackgroundMode( NoBackground );
else if ( widget->tqparentWidget() &&
- ( ( widget->inherits( "QListBox" ) && widget->tqparentWidget()->inherits( "QComboBox" ) ) ||
+ ( ( widget->inherits( TQLISTBOX_OBJECT_NAME_STRING ) && widget->tqparentWidget()->inherits( TQCOMBOBOX_OBJECT_NAME_STRING ) ) ||
widget->inherits( "KCompletionBox" ) ) ) {
TQListBox* listbox = (TQListBox*) widget;
listbox->setLineWidth( 4 );
@@ -379,17 +379,17 @@ void KeramikStyle::polish(TQWidget* widget)
void KeramikStyle::unPolish(TQWidget* widget)
{
//### TODO: This needs major cleanup (and so does polish() )
- if ( widget->inherits( "QPushButton" ) || widget->inherits( "QComboBox" ) )
+ if ( widget->inherits( TQPUSHBUTTON_OBJECT_NAME_STRING ) || widget->inherits( TQCOMBOBOX_OBJECT_NAME_STRING ) )
{
- if ( widget->inherits( "QComboBox" ) )
+ if ( widget->inherits( TQCOMBOBOX_OBJECT_NAME_STRING ) )
widget->setBackgroundMode( PaletteButton );
widget->removeEventFilter(this);
}
- else if ( widget->inherits( "QMenuBar" ) || widget->inherits( "QPopupMenu" ) )
+ else if ( widget->inherits( TQMENUBAR_OBJECT_NAME_STRING ) || widget->inherits( TQPOPUPMENU_OBJECT_NAME_STRING ) )
widget->setBackgroundMode( PaletteBackground );
else if ( widget->tqparentWidget() &&
- ( ( widget->inherits( "QListBox" ) && widget->tqparentWidget()->inherits( "QComboBox" ) ) ||
+ ( ( widget->inherits( TQLISTBOX_OBJECT_NAME_STRING ) && widget->tqparentWidget()->inherits( TQCOMBOBOX_OBJECT_NAME_STRING ) ) ||
widget->inherits( "KCompletionBox" ) ) ) {
TQListBox* listbox = (TQListBox*) widget;
listbox->setLineWidth( 1 );
@@ -1231,7 +1231,7 @@ void KeramikStyle::drawKStylePrimitive( KStylePrimitive kpe,
TQToolBar* parent = 0;
- if (widget && widget->parent() && widget->parent()->inherits("QToolBar"))
+ if (widget && widget->parent() && widget->parent()->inherits(TQTOOLBAR_OBJECT_NAME_STRING))
parent = static_cast<TQToolBar*>(widget->parent());
renderToolbarEntryBackground(p, parent, r, cg, (flags & Style_Horizontal));
@@ -1359,7 +1359,7 @@ void KeramikStyle::tqdrawControl( TQ_ControlElement element,
}
else
{
- if (widget->parent() && widget->parent()->inherits("QToolBar"))
+ if (widget->parent() && widget->parent()->inherits(TQTOOLBAR_OBJECT_NAME_STRING))
toolbarBlendWidget = widget;
tqdrawPrimitive( PE_ButtonCommand, p, r, cg, flags );
@@ -1466,7 +1466,7 @@ void KeramikStyle::tqdrawControl( TQ_ControlElement element,
case CE_ToolButtonLabel:
{
//const TQToolButton *toolbutton = static_cast<const TQToolButton * >(widget);
- bool onToolbar = widget->tqparentWidget() && widget->tqparentWidget()->inherits( "QToolBar" );
+ bool onToolbar = widget->tqparentWidget() && widget->tqparentWidget()->inherits( TQTOOLBAR_OBJECT_NAME_STRING );
TQRect nr = r;
if (!onToolbar)
@@ -1537,7 +1537,7 @@ void KeramikStyle::tqdrawControl( TQ_ControlElement element,
case CE_DockWindowEmptyArea:
{
TQRect pr = r;
- if (widget && widget->inherits("QToolBar"))
+ if (widget && widget->inherits(TQTOOLBAR_OBJECT_NAME_STRING))
{
const TQToolBar* tb = static_cast<const TQToolBar*>(widget);
if (tb->place() == TQDockWindow::OutsideDock)
@@ -1976,7 +1976,7 @@ void KeramikStyle::tqdrawComplexControl( TQ_ComplexControl control,
{
//Double-buffer only when we are in the slower full-blend mode
if (widget->parent() &&
- ( widget->tqparent()->inherits("QToolBar")|| !qstrcmp(widget->tqparent()->name(), kdeToolbarWidget) ) )
+ ( widget->tqparent()->inherits(TQTOOLBAR_OBJECT_NAME_STRING)|| !qstrcmp(widget->tqparent()->name(), kdeToolbarWidget) ) )
{
buf = new TQPixmap( r.width(), r.height() );
br.setX(0);
@@ -2209,10 +2209,10 @@ void KeramikStyle::tqdrawComplexControl( TQ_ComplexControl control,
// -------------------------------------------------------------------
case CC_ToolButton: {
const TQToolButton *toolbutton = (const TQToolButton *) widget;
- bool onToolbar = widget->tqparentWidget() && widget->tqparentWidget()->inherits( "QToolBar" );
+ bool onToolbar = widget->tqparentWidget() && widget->tqparentWidget()->inherits( TQTOOLBAR_OBJECT_NAME_STRING );
bool onExtender = !onToolbar &&
widget->tqparentWidget() && widget->tqparentWidget()->inherits( "QToolBarExtensionWidget") &&
- widget->tqparentWidget()->tqparentWidget()->inherits( "QToolBar" );
+ widget->tqparentWidget()->tqparentWidget()->inherits( TQTOOLBAR_OBJECT_NAME_STRING );
bool onControlButtons = false;
if (!onToolbar && !onExtender && widget->tqparentWidget() &&
@@ -2441,7 +2441,7 @@ TQSize KeramikStyle::tqsizeFromContents( ContentsType contents,
case CT_ToolButton:
{
- bool onToolbar = widget->tqparentWidget() && widget->tqparentWidget()->inherits( "QToolBar" );
+ bool onToolbar = widget->tqparentWidget() && widget->tqparentWidget()->inherits( TQTOOLBAR_OBJECT_NAME_STRING );
if (!onToolbar) //Behaves like a button, so scale appropriately to the border
{
int w = contentSize.width();
diff --git a/kstyles/klegacy/klegacystyle.cpp b/kstyles/klegacy/klegacystyle.cpp
index 9035f3b08..1579ac1cf 100644
--- a/kstyles/klegacy/klegacystyle.cpp
+++ b/kstyles/klegacy/klegacystyle.cpp
@@ -1898,23 +1898,23 @@ void KLegacyStyle::polish(TQWidget *widget) {
bool immediateRender = false;
bool bgPixmap = false;
- if (widget->inherits("QButton")) {
+ if (widget->inherits(TQBUTTON_OBJECT_NAME_STRING)) {
metaobject = TQButton::staticMetaObject();
eventFilter = true;
}
- if (widget->inherits("QComboBox")) {
+ if (widget->inherits(TQCOMBOBOX_OBJECT_NAME_STRING)) {
metaobject = TQComboBox::staticMetaObject();
eventFilter = true;
}
- if (widget->inherits("QScrollBar")) {
+ if (widget->inherits(TQSCROLLBAR_OBJECT_NAME_STRING)) {
metaobject = TQScrollBar::staticMetaObject();
eventFilter = true;
mouseTrack = true;
}
- if (widget->inherits("QMenuBar")) {
+ if (widget->inherits(TQMENUBAR_OBJECT_NAME_STRING)) {
eventFilter = true;
immediateRender = true;
@@ -1930,7 +1930,7 @@ void KLegacyStyle::polish(TQWidget *widget) {
widget->setBackgroundMode(TQWidget::PaletteBackground);
}
- if (widget->inherits("QToolBar")) {
+ if (widget->inherits(TQTOOLBAR_OBJECT_NAME_STRING)) {
metaobject = TQToolBar::staticMetaObject();
eventFilter = true;
@@ -1944,7 +1944,7 @@ void KLegacyStyle::polish(TQWidget *widget) {
widget->setBackgroundMode(TQWidget::PaletteBackground);
}
- if (widget->inherits("QLineEdit")) {
+ if (widget->inherits(TQLINEEDIT_OBJECT_NAME_STRING)) {
metaobject = TQLineEdit::staticMetaObject();
eventFilter = true;
@@ -1968,7 +1968,7 @@ void KLegacyStyle::polish(TQWidget *widget) {
detail = "base";
}
- if (widget->inherits("QPopupMenu")) {
+ if (widget->inherits(TQPOPUPMENU_OBJECT_NAME_STRING)) {
qDebug("polishing popup '%s'", widget->className());
metaobject = TQPopupMenu::staticMetaObject();
widget->setBackgroundMode(TQWidget::PaletteBackground);
@@ -2544,7 +2544,7 @@ void KLegacyStyle::drawComboButton(TQPainter *p, int x, int y, int w, int h,
key.data.state = KLegacy::Normal;
key.data.shadow = KLegacy::Out;
- if (priv->lastWidget && priv->lastWidget->inherits("QComboBox"))
+ if (priv->lastWidget && priv->lastWidget->inherits(TQCOMBOBOX_OBJECT_NAME_STRING))
key.data.state = KLegacy::Prelight;
TQPixmap *pix = gobj->draw(key, w, h, "optionmenu");
@@ -3081,7 +3081,7 @@ bool KLegacyStyle::eventFilter(TQObject *obj, TQEvent *e) {
{
TQWidget *w = (TQWidget *) obj;
- if (w->inherits("QPopupMenu") && w->width() < 700) {
+ if (w->inherits(TQPOPUPMENU_OBJECT_NAME_STRING) && w->width() < 700) {
GtkObject *gobj = priv->gtkDict.tqfind(TQPopupMenu::staticMetaObject());
if (gobj) {
@@ -3151,7 +3151,7 @@ bool KLegacyStyle::eventFilter(TQObject *obj, TQEvent *e) {
if (p && (! p->isNull()))
w->setBackgroundPixmap(*p);
}
- } else if (w->inherits("QLineEdit")) {
+ } else if (w->inherits(TQLINEEDIT_OBJECT_NAME_STRING)) {
GtkObject *gobj = priv->gtkDict.tqfind(TQLineEdit::staticMetaObject());
if (gobj) {
@@ -3191,8 +3191,8 @@ bool KLegacyStyle::eventFilter(TQObject *obj, TQEvent *e) {
w->setPalette(pal);
}
}
- } else if (w->inherits("QMenuBar") ||
- w->inherits("QToolBar")) {
+ } else if (w->inherits(TQMENUBAR_OBJECT_NAME_STRING) ||
+ w->inherits(TQTOOLBAR_OBJECT_NAME_STRING)) {
GtkObject *gobj = priv->gtkDict.tqfind(TQMenuBar::staticMetaObject());
if (gobj) {
@@ -3256,13 +3256,13 @@ bool KLegacyStyle::eventFilter(TQObject *obj, TQEvent *e) {
case TQEvent::Enter:
{
- if (obj->inherits("QPushButton") ||
- obj->inherits("QComboBox") ||
- obj->inherits("QSlider") ||
- obj->inherits("QScrollbar")) {
+ if (obj->inherits(TQPUSHBUTTON_OBJECT_NAME_STRING) ||
+ obj->inherits(TQCOMBOBOX_OBJECT_NAME_STRING) ||
+ obj->inherits(TQSLIDER_OBJECT_NAME_STRING) ||
+ obj->inherits(TQSCROLLBAR_OBJECT_NAME_STRING)) {
priv->lastWidget = (TQWidget *) obj;
priv->lastWidget->tqrepaint(false);
- } else if (obj->inherits("QRadioButton")) {
+ } else if (obj->inherits(TQRADIOBUTTON_OBJECT_NAME_STRING)) {
TQWidget *w = (TQWidget *) obj;
if (! w->isTopLevel() && w->isEnabled()) {
@@ -3290,7 +3290,7 @@ bool KLegacyStyle::eventFilter(TQObject *obj, TQEvent *e) {
}
}
}
- } else if (obj->inherits("QCheckBox")) {
+ } else if (obj->inherits(TQCHECKBOX_OBJECT_NAME_STRING)) {
TQWidget *w = (TQWidget *) obj;
if (! w->isTopLevel() && w->isEnabled()) {
@@ -3328,8 +3328,8 @@ bool KLegacyStyle::eventFilter(TQObject *obj, TQEvent *e) {
if (obj == priv->lastWidget) {
priv->lastWidget = 0;
((TQWidget *) obj)->tqrepaint(false);
- } else if (obj->inherits("QRadioButton") ||
- obj->inherits("QCheckBox")) {
+ } else if (obj->inherits(TQRADIOBUTTON_OBJECT_NAME_STRING) ||
+ obj->inherits(TQCHECKBOX_OBJECT_NAME_STRING)) {
TQWidget *w = (TQWidget *) obj;
if (! w->isTopLevel()) {
@@ -3346,7 +3346,7 @@ bool KLegacyStyle::eventFilter(TQObject *obj, TQEvent *e) {
{
TQMouseEvent *me = (TQMouseEvent *) e;
priv->mousePos = me->pos();
- if (obj->inherits("QScrollBar") &&
+ if (obj->inherits(TQSCROLLBAR_OBJECT_NAME_STRING) &&
(! (me->state() & (LeftButton | MidButton | RightButton)))) {
priv->hovering = true;
((TQWidget *) obj)->tqrepaint(false);
diff --git a/kstyles/light/lightstyle-v2.cpp b/kstyles/light/lightstyle-v2.cpp
index 133b309d4..90fd4d00f 100644
--- a/kstyles/light/lightstyle-v2.cpp
+++ b/kstyles/light/lightstyle-v2.cpp
@@ -295,7 +295,7 @@ void LightStyleV2::tqdrawPrimitive( TQ_PrimitiveElement pe,
if ( p && p->device()->devType() == TQInternal::Widget ) {
TQWidget *w = (TQWidget *) p->device();
TQWidget *p = w->tqparentWidget();
- if (p->inherits("QDockWindow") && ! p->inherits("QToolBar")) {
+ if (p->inherits(TQDOCKWINDOW_OBJECT_NAME_STRING) && ! p->inherits(TQTOOLBAR_OBJECT_NAME_STRING)) {
drawTitle = true;
title = p->caption();
}
diff --git a/kstyles/light/lightstyle-v3.cpp b/kstyles/light/lightstyle-v3.cpp
index 98e5c555d..07cd4d96b 100644
--- a/kstyles/light/lightstyle-v3.cpp
+++ b/kstyles/light/lightstyle-v3.cpp
@@ -427,7 +427,7 @@ void LightStyleV3::tqdrawPrimitive( TQ_PrimitiveElement pe,
if ( p && p->device()->devType() == TQInternal::Widget ) {
TQWidget *w = (TQWidget *) p->device();
TQWidget *p = w->tqparentWidget();
- if (p->inherits("QDockWindow") && ! p->inherits("QToolBar")) {
+ if (p->inherits(TQDOCKWINDOW_OBJECT_NAME_STRING) && ! p->inherits(TQTOOLBAR_OBJECT_NAME_STRING)) {
drawTitle = true;
title = p->caption();
}
diff --git a/kstyles/plastik/plastik.cpp b/kstyles/plastik/plastik.cpp
index 1b5f68596..72ecdc8de 100644
--- a/kstyles/plastik/plastik.cpp
+++ b/kstyles/plastik/plastik.cpp
@@ -247,7 +247,7 @@ void PlastikStyle::polish(TQWidget* widget)
if ( ::tqqt_cast<TQPushButton*>(widget) || ::tqqt_cast<TQComboBox*>(widget) ||
::tqqt_cast<TQSpinWidget*>(widget) || ::tqqt_cast<TQSlider*>(widget) ||
::tqqt_cast<TQCheckBox*>(widget) || ::tqqt_cast<TQRadioButton*>(widget) ||
- ::tqqt_cast<TQToolButton*>(widget) || widget->inherits("QSplitterHandle") )
+ ::tqqt_cast<TQToolButton*>(widget) || widget->inherits(TQSPLITTERHANDLE_OBJECT_NAME_STRING) )
{
// widget->setBackgroundMode(PaletteBackground);
widget->installEventFilter(this);
@@ -285,7 +285,7 @@ void PlastikStyle::unPolish(TQWidget* widget)
::tqqt_cast<TQSpinWidget*>(widget) || ::tqqt_cast<TQSlider*>(widget) ||
::tqqt_cast<TQCheckBox*>(widget) || ::tqqt_cast<TQRadioButton*>(widget) ||
::tqqt_cast<TQToolButton*>(widget) || ::tqqt_cast<TQLineEdit*>(widget) ||
- widget->inherits("QSplitterHandle") )
+ widget->inherits(TQSPLITTERHANDLE_OBJECT_NAME_STRING) )
{
widget->removeEventFilter(this);
}
@@ -3478,7 +3478,7 @@ bool PlastikStyle::eventFilter(TQObject *obj, TQEvent *ev)
//Hover highlight... use tqqt_cast to check if the widget inheits one of the classes.
if ( ::tqqt_cast<TQPushButton*>(obj) || ::tqqt_cast<TQComboBox*>(obj) ||
::tqqt_cast<TQSpinWidget*>(obj) || ::tqqt_cast<TQCheckBox*>(obj) ||
- ::tqqt_cast<TQRadioButton*>(obj) || ::tqqt_cast<TQToolButton*>(obj) || obj->inherits("QSplitterHandle") )
+ ::tqqt_cast<TQRadioButton*>(obj) || ::tqqt_cast<TQToolButton*>(obj) || obj->inherits(TQSPLITTERHANDLE_OBJECT_NAME_STRING) )
{
if ((ev->type() == TQEvent::Enter) && TQT_TQWIDGET(obj)->isEnabled())
{
diff --git a/kstyles/web/webstyle.cpp b/kstyles/web/webstyle.cpp
index 17dc46941..08474c701 100644
--- a/kstyles/web/webstyle.cpp
+++ b/kstyles/web/webstyle.cpp
@@ -250,10 +250,10 @@ WebStyle::unPolish(TQApplication *)
void
WebStyle::polish(TQWidget * w)
{
- if (w->inherits("QPushButton"))
+ if (w->inherits(TQPUSHBUTTON_OBJECT_NAME_STRING))
w->installEventFilter(this);
- else if (w->inherits("QGroupBox") || w->inherits("QFrame"))
+ else if (w->inherits(TQGROUPBOX_OBJECT_NAME_STRING) || w->inherits(TQFRAME_OBJECT_NAME_STRING))
{
TQFrame * f(static_cast<TQFrame *>(w));
@@ -282,7 +282,7 @@ WebStyle::polish(TQWidget * w)
void
WebStyle::unPolish(TQWidget * w)
{
- if (w->inherits("QPushButton"))
+ if (w->inherits(TQPUSHBUTTON_OBJECT_NAME_STRING))
w->removeEventFilter(this);
else if (w == _currentFrame)
@@ -1046,7 +1046,7 @@ WebStyle::drawKToolBarButton
{
bool toggleAndOn = false;
- if (button->inherits("QButton"))
+ if (button->inherits(TQBUTTON_OBJECT_NAME_STRING))
{
TQButton * b = static_cast<TQButton *>(button);
toggleAndOn = b->isToggleButton() && b->isOn();