-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
raefaldhia
authored and
Raefaldhi Amartya Junior
committed
Dec 30, 2016
1 parent
98f30e5
commit 5b74f58
Showing
116 changed files
with
20,001 additions
and
88 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,57 @@ | ||
#ifndef MAPSDATA_H | ||
#define MAPSDATA_H | ||
|
||
#include <vector> | ||
|
||
#include <Handler.h> | ||
#include <UrlRequest.h> | ||
|
||
class MapsData_Listener; | ||
|
||
enum { | ||
MAPDATA_UPDATE = 'mdud' | ||
}; | ||
|
||
struct Vector2 { | ||
float lon; | ||
float lat; | ||
struct MapsVector { | ||
int width; | ||
int height; | ||
|
||
float scale; | ||
|
||
float longitude; | ||
float latitude; | ||
float zoom; | ||
float bearing; | ||
float pitch; | ||
}; | ||
|
||
class MapsData { | ||
private: | ||
protected: | ||
MapsData(); | ||
~MapsData(); | ||
|
||
static BMallocIO* data; | ||
static std::vector<BHandler*> handler; | ||
public: | ||
static void Initialize(int, int); | ||
static void Retrieve(); | ||
|
||
static void SetLongitude(float); | ||
static void SetLatitude(float); | ||
static void SetZoom(float); | ||
static void Retrieve(); | ||
|
||
static BMallocIO* Get(); | ||
static void AddHandler(BHandler*); | ||
|
||
static float GetScale(); | ||
static Vector2 GetCoords(); | ||
static MapsVector GetVector(); | ||
private: | ||
static MapsVector mapsVector; | ||
|
||
static thread_id thread; | ||
static BUrlRequest* request; | ||
static MapsData_Listener* listener; | ||
|
||
static BString baseUrl; | ||
}; | ||
|
||
#endif // MAPSDATA_H |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.