Files
MuditaOS/module-gui/gui/core/BoundingBox.hpp
Adam Dobrowolski 1059543931 [BoxLayout] Added PageLayout & BoxLayout fixups
* Fixed Rect to always set maxSize and BoxLayout navigation
* removed commented out focusItem
* Removed redundant handling
* General BoxLayout fixes
2020-01-03 12:54:39 +01:00

33 lines
612 B
C++

/*
* BoundingBox.h
*
* Created on: 4 mar 2019
* Author: robert
*/
#ifndef MIDDLEWARES_GUI_WIDGETS_BOUNDINGBOX_HPP_
#define MIDDLEWARES_GUI_WIDGETS_BOUNDINGBOX_HPP_
#include <cstdint>
namespace gui {
class BoundingBox {
public:
int16_t x,y;
uint16_t w,h;
BoundingBox();
BoundingBox(int32_t x, int32_t y, uint32_t w, uint32_t h);
virtual ~BoundingBox();
static bool intersect(const BoundingBox &box1, const BoundingBox &box2, BoundingBox &result);
//inline
void clear() { x=0; y=0; w=0; h=0; };
};
} /* namespace gui */
#endif /* MIDDLEWARES_GUI_WIDGETS_BOUNDINGBOX_HPP_ */