From f081a3db4ea1612f1b4409f66f602fc6d1edc41c Mon Sep 17 00:00:00 2001 From: Colin McMillen Date: Mon, 24 Feb 2020 13:48:14 -0500 Subject: [PATCH] Apply VS suggestion for refactoring TextureRef.Get GitOrigin-RevId: 9758a333c456f6a150282d3f4adb00c68095e416 --- Shared/Textures.cs | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/Shared/Textures.cs b/Shared/Textures.cs index a444c99..08494b1 100644 --- a/Shared/Textures.cs +++ b/Shared/Textures.cs @@ -15,19 +15,16 @@ namespace SemiColinGames { } private readonly string contentPath; - private Texture2D texture; public TextureRef(string contentPath) { allTextures.Add(this); this.contentPath = contentPath; } - public Texture2D Get { - get { return texture; } - } + public Texture2D Get { get; private set; } private void Load(ContentManager content) { - texture = content.Load(contentPath); + Get = content.Load(contentPath); } }