Rename a number of classes to enhance compatibility with KDE4

pull/1/head
Timothy Pearson 12 years ago
parent 21d0413b17
commit a45915945e

@ -62,7 +62,7 @@ ProgressDialog::ProgressDialog( TQWidget* parent, const char* name, WFlags fl )
buttonCancel = new KPushButton( i18n("&Cancel"), this );
display = new KListView( this );
display = new TDEListView( this );
display->addColumn( i18n("Messages") );
display->addColumn( "sort" );
display->setColumnWidthMode( 0, TQListView::Maximum );
@ -77,7 +77,7 @@ ProgressDialog::ProgressDialog( TQWidget* parent, const char* name, WFlags fl )
buttonUndo->setText( i18n("&Undo") );
buttonUndo->setEnabled( false );
mnuButton = new KPopupMenu( this );
mnuButton = new TDEPopupMenu( this );
mnuButton->insertItem( i18n("Restart KRename..."), this, TQT_SLOT( restart() ));
mnuButton->insertSeparator();
mnuButton->insertItem( i18n("Rename Processed Files &Again..."), this, TQT_SLOT( again() ), 0, MNU_DONE_ID );
@ -143,7 +143,7 @@ void ProgressDialog::print( TQString text, TQString pixmap )
if( pixmap.isNull() )
pixmap = "ok";
KListViewItem* item = new KListViewItem( display, text, count() );
TDEListViewItem* item = new TDEListViewItem( display, text, count() );
item->setPixmap( 0, SmallIcon(pixmap) );
display->insertItem( item );
}
@ -157,7 +157,7 @@ void ProgressDialog::error( TQString text )
}
//TODO: simplify this (breaks i18n)
KListViewItem* item = new KListViewItem( display, TQString( i18n("Error: %1") ).arg( TQString() ) + simplify( text ), count() );
TDEListViewItem* item = new TDEListViewItem( display, TQString( i18n("Error: %1") ).arg( TQString() ) + simplify( text ), count() );
item->setPixmap( 0, SmallIcon("cancel") );
display->insertItem( item );
}
@ -170,7 +170,7 @@ void ProgressDialog::warning( TQString text )
m_timer->start( TIMER_INTERVAL );
}
KListViewItem* item = new KListViewItem( display, TQString( i18n("Warning: %1") ).arg( TQString() ) + simplify( text ), count() );
TDEListViewItem* item = new TDEListViewItem( display, TQString( i18n("Warning: %1") ).arg( TQString() ) + simplify( text ), count() );
item->setPixmap( 0, SmallIcon("idea") );
display->insertItem( item );
}

@ -31,8 +31,8 @@ typedef struct RenamedList
};
class KRenameImpl;
class KListView;
class KPopupMenu;
class TDEListView;
class TDEPopupMenu;
class KPushButton;
class TQProgressBar;
class TQStringList;
@ -91,13 +91,13 @@ class ProgressDialog : public TQWidget
TQTimer* m_timer;
KListView* display;
TDEListView* display;
KPushButton* buttonClose;
KPushButton* buttonRestart;
KPushButton* buttonOpenDest;
KPushButton* buttonUndo;
KPushButton* buttonCancel;
KPopupMenu* mnuButton;
TDEPopupMenu* mnuButton;
TQProgressBar* bar;

@ -88,7 +88,7 @@ void CommandPlugin::drawInterface( TQWidget* w, TQVBoxLayout* l )
vb->addLayout( hb );
list = new KListBox( w );
list = new TDEListBox( w );
vb->addWidget( list );
vb->setStretchFactor( list, 2 );
l->addLayout( vb );

