summaryrefslogtreecommitdiffstats
path: root/src/devices/mem24/gui
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-30 00:15:53 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-30 00:15:53 +0000
commit0aaa8e3fc8f8a1481333b564f0922277c8d8ad59 (patch)
treeb95c0ca86c4876dd139af376b9f4afd8917cf0cd /src/devices/mem24/gui
parentb79a2c28534cf09987eeeba3077fff9236df182a (diff)
downloadpiklab-0aaa8e3fc8f8a1481333b564f0922277c8d8ad59.tar.gz
piklab-0aaa8e3fc8f8a1481333b564f0922277c8d8ad59.zip
TQt4 port piklab
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/piklab@1238822 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'src/devices/mem24/gui')
-rw-r--r--src/devices/mem24/gui/mem24_group_ui.cpp4
-rw-r--r--src/devices/mem24/gui/mem24_group_ui.h8
-rw-r--r--src/devices/mem24/gui/mem24_hex_view.cpp10
-rw-r--r--src/devices/mem24/gui/mem24_hex_view.h5
-rw-r--r--src/devices/mem24/gui/mem24_memory_editor.cpp14
-rw-r--r--src/devices/mem24/gui/mem24_memory_editor.h15
6 files changed, 30 insertions, 26 deletions
diff --git a/src/devices/mem24/gui/mem24_group_ui.cpp b/src/devices/mem24/gui/mem24_group_ui.cpp
index 751e5a7..8a8bb5a 100644
--- a/src/devices/mem24/gui/mem24_group_ui.cpp
+++ b/src/devices/mem24/gui/mem24_group_ui.cpp
@@ -10,7 +10,7 @@
#include "mem24_hex_view.h"
-Device::HexView *Mem24::GroupUI::createHexView(const HexEditor &editor, QWidget *parent) const
+Device::HexView *Mem24::GroupUI::createHexView(const HexEditor &editor, TQWidget *tqparent) const
{
- return new HexView(editor, parent);
+ return new HexView(editor, tqparent);
}
diff --git a/src/devices/mem24/gui/mem24_group_ui.h b/src/devices/mem24/gui/mem24_group_ui.h
index 37766b5..c2b3360 100644
--- a/src/devices/mem24/gui/mem24_group_ui.h
+++ b/src/devices/mem24/gui/mem24_group_ui.h
@@ -16,10 +16,10 @@ namespace Mem24
class GroupUI : public Device::GroupUI
{
public:
- virtual Device::HexView *createHexView(const HexEditor &editor, QWidget *parent) const;
- virtual Register::View *createRegisterView(QWidget *) const { return 0; }
- virtual Device::MemoryEditor *createConfigEditor(Device::Memory &, QWidget *) const { return 0; }
- virtual void fillWatchListContainer(ListContainer *, QValueVector<Register::TypeData> &) const {}
+ virtual Device::HexView *createHexView(const HexEditor &editor, TQWidget *tqparent) const;
+ virtual Register::View *createRegisterView(TQWidget *) const { return 0; }
+ virtual Device::MemoryEditor *createConfigEditor(Device::Memory &, TQWidget *) const { return 0; }
+ virtual void fillWatchListContainer(ListContainer *, TQValueVector<Register::TypeData> &) const {}
virtual Register::ListViewItem *createWatchItem(const Register::TypeData &, KListViewItem *) const { return 0; }
};
diff --git a/src/devices/mem24/gui/mem24_hex_view.cpp b/src/devices/mem24/gui/mem24_hex_view.cpp
index 0ada8d0..7ded854 100644
--- a/src/devices/mem24/gui/mem24_hex_view.cpp
+++ b/src/devices/mem24/gui/mem24_hex_view.cpp
@@ -8,14 +8,14 @@
***************************************************************************/
#include "mem24_hex_view.h"
-#include <qlayout.h>
-#include <qlabel.h>
+#include <tqlayout.h>
+#include <tqlabel.h>
#include <klocale.h>
#include "mem24_memory_editor.h"
-Mem24::HexView::HexView(const HexEditor &editor, QWidget *parent)
- : Device::HexView(editor, parent, "mem24_hex_view")
+Mem24::HexView::HexView(const HexEditor &editor, TQWidget *tqparent)
+ : Device::HexView(editor, tqparent, "mem24_hex_view")
{}
void Mem24::HexView::display()
@@ -34,5 +34,5 @@ BitValue Mem24::HexView::checksum() const
BitValue cs = 0x0000;
for (uint i=0; i<static_cast<const Data &>(_memory->device()).nbBytes(); i++)
cs += static_cast<const Memory *>(_memory)->byte(i);
- return cs.maskWith(0xFFFF);
+ return cs.tqmaskWith(0xFFFF);
}
diff --git a/src/devices/mem24/gui/mem24_hex_view.h b/src/devices/mem24/gui/mem24_hex_view.h
index 378a25e..199865a 100644
--- a/src/devices/mem24/gui/mem24_hex_view.h
+++ b/src/devices/mem24/gui/mem24_hex_view.h
@@ -9,7 +9,7 @@
#ifndef MEM24_HEX_VIEW_H
#define MEM24_HEX_VIEW_H
-class QVBoxLayout;
+class TQVBoxLayout;
#include "devices/gui/hex_view.h"
@@ -19,8 +19,9 @@ namespace Mem24
class HexView : public Device::HexView
{
Q_OBJECT
+ TQ_OBJECT
public:
- HexView(const HexEditor &editor, QWidget *parent);
+ HexView(const HexEditor &editor, TQWidget *tqparent);
virtual uint nbChecksumChars() const { return 4; }
virtual BitValue checksum() const;
diff --git a/src/devices/mem24/gui/mem24_memory_editor.cpp b/src/devices/mem24/gui/mem24_memory_editor.cpp
index 61f98fe..a5203b9 100644
--- a/src/devices/mem24/gui/mem24_memory_editor.cpp
+++ b/src/devices/mem24/gui/mem24_memory_editor.cpp
@@ -8,7 +8,7 @@
***************************************************************************/
#include "mem24_memory_editor.h"
-#include <qlayout.h>
+#include <tqlayout.h>
#include <klocale.h>
#include <kpushbutton.h>
@@ -19,19 +19,19 @@
#include "devices/base/device_group.h"
//-----------------------------------------------------------------------------
-Mem24::MemoryRangeEditor::MemoryRangeEditor(Memory &memory, QWidget *parent)
- : Device::MemoryRangeEditor(memory, 16, 16, 0, -1, parent, "mem24_memory_range_editor"),
+Mem24::MemoryRangeEditor::MemoryRangeEditor(Memory &memory, TQWidget *tqparent)
+ : Device::MemoryRangeEditor(memory, 16, 16, 0, -1, tqparent, "mem24_memory_range_editor"),
MemoryCaster(memory)
{}
-Device::HexWordEditor *Mem24::MemoryRangeEditor::createHexWordEditor(QWidget *parent)
+Device::HexWordEditor *Mem24::MemoryRangeEditor::createHexWordEditor(TQWidget *tqparent)
{
- return new HexWordEditor(memory(), parent);
+ return new HexWordEditor(memory(), tqparent);
}
//-----------------------------------------------------------------------------
-Mem24::MemoryTypeEditor::MemoryTypeEditor(const HexView *hexview, Memory &memory, QWidget *parent)
- : Device::MemoryTypeEditor(hexview, memory, parent, "mem24_memory_type_editor"),
+Mem24::MemoryTypeEditor::MemoryTypeEditor(const HexView *hexview, Memory &memory, TQWidget *tqparent)
+ : Device::MemoryTypeEditor(hexview, memory, tqparent, "mem24_memory_type_editor"),
MemoryCaster(memory)
{}
diff --git a/src/devices/mem24/gui/mem24_memory_editor.h b/src/devices/mem24/gui/mem24_memory_editor.h
index eb99e97..657810a 100644
--- a/src/devices/mem24/gui/mem24_memory_editor.h
+++ b/src/devices/mem24/gui/mem24_memory_editor.h
@@ -34,12 +34,13 @@ private:
class HexWordEditor : public Device::HexWordEditor, public MemoryCaster
{
Q_OBJECT
+ TQ_OBJECT
public:
- HexWordEditor(Memory &memory, QWidget *parent)
- : Device::HexWordEditor(memory, 2, parent), MemoryCaster(memory) {}
+ HexWordEditor(Memory &memory, TQWidget *tqparent)
+ : Device::HexWordEditor(memory, 2, tqparent), MemoryCaster(memory) {}
private:
- virtual BitValue mask() const { return 0xFF; }
+ virtual BitValue tqmask() const { return 0xFF; }
virtual BitValue normalizeWord(BitValue value) const { return value; }
virtual BitValue word() const { return memory().byte(_offset); }
virtual void setWord(BitValue value) { memory().setByte(_offset, value); }
@@ -49,14 +50,15 @@ private:
class MemoryRangeEditor : public Device::MemoryRangeEditor, public MemoryCaster
{
Q_OBJECT
+ TQ_OBJECT
public:
- MemoryRangeEditor(Memory &memory, QWidget *parent);
+ MemoryRangeEditor(Memory &memory, TQWidget *tqparent);
private:
virtual uint nbWords() const { return device().nbBytes(); }
virtual uint addressIncrement() const { return 1; }
virtual Address startAddress() const { return 0x0; }
- virtual Device::HexWordEditor *createHexWordEditor(QWidget *parent);
+ virtual Device::HexWordEditor *createHexWordEditor(TQWidget *tqparent);
virtual bool isRangeReadOnly() const { return false; }
};
@@ -64,8 +66,9 @@ private:
class MemoryTypeEditor : public Device::MemoryTypeEditor, public MemoryCaster
{
Q_OBJECT
+ TQ_OBJECT
public:
- MemoryTypeEditor(const HexView *hexview, Memory &memory, QWidget *parent);
+ MemoryTypeEditor(const HexView *hexview, Memory &memory, TQWidget *tqparent);
virtual void init(bool first);
private: