hachem.wtf
aboutsummaryrefslogtreecommitdiff
path: root/src/ui/ui.h
diff options
context:
space:
mode:
authorhachem <im@hachem.wtf>2026-09-16 12:25:58 +0200
committerhachem <im@hachem.wtf>2026-09-16 12:25:58 +0200
commitabf4747f6c83350ec1c57db53cdda82b7aee5ec8 (patch)
tree7559becc40bcb2349b2960725311bb1fe27b2d0e /src/ui/ui.h
parent61ef54dd242d26f3668e306750e623d337978307 (diff)
feat: improve layout and themes
Diffstat (limited to 'src/ui/ui.h')
-rw-r--r--src/ui/ui.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/ui/ui.h b/src/ui/ui.h
index 251a2b4..c5ecf56 100644
--- a/src/ui/ui.h
+++ b/src/ui/ui.h
@@ -12,6 +12,8 @@
#include <filesystem>
#include <string>
#include <string_view>
+#include <unordered_map>
+#include <unordered_set>
#include <vector>
namespace Hsdbg
@@ -71,6 +73,8 @@ namespace Hsdbg
auto draw_menu_bar(Debugger& debugger) -> void;
auto draw_toolbar(Debugger& debugger) -> void;
+
+ auto handle_shortcuts(Debugger& debugger) -> void;
auto draw_status_bar(const Debugger& debugger) -> void;
auto draw_load_target_popup(Debugger& debugger) -> void;
auto draw_preferences_window() -> void;
@@ -100,6 +104,8 @@ namespace Hsdbg
auto follow_stop(Debugger& debugger) -> void;
auto follow_target(Debugger& debugger) -> void;
+ auto snapshot_values(const Debugger& debugger) -> void;
+
auto follow_selected_frame(Debugger& debugger) -> void;
auto show_frame(const StackFrame& frame) -> void;
@@ -116,6 +122,7 @@ namespace Hsdbg
Theme m_theme;
std::vector<ThemeEntry> m_themes;
+ std::vector<Theme> m_theme_previews;
bool m_prefs_open_prev = false;
ImFont* m_font_ui = nullptr;
@@ -145,6 +152,7 @@ namespace Hsdbg
std::string expression;
std::string value;
bool ok = false;
+ bool changed = false;
};
std::vector<Watch> m_watches;
@@ -168,6 +176,17 @@ namespace Hsdbg
uint64_t m_followed_stop = 0;
std::filesystem::path m_followed_target;
+ std::unordered_map<std::string, std::string> m_prev_locals;
+ std::unordered_map<std::string, std::string> m_curr_locals;
+ std::unordered_map<std::string, uint64_t> m_prev_registers;
+ std::unordered_map<std::string, uint64_t> m_curr_registers;
+ std::unordered_set<std::string> m_changed_locals;
+ std::string m_snapshot_function;
+ uint64_t m_snapshot_stop = 0;
+ uint64_t m_snapshot_thread = 0;
+ uint32_t m_snapshot_frame = 0;
+ bool m_snapshot_comparable = false;
+
std::filesystem::path m_revealed_source;
bool m_profiler_revealed = false;