Rewrote how input text box focus is decided

This commit is contained in:
Yousef Khadadeh 2026-05-07 21:48:47 +03:00
parent 1585e0aa67
commit 8b3e321ab5
41 changed files with 317 additions and 490 deletions

View file

@ -102,3 +102,7 @@ void DrawingProgramScreen::input_window_resize_callback(const InputManager::Wind
void DrawingProgramScreen::input_window_scale_callback(const InputManager::WindowScaleCallbackArgs& w) {
}
std::optional<InputManager::TextBoxStartInfo> DrawingProgramScreen::get_text_box_start_info() {
return main.world->get_text_box_start_info();
}

View file

@ -27,4 +27,5 @@ class DrawingProgramScreen : public Screen {
virtual void input_finger_motion_callback(const InputManager::FingerMotionCallbackArgs& motion) override;
virtual void input_window_resize_callback(const InputManager::WindowResizeCallbackArgs& w) override;
virtual void input_window_scale_callback(const InputManager::WindowScaleCallbackArgs& w) override;
virtual std::optional<InputManager::TextBoxStartInfo> get_text_box_start_info() override;
};

View file

@ -30,5 +30,6 @@ void Screen::input_finger_motion_callback(const InputManager::FingerMotionCallba
void Screen::input_window_resize_callback(const InputManager::WindowResizeCallbackArgs& w) {}
void Screen::input_window_scale_callback(const InputManager::WindowScaleCallbackArgs& w) {}
void Screen::input_app_about_to_go_to_background_callback() {}
std::optional<InputManager::TextBoxStartInfo> Screen::get_text_box_start_info() { return std::nullopt; }
Screen::~Screen() {}

View file

@ -32,6 +32,7 @@ class Screen {
virtual void input_window_resize_callback(const InputManager::WindowResizeCallbackArgs& w);
virtual void input_window_scale_callback(const InputManager::WindowScaleCallbackArgs& w);
virtual void input_app_about_to_go_to_background_callback();
virtual std::optional<InputManager::TextBoxStartInfo> get_text_box_start_info();
virtual ~Screen();
protected: