Replaced various '#define' with actual strings - part 3

Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
pull/100/head
Michele Calgaro 6 months ago
parent d3aa578340
commit 3b66617d9d
Signed by: MicheleC
GPG Key ID: 2A75B7CA8ADED5CF

@ -183,7 +183,7 @@ uint TabWidget::tabBarWidthForMaxChars( uint maxLength )
if ( tab->iconSet() ) if ( tab->iconSet() )
iw = tab->iconSet()->pixmap( TQIconSet::Small, TQIconSet::Normal ).width() + 4; iw = tab->iconSet()->pixmap( TQIconSet::Small, TQIconSet::Normal ).width() + 4;
x += ( tabBar()->style().tqsizeFromContents( TQStyle::CT_TabBarTab, this, TQSize( TQMAX( lw + hframe + iw, TQApplication::globalStrut().width() ), 0 ), TQStyleOption( tab ) ) ).width(); x += ( tabBar()->style().sizeFromContents( TQStyle::CT_TabBarTab, this, TQSize( TQMAX( lw + hframe + iw, TQApplication::globalStrut().width() ), 0 ), TQStyleOption( tab ) ) ).width();
} }
return x; return x;
} }

@ -362,7 +362,7 @@ void CertificateWizardImpl::createPersonalDataPage()
if ( config.entryIsImmutable( attr ) ) if ( config.entryIsImmutable( attr ) )
le->setEnabled( false ); le->setEnabled( false );
_attrPairList.append(tqMakePair(key, le)); _attrPairList.append(qMakePair(key, le));
connect( le, TQT_SIGNAL(textChanged(const TQString&)), connect( le, TQT_SIGNAL(textChanged(const TQString&)),
TQT_SLOT(slotEnablePersonalDataPageExit()) ); TQT_SLOT(slotEnablePersonalDataPageExit()) );

@ -98,7 +98,7 @@ void JumpButtonBar::updateButtons()
TQFontMetrics fm = fontMetrics(); TQFontMetrics fm = fontMetrics();
TQPushButton *btn = new TQPushButton( "", this ); TQPushButton *btn = new TQPushButton( "", this );
btn->hide(); btn->hide();
TQSize buttonSize = style().tqsizeFromContents( TQStyle::CT_PushButton, btn, TQSize buttonSize = style().sizeFromContents( TQStyle::CT_PushButton, btn,
fm.size( ShowPrefix, "X - X") ). fm.size( ShowPrefix, "X - X") ).
expandedTo( TQApplication::globalStrut() ); expandedTo( TQApplication::globalStrut() );
delete btn; delete btn;

