Beispiel #1
0
 private void ShowApplicationsNull()
 {
     this.statusMain.Text = "Loading Application List";
     if (localApps == null)
     {
         String installedAppPath = "//private/var/root/Library/Installer/LocalPackages.plist";
         if (myPhone.Exists(installedAppPath))
         {
             using (Stream inStream = iPhoneFile.OpenRead(myPhone, installedAppPath)) {
                 localApps = AppList.ReadXmlStream(inStream);
             }
         }
         CreateAppListGroups(localApps);
         listApps.Items.Clear();
         for (Int32 i = 0; i < localApps.Applications.Length; i++)
         {
             iPhoneApp    app  = localApps.Applications[i];
             ListViewItem item = new ListViewItem();
             item.Name        = app.Name;
             item.Text        = app.Name;
             item.ToolTipText = app.Name + Environment.NewLine + app.Description;
             ListViewItem.ListViewSubItem version = new ListViewItem.ListViewSubItem();
             version.Name = "Version";
             version.Text = app.Version;
             item.SubItems.Add(version);
             ListViewItem.ListViewSubItem desc = new ListViewItem.ListViewSubItem();
             desc.Name = "Description";
             desc.Text = app.Description;
             item.SubItems.Add(desc);
             ListViewItem.ListViewSubItem pub = new ListViewItem.ListViewSubItem();
             pub.Name = "Publisher";
             pub.Text = app.Source;
             item.SubItems.Add(pub);
             item.Group = listApps.Groups[app.Category];
             listApps.Items.Add(item);
         }
     }
     listApps.AutoResizeColumns(ColumnHeaderAutoResizeStyle.ColumnContent);
     listApps.Visible  = true;
     listFiles.Visible = false;
     SetStatus();
 }