mirror of
https://github.com/hyprwm/Hyprland
synced 2024-11-29 17:25:59 +01:00
Unbreak build with libc++ (#1457)
This commit is contained in:
parent
d4e2a0fd16
commit
f90ff8303b
9 changed files with 23 additions and 21 deletions
|
@ -11,6 +11,7 @@
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
|
|
||||||
|
#include <sstream>
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
std::string monitorsRequest(HyprCtl::eHyprCtlOutputFormat format) {
|
std::string monitorsRequest(HyprCtl::eHyprCtlOutputFormat format) {
|
||||||
|
|
|
@ -1,5 +1,7 @@
|
||||||
#include "BezierCurve.hpp"
|
#include "BezierCurve.hpp"
|
||||||
|
|
||||||
|
#include <algorithm>
|
||||||
|
|
||||||
void CBezierCurve::setup(std::vector<Vector2D>* pVec) {
|
void CBezierCurve::setup(std::vector<Vector2D>* pVec) {
|
||||||
m_dPoints.clear();
|
m_dPoints.clear();
|
||||||
|
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
#include "../Compositor.hpp"
|
#include "../Compositor.hpp"
|
||||||
#include <sys/utsname.h>
|
#include <sys/utsname.h>
|
||||||
#include <iomanip>
|
#include <iomanip>
|
||||||
|
#include <sstream>
|
||||||
|
|
||||||
#if defined(__DragonFly__) || defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__NetBSD__) || defined(__OpenBSD__)
|
#if defined(__DragonFly__) || defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__NetBSD__) || defined(__OpenBSD__)
|
||||||
#include <sys/sysctl.h>
|
#include <sys/sysctl.h>
|
||||||
|
|
|
@ -24,7 +24,7 @@ struct SSurfaceTreeNode {
|
||||||
void* globalOffsetData;
|
void* globalOffsetData;
|
||||||
CWindow* pWindowOwner = nullptr;
|
CWindow* pWindowOwner = nullptr;
|
||||||
|
|
||||||
bool operator==(const SSurfaceTreeNode& rhs) {
|
bool operator==(const SSurfaceTreeNode& rhs) const {
|
||||||
return pSurface == rhs.pSurface;
|
return pSurface == rhs.pSurface;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -41,7 +41,7 @@ struct SSubsurface {
|
||||||
|
|
||||||
CWindow* pWindowOwner = nullptr;
|
CWindow* pWindowOwner = nullptr;
|
||||||
|
|
||||||
bool operator==(const SSubsurface& rhs) {
|
bool operator==(const SSubsurface& rhs) const {
|
||||||
return pSubsurface == rhs.pSubsurface;
|
return pSubsurface == rhs.pSubsurface;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -43,7 +43,7 @@ struct SLayerSurface {
|
||||||
bool forceBlur = false;
|
bool forceBlur = false;
|
||||||
|
|
||||||
// For the list lookup
|
// For the list lookup
|
||||||
bool operator==(const SLayerSurface& rhs) {
|
bool operator==(const SLayerSurface& rhs) const {
|
||||||
return layerSurface == rhs.layerSurface && monitorID == rhs.monitorID;
|
return layerSurface == rhs.layerSurface && monitorID == rhs.monitorID;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -123,7 +123,7 @@ struct SKeyboard {
|
||||||
int numlockOn = -1;
|
int numlockOn = -1;
|
||||||
|
|
||||||
// For the list lookup
|
// For the list lookup
|
||||||
bool operator==(const SKeyboard& rhs) {
|
bool operator==(const SKeyboard& rhs) const {
|
||||||
return keyboard == rhs.keyboard;
|
return keyboard == rhs.keyboard;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -145,7 +145,7 @@ struct SMouse {
|
||||||
DYNLISTENER(commitConstraint);
|
DYNLISTENER(commitConstraint);
|
||||||
DYNLISTENER(destroyMouse);
|
DYNLISTENER(destroyMouse);
|
||||||
|
|
||||||
bool operator==(const SMouse& b) {
|
bool operator==(const SMouse& b) const {
|
||||||
return mouse == b.mouse;
|
return mouse == b.mouse;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -160,7 +160,7 @@ struct SConstraint {
|
||||||
DYNLISTENER(setConstraintRegion);
|
DYNLISTENER(setConstraintRegion);
|
||||||
DYNLISTENER(destroyConstraint);
|
DYNLISTENER(destroyConstraint);
|
||||||
|
|
||||||
bool operator==(const SConstraint& b) {
|
bool operator==(const SConstraint& b) const {
|
||||||
return constraint == b.constraint;
|
return constraint == b.constraint;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -185,7 +185,7 @@ struct SXDGPopup {
|
||||||
SSurfaceTreeNode* pSurfaceTree = nullptr;
|
SSurfaceTreeNode* pSurfaceTree = nullptr;
|
||||||
|
|
||||||
// For the list lookup
|
// For the list lookup
|
||||||
bool operator==(const SXDGPopup& rhs) {
|
bool operator==(const SXDGPopup& rhs) const {
|
||||||
return popup == rhs.popup;
|
return popup == rhs.popup;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -229,7 +229,7 @@ struct STablet {
|
||||||
|
|
||||||
std::string name = "";
|
std::string name = "";
|
||||||
|
|
||||||
bool operator==(const STablet& b) {
|
bool operator==(const STablet& b) const {
|
||||||
return wlrDevice == b.wlrDevice;
|
return wlrDevice == b.wlrDevice;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -252,7 +252,7 @@ struct STabletTool {
|
||||||
DYNLISTENER(TabletToolDestroy);
|
DYNLISTENER(TabletToolDestroy);
|
||||||
DYNLISTENER(TabletToolSetCursor);
|
DYNLISTENER(TabletToolSetCursor);
|
||||||
|
|
||||||
bool operator==(const STabletTool& b) {
|
bool operator==(const STabletTool& b) const {
|
||||||
return wlrTabletTool == b.wlrTabletTool;
|
return wlrTabletTool == b.wlrTabletTool;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -270,7 +270,7 @@ struct STabletPad {
|
||||||
DYNLISTENER(Ring);
|
DYNLISTENER(Ring);
|
||||||
DYNLISTENER(Destroy);
|
DYNLISTENER(Destroy);
|
||||||
|
|
||||||
bool operator==(const STabletPad& b) {
|
bool operator==(const STabletPad& b) const {
|
||||||
return wlrTabletPadV2 == b.wlrTabletPadV2;
|
return wlrTabletPadV2 == b.wlrTabletPadV2;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -281,7 +281,7 @@ struct SIdleInhibitor {
|
||||||
|
|
||||||
DYNLISTENER(Destroy);
|
DYNLISTENER(Destroy);
|
||||||
|
|
||||||
bool operator==(const SIdleInhibitor& b) {
|
bool operator==(const SIdleInhibitor& b) const {
|
||||||
return pWlrInhibitor == b.pWlrInhibitor;
|
return pWlrInhibitor == b.pWlrInhibitor;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -333,7 +333,7 @@ struct SIMEPopup {
|
||||||
|
|
||||||
DYNLISTENER(focusedSurfaceUnmap);
|
DYNLISTENER(focusedSurfaceUnmap);
|
||||||
|
|
||||||
bool operator==(const SIMEPopup& other) {
|
bool operator==(const SIMEPopup& other) const {
|
||||||
return pSurface == other.pSurface;
|
return pSurface == other.pSurface;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -347,7 +347,7 @@ struct STouchDevice {
|
||||||
|
|
||||||
DYNLISTENER(destroy);
|
DYNLISTENER(destroy);
|
||||||
|
|
||||||
bool operator==(const STouchDevice& other) {
|
bool operator==(const STouchDevice& other) const {
|
||||||
return pWlrDevice == other.pWlrDevice;
|
return pWlrDevice == other.pWlrDevice;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -358,7 +358,7 @@ struct SSwitchDevice {
|
||||||
DYNLISTENER(destroy);
|
DYNLISTENER(destroy);
|
||||||
DYNLISTENER(toggle);
|
DYNLISTENER(toggle);
|
||||||
|
|
||||||
bool operator==(const SSwitchDevice& other) {
|
bool operator==(const SSwitchDevice& other) const {
|
||||||
return pWlrDevice == other.pWlrDevice;
|
return pWlrDevice == other.pWlrDevice;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -33,7 +33,7 @@ struct SDwindleNodeData {
|
||||||
bool valid = true;
|
bool valid = true;
|
||||||
|
|
||||||
// For list lookup
|
// For list lookup
|
||||||
bool operator==(const SDwindleNodeData& rhs) {
|
bool operator==(const SDwindleNodeData& rhs) const {
|
||||||
return pWindow == rhs.pWindow && workspaceID == rhs.workspaceID && position == rhs.position && size == rhs.size && pParent == rhs.pParent &&
|
return pWindow == rhs.pWindow && workspaceID == rhs.workspaceID && position == rhs.position && size == rhs.size && pParent == rhs.pParent &&
|
||||||
children[0] == rhs.children[0] && children[1] == rhs.children[1];
|
children[0] == rhs.children[0] && children[1] == rhs.children[1];
|
||||||
}
|
}
|
||||||
|
|
|
@ -30,7 +30,7 @@ struct SMasterNodeData {
|
||||||
|
|
||||||
int workspaceID = -1;
|
int workspaceID = -1;
|
||||||
|
|
||||||
bool operator==(const SMasterNodeData& rhs) {
|
bool operator==(const SMasterNodeData& rhs) const {
|
||||||
return pWindow == rhs.pWindow;
|
return pWindow == rhs.pWindow;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -39,7 +39,7 @@ struct SMasterWorkspaceData {
|
||||||
int workspaceID = -1;
|
int workspaceID = -1;
|
||||||
eOrientation orientation = ORIENTATION_LEFT;
|
eOrientation orientation = ORIENTATION_LEFT;
|
||||||
|
|
||||||
bool operator==(const SMasterWorkspaceData& rhs) {
|
bool operator==(const SMasterWorkspaceData& rhs) const {
|
||||||
return workspaceID == rhs.workspaceID;
|
return workspaceID == rhs.workspaceID;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -14,7 +14,7 @@ struct SToplevelClient {
|
||||||
int ref = 0;
|
int ref = 0;
|
||||||
wl_resource* resource = nullptr;
|
wl_resource* resource = nullptr;
|
||||||
|
|
||||||
bool operator==(const SToplevelClient& other) {
|
bool operator==(const SToplevelClient& other) const {
|
||||||
return resource == other.resource;
|
return resource == other.resource;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -36,7 +36,7 @@ struct SToplevelFrame {
|
||||||
|
|
||||||
CWindow* pWindow = nullptr;
|
CWindow* pWindow = nullptr;
|
||||||
|
|
||||||
bool operator==(const SToplevelFrame& other) {
|
bool operator==(const SToplevelFrame& other) const {
|
||||||
return resource == other.resource && client == other.client;
|
return resource == other.resource && client == other.client;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,5 +1,3 @@
|
||||||
#define _POSIX_C_SOURCE 200809L
|
|
||||||
|
|
||||||
#include "../includes.hpp"
|
#include "../includes.hpp"
|
||||||
#include "../helpers/MiscFunctions.hpp"
|
#include "../helpers/MiscFunctions.hpp"
|
||||||
#include "ext-workspace-unstable-v1-protocol.h"
|
#include "ext-workspace-unstable-v1-protocol.h"
|
||||||
|
|
Loading…
Reference in a new issue