예제 #1
0
        private void Update()
        {
            Indices.Clear();
            LoadedInstanceIds.Clear();
            LoadedGroupIds.Clear();
            LoadedFileTypeIds.Clear();

            foreach (DatabasePackedFile packed in PackageFiles)
            {
                Indices.AddRange(packed.Indices);
            }

            foreach (DatabaseIndex index in Indices)
            {
                if (!LoadedInstanceIds.Contains(index.InstanceId))
                {
                    LoadedInstanceIds.Add(index.InstanceId);
                }

                if (!LoadedGroupIds.Contains(index.GroupId))
                {
                    LoadedGroupIds.Add(index.GroupId);
                }

                if (!LoadedFileTypeIds.Contains(index.TypeId))
                {
                    LoadedFileTypeIds.Add(index.TypeId);
                }
            }

            Indices.Changed();
            PackageFiles.Changed();
        }
예제 #2
0
 private void InstanceRegistryChanged(object sender, TGIRecord record)
 {
     foreach (DatabaseIndex i in Indices)
     {
         if (record.Id == i.InstanceId)
         {
             i.InstanceName = record.DisplayName;
         }
     }
     Indices.Changed();
 }