Rename obsolete tq methods to standard names

pull/1/head
Timothy Pearson 13 years ago
parent 59a076e933
commit 251c4d87e5

@ -54,7 +54,7 @@ FifteenApplet::FifteenApplet(const TQString& configFile, Type type, int actions,
_table = new PiecesTable(this); _table = new PiecesTable(this);
setCustomMenu(_table->popup()); setCustomMenu(_table->popup());
// setup tqlayout // setup layout
TQHBoxLayout *_layout = new TQHBoxLayout(this); TQHBoxLayout *_layout = new TQHBoxLayout(this);
_layout->add(_table); _layout->add(_table);

@ -52,7 +52,7 @@ void WrappingSpinBox::stepDown()
TimeEdit::TimeEdit(TQWidget* parent, const char* name) TimeEdit::TimeEdit(TQWidget* parent, const char* name)
: TQWidget(parent, name) : TQWidget(parent, name)
{ {
tqlayout = new TQHBoxLayout(this); layout = new TQHBoxLayout(this);
minuteBox = new TQSpinBox(0, 300, 1, this); minuteBox = new TQSpinBox(0, 300, 1, this);
// minuteBox->setFixedSize(minuteBox->sizeHint()); // minuteBox->setFixedSize(minuteBox->sizeHint());
@ -65,11 +65,11 @@ TimeEdit::TimeEdit(TQWidget* parent, const char* name)
TQLabel* sec = new TQLabel(i18n(" sec"),this); TQLabel* sec = new TQLabel(i18n(" sec"),this);
sec->setFixedSize(sec->sizeHint()); sec->setFixedSize(sec->sizeHint());
tqlayout->addWidget(minuteBox); layout->addWidget(minuteBox);
tqlayout->addWidget(min); layout->addWidget(min);
tqlayout->addWidget(secondBox); layout->addWidget(secondBox);
tqlayout->addWidget(sec); layout->addWidget(sec);
connect(minuteBox, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(spinBoxValueChanged(int)) ); connect(minuteBox, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(spinBoxValueChanged(int)) );
connect(secondBox, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(spinBoxValueChanged(int)) ); connect(secondBox, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(spinBoxValueChanged(int)) );

@ -67,7 +67,7 @@ signals:
protected: protected:
TQSpinBox *minuteBox; TQSpinBox *minuteBox;
WrappingSpinBox *secondBox; WrappingSpinBox *secondBox;
TQBoxLayout* tqlayout; TQBoxLayout* layout;
}; };
#endif #endif

@ -85,7 +85,7 @@ KSpriteSetup::KSpriteSetup( TQWidget *parent, const char *name )
button = bbox->addButton(KStdGuiItem::cancel()); button = bbox->addButton(KStdGuiItem::cancel());
connect( button, TQT_SIGNAL( clicked() ), TQT_SLOT( reject() ) ); connect( button, TQT_SIGNAL( clicked() ), TQT_SLOT( reject() ) );
bbox->tqlayout(); bbox->layout();
tl->addWidget(bbox); tl->addWidget(bbox);
tl->freeze(); tl->freeze();

@ -184,12 +184,12 @@ void dockwidget::initDock()
mainLayout->setMargin(0); mainLayout->setMargin(0);
mainLayout->addWidget(m_button, 0, TQt::AlignCenter); mainLayout->addWidget(m_button, 0, TQt::AlignCenter);
TQBoxLayout *tqlayout = new TQBoxLayout(mainLayout, TQBoxLayout::TopToBottom); TQBoxLayout *layout = new TQBoxLayout(mainLayout, TQBoxLayout::TopToBottom);
tqlayout->setSpacing(0); layout->setSpacing(0);
tqlayout->setMargin(0); layout->setMargin(0);
tqlayout->addWidget(m_lblTemp); layout->addWidget(m_lblTemp);
tqlayout->addWidget(m_lblWind); layout->addWidget(m_lblWind);
tqlayout->addWidget(m_lblPres); layout->addWidget(m_lblPres);
mainLayout->addSpacing(8); mainLayout->addSpacing(8);
@ -210,16 +210,16 @@ void dockwidget::resizeView( const TQSize &size )
if ( m_mode == ShowAll ) if ( m_mode == ShowAll )
{ {
if ( h <= 128 ) // left to right tqlayout if ( h <= 128 ) // left to right layout
{ {
static_cast<TQBoxLayout*>(tqlayout())->setDirection(TQBoxLayout::LeftToRight); static_cast<TQBoxLayout*>(layout())->setDirection(TQBoxLayout::LeftToRight);
m_lblTemp->setAlignment(TQt::AlignAuto | TQt::AlignVCenter); m_lblTemp->setAlignment(TQt::AlignAuto | TQt::AlignVCenter);
m_lblWind->setAlignment(TQt::AlignAuto | TQt::AlignVCenter); m_lblWind->setAlignment(TQt::AlignAuto | TQt::AlignVCenter);
m_lblPres->setAlignment(TQt::AlignAuto | TQt::AlignVCenter); m_lblPres->setAlignment(TQt::AlignAuto | TQt::AlignVCenter);
} }
else // top to bottom else // top to bottom
{ {
static_cast<TQBoxLayout*>(tqlayout())->setDirection(TQBoxLayout::TopToBottom); static_cast<TQBoxLayout*>(layout())->setDirection(TQBoxLayout::TopToBottom);
TQFontMetrics fm(m_font); TQFontMetrics fm(m_font);
h = 128 - (3 * fm.height()); // 3 lines of text below the button h = 128 - (3 * fm.height()); // 3 lines of text below the button
m_lblTemp->setAlignment(TQt::AlignCenter); m_lblTemp->setAlignment(TQt::AlignCenter);
@ -232,12 +232,12 @@ void dockwidget::resizeView( const TQSize &size )
{ {
if ( h <= 32 ) // left to right if ( h <= 32 ) // left to right
{ {
static_cast<TQBoxLayout*>(tqlayout())->setDirection(TQBoxLayout::LeftToRight); static_cast<TQBoxLayout*>(layout())->setDirection(TQBoxLayout::LeftToRight);
m_lblTemp->setAlignment(TQt::AlignAuto | TQt::AlignVCenter); m_lblTemp->setAlignment(TQt::AlignAuto | TQt::AlignVCenter);
} }
else // top to bottom else // top to bottom
{ {
static_cast<TQBoxLayout*>(tqlayout())->setDirection(TQBoxLayout::TopToBottom); static_cast<TQBoxLayout*>(layout())->setDirection(TQBoxLayout::TopToBottom);
TQFontMetrics fm(m_font); TQFontMetrics fm(m_font);
h = TQMIN(128, h) - fm.height(); h = TQMIN(128, h) - fm.height();
m_lblTemp->setAlignment(TQt::AlignCenter); m_lblTemp->setAlignment(TQt::AlignCenter);
@ -259,7 +259,7 @@ void dockwidget::resizeView( const TQSize &size )
{ {
if ( w <= 128 ) // top to bottom if ( w <= 128 ) // top to bottom
{ {
static_cast<TQBoxLayout*>(tqlayout())->setDirection(TQBoxLayout::TopToBottom); static_cast<TQBoxLayout*>(layout())->setDirection(TQBoxLayout::TopToBottom);
m_lblTemp->setAlignment(TQt::AlignCenter); m_lblTemp->setAlignment(TQt::AlignCenter);
m_lblWind->setAlignment(TQt::AlignCenter); m_lblWind->setAlignment(TQt::AlignCenter);
m_lblPres->setAlignment(TQt::AlignCenter); m_lblPres->setAlignment(TQt::AlignCenter);
@ -268,9 +268,9 @@ void dockwidget::resizeView( const TQSize &size )
h = h - (3 * fm.height()); // 3 lines of text below the button h = h - (3 * fm.height()); // 3 lines of text below the button
h = TQMIN(w, h); h = TQMIN(w, h);
} }
else // left to right tqlayout else // left to right layout
{ {
static_cast<TQBoxLayout*>(tqlayout())->setDirection(TQBoxLayout::LeftToRight); static_cast<TQBoxLayout*>(layout())->setDirection(TQBoxLayout::LeftToRight);
m_lblTemp->setAlignment(TQt::AlignAuto | TQt::AlignVCenter); m_lblTemp->setAlignment(TQt::AlignAuto | TQt::AlignVCenter);
m_lblWind->setAlignment(TQt::AlignAuto | TQt::AlignVCenter); m_lblWind->setAlignment(TQt::AlignAuto | TQt::AlignVCenter);
m_lblPres->setAlignment(TQt::AlignAuto | TQt::AlignVCenter); m_lblPres->setAlignment(TQt::AlignAuto | TQt::AlignVCenter);
@ -281,14 +281,14 @@ void dockwidget::resizeView( const TQSize &size )
{ {
if ( w <= 128 ) // top to bottom if ( w <= 128 ) // top to bottom
{ {
static_cast<TQBoxLayout*>(tqlayout())->setDirection(TQBoxLayout::TopToBottom); static_cast<TQBoxLayout*>(layout())->setDirection(TQBoxLayout::TopToBottom);
m_lblTemp->setAlignment(TQt::AlignCenter); m_lblTemp->setAlignment(TQt::AlignCenter);
h = w; h = w;
} }
else // left to right tqlayout else // left to right layout
{ {
static_cast<TQBoxLayout*>(tqlayout())->setDirection(TQBoxLayout::LeftToRight); static_cast<TQBoxLayout*>(layout())->setDirection(TQBoxLayout::LeftToRight);
m_lblTemp->setAlignment(TQt::AlignAuto | TQt::AlignVCenter); m_lblTemp->setAlignment(TQt::AlignAuto | TQt::AlignVCenter);
h = static_cast<int>(w * 0.33); h = static_cast<int>(w * 0.33);
@ -310,7 +310,7 @@ int dockwidget::widthForHeight(int h)
if ( m_mode == ShowAll ) if ( m_mode == ShowAll )
{ {
if ( h <= 128 ) // left to right tqlayout if ( h <= 128 ) // left to right layout
{ {
int pixelSize = h/3 - 3; int pixelSize = h/3 - 3;
pixelSize = TQMIN(pixelSize, fi.pixelSize()); // don't make it too large pixelSize = TQMIN(pixelSize, fi.pixelSize()); // don't make it too large
@ -337,7 +337,7 @@ int dockwidget::widthForHeight(int h)
} }
else if ( m_mode == ShowTempOnly ) else if ( m_mode == ShowTempOnly )
{ {
if ( h <= 32 ) // left to right tqlayout if ( h <= 32 ) // left to right layout
{ {
int pixelSize = h - 3; int pixelSize = h - 3;
pixelSize = TQMIN(pixelSize, fi.pixelSize()); // don't make it too large pixelSize = TQMIN(pixelSize, fi.pixelSize()); // don't make it too large

@ -54,12 +54,12 @@ KCMWeather::KCMWeather( TQWidget *parent, const char *name )
{ {
mWeatherService = new WeatherService_stub( "KWeatherService", mWeatherService = new WeatherService_stub( "KWeatherService",
"WeatherService" ); "WeatherService" );
TQVBoxLayout *tqlayout = new TQVBoxLayout( this ); TQVBoxLayout *layout = new TQVBoxLayout( this );
mWidget = new prefsDialogData( this ); mWidget = new prefsDialogData( this );
mWidget->m_reportLocation->setFocus(); mWidget->m_reportLocation->setFocus();
tqlayout->addWidget( mWidget ); layout->addWidget( mWidget );
tqlayout->addStretch(); layout->addStretch();
fillStationList(); fillStationList();
load(); load();

@ -41,13 +41,13 @@ extern "C"
KCMWeatherService::KCMWeatherService( TQWidget *parent, const char *name ) KCMWeatherService::KCMWeatherService( TQWidget *parent, const char *name )
: KCModule( parent, name ) : KCModule( parent, name )
{ {
TQVBoxLayout *tqlayout = new TQVBoxLayout( this ); TQVBoxLayout *layout = new TQVBoxLayout( this );
mWidget = new ServiceConfigWidget( this ); mWidget = new ServiceConfigWidget( this );
// not needed, as a change immediately changes the service // not needed, as a change immediately changes the service
//connect(mWidget, TQT_SIGNAL(changed(bool)), this, TQT_SIGNAL(changed(bool))); //connect(mWidget, TQT_SIGNAL(changed(bool)), this, TQT_SIGNAL(changed(bool)));
tqlayout->addWidget( mWidget ); layout->addWidget( mWidget );
KAboutData *about = new KAboutData( "kcmweatherservice", KAboutData *about = new KAboutData( "kcmweatherservice",
I18N_NOOP( "KWeather Configure Dialog" ), I18N_NOOP( "KWeather Configure Dialog" ),
0, 0, KAboutData::License_GPL, 0, 0, KAboutData::License_GPL,

@ -284,7 +284,7 @@
</property> </property>
<widget class="TQLayoutWidget"> <widget class="TQLayoutWidget">
<property name="name"> <property name="name">
<cstring>tqlayout1</cstring> <cstring>layout1</cstring>
</property> </property>
<hbox> <hbox>
<property name="name"> <property name="name">

@ -72,7 +72,7 @@ void reportView::render(){
TQString textColor = KGlobalSettings::textColor().name(); TQString textColor = KGlobalSettings::textColor().name();
TQString baseColor = KGlobalSettings::baseColor().name(); TQString baseColor = KGlobalSettings::baseColor().name();
TQColorGroup cg = tqpalette().active(); TQColorGroup cg = palette().active();
TQString bgColor = cg.background().name(); TQString bgColor = cg.background().name();
TQString hlColor = cg.highlight().name(); TQString hlColor = cg.highlight().name();
TQString hlTextColor = cg.highlightedText().name(); TQString hlTextColor = cg.highlightedText().name();

@ -169,7 +169,7 @@
</widget> </widget>
<widget class="TQLayoutWidget" row="5" column="0" rowspan="1" colspan="3"> <widget class="TQLayoutWidget" row="5" column="0" rowspan="1" colspan="3">
<property name="name"> <property name="name">
<cstring>tqlayout1</cstring> <cstring>layout1</cstring>
</property> </property>
<hbox> <hbox>
<property name="name"> <property name="name">

@ -1,7 +1,7 @@
/**************************************************************************** /****************************************************************************
** $Id$ ** $Id$
** **
** Implementing your own tqlayout: flow example ** Implementing your own layout: flow example
** **
** Copyright (C) 1996 by Trolltech AS. All rights reserved. ** Copyright (C) 1996 by Trolltech AS. All rights reserved.
** **

@ -1,7 +1,7 @@
/**************************************************************************** /****************************************************************************
** $Id$ ** $Id$
** **
** Definition of simple flow tqlayout for custom tqlayout example ** Definition of simple flow layout for custom layout example
** **
** Created : 979899 ** Created : 979899
** **

@ -122,7 +122,7 @@ void ZoneClock::editClock()
_name = _dlg->ClockCaption->text().append(":"); _name = _dlg->ClockCaption->text().append(":");
_nameLabel->setText(_dlg->ClockCaption->text().append(":")); _nameLabel->setText(_dlg->ClockCaption->text().append(":"));
updateTime(); updateTime();
tqlayout()->invalidate(); layout()->invalidate();
emit changed(); emit changed();
} }

Loading…
Cancel
Save