UnityEditor.AssetServer.IsGUIDValid C# (CSharp) Method

IsGUIDValid() private method

private IsGUIDValid ( string guid ) : int
guid string
return int
        public static extern int IsGUIDValid(string guid);
        [MethodImpl(MethodImplOptions.InternalCall)]

Usage Example

示例#1
0
 private void DoSelectionChange()
 {
     if (this.lv.row != -1)
     {
         string firstSelected = this.GetFirstSelected();
         if (firstSelected != string.Empty)
         {
             this.selectedGUID = firstSelected;
         }
         if (AssetServer.IsGUIDValid(this.selectedGUID) != 0)
         {
             int num = 0;
             this.pv.lv.row = -1;
             ParentViewFolder[] folders = this.pv.folders;
             for (int i = 0; i < folders.Length; i++)
             {
                 ParentViewFolder parentViewFolder = folders[i];
                 if (parentViewFolder.guid == this.selectedGUID)
                 {
                     this.pv.lv.row = num;
                     return;
                 }
                 num++;
                 ParentViewFile[] files = parentViewFolder.files;
                 for (int j = 0; j < files.Length; j++)
                 {
                     ParentViewFile parentViewFile = files[j];
                     if (parentViewFile.guid == this.selectedGUID)
                     {
                         this.pv.lv.row = num;
                         return;
                     }
                     num++;
                 }
             }
         }
         else
         {
             this.pv.lv.row = -1;
         }
     }
 }
All Usage Examples Of UnityEditor.AssetServer::IsGUIDValid
AssetServer