mirror of
https://github.com/hyprwm/Hyprland.git
synced 2025-08-28 02:13:49 -07:00
text-input-v3: move to new impl
This commit is contained in:
@@ -3,17 +3,19 @@
|
||||
#include "../../helpers/WLListener.hpp"
|
||||
#include "../../macros.hpp"
|
||||
#include "../../helpers/Box.hpp"
|
||||
#include "../../helpers/signal/Listener.hpp"
|
||||
#include <memory>
|
||||
|
||||
struct wlr_text_input_v3;
|
||||
struct wlr_surface;
|
||||
struct wl_client;
|
||||
|
||||
struct STextInputV1;
|
||||
class CTextInputV3;
|
||||
|
||||
class CTextInput {
|
||||
public:
|
||||
CTextInput(std::weak_ptr<CTextInputV3> ti);
|
||||
CTextInput(STextInputV1* ti);
|
||||
CTextInput(wlr_text_input_v3* ti);
|
||||
~CTextInput();
|
||||
|
||||
bool isV3();
|
||||
@@ -34,13 +36,13 @@ class CTextInput {
|
||||
wlr_surface* focusedSurface();
|
||||
|
||||
private:
|
||||
void setFocusedSurface(wlr_surface* pSurface);
|
||||
void initCallbacks();
|
||||
void setFocusedSurface(wlr_surface* pSurface);
|
||||
void initCallbacks();
|
||||
|
||||
wlr_surface* pFocusedSurface = nullptr;
|
||||
int enterLocks = 0;
|
||||
wlr_text_input_v3* pWlrInput = nullptr;
|
||||
STextInputV1* pV1Input = nullptr;
|
||||
wlr_surface* pFocusedSurface = nullptr;
|
||||
int enterLocks = 0;
|
||||
std::weak_ptr<CTextInputV3> pV3Input;
|
||||
STextInputV1* pV1Input = nullptr;
|
||||
|
||||
DYNLISTENER(textInputEnable);
|
||||
DYNLISTENER(textInputDisable);
|
||||
@@ -48,4 +50,11 @@ class CTextInput {
|
||||
DYNLISTENER(textInputDestroy);
|
||||
DYNLISTENER(surfaceUnmapped);
|
||||
DYNLISTENER(surfaceDestroyed);
|
||||
|
||||
struct {
|
||||
CHyprSignalListener enable;
|
||||
CHyprSignalListener disable;
|
||||
CHyprSignalListener commit;
|
||||
CHyprSignalListener destroy;
|
||||
} listeners;
|
||||
};
|
Reference in New Issue
Block a user