summaryrefslogtreecommitdiffstats
path: root/src/kprocessorview.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/kprocessorview.cpp')
-rwxr-xr-xsrc/kprocessorview.cpp66
1 files changed, 33 insertions, 33 deletions
diff --git a/src/kprocessorview.cpp b/src/kprocessorview.cpp
index f54469a..717bfa2 100755
--- a/src/kprocessorview.cpp
+++ b/src/kprocessorview.cpp
@@ -1,32 +1,32 @@
#include "kprocessorview.h"
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qscrollview.h>
-#include <qsize.h>
-#include <qmessagebox.h>
-#include <qpopupmenu.h>
-#include <qcursor.h>
-
-MyListView::MyListView(QWidget *parent) : KListView(parent)
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqscrollview.h>
+#include <tqsize.h>
+#include <tqmessagebox.h>
+#include <tqpopupmenu.h>
+#include <tqcursor.h>
+
+MyListView::MyListView(TQWidget *tqparent) : KListView(tqparent)
{
- connect( this, SIGNAL( contextMenu( KListView *, QListViewItem *, const QPoint & ) ),
- SLOT( slotContextMenu( KListView *, QListViewItem *, const QPoint & ) ) );
+ connect( this, TQT_SIGNAL( contextMenu( KListView *, TQListViewItem *, const TQPoint & ) ),
+ TQT_SLOT( slotContextMenu( KListView *, TQListViewItem *, const TQPoint & ) ) );
}
MyListView::~MyListView()
{
}
-void MyListView::slotContextMenu( KListView *, QListViewItem *, const QPoint & )
+void MyListView::slotContextMenu( KListView *, TQListViewItem *, const TQPoint & )
{
// mousePressEvent( NULL ) ;
emit showPopupMenu() ;
}
/*
-void MyListView::mousePressEvent( QMouseEvent * event )
+void MyListView::mousePressEvent( TQMouseEvent * event )
{
- //QMessageBox::information( this, "information", "mouse pressed" ) ;
+ //TQMessageBox::information( this, "information", "mouse pressed" ) ;
// if ( event->button() == RightButton )
emit showPopupMenu() ;
@@ -35,15 +35,15 @@ void MyListView::mousePressEvent( QMouseEvent * event )
}
*/
-KProcessorView::KProcessorView(QWidget *parent, const char *name)
- : KToolBar(parent)
+KProcessorView::KProcessorView(TQWidget *tqparent, const char *name)
+ : KToolBar(tqparent)
{
name = name ; // avoid compiler warning
view = new MyListView( this ) ;
- connect( view, SIGNAL( itemRenamed( QListViewItem*) ), this, SLOT( slotItemRenamed(QListViewItem*) ) ) ;
- connect( view, SIGNAL( showPopupMenu() ), this, SLOT( showPopupMenu() ) ) ;
+ connect( view, TQT_SIGNAL( itemRenamed( TQListViewItem*) ), this, TQT_SLOT( slotItemRenamed(TQListViewItem*) ) ) ;
+ connect( view, TQT_SIGNAL( showPopupMenu() ), this, TQT_SLOT( showPopupMenu() ) ) ;
view->addColumn( "Register" ) ;
view->addColumn( "Value" ) ;
@@ -57,29 +57,29 @@ KProcessorView::KProcessorView(QWidget *parent, const char *name)
int i ;
char str[ 128 ] ;
- QListViewItem *cpu = new QListViewItem( view ) ;
+ TQListViewItem *cpu = new TQListViewItem( view ) ;
cpu->setText( 0, "CPU" ) ;
- QListViewItem *flags = new QListViewItem( cpu ) ;
+ TQListViewItem *flags = new TQListViewItem( cpu ) ;
flags->setText( 0, "Flags" ) ;
- zeroFlag = new QListViewItem( flags ) ;
+ zeroFlag = new TQListViewItem( flags ) ;
zeroFlag->setText( 0, "Zero" ) ;
zeroFlag->setText( 1, "0" ) ;
- carryFlag = new QListViewItem( flags ) ;
+ carryFlag = new TQListViewItem( flags ) ;
carryFlag->setText( 0, "Carry" ) ;
carryFlag->setText( 1, "0" ) ;
- ieFlag = new QListViewItem( flags ) ;
+ ieFlag = new TQListViewItem( flags ) ;
ieFlag->setText( 0, "IE" ) ;
ieFlag->setText( 1, "0" ) ;
- QListViewItem *reg = new QListViewItem( cpu ) ;
+ TQListViewItem *reg = new TQListViewItem( cpu ) ;
reg->setText( 0, "Registers" ) ;
for ( i = 0 ; i < 16 ; i++ ) {
- regs[ i ] = new QListViewItem( reg ) ;
+ regs[ i ] = new TQListViewItem( reg ) ;
sprintf( str, "s%X", i ) ;
regs[ i ]->setText( 0, str ) ;
regs[ i ]->setText( 1, "0" ) ;
@@ -103,13 +103,13 @@ void KProcessorView::slotHexMode()
void KProcessorView::showPopupMenu()
{
- QPopupMenu *menu = new QPopupMenu( this ) ;
- menu->insertItem( "Hexadecimal", this, SLOT( slotHexMode() ), 0, 1 ) ;
+ TQPopupMenu *menu = new TQPopupMenu( this ) ;
+ menu->insertItem( "Hexadecimal", this, TQT_SLOT( slotHexMode() ), 0, 1 ) ;
menu->setItemChecked( 1, m_bHexMode ) ;
- menu->exec( QCursor::pos() );
+ menu->exec( TQCursor::pos() );
}
-void KProcessorView::slotItemRenamed( QListViewItem * item )
+void KProcessorView::slotItemRenamed( TQListViewItem * item )
{
int i, value, base ;
bool ok ;
@@ -125,7 +125,7 @@ void KProcessorView::slotItemRenamed( QListViewItem * item )
value = item->text(1).toInt( &ok, base ) ;
if ( !ok || value < 0 || value > 255 ) {
- QMessageBox::warning( parentWidget(), "Modify register", "Value should be between 0-255" ) ;
+ TQMessageBox::warning( tqparentWidget(), "Modify register", "Value should be between 0-255" ) ;
view->rename( item, 1 ) ;
} else {
emit processorRegsChanged() ;
@@ -137,13 +137,13 @@ void KProcessorView::slotItemRenamed( QListViewItem * item )
if ( zeroFlag == item || carryFlag == item || ieFlag == item ) {
value = item->text(1).toInt( &ok ) ;
if ( !ok || value < 0 || value > 1 ) {
- QMessageBox::warning( parentWidget(), "Modify flag", "Value should be between 0-1" ) ;
+ TQMessageBox::warning( tqparentWidget(), "Modify flag", "Value should be between 0-1" ) ;
} else
emit processorFlagsChanged() ;
}
}
-void KProcessorView::resizeEvent( QResizeEvent *event )
+void KProcessorView::resizeEvent( TQResizeEvent *event )
{
event = event ;
// view->resize( width() - 10, height() - 10 ) ;
@@ -169,7 +169,7 @@ void KProcessorView::setRegisterValues( unsigned char *values )
if ( m_bHexMode ) base = 16 ;
else base = 10 ;
- QString str;
+ TQString str;
for ( i = 0 ; i < 16 ; i++ ) {
str.setNum( values[ i ], base ) ;
regs[ i ]->setText( 1, str ) ;