@ -316,7 +316,7 @@ void CardViewItem::paintCard( TQPainter *p, TQColorGroup &cg )
// if we are the current item and the view has focus, draw focus rect // if we are the current item and the view has focus, draw focus rect
if ( mView->currentItem() == this && mView->hasFocus() ) { if ( mView->currentItem() == this && mView->hasFocus() ) {
mView->style().tqdrawPrimitive( TQStyle::PE_FocusRect, p, mView->style().drawPrimitive( TQStyle::PE_FocusRect, p,
TQRect( 0, 0, mView->itemWidth(), h + (2 * mg) ), cg, TQRect( 0, 0, mView->itemWidth(), h + (2 * mg) ), cg,
TQStyle::Style_FocusAtBorder, TQStyle::Style_FocusAtBorder,
TQStyleOption( isSelected() ? cg.highlight() : cg.base() ) ); TQStyleOption( isSelected() ? cg.highlight() : cg.base() ) );

@ -241,7 +241,7 @@ void KDGanttSplitterHandle::paintEvent( TQPaintEvent * )
p.setBrush( colorGroup().background() ); p.setBrush( colorGroup().background() );
p.setPen( colorGroup().foreground() ); p.setPen( colorGroup().foreground() );
p.drawRect( rect() ); p.drawRect( rect() );
parentWidget()->style().tqdrawPrimitive( TQStyle::PE_Panel, &p, rect(), parentWidget()->style().drawPrimitive( TQStyle::PE_Panel, &p, rect(),
parentWidget()->colorGroup()); parentWidget()->colorGroup());
int sw = 8; // Hardcoded, given I didn't use styles anymore, I didn't like to use their size int sw = 8; // Hardcoded, given I didn't use styles anymore, I didn't like to use their size
@ -601,7 +601,7 @@ bool KDGanttMinimizeSplitter::event( TQEvent *e )
void KDGanttMinimizeSplitter::drawSplitter( TQPainter *p, void KDGanttMinimizeSplitter::drawSplitter( TQPainter *p,
TQCOORD x, TQCOORD y, TQCOORD w, TQCOORD h ) TQCOORD x, TQCOORD y, TQCOORD w, TQCOORD h )
{ {
style().tqdrawPrimitive(TQStyle::PE_Splitter, p, TQRect(x, y, w, h), colorGroup(), style().drawPrimitive(TQStyle::PE_Splitter, p, TQRect(x, y, w, h), colorGroup(),
(orientation() == TQt::Horizontal ? (orientation() == TQt::Horizontal ?
TQStyle::Style_Horizontal : 0)); TQStyle::Style_Horizontal : 0));
} }

@ -1122,7 +1122,7 @@ TQ_INT64 KMFolderMaildir::doFolderSize() const
item = new KFileItem( S_IFDIR, -1, location() + "/tmp" ); item = new KFileItem( S_IFDIR, -1, location() + "/tmp" );
list.append( item ); list.append( item );
s_DirSizeJobQueue.append( s_DirSizeJobQueue.append(
tqMakePair( TQGuardedPtr<const KMFolderMaildir>( this ), list ) ); qMakePair( TQGuardedPtr<const KMFolderMaildir>( this ), list ) );
// if there's only one entry in the queue then we can start // if there's only one entry in the queue then we can start
// a dirSizeJob right away // a dirSizeJob right away

@ -78,7 +78,7 @@ void KNoteButton::drawButton( TQPainter* p )
if ( !m_flat ) if ( !m_flat )
flags |= TQStyle::Style_MouseOver; flags |= TQStyle::Style_MouseOver;
style().tqdrawPrimitive( TQStyle::PE_ButtonTool, p, rect(), colorGroup(), flags ); style().drawPrimitive( TQStyle::PE_ButtonTool, p, rect(), colorGroup(), flags );
drawButtonLabel( p ); drawButtonLabel( p );
} }

@ -1558,7 +1558,7 @@ TQPair<ResourceCalendar *, TQString> ActionManager::viewSubResourceCalendar()
cV = mCalendarView->viewManager()->multiAgendaView()->selectedAgendaView(); cV = mCalendarView->viewManager()->multiAgendaView()->selectedAgendaView();
} }
if ( cV ) { if ( cV ) {
p = tqMakePair( cV->resourceCalendar(), cV->subResourceCalendar() ); p = qMakePair( cV->resourceCalendar(), cV->subResourceCalendar() );
} }
return p; return p;
} }

@ -357,7 +357,7 @@ TQPair<ResourceCalendar *, TQString> CalendarView::viewSubResourceCalendar()
cV = mViewManager->multiAgendaView()->selectedAgendaView(); cV = mViewManager->multiAgendaView()->selectedAgendaView();
} }
if ( cV ) { if ( cV ) {
p = tqMakePair( cV->resourceCalendar(), cV->subResourceCalendar() ); p = qMakePair( cV->resourceCalendar(), cV->subResourceCalendar() );
} }
return p; return p;
} }

@ -332,7 +332,7 @@ TQPair<TQDate,TQDate> DateNavigatorContainer::dateLimits( int offset )
TQPair<TQDate,TQDate> firstMonthBoundary = KODayMatrix::matrixLimits( firstMonth ); TQPair<TQDate,TQDate> firstMonthBoundary = KODayMatrix::matrixLimits( firstMonth );
TQPair<TQDate,TQDate> lastMonthBoundary = KODayMatrix::matrixLimits( lastMonth ); TQPair<TQDate,TQDate> lastMonthBoundary = KODayMatrix::matrixLimits( lastMonth );
return tqMakePair( firstMonthBoundary.first, lastMonthBoundary.second ); return qMakePair( firstMonthBoundary.first, lastMonthBoundary.second );
} }
#include "datenavigatorcontainer.moc" #include "datenavigatorcontainer.moc"

