Address review comments and fix code compilation

This commit is contained in:
FearlessTobi 2020-08-29 20:56:51 +02:00
parent e6bd1fd1b8
commit d176feffad
13 changed files with 218 additions and 155 deletions

View file

@ -30,14 +30,15 @@ public:
static_cast<int>(Layout::ScreenUndocked::Width);
const float y = static_cast<float>(std::get<2>(m)) /
static_cast<int>(Layout::ScreenUndocked::Height);
return std::make_tuple(x, y, true);
return {x, y, true};
}
}
return std::make_tuple(0.0f, 0.0f, false);
return {};
}
private:
std::vector<std::tuple<std::unique_ptr<Input::ButtonDevice>, int, int>> map; // button, x, y
// A vector of the mapped button, its x and its y-coordinate
std::vector<std::tuple<std::unique_ptr<Input::ButtonDevice>, int, int>> map;
};
std::unique_ptr<Input::TouchDevice> TouchFromButtonFactory::Create(