File tree Expand file tree Collapse file tree 1 file changed +13
-3
lines changed
Expand file tree Collapse file tree 1 file changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -17,7 +17,9 @@ namespace CandyCoded.Forms
1717 public class Form : MonoBehaviour
1818 {
1919
20- public SubmitEvent FormSubmitted ;
20+ public SubmitEventObject FormSubmittedObject ;
21+
22+ public SubmitEventJSON FormSubmittedJSON ;
2123
2224 public Button submitButton ;
2325
@@ -81,7 +83,9 @@ private void HandleTabPress(Selectable selectable, Selectable[] allSelectable)
8183 private void HandleReturnPress ( )
8284 {
8385
84- FormSubmitted ? . Invoke ( GetFormRawValues ( ) ) ;
86+ FormSubmittedObject ? . Invoke ( GetFormRawValues ( ) ) ;
87+
88+ FormSubmittedJSON ? . Invoke ( ToJSON ( ) ) ;
8589
8690 }
8791
@@ -241,7 +245,13 @@ private void OnDisable()
241245 }
242246
243247 [ Serializable ]
244- public class SubmitEvent : UnityEvent < Dictionary < string , object > >
248+ public class SubmitEventObject : UnityEvent < Dictionary < string , object > >
249+ {
250+
251+ }
252+
253+ [ Serializable ]
254+ public class SubmitEventJSON : UnityEvent < string >
245255 {
246256
247257 }
You can’t perform that action at this time.
0 commit comments