File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change 11#include " Sortable.h"
22
3+ /* *
4+ * @brief Construct a new Sortable object. Sortables are the elements that comforms the main sorting array
5+ *
6+ * @param width width of the sortable on screen
7+ * @param height height of the sortable on screen
8+ * @param value associated value to each element used to sort
9+ */
310Sortable::Sortable (float width, float height, int value) {
411 this ->width = width;
512 this ->height = height;
613 this ->value = value;
714}
815
16+ /* *
17+ * @brief Defines a shape for the sortable
18+ *
19+ * @return sf::RectangleShape prepared to be directly drawed on screen
20+ */
921sf::RectangleShape Sortable::shape () {
1022 return sf::RectangleShape (sf::Vector2f ((float )width, (float )height));
1123}
You can’t perform that action at this time.
0 commit comments