changeset 1319:0290b7060167 broker

Build fix C++03
author Benjamin Golinvaux <bgo@osimis.io>
date Tue, 17 Mar 2020 08:57:45 +0100
parents cbfdba08e039
children 7702ad9b7011
files Applications/Generic/GuiAdapter.cpp
diffstat 1 files changed, 5 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/Applications/Generic/GuiAdapter.cpp	Tue Mar 17 08:40:13 2020 +0100
+++ b/Applications/Generic/GuiAdapter.cpp	Tue Mar 17 08:57:45 2020 +0100
@@ -681,7 +681,7 @@
 
       if (sendEvent)
       {
-        auto func = sdlEventHandlers_[i].func;
+        OnSdlEventCallback func = sdlEventHandlers_[i].func;
         (*func)(canvasName, sdlEvent, sdlEventHandlers_[i].userData);
       }
     }
@@ -913,12 +913,13 @@
         }
 
         // SECOND: collect all user events
-        for (auto& it : userEventsMap)
-          sdlEvents.push_back(it.second);
+        for (std::map<Uint32,SDL_Event>::const_iterator it = userEventsMap.begin(); it != userEventsMap.end(); ++it)
+          sdlEvents.push_back(it->second);
                 
         // now process the events
-        for(const SDL_Event& sdlEvent : sdlEvents)
+        for (std::vector<SDL_Event>::const_iterator it = sdlEvents.begin(); it != sdlEvents.end(); ++it)
         {
+          const SDL_Event& sdlEvent = *it;
           // TODO: lock all viewports here! (use a scoped object)
 
           if (sdlEvent.type == SDL_QUIT)