Rename obsolete tq methods to standard names

master
Timothy Pearson 13 years ago
parent 5491e8ebc4
commit db02bba0ad

@ -79,7 +79,7 @@
</spacer>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout6</cstring>
<cstring>layout6</cstring>
</property>
<hbox>
<property name="name">
@ -104,7 +104,7 @@
</spacer>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout5</cstring>
<cstring>layout5</cstring>
</property>
<grid>
<property name="name">

@ -27,16 +27,16 @@ DesktopEntry::DesktopEntry( TQWidget *p, const char *n )
void DesktopEntry::resize( int w, int h )
{
// kdDebug() << "DesktopEntry::resize( " << w << ", " << h << " )" << endl;
int margin = tqlayout()->margin() + tqlayout()->spacing() * 2
int margin = layout()->margin() + layout()->spacing() * 2
+ 6 /* spacer */ + m_icon->width() + m_check->width();
if ( m_check->isVisible() ) margin += m_check->width() + tqlayout()->spacing();
if ( m_check->isVisible() ) margin += m_check->width() + layout()->spacing();
int hFW1 = m_name->heightForWidth( w - margin );
int hFW2 = m_description->heightForWidth( w - margin );
/* kdDebug() << "margin = " << margin << ", hFW1 = " << hFW1 << ", hFW2 = "
<< hFW2 << endl; */
int height = 2 * tqlayout()->margin() + tqlayout()->spacing() + hFW1 + hFW2;
if ( height < 32 + 2*tqlayout()->margin() /* icon size + margin */ )
height = 32 + 2*tqlayout()->margin();
int height = 2 * layout()->margin() + layout()->spacing() + hFW1 + hFW2;
if ( height < 32 + 2*layout()->margin() /* icon size + margin */ )
height = 32 + 2*layout()->margin();
// m_description->resize( w - margin, m_description->heightForWidth( w - margin ) );
TQWidget::resize( w, height );
}

@ -43,7 +43,7 @@
</widget>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout4</cstring>
<cstring>layout4</cstring>
</property>
<hbox>
<property name="name">
@ -68,7 +68,7 @@
</spacer>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout3</cstring>
<cstring>layout3</cstring>
</property>
<grid>
<property name="name">

@ -106,7 +106,7 @@ void ExtendableList::updateExtender( ExtendableItem *i )
i->extender()->height() );
if ( i->height() != i->extender()->frameSize().height() ) {
i->setHeight( i->extender()->frameSize().height() );
delayedUpdateExtenders(); // re-update since we broke tqlayout
delayedUpdateExtenders(); // re-update since we broke layout
}
i->extender()->setupColors();

@ -38,7 +38,7 @@ GroupedDesktopSelector::GroupedDesktopSelector( TQWidget *p, const char *n )
} // *hack*
// AAAA hack
TQLayoutIterator li = tqlayout()->iterator();
TQLayoutIterator li = layout()->iterator();
TQHBoxLayout *hbox = 0;
while ( li.current() != 0 ) {
hbox = dynamic_cast< TQHBoxLayout * >( li.current() );

@ -27,7 +27,7 @@
</property>
<widget class="TQLayoutWidget" row="0" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>tqlayout5</cstring>
<cstring>layout5</cstring>
</property>
<hbox>
<property name="name">

@ -669,13 +669,13 @@ void ListerItemExtender::resize( int w, int h )
{
// XXX the magic constants are probably style-dependent... AW
int namew = - item()->lister()->extenderOffset( item() )
- tqlayout()->margin()
- tqlayout()->spacing()
- layout()->margin()
- layout()->spacing()
+ item()->lister()->columnWidth( 0 );
int statw = item()->lister()->columnWidth( Lister::ColStatus )
- tqlayout()->spacing();
- layout()->spacing();
int chw = item()->lister()->columnWidth( Lister::ColRequested )
- tqlayout()->spacing() - 3; // wth...
- layout()->spacing() - 3; // wth...
m_name->setMinimumWidth( namew );
m_status->setMinimumWidth( statw );
m_change->setMinimumWidth( chw );

@ -61,7 +61,7 @@
</spacer>
<widget class="TQLayoutWidget" row="0" column="1">
<property name="name">
<cstring>tqlayout7</cstring>
<cstring>layout7</cstring>
</property>
<hbox>
<property name="name">
@ -182,7 +182,7 @@
</widget>
<widget class="TQLayoutWidget" row="2" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>tqlayout3</cstring>
<cstring>layout3</cstring>
</property>
<hbox>
<property name="name">

@ -293,7 +293,7 @@
</widget>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout9</cstring>
<cstring>layout9</cstring>
</property>
<vbox>
<property name="name">

@ -88,7 +88,7 @@
</widget>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout5</cstring>
<cstring>layout5</cstring>
</property>
<hbox>
<property name="name">
@ -122,7 +122,7 @@
</widget>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout13</cstring>
<cstring>layout13</cstring>
</property>
<hbox>
<property name="name">

@ -38,7 +38,7 @@
</widget>
<widget class="TQLayoutWidget" row="0" column="1">
<property name="name">
<cstring>tqlayout4</cstring>
<cstring>layout4</cstring>
</property>
<hbox>
<property name="name">
@ -89,7 +89,7 @@
</widget>
<widget class="TQLayoutWidget" row="1" column="1">
<property name="name">
<cstring>tqlayout5</cstring>
<cstring>layout5</cstring>
</property>
<hbox>
<property name="name">

@ -92,7 +92,7 @@ void TagList::updateList()
appendLabel( new TagLabel( *i, this, m_tagBox ) );
}
}
m_tagBox->tqlayout()->addItem( m_tagSpacer );
m_tagBox->layout()->addItem( m_tagSpacer );
update();
parentWidget()->adjustSize();
m_updateScheduled = false;
@ -134,5 +134,5 @@ void TagList::clearList()
delete *i;
}
m_list.clear();
m_tagBox->tqlayout()->removeItem( m_tagSpacer );
m_tagBox->layout()->removeItem( m_tagSpacer );
}