@ -25,7 +25,7 @@
class TQCheckBox;
class KLineEdit;
class KListBox;
class TDEListBox;
class KPushButton;
class CommandPlugin : public Plugin {
Q_OBJECT
@ -52,7 +52,7 @@ class CommandPlugin : public Plugin {
private:
KLineEdit* commandline;
TQCheckBox* checkNoBlock;
KListBox* list;
TDEListBox* list;
KPushButton* buttonAdd;
KPushButton* buttonRemove;

@ -139,8 +139,8 @@ void FilePlugin::drawInterface( TQWidget* w, TQVBoxLayout* l )
l->addWidget( new TQLabel( m_comment, w ) );
l->addWidget( new TQLabel( i18n("Supported tokens:"), w ) );
KListBox* list = new KListBox( w );
list->setColumnMode( KListBox::FitToWidth );
TDEListBox* list = new TDEListBox( w );
list->setColumnMode( TDEListBox::FitToWidth );
for( unsigned int i = 0; i < keys.count(); i++ )
list->insertItem( "[" + keys[i] + "]" );

@ -77,7 +77,7 @@ HelpDialog::HelpDialog( HelpDialogData* data, TQWidget* parent,
comboHeadline = new TQComboBox( FALSE, this, "comboHeadline" );
HelpDialogLayout->addWidget( comboHeadline );
list = new KListView( this, "list" );
list = new TDEListView( this, "list" );
list->addColumn( i18n( "Token" ) );
list->addColumn( i18n( "Description" ) );
HelpDialogLayout->addWidget( list );
@ -132,7 +132,7 @@ void HelpDialog::updateItems()
for( unsigned int i = 0; i < items.count(); i++ ) {
TQString tmp = items[i];
new KListViewItem( list, tmp.section( ";;", 0, 0 ), tmp.section( ";;", 1, 1 ) );
new TDEListViewItem( list, tmp.section( ";;", 0, 0 ), tmp.section( ";;", 1, 1 ) );
}
}

@ -29,7 +29,7 @@ class TQGridLayout;
class TQComboBox;
class TQLineEdit;
class TQPixmap;
class KListView;
class TDEListView;
class KPushButton;
class HelpDialogData : public TQObject {
@ -92,7 +92,7 @@ class HelpDialog : public TQDialog
private:
TQComboBox* comboHeadline;
KListView* list;
TDEListView* list;
KPushButton* buttonAdd;
KPushButton* buttonClose;

@ -44,7 +44,7 @@
using namespace TDEIO;
KMyListBox::KMyListBox(TQWidget* parent, const char* name, WFlags fl)
:KListBox(parent, name, fl)
:TDEListBox(parent, name, fl)
{
m_running_lister_counter = 0;
@ -86,7 +86,7 @@ void KMyListBox::setPreviewSize( int size )
void KMyListBox::removeItem( int index )
{
KListBox::removeItem( index );
TDEListBox::removeItem( index );
}
void KMyListBox::addFile( const KURL & filename, bool isfile )
@ -201,7 +201,7 @@ void KMyListBox::viewportMousePressEvent( TQMouseEvent* e )
if( moving )
move( index( itemAt( e->pos() ) ) );
else {
KListBox::viewportMousePressEvent( e );
TDEListBox::viewportMousePressEvent( e );
TQPoint p( e->pos() );
TQListBoxItem *i = itemAt( p );
if ( i ) {
@ -226,13 +226,13 @@ void KMyListBox::viewportMouseMoveEvent( TQMouseEvent* e )
ud->drag();
}
} else
KListBox::viewportMouseMoveEvent( e );
TDEListBox::viewportMouseMoveEvent( e );
}
void KMyListBox::viewportMouseReleaseEvent( TQMouseEvent* e )
{
mousePressed = FALSE;
KListBox::viewportMouseReleaseEvent( e );
TDEListBox::viewportMouseReleaseEvent( e );
}
void KMyListBox::keyPressEvent( TQKeyEvent* e )
@ -697,13 +697,13 @@ const TQString KMyListBox::findNumInString( unsigned int pos, const TQString & s
void KMyListBox::resizeEvent( TQResizeEvent* e )
{
KListBox::resizeEvent( e );
TDEListBox::resizeEvent( e );
positionLabel();
}
void KMyListBox::clear()
{
KListBox::clear();
TDEListBox::clear();
positionLabel();
}
@ -726,7 +726,7 @@ void KMyListBox::paintEvent( TQPaintEvent* e )
{
// tqDebug("Updates=%i", (int)isUpdatesEnabled() );
//if( isUpdatesEnabled() )
KListBox::paintEvent( e );
TDEListBox::paintEvent( e );
}
KMyListBoxItem::KMyListBoxItem( const KMyListBoxItem* item )

@ -35,7 +35,7 @@ class TQDragObject;
class TQPixmap;
class TQPainter;
class TQPoint;
class KMyListBox : public KListBox {
class KMyListBox : public TDEListBox {
Q_OBJECT
public:

@ -25,7 +25,7 @@
#include <krun.h>
KMyListView::KMyListView( TQValueList<manualchanges>* _changes, KMyListBox* _list, TQWidget* parent, const char* name )
:KListView(parent, name )
:TDEListView(parent, name )
{
changes = _changes;
list = _list;
@ -75,7 +75,7 @@ void KMyListView::changeItem( TQListViewItem* item, const TQPoint&, int )
void KMyListView::showContext( TQListViewItem* item, const TQPoint& pos, int )
{
KPopupMenu* menu = new KPopupMenu( this );
TDEPopupMenu* menu = new TDEPopupMenu( this );
if(item) {
menu->insertTitle( list->text( itemIndex( item ) ), 0, 0 );
menu->insertItem( i18n("&Change Filename Manually"), this, TQT_SLOT( changeCurrentItem() ), Key_F2 );
@ -115,25 +115,25 @@ void KMyListView::openCurrent()
/////////////////////////////////////////////////////////////
KMyListViewItem::KMyListViewItem(TQListView *parent)
: KListViewItem(parent)
: TDEListViewItem(parent)
{ }
KMyListViewItem::KMyListViewItem(TQListViewItem *parent)
: KListViewItem(parent)
: TDEListViewItem(parent)
{ }
KMyListViewItem::KMyListViewItem(TQListView *parent, TQListViewItem *after)
: KListViewItem(parent, after)
: TDEListViewItem(parent, after)
{ }
KMyListViewItem::KMyListViewItem(TQListViewItem *parent, TQListViewItem *after)
: KListViewItem(parent, after)
: TDEListViewItem(parent, after)
{ }
KMyListViewItem::KMyListViewItem(bool m, TQListView *parent,
TQString label1, TQString label2, TQString label3, TQString label4,
TQString label5, TQString label6, TQString label7, TQString label8)
: KListViewItem(parent, label1, label2, label3, label4, label5, label6, label7, label8)
: TDEListViewItem(parent, label1, label2, label3, label4, label5, label6, label7, label8)
{
modified = m;
}
@ -141,7 +141,7 @@ KMyListViewItem::KMyListViewItem(bool m, TQListView *parent,
KMyListViewItem::KMyListViewItem(bool m, TQListViewItem *parent,
TQString label1, TQString label2, TQString label3, TQString label4,
TQString label5, TQString label6, TQString label7, TQString label8)
: KListViewItem(parent, label1, label2, label3, label4, label5, label6, label7, label8)
: TDEListViewItem(parent, label1, label2, label3, label4, label5, label6, label7, label8)
{
modified = m;
}
@ -149,7 +149,7 @@ KMyListViewItem::KMyListViewItem(bool m, TQListViewItem *parent,
KMyListViewItem::KMyListViewItem(bool m, TQListView *parent, TQListViewItem *after,
TQString label1, TQString label2, TQString label3, TQString label4,
TQString label5, TQString label6, TQString label7, TQString label8)
: KListViewItem(parent, after, label1, label2, label3, label4, label5, label6, label7, label8)
: TDEListViewItem(parent, after, label1, label2, label3, label4, label5, label6, label7, label8)
{
modified = m;
}
@ -157,7 +157,7 @@ KMyListViewItem::KMyListViewItem(bool m, TQListView *parent, TQListViewItem *aft
KMyListViewItem::KMyListViewItem(TQListViewItem *parent, TQListViewItem *after,
TQString label1, TQString label2, TQString label3, TQString label4,
TQString label5, TQString label6, TQString label7, TQString label8)
: KListViewItem(parent, after, label1, label2, label3, label4, label5, label6, label7, label8)
: TDEListViewItem(parent, after, label1, label2, label3, label4, label5, label6, label7, label8)
{ }
KMyListViewItem::~KMyListViewItem()
@ -171,7 +171,7 @@ void KMyListViewItem::paintCell( TQPainter *p, const TQColorGroup &cg,
if( modified )
_cg.setColor( TQColorGroup::Text, TQt::red );
KListViewItem::paintCell( p, _cg, column, width, alignment );
TDEListViewItem::paintCell( p, _cg, column, width, alignment );
_cg.setColor( TQColorGroup::Text, c );
}

@ -24,7 +24,7 @@
#include <tqvaluelist.h>
class TQMouseEvent;
class KMyListView : public KListView {
class KMyListView : public TDEListView {
Q_OBJECT
public:
@ -52,7 +52,7 @@ class KMyListView : public KListView {
/////////////////////////////////////////////////////////////
class TQColor;
class TQString;
class KMyListViewItem : public KListViewItem {
class KMyListViewItem : public TDEListViewItem {
public:
KMyListViewItem(TQListView *parent);
KMyListViewItem(TQListViewItem *parent);

@ -293,10 +293,10 @@ void KRenameImpl::parseCommandline()
void KRenameImpl::setupActions()
{
KActionCollection* actionCollection = new KActionCollection( this );
TDEActionCollection* actionCollection = new TDEActionCollection( this );
KPopupMenu* mnuExtra = new KPopupMenu( parent );
KPopupMenu* mnuSettings = new KPopupMenu( parent );
TDEPopupMenu* mnuExtra = new TDEPopupMenu( parent );
TDEPopupMenu* mnuSettings = new TDEPopupMenu( parent );
KHelpMenu* mnuHelp = new KHelpMenu( parent );
menuBar->insertItem( i18n("E&xtras"), mnuExtra );
@ -307,9 +307,9 @@ void KRenameImpl::setupActions()
menuBar->insertSeparator();
menuBar->insertItem( i18n("&Help"), mnuHelp->menu() );
KAction* prefAct = KStdAction::preferences( this, TQT_SLOT(preferences()), actionCollection );
loadPlugins = new KAction( i18n("&Load TDE file plugins"), 0, this, TQT_SLOT( loadFilePlugins() ), actionCollection );
KAction* reloadAct = new KAction( i18n("&Reload Plugin Data"), 0, this, TQT_SLOT( reloadFilePluginData() ), actionCollection );
TDEAction* prefAct = KStdAction::preferences( this, TQT_SLOT(preferences()), actionCollection );
loadPlugins = new TDEAction( i18n("&Load TDE file plugins"), 0, this, TQT_SLOT( loadFilePlugins() ), actionCollection );
TDEAction* reloadAct = new TDEAction( i18n("&Reload Plugin Data"), 0, this, TQT_SLOT( reloadFilePluginData() ), actionCollection );
prefAct->plug( mnuSettings );
mnuSettings->insertSeparator();

@ -24,16 +24,16 @@
class HelpDialog;
class HelpDialogData;
class KAction;
class TDEAction;
class KComboBox;
class KJanusWidget;
class KMyHistoryCombo;
class KMyListBox;
class KMyListView;
class KMenuBar;
class KPopupMenu;
class TDEPopupMenu;
class KPushButton;
class KToggleAction;
class TDEToggleAction;
class KURL;
class KURLRequester;
class KIntNumInput;
@ -197,8 +197,8 @@ class KRenameImpl : public TQObject, public KRenameDCOP {
protected:
TQWidget* parent;
KMenuBar* menuBar;
KPopupMenu* mnuSort;
KAction* loadPlugins;
TDEPopupMenu* mnuSort;
TDEAction* loadPlugins;
TQPushButton* finishButton;

@ -71,7 +71,7 @@ NumberDialog::NumberDialog(TQValueList<int> & n,TQWidget *parent )
TQHBoxLayout* group2Layout = new TQHBoxLayout( group2->layout() );
group2Layout->setAlignment( TQt::AlignTop );
listNumbers = new KListBox( group2 );
listNumbers = new TDEListBox( group2 );
buttonAdd = new KPushButton( group2 );
buttonAdd->setText( i18n( "&Add Number" ) );

@ -42,7 +42,7 @@ class KMyIntSpinBox : public KIntSpinBox
class TQCheckBox;
class KIntNumInput;
class KListBox;
class TDEListBox;
class KPushButton;
class NumberDialog : public KDialogBase {
Q_OBJECT
@ -67,7 +67,7 @@ class NumberDialog : public KDialogBase {
private:
void sort();
KListBox* listNumbers;
TDEListBox* listNumbers;
KPushButton* buttonAdd;
KPushButton* buttonRemove;
KMyIntSpinBox* spinNumber;

@ -400,7 +400,7 @@ ProfileDlg::ProfileDlg(KRenameImpl* krename, TQWidget *parent, const char *name)
TQHBoxLayout* layout = new TQHBoxLayout( plainPage(), 6, 6 );
TQVBoxLayout* button = new TQVBoxLayout( 0, 6, 6 );
profiles = new KListBox( plainPage() );
profiles = new TDEListBox( plainPage() );
profiles->insertItem( new ProfileListBoxText( PROFILE_WIZARD_NAME ), PROFILE_WIZARD_INDEX );
profiles->insertItem( new ProfileListBoxText( PROFILE_TABBED_NAME ), PROFILE_TABBED_INDEX );

@ -20,7 +20,7 @@
#include <kdialogbase.h>
class KListBox;
class TDEListBox;
class KPushButton;
class KRenameImpl;
class TQCheckBox;
@ -69,7 +69,7 @@ class ProfileDlg : public KDialogBase, public ProfileManager
void slotHidden();
private:
KListBox* profiles;
TDEListBox* profiles;
TQCheckBox* checkDefault;
KPushButton* createProfile;

@ -41,7 +41,7 @@ ReplaceDialog::ReplaceDialog( TQValueList<replacestrings> & r, TQWidget* parent
{
ReplaceDialogLayout = new TQGridLayout( plainPage(), 11, 6);
list = new KListView( plainPage() );
list = new TDEListView( plainPage() );
list->addColumn( i18n("Find") );
list->addColumn( i18n("Replace With") );
list->addColumn( i18n("Regular Expression") );
@ -111,7 +111,7 @@ ReplaceDialog::ReplaceDialog( TQValueList<replacestrings> & r, TQWidget* parent
BatchRenamer::unEscape( rs.find );
KListViewItem* item = new KListViewItem( list );
TDEListViewItem* item = new TDEListViewItem( list );
item->setText( 0, encode( rs.find ) );
item->setText( 1, encode( rs.replace ) );
item->setText( 2, rs.reg ? i18n("yes") : i18n("no") );
@ -141,7 +141,7 @@ void ReplaceDialog::add()
it = it->nextSibling();
}
KListViewItem* item = new KListViewItem( list, i18n("Regular expression") );
TDEListViewItem* item = new TDEListViewItem( list, i18n("Regular expression") );
item->setText( 0, encode( text1->text() ) );
item->setText( 1, encode( text2->text() ) );
item->setText( 2, checkReg->isChecked() ? i18n("yes") : i18n("no") );

@ -32,7 +32,7 @@ class TQLabel;
class TQLineEdit;
class KPushButton;
class TQListViewItem;
class KListView;
class TDEListView;
class ReplaceDialog : public KDialogBase
{
Q_OBJECT
@ -59,7 +59,7 @@ class ReplaceDialog : public KDialogBase
TQLineEdit* text2;
TQLabel* TextLabel2;
TQLineEdit* text1;
KListView* list;
TDEListView* list;
TQCheckBox* checkReg;
KPushButton* buttonAdd;

Loading…
Cancel
Save