Exemplo n.º 1
0
 //public void Show()
 //{
 //        if (CustomWindow.Current != null)
 //        {
 //                CustomWindow.Current.ShowDialog(this);
 //        }
 //}
 public void Show(IDialogContainer container)
 {
     if (container != null)
     {
         container.ShowDialog(this);
     }
 }
Exemplo n.º 2
0
        private void OnShareMouseDown(Event e)
        {
            if (shareDialog == null)
            {
                shareDialog = CreateShareDialog();
            }

            if (shareTooltipRemoved)
            {
                dialogContainer.ShowDialog(shareDialog, 500, 300);
            }
            else if (!shareTooltipAdded)
            {
                Tooltip tooltip = new Tooltip("Thank you!", Direction.Bottom, 20)
                {
                    Top = -48
                };
                tooltip.HtmlElement.Style.Right = "39px";

                AppendChild(tooltip);
                shareTooltipAdded = true;

                tooltip.StartAppearAnimation();

                Window.SetTimeout(() =>
                {
                    tooltip.StartDisappearAnimation();
                    dialogContainer.ShowDialog(shareDialog, 500, 300);
                }, 2000);

                Window.SetTimeout(() =>
                {
                    RemoveChild(tooltip);
                    shareTooltipRemoved = true;
                }, 2000 + Tooltip.DisappearDuration);
            }
        }