@ -274,7 +274,7 @@ void KOAgenda::init()
mClickedItem = 0; mClickedItem = 0;
mActionItem = 0; mActionItem = 0;
mResPair = tqMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); mResPair = qMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() );
mActionType = NOP; mActionType = NOP;
mItemMoved = false; mItemMoved = false;
@ -623,7 +623,7 @@ bool KOAgenda::eventFilter_mouse(TQObject *object, TQMouseEvent *me)
Incidence *incidence = item->incidence(); Incidence *incidence = item->incidence();
if ( incidence->isReadOnly() ) { if ( incidence->isReadOnly() ) {
mActionItem = 0; mActionItem = 0;
mResPair = tqMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); mResPair = qMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() );
} else { } else {
mActionItem = item; mActionItem = item;
mResPair = CalHelper::incSubResourceCalendar( mCalendar, incidence ); mResPair = CalHelper::incSubResourceCalendar( mCalendar, incidence );
@ -657,7 +657,7 @@ bool KOAgenda::eventFilter_mouse(TQObject *object, TQMouseEvent *me)
if ( !ptInSelection( gpos ) ) { if ( !ptInSelection( gpos ) ) {
selectItem(0); selectItem(0);
mActionItem = 0; mActionItem = 0;
mResPair = tqMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); mResPair = qMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() );
setCursor(arrowCursor); setCursor(arrowCursor);
startSelectAction(viewportPos); startSelectAction(viewportPos);
} }
@ -918,7 +918,7 @@ void KOAgenda::performItemAction(const TQPoint& viewportPos)
emit startDragSignal( mActionItem->incidence() ); emit startDragSignal( mActionItem->incidence() );
setCursor( arrowCursor ); setCursor( arrowCursor );
mActionItem = 0; mActionItem = 0;
mResPair = tqMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); mResPair = qMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() );
mActionType = NOP; mActionType = NOP;
mItemMoved = false; mItemMoved = false;
return; return;
@ -952,7 +952,7 @@ void KOAgenda::performItemAction(const TQPoint& viewportPos)
placeSubCells( mActionItem ); placeSubCells( mActionItem );
setCursor( arrowCursor ); setCursor( arrowCursor );
mActionItem = 0; mActionItem = 0;
mResPair = tqMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); mResPair = qMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() );
mActionType = NOP; mActionType = NOP;
mItemMoved = false; mItemMoved = false;
return; return;
@ -1192,7 +1192,7 @@ void KOAgenda::endItemAction()
} }
mActionItem = 0; mActionItem = 0;
mResPair = tqMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() ); mResPair = qMakePair( static_cast<ResourceCalendar *>( 0 ), TQString() );
mItemMoved = false; mItemMoved = false;
if ( multiModify ) { if ( multiModify ) {

@ -725,5 +725,5 @@ TQPair<TQDate,TQDate> KODayMatrix::matrixLimits( const TQDate &month )
d = d.addDays( -7 ); // Start on the second line d = d.addDays( -7 ); // Start on the second line
} }
return tqMakePair( d, d.addDays( NUMDAYS-1 ) ); return qMakePair( d, d.addDays( NUMDAYS-1 ) );
} }

@ -1065,7 +1065,7 @@ void KOTodoView::itemStateChanged( TQListViewItem *item )
void KOTodoView::setNewPercentageDelayed( KOTodoViewItem *item, int percentage ) void KOTodoView::setNewPercentageDelayed( KOTodoViewItem *item, int percentage )
{ {
mPercentChangedMap.append( tqMakePair( item, percentage ) ); mPercentChangedMap.append( qMakePair( item, percentage ) );
TQTimer::singleShot( 0, this, TQT_SLOT( processDelayedNewPercentage() ) ); TQTimer::singleShot( 0, this, TQT_SLOT( processDelayedNewPercentage() ) );
} }

