core/panelwindow: move Margins to types.hpp

This commit is contained in:
outfoxxed 2025-05-30 00:26:41 -07:00
parent 2773e5468f
commit ef077ddd24
Signed by untrusted user: outfoxxed
GPG key ID: 4C88A185FB89301E
5 changed files with 51 additions and 44 deletions

View file

@ -1,6 +1,7 @@
#include "types.hpp"
#include <qdebug.h>
#include <qmargins.h>
#include <qnamespace.h>
#include <qrect.h>
@ -21,3 +22,5 @@ Qt::Edges Edges::toQt(Edges::Flags edges) { return Qt::Edges(edges.toInt()); }
bool Edges::isOpposing(Edges::Flags edges) {
return edges.testFlags(Edges::Top | Edges::Bottom) || edges.testFlags(Edges::Left | Edges::Right);
}
QMargins Margins::qmargins() const { return {this->left, this->top, this->right, this->bottom}; }