Fix a bunch of warnings
This commit is contained in:
@@ -143,12 +143,13 @@ namespace Nz::GL
|
||||
return context;
|
||||
}
|
||||
|
||||
std::unique_ptr<Context> EGLLoader::CreateContext(const OpenGLDevice* device, const ContextParams& params, WindowHandle handle, Context* shareContext) const
|
||||
std::unique_ptr<Context> EGLLoader::CreateContext([[maybe_unused]] const OpenGLDevice* device, const ContextParams& params, WindowHandle handle, Context* shareContext) const
|
||||
{
|
||||
std::unique_ptr<EGLContextBase> context;
|
||||
switch (handle.type)
|
||||
{
|
||||
case WindowBackend::Invalid:
|
||||
case WindowBackend::Cocoa: //< TODO?
|
||||
break;
|
||||
|
||||
case WindowBackend::X11:
|
||||
|
||||
@@ -43,6 +43,9 @@ namespace Nz
|
||||
}
|
||||
|
||||
Node::Node(Node&& node) noexcept :
|
||||
OnNodeInvalidation(std::move(node.OnNodeInvalidation)),
|
||||
OnNodeNewParent(std::move(node.OnNodeNewParent)),
|
||||
OnNodeRelease(std::move(node.OnNodeRelease)),
|
||||
m_childs(std::move(node.m_childs)),
|
||||
m_initialRotation(node.m_initialRotation),
|
||||
m_rotation(node.m_rotation),
|
||||
@@ -55,10 +58,7 @@ namespace Nz
|
||||
m_inheritPosition(node.m_inheritPosition),
|
||||
m_inheritRotation(node.m_inheritRotation),
|
||||
m_inheritScale(node.m_inheritScale),
|
||||
m_transformMatrixUpdated(false),
|
||||
OnNodeInvalidation(std::move(node.OnNodeInvalidation)),
|
||||
OnNodeNewParent(std::move(node.OnNodeNewParent)),
|
||||
OnNodeRelease(std::move(node.OnNodeRelease))
|
||||
m_transformMatrixUpdated(false)
|
||||
{
|
||||
if (m_parent)
|
||||
{
|
||||
|
||||
@@ -39,8 +39,6 @@ namespace Nz
|
||||
SkeletonComponent& entitySkeleton = m_registry.get<SkeletonComponent>(entity);
|
||||
|
||||
// TODO: When attaching for the first time, set the skeleton to the position of the node before attaching the node
|
||||
Node* skeletonRoot = entitySkeleton.GetRootNode();
|
||||
|
||||
entityNode.SetParent(entitySkeleton.GetRootNode());
|
||||
});
|
||||
|
||||
|
||||
@@ -35,8 +35,8 @@ namespace Nz
|
||||
|
||||
VertexBuffer::VertexBuffer(std::shared_ptr<const VertexDeclaration> vertexDeclaration, UInt32 vertexCount, BufferUsageFlags usage, const BufferFactory& bufferFactory, const void* initialData) :
|
||||
m_vertexDeclaration(std::move(vertexDeclaration)),
|
||||
m_startOffset(0),
|
||||
m_vertexCount(vertexCount)
|
||||
m_vertexCount(vertexCount),
|
||||
m_startOffset(0)
|
||||
{
|
||||
NazaraAssert(m_vertexDeclaration, "invalid vertex declaration");
|
||||
NazaraAssert(vertexCount > 0, "invalid vertex count");
|
||||
|
||||
@@ -119,7 +119,7 @@ namespace Nz
|
||||
return createInfo;
|
||||
}
|
||||
|
||||
std::vector<VkDynamicState> VulkanRenderPipeline::BuildDynamicStateList(const RenderPipelineInfo& pipelineInfo)
|
||||
std::vector<VkDynamicState> VulkanRenderPipeline::BuildDynamicStateList(const RenderPipelineInfo& /*pipelineInfo*/)
|
||||
{
|
||||
std::vector<VkDynamicState> dynamicStates;
|
||||
dynamicStates.push_back(VK_DYNAMIC_STATE_VIEWPORT);
|
||||
@@ -160,7 +160,7 @@ namespace Nz
|
||||
return createInfo;
|
||||
}
|
||||
|
||||
VkPipelineViewportStateCreateInfo VulkanRenderPipeline::BuildViewportInfo(const RenderPipelineInfo& pipelineInfo)
|
||||
VkPipelineViewportStateCreateInfo VulkanRenderPipeline::BuildViewportInfo(const RenderPipelineInfo& /*pipelineInfo*/)
|
||||
{
|
||||
VkPipelineViewportStateCreateInfo createInfo = {};
|
||||
createInfo.sType = VK_STRUCTURE_TYPE_PIPELINE_VIEWPORT_STATE_CREATE_INFO;
|
||||
|
||||
@@ -77,12 +77,12 @@ namespace Nz
|
||||
m_state->sizeVar.emplace_back();
|
||||
auto& sizeVar = m_state->sizeVar.back();
|
||||
|
||||
m_state->solver.addConstraint({ sizeVar >= minimumSize | kiwi::strength::required });
|
||||
m_state->solver.addConstraint({ (sizeVar >= minimumSize) | kiwi::strength::required });
|
||||
|
||||
if (maximumSize < std::numeric_limits<float>::infinity())
|
||||
m_state->solver.addConstraint({ sizeVar <= maximumSize | kiwi::strength::required });
|
||||
m_state->solver.addConstraint({ (sizeVar <= maximumSize) | kiwi::strength::required });
|
||||
|
||||
m_state->solver.addConstraint({ sizeVar >= perfectSpacePerWidget | kiwi::strength::medium });
|
||||
m_state->solver.addConstraint({ (sizeVar >= perfectSpacePerWidget) | kiwi::strength::medium });
|
||||
|
||||
sizeSum = sizeSum + sizeVar;
|
||||
});
|
||||
|
||||
@@ -150,7 +150,7 @@ namespace Nz
|
||||
UpdateHoveredWidget(event.x, event.y);
|
||||
}
|
||||
|
||||
void Canvas::OnEventMouseEntered(const EventHandler* eventHandler)
|
||||
void Canvas::OnEventMouseEntered(const EventHandler* /*eventHandler*/)
|
||||
{
|
||||
// Keep previous mouse states but not new ones
|
||||
if (m_mouseOwner != InvalidCanvasIndex)
|
||||
|
||||
@@ -238,7 +238,7 @@ namespace Nz
|
||||
|
||||
std::unique_ptr<ScrollAreaWidgetStyle> DefaultWidgetTheme::CreateStyle(ScrollAreaWidget* scrollAreaWidget) const
|
||||
{
|
||||
return nullptr;
|
||||
return nullptr; //< TODO
|
||||
}
|
||||
|
||||
std::unique_ptr<ScrollbarWidgetStyle> DefaultWidgetTheme::CreateStyle(ScrollbarWidget* scrollBarWidget) const
|
||||
|
||||
@@ -37,7 +37,7 @@ namespace Nz
|
||||
return false;
|
||||
}
|
||||
|
||||
bool ScrollbarButtonWidget::OnMouseButtonRelease(int x, int y, Mouse::Button button)
|
||||
bool ScrollbarButtonWidget::OnMouseButtonRelease(int /*x*/, int /*y*/, Mouse::Button button)
|
||||
{
|
||||
if (button == Mouse::Left)
|
||||
{
|
||||
|
||||
@@ -416,12 +416,6 @@ namespace Nz
|
||||
|
||||
void SimpleScrollbarWidgetStyle::Layout(const Vector2f& size)
|
||||
{
|
||||
float totalSize;
|
||||
if (GetOwnerWidget<ScrollbarWidget>()->GetOrientation() == ScrollbarOrientation::Horizontal)
|
||||
totalSize = size.x;
|
||||
else
|
||||
totalSize = size.y;
|
||||
|
||||
m_backgroundScrollbarSprite->SetSize(size);
|
||||
}
|
||||
|
||||
|
||||
@@ -247,7 +247,7 @@ namespace Nz
|
||||
}
|
||||
}
|
||||
|
||||
void TextAreaWidget::HandleWordSelection(const Vector2ui& position)
|
||||
void TextAreaWidget::HandleWordSelection(const Vector2ui& /*position*/)
|
||||
{
|
||||
NAZARA_USE_ANONYMOUS_NAMESPACE
|
||||
|
||||
|
||||
Reference in New Issue
Block a user