• Skip to content
  • Skip to link menu
KDE API Reference
  • KDE API Reference
  • kdegames API Reference
  • KDE Home
  • Contact Us
 

granatier

  • sources
  • kde-4.14
  • kdegames
  • granatier
  • src
blockitem.h
Go to the documentation of this file.
1 /*
2  * Copyright 2009 Mathias Kraus <k.hias@gmx.de>
3  *
4  * This program is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU General Public License as
6  * published by the Free Software Foundation; either version 2 of
7  * the License, or (at your option) any later version.
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program. If not, see <http://www.gnu.org/licenses/>.
16  */
17 
18 #ifndef BLOCKITEM_H
19 #define BLOCKITEM_H
20 
21 #include "elementitem.h"
22 
23 class Block;
24 class QTimer;
25 class KGameRenderer;
26 
30 class BlockItem : public ElementItem
31 {
32 
33  Q_OBJECT
34 
35 protected:
36 
38  QTimer* m_destructionTimer;
39 
41  int m_destructionCounter;
42 
43 public:
44 
50  BlockItem(Block* p_model, KGameRenderer* renderer);
51 
55  ~BlockItem();
56 
57 private slots:
61  void startDestructionAnimation();
62 
66  void destructionAnimation();
67 
68 signals:
73  void blockItemDestroyed(BlockItem* blockItem);
74 };
75 
76 #endif
BlockItem::blockItemDestroyed
void blockItemDestroyed(BlockItem *blockItem)
signals the end of the destruction animation
BlockItem::m_destructionTimer
QTimer * m_destructionTimer
Timer used to animate explosion.
Definition: blockitem.h:38
BlockItem::m_destructionCounter
int m_destructionCounter
Number of frames for the destruction.
Definition: blockitem.h:41
BlockItem::BlockItem
BlockItem(Block *p_model, KGameRenderer *renderer)
Creates a new BlockItem instance.
Definition: blockitem.cpp:25
QTimer
BlockItem::~BlockItem
~BlockItem()
Deletes the BlockItem instance.
Definition: blockitem.cpp:32
ElementItem
This class is the graphical representation of a game Element.
Definition: elementitem.h:30
BlockItem
This class is the graphical representation of a Block.
Definition: blockitem.h:30
elementitem.h
Block
This class represents a block with the possibility of a bonus inside.
Definition: block.h:30
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:18:10 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.

granatier

Skip menu "granatier"
  • Main Page
  • Namespace List
  • Namespace Members
  • Alphabetical List
  • Class List
  • Class Hierarchy
  • Class Members
  • File List
  • File Members

kdegames API Reference

Skip menu "kdegames API Reference"
  • granatier
  • kapman
  • kblackbox
  • kgoldrunner
  • kigo
  • kmahjongg
  • KShisen
  • ksquares
  • libkdegames
  •   highscore
  •   libkdegamesprivate
  •     kgame
  • libkmahjongg
  • palapeli
  •   libpala

Search



Report problems with this website to our bug tracking system.
Contact the specific authors with questions and comments about the page contents.

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal