mirror of
https://github.com/Zelda64Recomp/Zelda64Recomp
synced 2026-05-30 17:06:28 -04:00
Finish drag and drop mod installation, disable mod refresh button and code mod toggle when game starts
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
#include "RmlUi/Core/StringUtilities.h"
|
||||
|
||||
#include "recomp_ui.h"
|
||||
#include "ui_element.h"
|
||||
#include "../core/ui_context.h"
|
||||
|
||||
@@ -134,6 +135,7 @@ void Element::handle_event(const Event& event) {
|
||||
}
|
||||
|
||||
void Element::ProcessEvent(Rml::Event &event) {
|
||||
ContextId prev_context = recompui::try_close_current_context();
|
||||
ContextId context = ContextId::null();
|
||||
Rml::ElementDocument* doc = event.GetTargetElement()->GetOwnerDocument();
|
||||
if (doc != nullptr) {
|
||||
@@ -198,6 +200,10 @@ void Element::ProcessEvent(Rml::Event &event) {
|
||||
if (context != ContextId::null() && did_open) {
|
||||
context.close();
|
||||
}
|
||||
|
||||
if (prev_context != ContextId::null()) {
|
||||
prev_context.open();
|
||||
}
|
||||
}
|
||||
|
||||
void Element::set_attribute(const Rml::String &attribute_key, const Rml::String &attribute_value) {
|
||||
|
||||
Reference in New Issue
Block a user