#ifndef KOLFPOOLBALL_H #define KOLFPOOLBALL_H #include #include #include #include #include #include #include #include class StateDB; class KConfig; class PoolBallFactory : KLibFactory { Q_OBJECT TQ_OBJECT public: TQObject *createObject(TQObject *, const char *, const char *, const TQStringList & = TQStringList()); }; class PoolBall : public Ball { public: PoolBall(TQCanvas *canvas); virtual bool deleteable() const { return true; } virtual Config *config(TQWidget *tqparent); virtual void saveState(StateDB *); virtual void save(KConfig *cfg); virtual void loadState(StateDB *); virtual void load(KConfig *cfg); virtual void draw(TQPainter &); virtual bool fastAdvance() const { return true; } int number() const { return m_number; } void setNumber(int newNumber) { m_number = newNumber; update(); } private: int m_number; }; class PoolBallConfig : public Config { Q_OBJECT TQ_OBJECT public: PoolBallConfig(PoolBall *poolBall, TQWidget *tqparent); private slots: void numberChanged(int); private: PoolBall *m_poolBall; }; class PoolBallObj : public Object { public: PoolBallObj() { m_name = i18n("Pool Ball"); m__name = "poolball"; m_author = "Jason Katz-Brown"; } virtual TQCanvasItem *newObject(TQCanvas *canvas) { return new PoolBall(canvas); } }; #endif