示例#1
0
        private IEnumerator FinishLoadingProfileInfo()
        {
            this.playerNumberText.color = ThemeHelper.GetThemeBaseFontColor(this.Theme);
            var socialUser = userGroup.GetUsersFromXboxUserIds(new List <string> {
                this.xboxLiveUser.XboxUserId
            })[0];

            var www = new WWW(socialUser.DisplayPicRaw + "&w=128");

            yield return(www);

            try
            {
                if (www.isDone && string.IsNullOrEmpty(www.error))
                {
                    var t = www.texture;
                    var r = new Rect(0, 0, t.width, t.height);
                    this.gamerpic.sprite = Sprite.Create(t, r, Vector2.zero);
                }
            }
            catch (Exception ex)
            {
                ExceptionManager.Instance.ThrowException(
                    ExceptionSource.PlayerAuthentication,
                    ExceptionType.LoadGamerPicFailed,
                    ex);
            }
            this.Refresh();
        }
示例#2
0
        private IEnumerator FinishLoadingProfileInfo()
        {
            this.playerNumberText.color = ThemeHelper.GetThemeBaseFontColor(this.Theme);
            var socialUser = userGroup.GetUsersFromXboxUserIds(new List <string> {
                this.xboxLiveUser.XboxUserId
            })[0];

            var www = new WWW(socialUser.DisplayPicRaw + "&w=128");

            yield return(www);

            try
            {
                if (www.isDone && string.IsNullOrEmpty(www.error))
                {
                    var t = www.texture;
                    var r = new Rect(0, 0, t.width, t.height);
                    this.gamerpic.sprite = Sprite.Create(t, r, Vector2.zero);
                }
            }
            catch (Exception ex)
            {
                if (XboxLiveServicesSettings.Instance.DebugLogsOn)
                {
                    Debug.Log("There was an error while loading Profile Info. Exception: " + ex.Message);
                }
            }
            this.Refresh();
        }
 public void UpdateStatus(bool enable)
 {
     isEnabled = enable;
     SelectedLineImage.GetComponent <Image>().enabled = isEnabled;
     FilterText.color = isEnabled ?
                        ThemeHelper.GetThemeHighlightColor(this.Theme) :
                        ThemeHelper.GetThemeBaseFontColor(this.Theme);
 }
 public void UpdateStatus(bool enable)
 {
     isEnabled = enable;
     SelectedLineImage.GetComponent <Image>().enabled = isEnabled;
     FilterText.color = isEnabled ?
                        ThemeHelper.GetThemeHighlightColor(this.Theme) :
                        ThemeHelper.GetThemeBaseFontColor(this.Theme);
     this.SelectedLineImage.sprite = ThemeHelper.LoadSprite(this.Theme, "RowBackground-Highlighted");
 }
示例#5
0
        private IEnumerator LoadTheme()
        {
            yield return(null);

            var backgroundColor = ThemeHelper.GetThemeBackgroundColor(this.Theme);

            this.profileInfoPanelImage.color = backgroundColor;
            this.gamerpicMask.color          = backgroundColor;
            this.signInPanelImage.sprite     = ThemeHelper.LoadSprite(this.Theme, "RowBackground-Highlighted");
            this.gamertag.color = ThemeHelper.GetThemeBaseFontColor(this.Theme);
        }
        private IEnumerator LoadTheme(Theme theme)
        {
            yield return(null);

            this.HeaderRowImage.sprite = ThemeHelper.LoadSprite(this.Theme, "LabelRowBackground");
            this.BackgroundImage.color = ThemeHelper.GetThemeBackgroundColor(this.Theme);
            var fontColor = ThemeHelper.GetThemeBaseFontColor(this.Theme);

            this.HeaderText.color       = fontColor;
            this.pageText.color         = ThemeHelper.GetThemeHighlightColor(this.Theme);
            this.NextPageText.color     = fontColor;
            this.PreviousPageText.color = fontColor;
            var lineSprite = ThemeHelper.LoadSprite(this.Theme, "Line");

            this.BottomLine.sprite = lineSprite;
            this.TopLine.sprite    = lineSprite;
        }