Skip to content

Commit

Permalink
* Fix OnReturnPressedEvent inspector view
Browse files Browse the repository at this point in the history
  • Loading branch information
mops committed Nov 15, 2018
1 parent 60c8701 commit e1a5d58
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,9 @@ public class MobileInputEditor : Editor {
private SerializedObject _object;

/// <summary>
/// Return key type
/// Return press event
/// </summary>
private SerializedProperty _returnKey;
private SerializedProperty _onReturnPressedEvent;

#if UNITY_IOS
/// <summary>
Expand All @@ -58,7 +58,7 @@ public class MobileInputEditor : Editor {
private void OnEnable () {
_target = (MobileInputField) target;
_object = new SerializedObject (target);
_returnKey = _object.FindProperty ("ReturnKey");
_onReturnPressedEvent = _object.FindProperty ("OnReturnPressedEvent");
#if UNITY_IOS
_isWithDoneButton = _object.FindProperty ("IsWithDoneButton");
_isWithClearButton = _object.FindProperty ("IsWithClearButton");
Expand All @@ -82,6 +82,7 @@ public override void OnInspectorGUI () {
_target.IsWithClearButton = GUILayout.Toggle (_target.IsWithClearButton, " Show \"Clear\" button");
GUILayout.Space (OFFSET);
#endif
EditorGUILayout.PropertyField (_onReturnPressedEvent);
if (EditorGUI.EndChangeCheck ()) {
_object.ApplyModifiedProperties ();
}
Expand Down

0 comments on commit e1a5d58

Please sign in to comment.