Skip to content

Commit

Permalink
Integrate Latest @ 139483111
Browse files Browse the repository at this point in the history
- Fixed SDK links and removed reference to Firebase App in sample readmes.
- Moved control panel into a scroll view for devices with low resolutions.

CL: 139483111
  • Loading branch information
Stewart Miles committed Nov 17, 2016
1 parent f3fd5bb commit 5ea23da
Show file tree
Hide file tree
Showing 11 changed files with 71 additions and 70 deletions.
4 changes: 4 additions & 0 deletions analytics/testapp/Assets/TestApp/UIHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
public class UIHandler : MonoBehaviour {

public GUISkin fb_GUISkin;
private Vector2 controlsScrollViewVector = Vector2.zero;
private Vector2 scrollViewVector = Vector2.zero;
bool UIEnabled = true;
private string logText = "";
Expand Down Expand Up @@ -149,6 +150,8 @@ void GUIDisplayLog() {
// Render the buttons and other controls.
void GUIDisplayControls(){
if (UIEnabled) {
controlsScrollViewVector =
GUILayout.BeginScrollView(controlsScrollViewVector);
GUILayout.BeginVertical();

if (GUILayout.Button("Log Login")) {
Expand All @@ -167,6 +170,7 @@ void GUIDisplayControls(){
AnalyticsLevelUp();
}
GUILayout.EndVertical();
GUILayout.EndScrollView();
}
}

Expand Down
24 changes: 9 additions & 15 deletions analytics/testapp/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
The Firebase Analytics Unity Sample demonstrates logging a range of different
events using [Firebase Analytics](https://firebase.google.com/docs/analytics/)
with the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz).
[Firebase Unity SDK](https://firebase.google.com/docs/unity/setup).


## Requirements
Expand Down Expand Up @@ -35,7 +35,8 @@ with the
- For further details please refer to the
[general instructions](https://firebase.google.com/docs/ios/setup)
which describes how to configure a Firebase application for iOS.
- Download the [Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz)
- Download the
[Firebase Unity SDK](https://firebase.google.com/download/unity)
and unzip it somewhere convenient.
- Open the sample project in the Unity editor.
- Select the `File > Open Project` menu item.
Expand All @@ -45,15 +46,11 @@ with the
- Open the scene `MainScene`.
- Navigate to `Assets/TestApp/MainScene` in the `Project` window.
- Double click on `MainScene` file to open.
- Import the `Firebase App` plugin.
- Select the `Assets > Import Package > Custom Package` menu item.
- Import `FirebaseApp.unitypackage` from the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz), downloaded previously.
- Click the `Import` when the `Import Unity Package` window appears.
- Import the `Firebase Analytics` plugin.
- Select the `Assets > Import Package > Custom Package` menu item.
- Import `FirebaseAnalytics.unitypackage` from the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz), downloaded previously.
[Firebase Unity SDK](https://firebase.google.com/download/unity),
downloaded previously.
- Click the `Import` when the `Import Unity Package` window appears.
- Add the `GoogleService-Info.plist` file to the project.
- Navigate to the `Assets\TestApp` folder in the `Project` window.
Expand Down Expand Up @@ -110,7 +107,8 @@ with the
- For further details please refer to the
[general instructions](https://firebase.google.com/docs/android/setup)
which describes how to configure a Firebase application for Android.
- Download the [Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz)
- Download the
[Firebase Unity SDK](https://firebase.google.com/download/unity)
and unzip it somewhere convenient.
- Open the sample project in the Unity editor.
- Select the `File > Open Project` menu item.
Expand All @@ -120,15 +118,11 @@ with the
- Open the scene `MainScene`.
- Navigate to `Assets/TestApp/MainScene` in the `Project` window.
- Double click on `MainScene` file to open.
- Import the `Firebase App` plugin.
- Select the `Assets > Import Package > Custom Package` menu item.
- Import `FirebaseApp.unitypackage` from the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz), downloaded previously.
- Click the `Import` when the `Import Unity Package` window appears.
- Import the `Firebase Analytics` plugin.
- Select the `Assets > Import Package > Custom Package` menu item.
- Import `FirebaseAnalytics.unitypackage` from the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz), downloaded previously.
[Firebase Unity SDK](https://firebase.google.com/download/unity),
downloaded previously.
- Click the `Import` when the `Import Unity Package` window appears.
- Add the `google-services.json` file to the project.
- Navigate to the `Assets\TestApp` folder in the `Project` window.
Expand Down
6 changes: 5 additions & 1 deletion auth/testapp/Assets/TestApp/UIHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ public class UIHandler : MonoBehaviour {
// NOTE: In some versions of Unity the password input box does not work in
// iOS simulators.
public bool usePasswordInput = false;
private Vector2 controlsScrollViewVector = Vector2.zero;
private Vector2 scrollViewVector = Vector2.zero;
bool UIEnabled = true;

Expand Down Expand Up @@ -212,14 +213,16 @@ void HandleDeleteResult(Task authTask) {

// Render the log output in a scroll view.
void GUIDisplayLog() {
scrollViewVector = GUILayout.BeginScrollView (scrollViewVector);
scrollViewVector = GUILayout.BeginScrollView(scrollViewVector);
GUILayout.Label(logText);
GUILayout.EndScrollView();
}

// Render the buttons and other controls.
void GUIDisplayControls(){
if (UIEnabled) {
controlsScrollViewVector =
GUILayout.BeginScrollView(controlsScrollViewVector);
GUILayout.BeginVertical();
GUILayout.BeginHorizontal();
GUILayout.Label("Email:", GUILayout.Width(Screen.width * 0.20f));
Expand Down Expand Up @@ -252,6 +255,7 @@ void GUIDisplayControls(){
DeleteUser();
}
GUILayout.EndVertical();
GUILayout.EndScrollView();
}
}

Expand Down
24 changes: 9 additions & 15 deletions auth/testapp/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ The Firebase Auth Unity Sample demonstrates user authentication and
user profile operations using
[Firebase Authentication](https://firebase.google.com/docs/auth/)
with the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz).
[Firebase Unity SDK](https://firebase.google.com/docs/unity/setup).


## Requirements
Expand Down Expand Up @@ -41,7 +41,8 @@ with the
- For further details please refer to the
[general instructions](https://firebase.google.com/docs/ios/setup)
which describes how to configure a Firebase application for iOS.
- Download the [Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz)
- Download the
[Firebase Unity SDK](https://firebase.google.com/download/unity)
and unzip it somewhere convenient.
- Open the sample project in the Unity editor.
- Select the `File > Open Project` menu item.
Expand All @@ -51,15 +52,11 @@ with the
- Open the scene `MainScene`.
- Navigate to `Assets/TestApp/MainScene` in the `Project` window.
- Double click on `MainScene` file to open.
- Import the `Firebase App` plugin.
- Select the `Assets > Import Package > Custom Package` menu item.
- Import `FirebaseApp.unitypackage` from the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz), downloaded previously.
- Click the `Import` when the `Import Unity Package` window appears.
- Import the `Firebase Auth` plugin.
- Select the `Assets > Import Package > Custom Package` menu item.
- Import `FirebaseAuth.unitypackage` from the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz), downloaded previously.
[Firebase Unity SDK](https://firebase.google.com/download/unity),
downloaded previously.
- Click the `Import` when the `Import Unity Package` window appears.
- Add the `GoogleService-Info.plist` file to the project.
- Navigate to the `Assets\TestApp` folder in the `Project` window.
Expand Down Expand Up @@ -121,7 +118,8 @@ with the
- For further details please refer to the
[general instructions](https://firebase.google.com/docs/android/setup)
which describes how to configure a Firebase application for Android.
- Download the [Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz)
- Download the
[Firebase Unity SDK](https://firebase.google.com/download/unity)
and unzip it somewhere convenient.
- Open the sample project in the Unity editor.
- Select the `File > Open Project` menu item.
Expand All @@ -131,15 +129,11 @@ with the
- Open the scene `MainScene`.
- Navigate to `Assets/TestApp/MainScene` in the `Project` window.
- Double click on `MainScene` file to open.
- Import the `Firebase App` plugin.
- Select the `Assets > Import Package > Custom Package` menu item.
- Import `FirebaseApp.unitypackage` from the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz), downloaded previously.
- Click the `Import` when the `Import Unity Package` window appears.
- Import the `Firebase Auth` plugin.
- Select the `Assets > Import Package > Custom Package` menu item.
- Import `FirebaseAuth.unitypackage` from the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz), downloaded previously.
[Firebase Unity SDK](https://firebase.google.com/download/unity),
downloaded previously.
- Click the `Import` when the `Import Unity Package` window appears.
- Add the `google-services.json` file to the project.
- Navigate to the `Assets\TestApp` folder in the `Project` window.
Expand Down
4 changes: 4 additions & 0 deletions database/testapp/Assets/TestApp/UIHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ public class UIHandler : MonoBehaviour {

ArrayList leaderBoard;
Vector2 scrollPosition = Vector2.zero;
private Vector2 controlsScrollViewVector = Vector2.zero;

public GUISkin fb_GUISkin;

Expand Down Expand Up @@ -184,6 +185,8 @@ void GUIDisplayLog() {
// Render the buttons and other controls.
void GUIDisplayControls() {
if (UIEnabled) {
controlsScrollViewVector =
GUILayout.BeginScrollView(controlsScrollViewVector);
GUILayout.BeginVertical();
GUILayout.BeginHorizontal();
GUILayout.Label("Email:", GUILayout.Width(Screen.width * 0.20f));
Expand All @@ -203,6 +206,7 @@ void GUIDisplayControls() {
AddScore();
}
GUILayout.EndVertical();
GUILayout.EndScrollView();
}
}

Expand Down
11 changes: 7 additions & 4 deletions database/testapp/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
The Firebase Database Unity Sample demonstrates
[Firebase Realtime Database](https://firebase.google.com/docs/database/)
with the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz)
[Firebase Unity SDK](https://firebase.google.com/docs/unity/setup)
inside the Unity Editor.

## Requirements
Expand All @@ -12,7 +12,8 @@ inside the Unity Editor.

## Running the Sample inside the Editor

- Download the [Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz)
- Download the
[Firebase Unity SDK](https://firebase.google.com/download/unity)
and unzip it somewhere convenient.
- Open the sample project in the Unity editor.
- Select the `File > Open Project` menu item.
Expand All @@ -25,12 +26,14 @@ inside the Unity Editor.
- Import the `Firebase Auth` plugin.
- Select the `Assets > Import Package > Custom Package` menu item.
- Import `FirebaseAuth.unitypackage` from the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz), downloaded previously.
[Firebase Unity SDK](https://firebase.google.com/download/unity),
downloaded previously.
- Click the `Import` when the `Import Unity Package` window appears.
- Import the `Firebase Database` plugin.
- Select the `Assets > Import Package > Custom Package` menu item.
- Import `FirebaseDatabase.unitypackage` from the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz), downloaded previously.
[Firebase Unity SDK](https://firebase.google.com/download/unity),
downloaded previously.
- Click the `Import` when the `Import Unity Package` window appears.
- Turn off secure access. [Configure your rules for public access.](https://firebase.google.com/docs/database/security/quickstart#sample-rules)
- Change the line `SetEditorDatabaseUrl("https://YOUR-FIREBASE-APP.firebaseio.com/");`
Expand Down
4 changes: 4 additions & 0 deletions invites/testapp/Assets/TestApp/UIHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
public class UIHandler : MonoBehaviour {

public GUISkin fb_GUISkin;
private Vector2 controlsScrollViewVector = Vector2.zero;
private Vector2 scrollViewVector = Vector2.zero;
bool UIEnabled = true;
private string logText = "";
Expand Down Expand Up @@ -160,13 +161,16 @@ void GUIDisplayLog() {
// Render the buttons and other controls.
void GUIDisplayControls() {
if (UIEnabled) {
controlsScrollViewVector =
GUILayout.BeginScrollView(controlsScrollViewVector);
GUILayout.BeginVertical();

if (GUILayout.Button("Send Invite")) {
SendInvite();
}

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

Expand Down
24 changes: 9 additions & 15 deletions invites/testapp/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ The Firebase Dynamic Links and Invites Unity Sample demonstrates sending and
receiving [Firebase Invites](https://firebase.google.com/docs/invites/) and
[Firebase Dynamic Links](https://firebase.google.com/docs/dynamic-links/)
using the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz).
[Firebase Unity SDK](https://firebase.google.com/docs/unity/setup).


## Requirements
Expand Down Expand Up @@ -36,7 +36,8 @@ using the
- For further details please refer to the
[general instructions](https://firebase.google.com/docs/ios/setup)
which describes how to configure a Firebase application for iOS.
- Download the [Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz)
- Download the
[Firebase Unity SDK](https://firebase.google.com/download/unity)
and unzip it somewhere convenient.
- Open the sample project in the Unity editor.
- Select the `File > Open Project` menu item.
Expand All @@ -46,15 +47,11 @@ using the
- Open the scene `MainScene`.
- Navigate to `Assets/TestApp/MainScene` in the `Project` window.
- Double click on `MainScene` file to open.
- Import the `Firebase App` plugin.
- Select the `Assets > Import Package > Custom Package` menu item.
- Import `FirebaseApp.unitypackage` from the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz), downloaded previously.
- Click the `Import` when the `Import Unity Package` window appears.
- Import the `Firebase Invites and Dynamic Links` plugin.
- Select the `Assets > Import Package > Custom Package` menu item.
- Import `FirebaseInvites.unitypackage` from the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz), downloaded previously.
[Firebase Unity SDK](https://firebase.google.com/download/unity),
downloaded previously.
- Click the `Import` when the `Import Unity Package` window appears.
- Add the `GoogleService-Info.plist` file to the project.
- Navigate to the `Assets\TestApp` folder in the `Project` window.
Expand Down Expand Up @@ -111,7 +108,8 @@ using the
- For further details please refer to the
[general instructions](https://firebase.google.com/docs/android/setup)
which describes how to configure a Firebase application for Android.
- Download the [Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz)
- Download the
[Firebase Unity SDK](https://firebase.google.com/download/unity)
and unzip it somewhere convenient.
- Open the sample project in the Unity editor.
- Select the `File > Open Project` menu item.
Expand All @@ -121,15 +119,11 @@ using the
- Open the scene `MainScene`.
- Navigate to `Assets/TestApp/MainScene` in the `Project` window.
- Double click on `MainScene` file to open.
- Import the `Firebase App` plugin.
- Select the `Assets > Import Package > Custom Package` menu item.
- Import `FirebaseApp.unitypackage` from the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz), downloaded previously.
- Click the `Import` when the `Import Unity Package` window appears.
- Import the `Firebase Invites and Dynamic Links` plugin.
- Select the `Assets > Import Package > Custom Package` menu item.
- Import `FirebaseInvites.unitypackage` from the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz), downloaded previously.
[Firebase Unity SDK](https://firebase.google.com/download/unity),
downloaded previously.
- Click the `Import` when the `Import Unity Package` window appears.
- Add the `google-services.json` file to the project.
- Navigate to the `Assets\TestApp` folder in the `Project` window.
Expand Down
13 changes: 8 additions & 5 deletions messaging/testapp/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ The Firebase Messaging Unity Sample demonstrates receiving messages from
from
[Firebase Cloud Messaging](https://firebase.google.com/docs/cloud-messaging/)
using the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz).
[Firebase Unity SDK](https://firebase.google.com/docs/unity/setup).


## Requirements
Expand Down Expand Up @@ -46,7 +46,7 @@ using the
- For further details please refer to the
[general instructions](https://firebase.google.com/docs/ios/setup)
which describes how to configure a Firebase application for iOS.
- Download the [Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz)
- Download the [Firebase Unity SDK](https://firebase.google.com/download/unity)
and unzip it somewhere convenient.
- Open the sample project in the Unity editor.
- Select the `File > Open Project` menu item.
Expand All @@ -59,7 +59,8 @@ using the
- Import the `Firebase Messaging` plugin.
- Select the `Assets > Import Package > Custom Package` menu item.
- Import `FirebaseMessaging.unitypackage` from the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz), downloaded previously.
[Firebase Unity SDK](https://firebase.google.com/download/unity),
downloaded previously.
- Click the `Import` when the `Import Unity Package` window appears.
- Add the `GoogleService-Info.plist` file to the project.
- Navigate to the `Assets\TestApp` folder in the `Project` window.
Expand Down Expand Up @@ -126,7 +127,8 @@ using the
- For further details please refer to the
[general instructions](https://firebase.google.com/docs/android/setup)
which describes how to configure a Firebase application for Android.
- Download the [Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz)
- Download the
[Firebase Unity SDK](https://firebase.google.com/download/unity)
and unzip it somewhere convenient.
- Open the sample project in the Unity editor.
- Select the `File > Open Project` menu item.
Expand All @@ -139,7 +141,8 @@ using the
- Import the `Firebase Messaging` plugin.
- Select the `Assets > Import Package > Custom Package` menu item.
- Import `FirebaseMessaging.unitypackage` from the
[Firebase Unity SDK](https://dev-partners.googlesource.com/unity-firebase/+archive/zip.tar.gz), downloaded previously.
[Firebase Unity SDK](https://firebase.google.com/download/unity),
downloaded previously.
- Click the `Import` when the `Import Unity Package` window appears.
- Add the `google-services.json` file to the project.
- Navigate to the `Assets\TestApp` folder in the `Project` window.
Expand Down
Loading

0 comments on commit 5ea23da

Please sign in to comment.