Content


NTL
Core
IWindowListener

IWindowListener



Describes window listener. You may set it to window to receive notifications about events happened to window or system. Form sets listener to associated window. What each event means is pretty clear from it name, so we don't provide additional description here. You may have a look at form service. There are corresponding notifications with descriptions.

You can find more information in comments below.

class IWindowListener : public virtual IWindowListenerOnMessage
{
public:
    virtual void OnCreate() = 0;
    virtual void OnDestroy() = 0;
    virtual void OnActivate(const MessageWindowActivate &m) = 0;
    virtual void OnDeactivate() = 0;
    virtual void OnSetFocus() = 0;
    virtual void OnKillFocus() = 0;
    virtual void OnEnable() = 0;
    virtual void OnDisable() = 0;
    virtual void OnClose(CloseAction &action) = 0;
    virtual void OnShow() = 0;
    virtual void OnHide() = 0;
    virtual void OnActivateApp() = 0;
    virtual void OnDeactivateApp() = 0;
    virtual void OnMove(const MessagePosition &m) = 0;
    virtual void OnRestore(const MessageSize &m) = 0;
    virtual void OnMinimize(const MessageSize &m) = 0;
    virtual void OnMaximize(const MessageSize &m) = 0;
    virtual void OnResizing(const MessageWindowResizing &m) = 0;
    virtual void OnMoving(const MessageRect &m) = 0;
    virtual void OnEnterSizeMove() = 0;
    virtual void OnExitSizeMove() = 0;
    virtual void OnKeyDown(const MessageKey &m) = 0;
    virtual void OnKeyUp(const MessageKey &m) = 0;
    virtual void OnChar(const MessageChar &m) = 0;
    virtual void OnDeadChar(const MessageChar &m) = 0;
    virtual void OnHScroll(const MessageWindowScroll &m) = 0;
    virtual void OnVScroll(const MessageWindowScroll &m) = 0;
    virtual void OnGestureZoom(const MessagePosition &m) = 0;
    virtual void OnGesturePan(const MessagePosition &m) = 0;
    virtual void OnGestureRotate(const MessagePosition &m) = 0;
    virtual void OnGestureTwoFingerTap(const MessagePosition &m) = 0;
    virtual void OnGesturePressAndTap(const MessagePosition &m) = 0;
    virtual void OnGestureNotify() = 0;
    virtual void OnMouseMove(const MessageMouse &m) = 0;
    virtual void OnLeftMouseButtonDown(const MessageMouse &m) = 0;
    virtual void OnLeftMouseButtonUp(const MessageMouse &m) = 0;
    virtual void OnLeftMouseButtonDoubleClick(const MessageMouse &m) = 0;
    virtual void OnRightMouseButtonDown(const MessageMouse &m) = 0;
    virtual void OnRightMouseButtonUp(const MessageMouse &m) = 0;
    virtual void OnRightMouseButtonDoubleClick(const MessageMouse &m) = 0;
    virtual void OnMiddleMouseButtonDown(const MessageMouse &m) = 0;
    virtual void OnMiddleMouseButtonUp(const MessageMouse &m) = 0;
    virtual void OnMiddleMouseButtonDoubleClick(const MessageMouse &m) = 0;
    virtual void OnMouseVerticalWheel(const MessageMouseWheel &m) = 0;
    virtual void OnMouseHorizontalWheel(const MessageMouseWheel &m) = 0;
    virtual void OnMouseHover(const MessageMouse &m) = 0;
    virtual void OnMouseLeave() = 0;
    virtual void OnLoseCapture() = 0;
    virtual void OnPaint(const MessageRect &m) = 0;
    virtual void OnQueryEndSession(bool &restricted) = 0;
    virtual void OnQueryOpen(bool &restricted) = 0;
    virtual void OnEndSession(const MessageEndSession &m) = 0;
    virtual void OnDeviceModeChange() = 0;
    virtual void OnTimeChange() = 0;
    virtual void OnInputLanguageChangeRequest(bool &restricted) = 0;
    virtual void OnInputLanguageChange() = 0;
    virtual void OnDisplayChange(const MessageSize &m) = 0;
    virtual void OnThemeChanged() = 0;
    virtual void OnClipboardUpdate() = 0;
    virtual void OnDropFiles(const MessageDropFiles &m, bool accepted) = 0;
    virtual void OnTouch(const MessageTouch &m) = 0;
    virtual void OnPasteString(const MessagePasteString &m) = 0; // Called when paste operation was requested and there is something to paste 
};

Remarks

Below you can find methods' availability/usage information depending on the operating system. Windows is the most powerful and user friendly operating system. Many methods are used under the Windows while only few of them are used on another operating systems.

Option Windows Android Linux
OnCreate + + N/A
OnDestroy + + +
OnActivate + + N/A
OnDeactivate + + N/A
OnSetFocus + + +
OnKillFocus + + +
OnEnable + N/A +
OnDisable + N/A +
OnClose + N/A +
OnShow + + +
OnHide + + +
OnActivateApp + + N/A
OnDeactivateApp + + N/A
OnMove + N/A +
OnRestore + N/A N/A
OnMinimize + N/A N/A
OnMaximize + N/A N/A
OnResizing + + +
OnMoving + N/A N/A
OnEnterSizeMove + N/A N/A
OnExitSizeMove + N/A N/A
OnKeyDown + + +
OnKeyUp + + +
OnChar + N/A +
OnDeadChar + N/A N/A
OnHScroll + N/A N/A
OnVScroll + N/A N/A
OnGestureZoom + N/A N/A
OnGesturePan + N/A N/A
OnGestureRotate + N/A N/A
OnGestureTwoFingerTap + N/A N/A
OnGesturePressAndTap + N/A N/A
OnGestureNotify + N/A N/A
OnMouseMove + + +
OnLeftMouseButtonDown + + +
OnLeftMouseButtonUp + + +
OnLeftMouseButtonDoubleClick + N/A -
OnRightMouseButtonDown + + +
OnRightMouseButtonUp + + +
OnRightMouseButtonDoubleClick + N/A -
OnMiddleMouseButtonDown + N/A +
OnMiddleMouseButtonUp + N/A +
OnMiddleMouseButtonDoubleClick + N/A -
OnMouseVerticalWheel + N/A +
OnMouseHorizontalWheel + N/A N/A
OnMouseHover + N/A +
OnMouseLeave + N/A +
OnLoseCapture + N/A N/A
OnPaint + + +
OnQueryEndSession + N/A N/A
OnQueryOpen + N/A N/A
OnEndSession + N/A N/A
OnDeviceModeChange + + N/A
OnTimeChange + N/A N/A
OnInputLanguageChangeRequest + N/A N/A
OnInputLanguageChange + N/A N/A
OnDisplayChange + N/A N/A
OnThemeChanged + N/A N/A
OnClipboardUpdate + N/A N/A
OnDropFiles + N/A -
OnTouch + N/A N/A
OnPasteString + N/A +

Where:

+ - available
- - not used
N/A - not available on the platform

Namespace: nitisa
Include: Nitisa/Interfaces/IWindowListener.h