/// <summary> /// Creates and initializes a new instance of the Popup class. /// </summary> /// <param name="parent">The EvasObject to which the new popup will be attached as a child.</param> /// <since_tizen> preview </since_tizen> public Popup(EvasObject parent) : base(parent) { _dismissed = new SmartEvent(this, "dismissed"); _dismissed.On += (sender, e) => { Dismissed?.Invoke(this, EventArgs.Empty); }; _blockClicked = new SmartEvent(this, "block,clicked"); _blockClicked.On += (sender, e) => { OutsideClicked?.Invoke(this, EventArgs.Empty); }; _timeout = new SmartEvent(this, "timeout"); _timeout.On += (sender, e) => { TimedOut?.Invoke(this, EventArgs.Empty); }; _showFinished = new SmartEvent(this, "show,finished"); _showFinished.On += (sender, e) => { ShowAnimationFinished?.Invoke(this, EventArgs.Empty); }; }
protected override IntPtr CreateHandle(EvasObject parent) { _popup = new Popup(parent); _popup.Dismissed += (s, e) => { OnDismissed(); Dismissed?.Invoke(s, e); }; _popup.OutsideClicked += (s, e) => { OutsideClicked?.Invoke(s, e); }; _popup.TimedOut += (s, e) => { TimedOut?.Invoke(s, e); }; _popup.ShowAnimationFinished += (s, e) => { ShowAnimationFinished?.Invoke(s, e); }; return(_popup); }