Skip to content

Commit

Permalink
move delay to the inherited class
Browse files Browse the repository at this point in the history
  • Loading branch information
silverchris committed Aug 14, 2022
1 parent d2a56e8 commit a7085fd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
1 change: 1 addition & 0 deletions include/Platforms/Mazda/Managers/GPSManager.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ class GPSManager: public IGPSManager{

int errorCount;
std::time_t lastError;
const int delay = 1000;

void update_position(const asio::error_code &error);

Expand Down
4 changes: 1 addition & 3 deletions include/autoapp/Managers/IGPSManager.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@ class IGPSManager: public IManager{
private:
std::vector<locationCallback> locationCallbacks;

protected:
int delay = 1000;
public:
IGPSManager() = default;
~IGPSManager() override = default;
Expand All @@ -22,7 +20,7 @@ class IGPSManager: public IManager{
locationCallbacks.emplace_back(callback);
};

void updateLocation(aasdk::proto::data::GPSLocation locationData) {
void updateLocation(const aasdk::proto::data::GPSLocation& locationData) {
for (auto &callback : locationCallbacks) {
callback(locationData);
}
Expand Down

0 comments on commit a7085fd

Please sign in to comment.