void GUIDisplayControls()

in firestore/testapp/Assets/Firebase/Sample/Firestore/UIHandler.cs [258:315]


    void GUIDisplayControls() {
      if (UIEnabled) {
        controlsScrollViewVector = GUILayout.BeginScrollView(controlsScrollViewVector);

        GUILayout.BeginVertical();

        GUILayout.Label("CollectionPath:");
        collectionPath = GUILayout.TextField(collectionPath);

        GUILayout.Label("DocumentId (set to empty for autoid):");
        documentId = GUILayout.TextField(documentId);

        GUILayout.Label("Text:");
        if (fieldContents == null) {
          // TODO(rgowman): Provide instructions on how to set document contents here.
          fieldContents = "Sample text... (type here)";
        }
        fieldContents = GUILayout.TextField(fieldContents);

        GUILayout.Space(10);

        GUILayout.BeginVertical();

        if (Button("GetKnownValue", !operationInProgress)) {
          StartCoroutine(GetKnownValue());
        }

        if (Button("WriteDoc", !operationInProgress)) {
          // TODO(rgowman): allow these values to be set by the user via the UI.
          var data = new Dictionary<string, object>{
            {"f1", "v1"},
            {"f2", 2},
            {"f3", true},
            // TODO(rgowman): Add other types here too.
          };
          StartCoroutine(WriteDoc(GetDocumentReference(), data));
        }

        if (Button("UpdateDoc", !operationInProgress)) {
          // TODO(rgowman): allow these values to be set by the user via the UI.
          var data = new Dictionary<string, object>{
            {"f1", "v1b"},
            {"f4", "v4"},
            // TODO(rgowman): Add other types here too.
          };
          StartCoroutine(UpdateDoc(GetDocumentReference(), data));
        }

        if (Button("ReadDoc", !operationInProgress)) {
          StartCoroutine(ReadDoc(GetDocumentReference()));
        }

        GUILayout.EndVertical();

        GUILayout.EndVertical();
        GUILayout.EndScrollView();
      }
    }