Пример #1
0
            // Token: 0x060000AE RID: 174 RVA: 0x00007A94 File Offset: 0x00005C94
            protected override void OnItemContextMenu(GUIListViewContextMenuArgs args)
            {
                base.OnItemContextMenu(args);
                if (base.SelectedItemsCount < 1)
                {
                    return;
                }
                GUIUtility.hotControl = 0;
                AssetBundleManifestUI.Listbox.Model model = args.Model as AssetBundleManifestUI.Listbox.Model;
                GenericMenu genericMenu = new GenericMenu();

                genericMenu.AddItem(new GUIContent((Application.platform == null) ? "Reveal in Finder" : "Show in Explorer"), false, (base.SelectedItemsCount <= 10) ? new GenericMenu.MenuFunction2(this.OnContextMenuShowInExplorer) : null, model);
                genericMenu.AddItem(new GUIContent(string.Empty), false, null);
                genericMenu.AddItem(new GUIContent("Copy Full Path"), false, new GenericMenu.MenuFunction(this.OnContextMenuCopyFullPath));
                genericMenu.DropDown(new Rect(args.MenuLocation.x, args.MenuLocation.y, 0f, 0f));
                Event.current.Use();
                base.Editor.Repaint();
            }
Пример #2
0
            // Token: 0x060001A8 RID: 424 RVA: 0x0000C810 File Offset: 0x0000AA10
            protected override void OnItemContextMenu(GUIListViewContextMenuArgs args)
            {
                base.OnItemContextMenu(args);
                if (base.SelectedItemsCount < 1)
                {
                    return;
                }
                FindAssetUsage.AssetProxy assetProxy = args.Model as FindAssetUsage.AssetProxy;
                bool        flag        = FileUtil2.Exists(assetProxy.AssetPath);
                GenericMenu genericMenu = new GenericMenu();

                genericMenu.AddItem(new GUIContent((Application.platform == null) ? "Reveal in Finder" : "Show in Explorer"), false, flag ? new GenericMenu.MenuFunction(this.OnContextMenuShowInExplorer) : null);
                genericMenu.AddItem(new GUIContent("Open %enter"), false, FileUtil2.Exists(assetProxy.AssetPath) ? new GenericMenu.MenuFunction(this.OnContextMenuOpenWithDefaultApp) : null);
                genericMenu.AddItem(new GUIContent(string.Empty), false, null);
                genericMenu.AddItem(new GUIContent("Select in Project _enter"), false, flag ? new GenericMenu.MenuFunction(this.OnContextMenuSelect) : null);
                genericMenu.AddItem(new GUIContent("Find References in Scene"), false, (base.SelectedItemsCount == 1) ? new GenericMenu.MenuFunction(this.OnContextMenuFindReferencesInScene) : null);
                genericMenu.AddItem(new GUIContent(string.Empty), false, null);
                genericMenu.AddItem(new GUIContent("Copy Full Path"), false, flag ? new GenericMenu.MenuFunction(this.OnContextMenuCopyFullPath) : null);
                genericMenu.DropDown(new Rect(args.MenuLocation.x, args.MenuLocation.y, 0f, 0f));
                Event.current.Use();
                base.Editor.Repaint();
            }