Rename User to APIUser and move to correct namespace

This commit is contained in:
Dean Herbert
2021-11-04 18:02:44 +09:00
parent 69aa620ab7
commit 0ecf5f201c
195 changed files with 990 additions and 946 deletions

View File

@ -4,15 +4,16 @@
using osu.Framework.Graphics;
using osu.Framework.Graphics.Containers;
using osu.Framework.Graphics.Effects;
using osu.Game.Online.API.Requests.Responses;
namespace osu.Game.Users.Drawables
{
/// <summary>
/// An avatar which can update to a new user when needed.
/// </summary>
public class UpdateableAvatar : ModelBackedDrawable<User>
public class UpdateableAvatar : ModelBackedDrawable<APIUser>
{
public User User
public APIUser User
{
get => Model;
set => Model = value;
@ -55,7 +56,7 @@ namespace osu.Game.Users.Drawables
/// <param name="isInteractive">If set to true, hover/click sounds will play and clicking the avatar will open the user's profile.</param>
/// <param name="showUsernameTooltip">Whether to show the username rather than "view profile" on the tooltip. (note: this only applies if <paramref name="isInteractive"/> is also true)</param>
/// <param name="showGuestOnNull">Whether to show a default guest representation on null user (as opposed to nothing).</param>
public UpdateableAvatar(User user = null, bool isInteractive = true, bool showUsernameTooltip = false, bool showGuestOnNull = true)
public UpdateableAvatar(APIUser user = null, bool isInteractive = true, bool showUsernameTooltip = false, bool showGuestOnNull = true)
{
this.isInteractive = isInteractive;
this.showUsernameTooltip = showUsernameTooltip;
@ -64,7 +65,7 @@ namespace osu.Game.Users.Drawables
User = user;
}
protected override Drawable CreateDrawable(User user)
protected override Drawable CreateDrawable(APIUser user)
{
if (user == null && !showGuestOnNull)
return null;