diff options
Diffstat (limited to 'katomic/feld.cpp')
-rw-r--r-- | katomic/feld.cpp | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/katomic/feld.cpp b/katomic/feld.cpp index 47af46d5..e01060cb 100644 --- a/katomic/feld.cpp +++ b/katomic/feld.cpp @@ -26,27 +26,27 @@ extern Options settings; -Feld::Feld( QWidget *parent, const char *name ) : - QWidget( parent, name ), +Feld::Feld( TQWidget *parent, const char *name ) : + TQWidget( parent, name ), data(locate("appdata", "pics/abilder.png")), undoBegin (0), undoSize (0), redoSize (0) { anim = false; dir = None; - sprite = QPixmap (30, 30); + sprite = TQPixmap (30, 30); cx = -1; cy = -1; - point = new QPoint [1]; + point = new TQPoint [1]; moving = false; chosen = false; setMouseTracking(true); - setFocusPolicy(QWidget::StrongFocus); - setBackgroundColor( QColor( 0, 0, 0) ); + setFocusPolicy(TQWidget::StrongFocus); + setBackgroundColor( TQColor( 0, 0, 0) ); setFixedSize(15 * 30, 15 * 30); } @@ -74,12 +74,12 @@ void Feld::load (const KSimpleConfig& config) mol->load(config); - QString key; + TQString key; for (int j = 0; j < FIELD_SIZE; j++) { key.sprintf("feld_%02d", j); - QString line = config.readEntry(key); + TQString line = config.readEntry(key); for (int i = 0; i < FIELD_SIZE; i++) feld[i][j] = atom2int(line[i].latin1()); @@ -98,7 +98,7 @@ void Feld::load (const KSimpleConfig& config) nextAtom(); } -void Feld::mousePressEvent (QMouseEvent *e) +void Feld::mousePressEvent (TQMouseEvent *e) { if (moving) return; @@ -406,7 +406,7 @@ void Feld::doRedo () bitBlt (&sprite, 0, 0, this, cx, cy, 30, 30, CopyROP); } -void Feld::mouseMoveEvent (QMouseEvent *e) +void Feld::mouseMoveEvent (TQMouseEvent *e) { // warning: mouseMoveEvents can report positions upto 1 pixel outside // of the field widget, so we must be sure handle this case @@ -450,7 +450,7 @@ bool Feld::checkDone () int mx = 0; int my = j - 1; - QRect extent(0, 0, FIELD_SIZE - molecWidth + 1, FIELD_SIZE - molecHeight + 1); + TQRect extent(0, 0, FIELD_SIZE - molecWidth + 1, FIELD_SIZE - molecHeight + 1); extent.moveBy(0, my); // find first atom in playing field @@ -486,7 +486,7 @@ bool Feld::checkDone () } -void Feld::timerEvent (QTimerEvent *) +void Feld::timerEvent (TQTimerEvent *) { // animation beenden if (frames <= 0) @@ -510,7 +510,7 @@ void Feld::paintMovingAtom() { int a = settings.anim_speed; - QPainter paint(this); + TQPainter paint(this); switch(dir) { @@ -554,11 +554,11 @@ void Feld::putNonAtom (int x, int y, Direction which, bool brick) bitBlt(this, x * 30, y * 30, &data, xarr, yarr, 30, 30, CopyROP); } -void Feld::paintEvent( QPaintEvent * ) +void Feld::paintEvent( TQPaintEvent * ) { int i, j, x, y; - QPainter paint ( this ); + TQPainter paint ( this ); paint.setPen (black); |