@ -210,9 +210,9 @@ bool App::confirmRequest( entity::Package p, component::State::Action a )
KDialogBase *db = new KDialogBase( KDialogBase::Plain, i18n( "Confirm action" ),
KDialogBase::Ok | KDialogBase::Cancel,
KDialogBase::Ok, this );
TQVBoxLayout *tqlayout = new TQVBoxLayout( db->plainPage() );
tqlayout->setSpacing( 4 );
// db->plainPage()->setLayout( tqlayout = new TQVBoxLayout( db->plainPage() ) );
TQVBoxLayout *layout = new TQVBoxLayout( db->plainPage() );
layout->setSpacing( 4 );
// db->plainPage()->setLayout( layout = new TQVBoxLayout( db->plainPage() ) );
// TQVBox *vb = new TQVBox( db );
TQLabel *txt = new TQLabel( db->plainPage() );
txt->setAlignment( TQt::AlignLeft | TQt::AlignTop | TQt::WordBreak );
@ -225,8 +225,8 @@ bool App::confirmRequest( entity::Package p, component::State::Action a )
l->setMinimumHeight( 220 );
l->setMinimumWidth( 320 );
l->setDisplayCheckboxes( false );
tqlayout->addWidget( txt );
tqlayout->addWidget( l );
layout->addWidget( txt );
layout->addWidget( l );
l->insertRange( filteredRange( d.entries(),
Adaptor( &entity::Desktop::package, p ) ) );
db->adjustSize();

@ -79,7 +79,7 @@
</spacer>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout6</cstring>
<cstring>layout6</cstring>
</property>
<hbox>
<property name="name">
@ -104,7 +104,7 @@
</spacer>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout5</cstring>
<cstring>layout5</cstring>
</property>
<grid>
<property name="name">

@ -27,16 +27,16 @@ DesktopEntry::DesktopEntry( TQWidget *p, const char *n )
void DesktopEntry::resize( int w, int h )
{
// kdDebug() << "DesktopEntry::resize( " << w << ", " << h << " )" << endl;
int margin = tqlayout()->margin() + tqlayout()->spacing() * 2
int margin = layout()->margin() + layout()->spacing() * 2
+ 6 /* spacer */ + m_icon->width() + m_check->width();
if ( m_check->isVisible() ) margin += m_check->width() + tqlayout()->spacing();
if ( m_check->isVisible() ) margin += m_check->width() + layout()->spacing();
int hFW1 = m_name->heightForWidth( w - margin );
int hFW2 = m_description->heightForWidth( w - margin );
/* kdDebug() << "margin = " << margin << ", hFW1 = " << hFW1 << ", hFW2 = "
<< hFW2 << endl; */
int height = 2 * tqlayout()->margin() + tqlayout()->spacing() + hFW1 + hFW2;
if ( height < 32 + 2*tqlayout()->margin() /* icon size + margin */ )
height = 32 + 2*tqlayout()->margin();
int height = 2 * layout()->margin() + layout()->spacing() + hFW1 + hFW2;
if ( height < 32 + 2*layout()->margin() /* icon size + margin */ )
height = 32 + 2*layout()->margin();
// m_description->resize( w - margin, m_description->heightForWidth( w - margin ) );
TQWidget::resize( w, height );
}

