예제 #1
0
 public void CloseApplications()
 {
     if (this.Child != null)
     {
         ContentPresenter   item        = ContentContainer as ContentPresenter;
         IHostedApplication application = item.Tag as IHostedApplication;
         if (application != null)
         {
             IDesktopUserActions desktop = AifServiceContainer.Instance.GetService <IDesktopUserActions>();
             if (desktop != null)
             {
                 desktop.CloseDynamicApplication(application.ApplicationName);
             }
         }
         ContentContainer = null;
     }
 }
        public void CloseApplications()
        {
            List <IHostedApplication> tabApps = new List <IHostedApplication>();

            if (floatingWindows.Count > 0)
            {
                foreach (Window item in floatingWindows)
                {
                    IHostedApplication tabApp = item.Tag as IHostedApplication;
                    if (tabApp != null)
                    {
                        IDesktopUserActions desktop = AifServiceContainer.Instance.GetService <IDesktopUserActions>();
                        if (desktop != null)
                        {
                            desktop.CloseDynamicApplication(tabApp.ApplicationName);
                        }
                    }
                }
                floatingWindows.Clear();
            }
        }
예제 #3
0
 /// <summary>
 /// Provides access to system level Uii Functions
 /// </summary>
 /// <param name="desktopAccess"></param>
 public void SetDesktopUserActionsAccess(IDesktopUserActions desktopAccess)
 {
     if (uiiDesktop == null)
         uiiDesktop = desktopAccess;
 }