* Sets up a base view with the specified size and position. * @param width Width in pixels. * @param height Height in pixels. * @param x X position in pixels. * @param y Y position in pixels. */
| 43 | * @param y Y position in pixels. |
| 44 | */ |
| 45 | BaseView::BaseView(int width, int height, int x, int y) : InteractiveSurface(width, height, x, y), _base(0), _texture(0), _selFacility(0), _big(0), _small(0), _lang(0), _gridX(0), _gridY(0), _selSize(0), _selector(0), _blink(true) |
| 46 | { |
| 47 | for (int x = 0; x < BASE_SIZE; ++x) |
| 48 | for (int y = 0; y < BASE_SIZE; ++y) |
| 49 | _facilities[x][y] = 0; |
| 50 | |
| 51 | _timer = new Timer(100); |
| 52 | _timer->onTimer((SurfaceHandler)&BaseView::blink); |
| 53 | _timer->start(); |
| 54 | } |
| 55 | |
| 56 | /** |
| 57 | * Deletes contents. |