@ -43,7 +43,7 @@
</widget>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout4</cstring>
<cstring>layout4</cstring>
</property>
<hbox>
<property name="name">
@ -68,7 +68,7 @@
</spacer>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout3</cstring>
<cstring>layout3</cstring>
</property>
<grid>
<property name="name">

@ -102,7 +102,7 @@ void ExtendableList::updateExtender( ExtendableItem *i )
i->extender()->height() );
if ( i->height() != i->extender()->frameSize().height() ) {
i->setHeight( i->extender()->frameSize().height() );
delayedUpdateExtenders(); // re-update since we broke tqlayout
delayedUpdateExtenders(); // re-update since we broke layout
}
i->extender()->setupColors();

@ -38,7 +38,7 @@ GroupedDesktopSelector::GroupedDesktopSelector( TQWidget *p, const char *n )
} // *hack*
// AAAA hack
TQLayoutIterator li = tqlayout()->iterator();
TQLayoutIterator li = layout()->iterator();
TQHBoxLayout *hbox = 0;
while ( li.current() != 0 ) {
hbox = dynamic_cast< TQHBoxLayout * >( li.current() );

@ -27,7 +27,7 @@
</property>
<widget class="TQLayoutWidget" row="0" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>tqlayout5</cstring>
<cstring>layout5</cstring>
</property>
<hbox>
<property name="name">

@ -596,13 +596,13 @@ bool ListerItemExtender::eventFilter( TQObject *o, TQEvent *e )
void ListerItemExtender::resize( int w, int h )
{
int namew = - item()->lister()->extenderOffset( item() ) - 2
- tqlayout()->margin()
- tqlayout()->spacing()
- layout()->margin()
- layout()->spacing()
+ item()->lister()->columnWidth( 0 );
int statw = item()->lister()->columnWidth( 1 )
- tqlayout()->spacing();
- layout()->spacing();
int chw = item()->lister()->columnWidth( 2 ) - 2
- tqlayout()->spacing();
- layout()->spacing();
m_name->setMinimumWidth( namew );
m_status->setMinimumWidth( statw );
m_change->setMinimumWidth( chw );

@ -78,7 +78,7 @@
</spacer>
<widget class="TQLayoutWidget" row="0" column="1">
<property name="name">
<cstring>tqlayout7</cstring>
<cstring>layout7</cstring>
</property>
<hbox>
<property name="name">
@ -183,7 +183,7 @@
</widget>
<widget class="TQLayoutWidget" row="2" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>tqlayout3</cstring>
<cstring>layout3</cstring>
</property>
<hbox>
<property name="name">

@ -293,7 +293,7 @@
</widget>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout9</cstring>
<cstring>layout9</cstring>
</property>
<vbox>
<property name="name">

@ -88,7 +88,7 @@
</widget>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout5</cstring>
<cstring>layout5</cstring>
</property>
<hbox>
<property name="name">
@ -122,7 +122,7 @@
</widget>
<widget class="TQLayoutWidget">
<property name="name">
<cstring>tqlayout13</cstring>
<cstring>layout13</cstring>
</property>
<hbox>
<property name="name">

@ -38,7 +38,7 @@
</widget>
<widget class="TQLayoutWidget" row="0" column="1">
<property name="name">
<cstring>tqlayout4</cstring>
<cstring>layout4</cstring>
</property>
<hbox>
<property name="name">
@ -89,7 +89,7 @@
</widget>
<widget class="TQLayoutWidget" row="1" column="1">
<property name="name">
<cstring>tqlayout5</cstring>
<cstring>layout5</cstring>
</property>
<hbox>
<property name="name">

@ -88,7 +88,7 @@ void TagList::updateList()
appendLabel( new TagLabel( *i, this, m_tagBox ) );
}
}
m_tagBox->tqlayout()->addItem( m_tagSpacer );
m_tagBox->layout()->addItem( m_tagSpacer );
update();
parentWidget()->adjustSize();
m_updateScheduled = false;
@ -130,5 +130,5 @@ void TagList::clearList()
delete *i;
}
m_list.clear();
m_tagBox->tqlayout()->removeItem( m_tagSpacer );
m_tagBox->layout()->removeItem( m_tagSpacer );
}

Loading…
Cancel
Save