tweak: removed docking toggle from main menu bar
This commit is contained in:
parent
e1b7e97348
commit
7565529412
|
|
@ -31,12 +31,10 @@ void draw_scene(sf::RenderTarget &target, sf::RenderStates const &states) {
|
|||
target.draw(rect, n_states);
|
||||
}
|
||||
|
||||
static bool dockspace = true;
|
||||
|
||||
void draw_main_menu_bar() {
|
||||
if (ImGui::BeginMenu("Edit")) {
|
||||
if (ImGui::MenuItem("Dockspace?")) {
|
||||
dockspace = !dockspace;
|
||||
if (ImGui::MenuItem("Menu item!")) {
|
||||
std::println("Wahooo!!!");
|
||||
}
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
|
|
@ -44,9 +42,7 @@ void draw_main_menu_bar() {
|
|||
|
||||
void draw_gui() {
|
||||
// draw your GUI
|
||||
if (dockspace) {
|
||||
ImGui::DockSpaceOverViewport(0, NULL, ImGuiDockNodeFlags_PassthruCentralNode);
|
||||
}
|
||||
ImGui::DockSpaceOverViewport(0, NULL, ImGuiDockNodeFlags_PassthruCentralNode);
|
||||
if (ImGui::Begin("My Window")) {
|
||||
ImGui::Text("A window with text and a button!!");
|
||||
if (ImGui::Button("My Button")) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue