Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/mapwidget.h')
-rw-r--r--src/mapwidget.h30
1 files changed, 28 insertions, 2 deletions
diff --git a/src/mapwidget.h b/src/mapwidget.h
index f698a1c..7371ffd 100644
--- a/src/mapwidget.h
+++ b/src/mapwidget.h
@@ -32,18 +32,44 @@ public:
MapEntity *addEntity();
protected:
- virtual void resizeEvent (QResizeEvent *event);
+
+ /**
+ * @brief handle draw events
+ * */
virtual void paintEvent(QPaintEvent *event);
+
+ /**
+ * @brief handle resize events
+ * */
+ virtual void resizeEvent(QResizeEvent *event);
+
+ /**
+ * @brief handle mousewheel events
+ * */
virtual void wheelEvent(QWheelEvent *event);
+
+signals:
+ /**
+ * @brief the selected() signal is emitted if an entity on the map is selected
+ * */
+ void selected(MapEntity *entity);
+
+private slots:
+ /**
+ * @brief called when an entity on the map has been clicked
+ * */
+ void select(MapEntity *entity);
private:
void resizeChildren();
int mapwidget_zoom;
+ int center_x;
+ int center_y;
QList<MapEntity *> mapwidget_enties;
};
}
-#endif // __INCLUDED_EDITOR_MAPWIDGET__ \ No newline at end of file
+#endif // __INCLUDED_EDITOR_MAPWIDGET__