mirror of
https://github.com/Siccity/xNode.git
synced 2025-12-20 17:26:02 +08:00
Added F for "Home" hotkey
This commit is contained in:
parent
14af49468e
commit
ed2edab72f
@ -140,8 +140,12 @@ namespace XNodeEditor {
|
|||||||
} else if (!IsHoveringNode) {
|
} else if (!IsHoveringNode) {
|
||||||
// If click outside node, release field focus
|
// If click outside node, release field focus
|
||||||
if (!isPanning) {
|
if (!isPanning) {
|
||||||
|
// I've got no idea which of these do what, so we'll just reset all of it.
|
||||||
GUIUtility.hotControl = 0;
|
GUIUtility.hotControl = 0;
|
||||||
GUIUtility.keyboardControl = 0;
|
GUIUtility.keyboardControl = 0;
|
||||||
|
EditorGUIUtility.editingTextField = false;
|
||||||
|
EditorGUIUtility.keyboardControl = 0;
|
||||||
|
EditorGUIUtility.hotControl = 0;
|
||||||
}
|
}
|
||||||
AssetDatabase.SaveAssets();
|
AssetDatabase.SaveAssets();
|
||||||
}
|
}
|
||||||
@ -165,6 +169,10 @@ namespace XNodeEditor {
|
|||||||
isPanning = false;
|
isPanning = false;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
case EventType.KeyDown:
|
||||||
|
if (EditorGUIUtility.editingTextField) break;
|
||||||
|
else if (e.keyCode == KeyCode.F) Home();
|
||||||
|
break;
|
||||||
case EventType.ValidateCommand:
|
case EventType.ValidateCommand:
|
||||||
if (e.commandName == "SoftDelete") RemoveSelectedNodes();
|
if (e.commandName == "SoftDelete") RemoveSelectedNodes();
|
||||||
else if (e.commandName == "Duplicate") DublicateSelectedNodes();
|
else if (e.commandName == "Duplicate") DublicateSelectedNodes();
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user