mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-08 20:41:49 +00:00
'ifnot' template property + hpp
This commit is contained in:
parent
8b1c102cfe
commit
9ea67deb13
59 changed files with 204 additions and 201 deletions
|
|
@ -1,8 +1,9 @@
|
|||
#include "BlocksPreview.hpp"
|
||||
|
||||
#include "../../assets/Assets.h"
|
||||
#include "../../constants.h"
|
||||
#include "../../content/Content.h"
|
||||
#include "../../frontend/ContentGfxCache.h"
|
||||
#include "../../frontend/ContentGfxCache.hpp"
|
||||
#include "../../voxels/Block.h"
|
||||
#include "../../window/Camera.hpp"
|
||||
#include "../../window/Window.hpp"
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
#include "BlocksRenderer.hpp"
|
||||
|
||||
#include "../core/Mesh.hpp"
|
||||
#include "../../maths/UVRegion.hpp"
|
||||
#include "../../constants.h"
|
||||
|
|
@ -8,7 +9,7 @@
|
|||
#include "../../voxels/VoxelsVolume.h"
|
||||
#include "../../voxels/ChunksStorage.h"
|
||||
#include "../../lighting/Lightmap.h"
|
||||
#include "../../frontend/ContentGfxCache.h"
|
||||
#include "../../frontend/ContentGfxCache.hpp"
|
||||
#include "../../settings.h"
|
||||
|
||||
#include <glm/glm.hpp>
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
#include <algorithm>
|
||||
|
||||
#include "../../assets/Assets.h"
|
||||
#include "../../frontend/UiDocument.h"
|
||||
#include "../../frontend/UiDocument.hpp"
|
||||
#include "../../graphics/core/Batch2D.hpp"
|
||||
#include "../../graphics/core/Shader.hpp"
|
||||
#include "../../graphics/core/DrawContext.hpp"
|
||||
|
|
|
|||
|
|
@ -533,9 +533,13 @@ void UiXmlReader::addIgnore(const std::string& tag) {
|
|||
std::shared_ptr<UINode> UiXmlReader::readUINode(xml::xmlelement element) {
|
||||
if (element->has("if")) {
|
||||
const auto& cond = element->attr("if").getText();
|
||||
if (cond.empty() || cond == "false" || cond == "nil") {
|
||||
if (cond.empty() || cond == "false" || cond == "nil")
|
||||
return nullptr;
|
||||
}
|
||||
if (element->has("ifnot")) {
|
||||
const auto& cond = element->attr("ifnot").getText();
|
||||
if (!(cond.empty() || cond == "false" || cond == "nil"))
|
||||
return nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
const std::string& tag = element->getTag();
|
||||
|
|
|
|||
|
|
@ -1,14 +1,14 @@
|
|||
#ifndef FRONTEND_GUI_GUI_XML_HPP_
|
||||
#define FRONTEND_GUI_GUI_XML_HPP_
|
||||
|
||||
#include "GUI.hpp"
|
||||
#include "../../coders/xml.hpp"
|
||||
|
||||
#include <memory>
|
||||
#include <stack>
|
||||
#include <unordered_set>
|
||||
#include <unordered_map>
|
||||
|
||||
#include "GUI.hpp"
|
||||
#include "../../coders/xml.h"
|
||||
|
||||
namespace gui {
|
||||
class UiXmlReader;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue