*/
static QString tilePath(int zoomLevel, int x, int y);
+ /**
+ * @brief converts scene coordinates to latitude and longitude
+ *
+ * @param current zoom level
+ * @param sceneCoordinate that will be converted
+ */
+ QPointF convertSceneCoordinateToLatLon(int zoomLevel, QPoint sceneCoordinate);
+
public slots:
/**
* @brief Slot for setting current view location
void viewResized(const QSize &size);
/**
+ * @brief Returns own location crosshair's latitude and longitude coordinates
+ *
+ */
+ void ownLocation();
+
+ /**
* @brief Slot to catch user own location data
*
* @param user User info
*/
- void receiveOwnLocation(User *user);
+ void receiveOwnLocation(User *user);
+
+ /**
+ * @brief Slot to receive visible area of map scene
+ *
+ * @param visible area of map scene
+ */
+ void receiveViewSceneRect(QRect viewSceneRect);
private:
/**
void minZoomLevelReached();
/**
+ * @brief Signal request mapView to update view port contents
+ */
+ void requestToGetViewPortContents();
+
+ /**
+ * @brief Signal sends location of crosshair
+ *
+ * @param ownLocation location of crosshair (Latitude, Longitude)
+ */
+ void ownLocation(const QPointF ownLocation);
+
+ /**
* @brief Signal for zoom level change
*
* @param newZoomLevel New zoom level
QSize m_viewSize; ///< Current view size
bool m_zoomedIn; ///< Flag for checking if zoomed in when zoom is finished
int m_zoomLevel; ///< Current zoom level
+ QRect m_viewArea; ///< Visible area of map scene
};
#endif // MAPENGINE_H