initial commit
This commit is contained in:
37
mapview/model/MMFloors.h
Normal file
37
mapview/model/MMFloors.h
Normal file
@@ -0,0 +1,37 @@
|
||||
#ifndef MMFLOORS_H
|
||||
#define MMFLOORS_H
|
||||
|
||||
#include "MapLayer.h"
|
||||
#include "MMFloor.h"
|
||||
|
||||
#include <Indoor/floorplan/v2/Floorplan.h>
|
||||
|
||||
/**
|
||||
* layer containing all of the map's floors
|
||||
*/
|
||||
class MMFloors : public MapLayer {
|
||||
|
||||
private:
|
||||
|
||||
Floorplan::IndoorMap* map;
|
||||
|
||||
public:
|
||||
|
||||
/** ctor with the underlying model */
|
||||
MMFloors(MapLayer* parent, Floorplan::IndoorMap* map) : MapLayer(parent, MapLayerType::FLOORS), map(map) {
|
||||
|
||||
// add all floors
|
||||
for (Floorplan::Floor* floor : map->floors) {
|
||||
new MMFloor(this, floor);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
std::string getLayerName() const override {return "floors";}
|
||||
|
||||
/** get the underlying model */
|
||||
Floorplan::IndoorMap* getMap() {return map;}
|
||||
|
||||
};
|
||||
|
||||
#endif // MMFLOORS_H
|
||||
Reference in New Issue
Block a user