Skip to content

Commit

Permalink
Merge pull request #2824 from jizc/fix/compile-errors-2017.1
Browse files Browse the repository at this point in the history
Fixed compile errors in Unity 2017.1 and 2017.2
  • Loading branch information
ozdemir08 authored Dec 27, 2019
2 parents 7db8ac5 + 7e3eac8 commit b06fa21
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ namespace GooglePlayGames.Editor
{
using System.Collections.Generic;
using System.IO;
#if UNITY_2017_1_OR_NEWER
#if UNITY_2017_3_OR_NEWER
using UnityEngine.Networking;
#else
using UnityEngine;
Expand Down Expand Up @@ -102,7 +102,7 @@ public string Get(string key, Dictionary<string, string> overrides)
}
else if (mDict.ContainsKey(key))
{
#if UNITY_2017_1_OR_NEWER
#if UNITY_2017_3_OR_NEWER
return UnityWebRequest.UnEscapeURL(mDict[key]);
#else
return WWW.UnEscapeURL(mDict[key]);
Expand All @@ -118,7 +118,7 @@ public string Get(string key, string defaultValue)
{
if (mDict.ContainsKey(key))
{
#if UNITY_2017_1_OR_NEWER
#if UNITY_2017_3_OR_NEWER
return UnityWebRequest.UnEscapeURL(mDict[key]);
#else
return WWW.UnEscapeURL(mDict[key]);
Expand Down Expand Up @@ -147,7 +147,7 @@ public bool GetBool(string key)

public void Set(string key, string val)
{
#if UNITY_2017_1_OR_NEWER
#if UNITY_2017_3_OR_NEWER
string escaped = UnityWebRequest.EscapeURL(val);
#else
string escaped = WWW.EscapeURL(val);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ namespace GooglePlayGames
using System.Collections;
using GooglePlayGames.OurUtils;
using UnityEngine;
#if UNITY_2017_1_OR_NEWER
#if UNITY_2017_2_OR_NEWER
using UnityEngine.Networking;
#endif
using UnityEngine.SocialPlatforms;
Expand Down Expand Up @@ -120,7 +120,7 @@ internal IEnumerator LoadImage()
// avatar configured.
if (!string.IsNullOrEmpty(AvatarURL))
{
#if UNITY_2017_1_OR_NEWER
#if UNITY_2017_2_OR_NEWER
UnityWebRequest www = UnityWebRequestTexture.GetTexture(AvatarURL);
www.SendWebRequest();
#else
Expand All @@ -133,7 +133,7 @@ internal IEnumerator LoadImage()

if (www.error == null)
{
#if UNITY_2017_1_OR_NEWER
#if UNITY_2017_2_OR_NEWER
this.mImage = DownloadHandlerTexture.GetContent(www);
#else
this.mImage = www.texture;
Expand Down

0 comments on commit b06fa21

Please sign in to comment.