예제 #1
0
        void DrawRightPane()
        {
            HGUIToolbar.Begin();
            if (HGUIToolbar.Button("ソースコード整形"))
            {
                ShellUtils.Start("dotnet-format", $"-v diag {m_treeView.currentItem.m_json.name}.csproj");
            }
            //GUILayout.Space(1);

            GUILayout.FlexibleSpace();
            if (HGUIToolbar.Button("Sort"))
            {
                m_treeView.Sort(m_treeView.currentItem);
            }
            ScopeDisable.Begin(m_treeView.currentItem == null ? true : !m_treeView.currentItem.isDIRTY);
            if (HGUIToolbar.Button("Apply"))
            {
                m_treeView.ApplyAndSave(m_treeView.currentItem);
            }
            ScopeDisable.End();
            HGUIToolbar.End();

            using (var sc = new GUILayout.ScrollViewScope(m_scroll)) {
                m_scroll = sc.scrollPosition;
                m_treeView.DrawItem();
            }
        }
예제 #2
0
        /////////////////////////////////////////
        protected override void OnDoubleClickedItem(Item item)
        {
#if UNITY_EDITOR_WIN
            ShellUtils.Start("explorer.exe", $"{fs.currentDirectory}/{item.guid.ToAssetPath()}".separatorToOS());
#endif
        }