Add using text Show in Finder on macOS in Editor
This commit is contained in:
@@ -139,7 +139,7 @@ namespace FlaxEditor.Content.Import
|
||||
var menu = new ContextMenu();
|
||||
menu.AddButton("Rename", OnRenameClicked);
|
||||
menu.AddButton("Don't import", OnDontImportClicked);
|
||||
menu.AddButton("Show in Explorer", OnShowInExplorerClicked);
|
||||
menu.AddButton(Utilities.Constants.ShowInExplorer, OnShowInExplorerClicked);
|
||||
menu.Tag = node;
|
||||
menu.Show(node, location);
|
||||
}
|
||||
|
||||
@@ -14,5 +14,11 @@ namespace FlaxEditor.Utilities
|
||||
public const string FacebookUrl = "https://facebook.com/FlaxEngine";
|
||||
public const string YoutubeUrl = "https://youtube.com/c/FlaxEngine";
|
||||
public const string TwitterUrl = "https://twitter.com/FlaxEngine";
|
||||
|
||||
#if PLATFORM_MAC
|
||||
public const string ShowInExplorer = "Show in Finder";
|
||||
#else
|
||||
public const string ShowInExplorer = "Show in explorer";
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
@@ -58,7 +58,7 @@ namespace FlaxEditor.Windows
|
||||
|
||||
if (item is ContentFolder contentFolder && contentFolder.Node is ProjectTreeNode)
|
||||
{
|
||||
cm.AddButton("Show in explorer", () => FileSystem.ShowFileExplorer(CurrentViewFolder.Path));
|
||||
cm.AddButton(Utilities.Constants.ShowInExplorer, () => FileSystem.ShowFileExplorer(CurrentViewFolder.Path));
|
||||
}
|
||||
else if (isValidElement)
|
||||
{
|
||||
@@ -72,7 +72,7 @@ namespace FlaxEditor.Windows
|
||||
Open(e);
|
||||
});
|
||||
|
||||
cm.AddButton("Show in explorer", () => FileSystem.ShowFileExplorer(System.IO.Path.GetDirectoryName(item.Path)));
|
||||
cm.AddButton(Utilities.Constants.ShowInExplorer, () => FileSystem.ShowFileExplorer(System.IO.Path.GetDirectoryName(item.Path)));
|
||||
|
||||
if (item.HasDefaultThumbnail == false)
|
||||
{
|
||||
@@ -135,7 +135,7 @@ namespace FlaxEditor.Windows
|
||||
}
|
||||
else
|
||||
{
|
||||
cm.AddButton("Show in explorer", () => FileSystem.ShowFileExplorer(CurrentViewFolder.Path));
|
||||
cm.AddButton(Utilities.Constants.ShowInExplorer, () => FileSystem.ShowFileExplorer(CurrentViewFolder.Path));
|
||||
|
||||
b = cm.AddButton("Paste", _view.Paste);
|
||||
b.Enabled = _view.CanPaste();
|
||||
|
||||
@@ -195,7 +195,7 @@ namespace FlaxEditor.Windows
|
||||
_contextMenu.AddButton("Clear log", Clear);
|
||||
_contextMenu.AddButton("Copy selection", _output.Copy);
|
||||
_contextMenu.AddButton("Select All", _output.SelectAll);
|
||||
_contextMenu.AddButton("Show in explorer", () => FileSystem.ShowFileExplorer(Path.Combine(Globals.ProjectFolder, "Logs")));
|
||||
_contextMenu.AddButton(Utilities.Constants.ShowInExplorer, () => FileSystem.ShowFileExplorer(Path.Combine(Globals.ProjectFolder, "Logs")));
|
||||
_contextMenu.AddButton("Scroll to bottom", () => { _vScroll.TargetValue = _vScroll.Maximum; }).Icon = Editor.Icons.ArrowDown12;
|
||||
|
||||
// Setup editor options
|
||||
|
||||
@@ -274,7 +274,7 @@ namespace FlaxEditor.Windows.Profiler
|
||||
ContextMenuButton b;
|
||||
b = cm.AddButton("Open", () => Editor.Instance.ContentEditing.Open(assetItem));
|
||||
cm.AddButton("Show in content window", () => Editor.Instance.Windows.ContentWin.Select(assetItem));
|
||||
cm.AddButton("Show in explorer", () => FileSystem.ShowFileExplorer(System.IO.Path.GetDirectoryName(assetItem.Path)));
|
||||
cm.AddButton(Utilities.Constants.ShowInExplorer, () => FileSystem.ShowFileExplorer(System.IO.Path.GetDirectoryName(assetItem.Path)));
|
||||
cm.AddButton("Select actors using this asset", () => Editor.Instance.SceneEditing.SelectActorsUsingAsset(assetItem.ID));
|
||||
cm.AddButton("Show asset references graph", () => Editor.Instance.Windows.Open(new AssetReferencesGraphWindow(Editor.Instance, assetItem)));
|
||||
cm.AddButton("Copy name", () => Clipboard.Text = assetItem.NamePath);
|
||||
|
||||
@@ -157,7 +157,7 @@ namespace FlaxEditor.Windows.Search
|
||||
var cm = new FlaxEditor.GUI.ContextMenu.ContextMenu { Tag = assetItem };
|
||||
b = cm.AddButton("Open", () => Editor.Instance.ContentFinding.Open(Item));
|
||||
cm.AddSeparator();
|
||||
cm.AddButton("Show in explorer", () => FileSystem.ShowFileExplorer(System.IO.Path.GetDirectoryName(assetItem.Path)));
|
||||
cm.AddButton(Utilities.Constants.ShowInExplorer, () => FileSystem.ShowFileExplorer(System.IO.Path.GetDirectoryName(assetItem.Path)));
|
||||
cm.AddButton("Show in Content window", () => Editor.Instance.Windows.ContentWin.Select(assetItem, true));
|
||||
b.Enabled = proxy != null && proxy.CanReimport(assetItem);
|
||||
if (assetItem is BinaryAssetItem binaryAsset)
|
||||
|
||||
Reference in New Issue
Block a user