@ -162,6 +162,6 @@ TQPair<ResourceCalendar *, TQString> CalHelper::incSubResourceCalendar( Calendar
if ( res && res->canHaveSubresources() ) { if ( res && res->canHaveSubresources() ) {
subRes = res->subresourceIdentifier( incidence ); subRes = res->subresourceIdentifier( incidence );
} }
p = tqMakePair( res, subRes ); p = qMakePair( res, subRes );
return p; return p;
} }

@ -1104,7 +1104,7 @@ bool parseParameter( const char* & scursor, const char * const send,
"Chopping away \"*\"." << endl; "Chopping away \"*\"." << endl;
maybeAttribute.truncate( maybeAttribute.length() - 1 ); maybeAttribute.truncate( maybeAttribute.length() - 1 );
} }
result = tqMakePair( maybeAttribute.lower(), TQStringOrTQPair() ); result = qMakePair( maybeAttribute.lower(), TQStringOrTQPair() );
return true; return true;
} }
@ -1128,19 +1128,19 @@ bool parseParameter( const char* & scursor, const char * const send,
if ( !parseGenericQuotedString( scursor, send, maybeValue.qstring, isCRLF ) ) { if ( !parseGenericQuotedString( scursor, send, maybeValue.qstring, isCRLF ) ) {
scursor = oldscursor; scursor = oldscursor;
result = tqMakePair( maybeAttribute.lower(), TQStringOrTQPair() ); result = qMakePair( maybeAttribute.lower(), TQStringOrTQPair() );
return false; // this case needs further processing by upper layers!! return false; // this case needs further processing by upper layers!!
} }
} else { } else {
// value is a token: // value is a token:
if ( !parseToken( scursor, send, maybeValue.qpair, false /* no 8bit */ ) ) { if ( !parseToken( scursor, send, maybeValue.qpair, false /* no 8bit */ ) ) {
scursor = oldscursor; scursor = oldscursor;
result = tqMakePair( maybeAttribute.lower(), TQStringOrTQPair() ); result = qMakePair( maybeAttribute.lower(), TQStringOrTQPair() );
return false; // this case needs further processing by upper layers!! return false; // this case needs further processing by upper layers!!
} }
} }
result = tqMakePair( maybeAttribute.lower(), maybeValue ); result = qMakePair( maybeAttribute.lower(), maybeValue );
return true; return true;
} }

@ -763,7 +763,7 @@ void AddresseeLineEdit::addCompletionItem( const TQString& string, int weight, i
weight = TQMAX( ( *it ).first, weight ); weight = TQMAX( ( *it ).first, weight );
( *it ).first = weight; ( *it ).first = weight;
} else { } else {
s_completionItemMap->insert( string, tqMakePair( weight, completionItemSource ) ); s_completionItemMap->insert( string, qMakePair( weight, completionItemSource ) );
} }
if ( keyWords == 0 ) if ( keyWords == 0 )
s_completion->addItem( string, weight ); s_completion->addItem( string, weight );

@ -44,7 +44,7 @@ static ParseList parseCustom( const TQString& str )
Q_ASSERT( helpList.count() < 3 ); // 1 or 2 items, but not more Q_ASSERT( helpList.count() < 3 ); // 1 or 2 items, but not more
const TQString uid = helpList.first(); const TQString uid = helpList.first();
const TQString email = helpList.last(); const TQString email = helpList.last();
res.append( tqMakePair( uid, email ) ); res.append( qMakePair( uid, email ) );
} }
return res; return res;
} }

@ -711,7 +711,7 @@ bool ResourceKolab::addIncidence( KCal::Incidence* incidence, const TQString& _s
/* Will be needed when kmail triggers a delete, so we don't delete the inocent /* Will be needed when kmail triggers a delete, so we don't delete the inocent
* incidence that's sharing the uid with this one */ * incidence that's sharing the uid with this one */
mOriginalUID2fakeUID[tqMakePair( incidence->schedulingID(), subResource )] = uid; mOriginalUID2fakeUID[qMakePair( incidence->schedulingID(), subResource )] = uid;
} }
} }
/* Add to the cache if the add didn't come from KOrganizer, in which case /* Add to the cache if the add didn't come from KOrganizer, in which case

Loading…
Cancel
Save