Remove widgets namespace

This commit is contained in:
scawful
2023-11-25 22:45:00 -05:00
parent 664b03d2e3
commit 9336f9cb9d
2 changed files with 12 additions and 4 deletions

View File

@@ -9,7 +9,14 @@
namespace yaze { namespace yaze {
namespace app { namespace app {
namespace gui { namespace gui {
namespace widgets {
void RenderTabItem(const std::string &title,
const std::function<void()> &render_func) {
if (ImGui::BeginTabItem(title.c_str())) {
render_func();
ImGui::EndTabItem();
}
}
// ============================================================================ // ============================================================================
// 65816 LanguageDefinition // 65816 LanguageDefinition
@@ -92,7 +99,6 @@ TextEditor::LanguageDefinition GetAssemblyLanguageDef() {
return language_65816; return language_65816;
} }
} // namespace widgets
} // namespace gui } // namespace gui
} // namespace app } // namespace app
} // namespace yaze } // namespace yaze

View File

@@ -5,6 +5,7 @@
#include <imgui/imgui.h> #include <imgui/imgui.h>
#include <imgui/misc/cpp/imgui_stdlib.h> #include <imgui/misc/cpp/imgui_stdlib.h>
#include <functional>
#include <vector> #include <vector>
#include "absl/status/status.h" #include "absl/status/status.h"
@@ -14,10 +15,12 @@
namespace yaze { namespace yaze {
namespace app { namespace app {
namespace gui { namespace gui {
namespace widgets {
TextEditor::LanguageDefinition GetAssemblyLanguageDef(); TextEditor::LanguageDefinition GetAssemblyLanguageDef();
void RenderTabItem(const std::string& title,
const std::function<void()>& render_func);
class BitmapViewer { class BitmapViewer {
public: public:
BitmapViewer() : current_bitmap_index_(0) {} BitmapViewer() : current_bitmap_index_(0) {}
@@ -65,7 +68,6 @@ class BitmapViewer {
int current_bitmap_index_; int current_bitmap_index_;
}; };
} // namespace widgets
} // namespace gui } // namespace gui
} // namespace app } // namespace app
} // namespace yaze } // namespace yaze