mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-04-03 20:03:50 +00:00
chore(application): extract appearance controller and unify UI flow
- Refactor UI application architecture: extracted appearance controller into ui_services.hpp + implementation updates - Update UI components and managers to use new service layer: - `action_bar_panel`, `auth_screen`, `character_screen`, `chat_panel`, `combat_ui`, `dialog_manager`, `game_screen`, `settings_panel`, `social_panel`, `toast_manager`, `ui_manager`, `window_manager` - Adjust core application entrypoints: - application.cpp - Update component implementations for new controller flow: - action_bar_panel.cpp, `chat_panel.cpp`, `combat_ui.cpp`, `dialog_manager.cpp`, `game_screen.cpp`, `settings_panel.cpp`, `social_panel.cpp`, `toast_manager.cpp`, `window_manager.cpp` These staged changes implement a major architectural refactor for UI/appearance controller separation
This commit is contained in:
parent
d43397163e
commit
1c0e9dd1df
23 changed files with 315 additions and 134 deletions
|
|
@ -1,5 +1,6 @@
|
|||
#pragma once
|
||||
|
||||
#include "ui/ui_services.hpp"
|
||||
#include "game/game_handler.hpp"
|
||||
#include <imgui.h>
|
||||
#include <string>
|
||||
|
|
@ -48,6 +49,9 @@ public:
|
|||
void setOnBack(std::function<void()> cb) { onBack = std::move(cb); }
|
||||
void setOnDeleteCharacter(std::function<void(uint64_t)> cb) { onDeleteCharacter = std::move(cb); }
|
||||
|
||||
/// Set services (dependency injection)
|
||||
void setServices(const UIServices& services) { services_ = services; }
|
||||
|
||||
/**
|
||||
* Reset selection state (e.g., when switching servers)
|
||||
*/
|
||||
|
|
@ -89,6 +93,8 @@ public:
|
|||
void selectCharacterByName(const std::string& name);
|
||||
|
||||
private:
|
||||
UIServices services_; // Injected service references
|
||||
|
||||
// UI state
|
||||
int selectedCharacterIndex = -1;
|
||||
bool characterSelected = false;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue