summaryrefslogtreecommitdiffstats
path: root/languages/cpp/debugger/memviewdlg.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'languages/cpp/debugger/memviewdlg.cpp')
-rw-r--r--languages/cpp/debugger/memviewdlg.cpp138
1 files changed, 69 insertions, 69 deletions
diff --git a/languages/cpp/debugger/memviewdlg.cpp b/languages/cpp/debugger/memviewdlg.cpp
index 5316aa91..6d700233 100644
--- a/languages/cpp/debugger/memviewdlg.cpp
+++ b/languages/cpp/debugger/memviewdlg.cpp
@@ -26,15 +26,15 @@
#include <kdebug.h>
#include <kiconloader.h>
-#include <qlabel.h>
-#include <qlayout.h>
-#include <qmultilineedit.h>
-#include <qpushbutton.h>
-#include <qvariant.h>
-#include <qpopupmenu.h>
-#include <qhbox.h>
-#include <qtoolbox.h>
-#include <qtextedit.h>
+#include <tqlabel.h>
+#include <tqlayout.h>
+#include <tqmultilineedit.h>
+#include <tqpushbutton.h>
+#include <tqvariant.h>
+#include <tqpopupmenu.h>
+#include <tqhbox.h>
+#include <tqtoolbox.h>
+#include <tqtextedit.h>
#include <kmessagebox.h>
@@ -76,28 +76,28 @@ namespace GDBDebugger
public:
KLineEdit* startAddressLineEdit;
KLineEdit* amountLineEdit;
- QPushButton* okButton;
- QPushButton* cancelButton;
+ TQPushButton* okButton;
+ TQPushButton* cancelButton;
- MemoryRangeSelector(QWidget* parent)
- : QWidget(parent)
+ MemoryRangeSelector(TQWidget* parent)
+ : TQWidget(parent)
{
- QVBoxLayout* l = new QVBoxLayout(this);
+ TQVBoxLayout* l = new TQVBoxLayout(this);
// Grid layout: labels + address field
- QGridLayout* gl = new QGridLayout(l);
+ TQGridLayout* gl = new TQGridLayout(l);
gl->setColSpacing(0, 2);
gl->setColSpacing(1, 4);
gl->setRowSpacing(1, 2);
- QLabel* l1 = new QLabel(i18n("Start"), this);
+ TQLabel* l1 = new TQLabel(i18n("Start"), this);
gl->addWidget(l1, 0, 1);
startAddressLineEdit = new KLineEdit(this);
gl->addWidget(startAddressLineEdit, 0, 3);
- QLabel* l2 = new QLabel(i18n("Amount"), this);
+ TQLabel* l2 = new TQLabel(i18n("Amount"), this);
gl->addWidget(l2, 2, 1);
amountLineEdit = new KLineEdit(this);
@@ -105,30 +105,30 @@ namespace GDBDebugger
l->addSpacing(2);
- QHBoxLayout* hb = new QHBoxLayout(l);
+ TQHBoxLayout* hb = new TQHBoxLayout(l);
hb->addStretch();
- okButton = new QPushButton(i18n("OK"), this);
+ okButton = new TQPushButton(i18n("OK"), this);
hb->addWidget(okButton);
- cancelButton = new QPushButton(i18n("Cancel"), this);
+ cancelButton = new TQPushButton(i18n("Cancel"), this);
hb->addWidget(cancelButton);
l->addSpacing(2);
- connect(startAddressLineEdit, SIGNAL(returnPressed()),
- okButton, SLOT(animateClick()));
+ connect(startAddressLineEdit, TQT_SIGNAL(returnPressed()),
+ okButton, TQT_SLOT(animateClick()));
- connect(amountLineEdit, SIGNAL(returnPressed()),
- okButton, SLOT(animateClick()));
+ connect(amountLineEdit, TQT_SIGNAL(returnPressed()),
+ okButton, TQT_SLOT(animateClick()));
}
};
MemoryView::MemoryView(GDBController* controller,
- QWidget* parent, const char* name)
- : QWidget(parent, name),
+ TQWidget* parent, const char* name)
+ : TQWidget(parent, name),
controller_(controller),
// New memory view can be created only when debugger is active,
// so don't set s_appNotStarted here.
@@ -147,7 +147,7 @@ namespace GDBDebugger
void MemoryView::initWidget()
{
- QVBoxLayout *l = new QVBoxLayout(this, 0, 0);
+ TQVBoxLayout *l = new TQVBoxLayout(this, 0, 0);
khexedit2_widget = KHE::createBytesEditWidget(this);
@@ -155,22 +155,22 @@ namespace GDBDebugger
if (khexedit2_widget)
{
- QWidget* real_widget = (QWidget*)
+ TQWidget* real_widget = (TQWidget*)
khexedit2_widget->child("BytesEdit");
if (real_widget)
{
ok_ = true;
- connect(real_widget, SIGNAL(bufferChanged(int, int)),
- this, SLOT(memoryEdited(int, int)));
+ connect(real_widget, TQT_SIGNAL(bufferChanged(int, int)),
+ this, TQT_SLOT(memoryEdited(int, int)));
khexedit2_real_widget = real_widget;
- QVariant resize_style(2); // full size usage.
+ TQVariant resize_style(2); // full size usage.
real_widget->setProperty("ResizeStyle", resize_style);
- //QVariant group(8);
+ //TQVariant group(8);
//real_widget->setProperty("StartOffset", start);
//real_widget->setProperty("NoOfBytesPerLine", group);
@@ -179,10 +179,10 @@ namespace GDBDebugger
// 3 -- binary
// 1 -- decimal
// 0 -- hex
- //QVariant coding(3);
+ //TQVariant coding(3);
//real_widget->setProperty("Coding", coding);
- //QVariant gap(32);
+ //TQVariant gap(32);
//real_widget->setProperty("BinaryGapWidth", gap);
}
@@ -197,28 +197,28 @@ namespace GDBDebugger
rangeSelector_ = new MemoryRangeSelector(this);
l->addWidget(rangeSelector_);
- connect(rangeSelector_->okButton, SIGNAL(clicked()),
- this, SLOT(slotChangeMemoryRange()));
+ connect(rangeSelector_->okButton, TQT_SIGNAL(clicked()),
+ this, TQT_SLOT(slotChangeMemoryRange()));
- connect(rangeSelector_->cancelButton, SIGNAL(clicked()),
- this, SLOT(slotHideRangeDialog()));
+ connect(rangeSelector_->cancelButton, TQT_SIGNAL(clicked()),
+ this, TQT_SLOT(slotHideRangeDialog()));
connect(rangeSelector_->startAddressLineEdit,
- SIGNAL(textChanged(const QString&)),
+ TQT_SIGNAL(textChanged(const TQString&)),
this,
- SLOT(slotEnableOrDisable()));
+ TQT_SLOT(slotEnableOrDisable()));
connect(rangeSelector_->amountLineEdit,
- SIGNAL(textChanged(const QString&)),
+ TQT_SIGNAL(textChanged(const TQString&)),
this,
- SLOT(slotEnableOrDisable()));
+ TQT_SLOT(slotEnableOrDisable()));
l->addWidget(khexedit2_widget);
} else {
- QTextEdit* edit = new QTextEdit(this);
+ TQTextEdit* edit = new TQTextEdit(this);
l->addWidget(edit);
edit->setText(
@@ -257,12 +257,12 @@ namespace GDBDebugger
this, &MemoryView::sizeComputed));
}
- void MemoryView::sizeComputed(const QString& size)
+ void MemoryView::sizeComputed(const TQString& size)
{
controller_->addCommand(
new
GDBCommand(
- QString("-data-read-memory %1 x 1 1 %2")
+ TQString("-data-read-memory %1 x 1 1 %2")
.arg(rangeSelector_->startAddressLineEdit->text())
.arg(size).ascii(),
this,
@@ -279,7 +279,7 @@ namespace GDBDebugger
amountAsString_ = rangeSelector_->amountLineEdit->text();
start_ = startAsString_.toUInt(0, 0);
- setCaption(QString("%1 (%2 bytes)")
+ setCaption(TQString("%1 (%2 bytes)")
.arg(startAsString_).arg(amount_));
emit captionChanged(caption());
@@ -302,10 +302,10 @@ namespace GDBDebugger
// inserting new data.
bytesEditor->setOverwriteOnly( true );
- QVariant start_v(start_);
+ TQVariant start_v(start_);
khexedit2_real_widget->setProperty("FirstLineOffset", start_v);
- //QVariant bsw(0);
+ //TQVariant bsw(0);
//khexedit2_real_widget->setProperty("ByteSpacingWidth", bsw);
// HACK: use hardcoded constant taht should match
@@ -313,7 +313,7 @@ namespace GDBDebugger
// 3 -- binary
// 1 -- decimal
// 0 -- hex
- //QVariant coding(1);
+ //TQVariant coding(1);
//khexedit2_real_widget->setProperty("Coding", coding);
@@ -327,19 +327,19 @@ namespace GDBDebugger
{
controller_->addCommand(
new GDBCommand(
- QString("set *(char*)(%1 + %2) = %3")
+ TQString("set *(char*)(%1 + %2) = %3")
.arg(start_)
.arg(i)
- .arg(QString::number(data_[i]))));
+ .arg(TQString::number(data_[i]))));
}
}
- void MemoryView::contextMenuEvent ( QContextMenuEvent * e )
+ void MemoryView::contextMenuEvent ( TQContextMenuEvent * e )
{
if (!isOk())
return;
- QPopupMenu menu;
+ TQPopupMenu menu;
bool app_running = !(debuggerState_ & s_appNotStarted);
@@ -373,7 +373,7 @@ namespace GDBDebugger
controller_->addCommand(
new
GDBCommand(
- QString("-data-read-memory %1 x 1 1 %2")
+ TQString("-data-read-memory %1 x 1 1 %2")
.arg(start_).arg(amount_).ascii(),
this,
&MemoryView::memoryRead));
@@ -403,16 +403,16 @@ namespace GDBDebugger
ViewerWidget::ViewerWidget(GDBController* controller,
- QWidget* parent,
+ TQWidget* parent,
const char* name)
- : QWidget(parent, name),
+ : TQWidget(parent, name),
controller_(controller)
{
setIcon(SmallIcon("math_brace"));
- QVBoxLayout *l = new QVBoxLayout(this, 0, 0);
+ TQVBoxLayout *l = new TQVBoxLayout(this, 0, 0);
- toolBox_ = new QToolBox(this);
+ toolBox_ = new TQToolBox(this);
l->addWidget(toolBox_);
}
@@ -436,14 +436,14 @@ namespace GDBDebugger
toolBox_->setCurrentItem(widget);
memoryViews_.push_back(widget);
- connect(widget, SIGNAL(captionChanged(const QString&)),
- this, SLOT(slotChildCaptionChanged(const QString&)));
+ connect(widget, TQT_SIGNAL(captionChanged(const TQString&)),
+ this, TQT_SLOT(slotChildCaptionChanged(const TQString&)));
- connect(widget, SIGNAL(destroyed(QObject*)),
- this, SLOT(slotChildDestroyed(QObject*)));
+ connect(widget, TQT_SIGNAL(destroyed(TQObject*)),
+ this, TQT_SLOT(slotChildDestroyed(TQObject*)));
}
- void ViewerWidget::slotDebuggerState(const QString&, int state)
+ void ViewerWidget::slotDebuggerState(const TQString&, int state)
{
for(unsigned i = 0; i < memoryViews_.size(); ++i)
{
@@ -451,19 +451,19 @@ namespace GDBDebugger
}
}
- void ViewerWidget::slotChildCaptionChanged(const QString& caption)
+ void ViewerWidget::slotChildCaptionChanged(const TQString& caption)
{
- const QWidget* s = static_cast<const QWidget*>(sender());
- QWidget* ncs = const_cast<QWidget*>(s);
- QString cap = caption;
+ const TQWidget* s = static_cast<const TQWidget*>(sender());
+ TQWidget* ncs = const_cast<TQWidget*>(s);
+ TQString cap = caption;
// Prevent intepreting '&' as accelerator specifier.
cap.replace("&", "&&");
toolBox_->setItemLabel(toolBox_->indexOf(ncs), cap);
}
- void ViewerWidget::slotChildDestroyed(QObject* child)
+ void ViewerWidget::slotChildDestroyed(TQObject* child)
{
- QValueVector<MemoryView*>::iterator i, e;
+ TQValueVector<MemoryView*>::iterator i, e;
for(i = memoryViews_.begin(), e = memoryViews_.end(); i != e; ++i)
{
if (*i == child)