mirror of
https://github.com/hyprwm/Hyprland.git
synced 2025-08-17 04:53:48 -07:00
IME: Refactor and fixup popups
This commit is contained in:
@@ -4,8 +4,10 @@
|
||||
#include "../../defines.hpp"
|
||||
#include "../../helpers/WLClasses.hpp"
|
||||
#include "TextInput.hpp"
|
||||
#include "InputMethodPopup.hpp"
|
||||
|
||||
class CInputManager;
|
||||
class CHyprRenderer;
|
||||
struct STextInputV1;
|
||||
|
||||
class CInputMethodRelay {
|
||||
@@ -27,18 +29,20 @@ class CInputMethodRelay {
|
||||
|
||||
SIMEKbGrab* getIMEKeyboardGrab(SKeyboard*);
|
||||
|
||||
void setIMEPopupFocus(SIMEPopup*, wlr_surface*);
|
||||
void updateInputPopup(SIMEPopup*);
|
||||
void damagePopup(SIMEPopup*);
|
||||
void removePopup(SIMEPopup*);
|
||||
void setIMEPopupFocus(CInputPopup*, wlr_surface*);
|
||||
void removePopup(CInputPopup*);
|
||||
|
||||
CInputPopup* popupFromCoords(const Vector2D& point);
|
||||
|
||||
void updateAllPopups();
|
||||
|
||||
private:
|
||||
std::unique_ptr<SIMEKbGrab> m_pKeyboardGrab;
|
||||
std::unique_ptr<SIMEKbGrab> m_pKeyboardGrab;
|
||||
|
||||
std::list<std::unique_ptr<CTextInput>> m_vTextInputs;
|
||||
std::list<SIMEPopup> m_lIMEPopups;
|
||||
std::vector<std::unique_ptr<CTextInput>> m_vTextInputs;
|
||||
std::vector<std::unique_ptr<CInputPopup>> m_vIMEPopups;
|
||||
|
||||
wlr_surface* m_pLastKbFocus = nullptr;
|
||||
wlr_surface* m_pLastKbFocus = nullptr;
|
||||
|
||||
DYNLISTENER(textInputNew);
|
||||
DYNLISTENER(IMECommit);
|
||||
@@ -50,4 +54,5 @@ class CInputMethodRelay {
|
||||
friend class CInputManager;
|
||||
friend class CTextInputV1ProtocolManager;
|
||||
friend struct CTextInput;
|
||||
friend class CHyprRenderer;
|
||||
};
|
||||
|
Reference in New Issue
Block a user