Try to fix compilation for gcc 4.6 [2]

master
Eduardo Bart 11 years ago
parent 69f72b9c86
commit 392acc0b43

@ -35,12 +35,12 @@ public:
void stop();
template<class F>
boost::unique_future<typename std::result_of<F()>::type> schedule(const F& task) {
boost::shared_future<typename std::result_of<F()>::type> schedule(const F& task) {
std::lock_guard<std::mutex> lock(m_mutex);
auto prom = std::make_shared<boost::promise<typename std::result_of<F()>::type>>();
m_tasks.push_back([=]() { prom->set_value(task()); });
m_condition.notify_all();
return prom->get_future();
return prom->get_future().share();
}
protected:

@ -322,7 +322,7 @@ void Application::registerLuaFunctions()
g_lua.bindSingletonFunction("g_ui", "getDraggingWidget", &UIManager::getDraggingWidget, &g_ui);
g_lua.bindSingletonFunction("g_ui", "getPressedWidget", &UIManager::getPressedWidget, &g_ui);
g_lua.bindSingletonFunction("g_ui", "setDebugBoxesDrawing", &UIManager::setDebugBoxesDrawing, &g_ui);
g_lua.bindSingletonFunction("g_ui", "isDrawingDebugBoxes", &UIManager::setDebugBoxesDrawing, &g_ui);
g_lua.bindSingletonFunction("g_ui", "isDrawingDebugBoxes", &UIManager::isDrawingDebugBoxes, &g_ui);
g_lua.bindSingletonFunction("g_ui", "isMouseGrabbed", &UIManager::isMouseGrabbed, &g_ui);
g_lua.bindSingletonFunction("g_ui", "isKeyboardGrabbed", &UIManager::isKeyboardGrabbed, &g_ui);

@ -57,7 +57,7 @@ private:
ALCdevice *m_device;
ALCcontext *m_context;
std::map<StreamSoundSourcePtr, boost::unique_future<SoundFilePtr>> m_streamFiles;
std::map<StreamSoundSourcePtr, boost::shared_future<SoundFilePtr>> m_streamFiles;
std::unordered_map<std::string, SoundBufferPtr> m_buffers;
std::vector<SoundSourcePtr> m_sources;
stdext::boolean<true> m_audioEnabled;

Loading…
Cancel
Save