mirror of
https://github.com/osukey/osukey.git
synced 2025-08-05 07:33:55 +09:00
Rename User
to APIUser
and move to correct namespace
This commit is contained in:
@ -8,7 +8,7 @@ using System.Linq;
|
||||
using Newtonsoft.Json;
|
||||
using osu.Framework.Bindables;
|
||||
using osu.Framework.Lists;
|
||||
using osu.Game.Users;
|
||||
using osu.Game.Online.API.Requests.Responses;
|
||||
|
||||
namespace osu.Game.Online.Chat
|
||||
{
|
||||
@ -19,7 +19,7 @@ namespace osu.Game.Online.Chat
|
||||
/// <summary>
|
||||
/// Contains every joined user except the current logged in user. Currently only returned for PM channels.
|
||||
/// </summary>
|
||||
public readonly ObservableCollection<User> Users = new ObservableCollection<User>();
|
||||
public readonly ObservableCollection<APIUser> Users = new ObservableCollection<APIUser>();
|
||||
|
||||
[JsonProperty(@"users")]
|
||||
private int[] userIds
|
||||
@ -27,7 +27,7 @@ namespace osu.Game.Online.Chat
|
||||
set
|
||||
{
|
||||
foreach (int id in value)
|
||||
Users.Add(new User { Id = id });
|
||||
Users.Add(new APIUser { Id = id });
|
||||
}
|
||||
}
|
||||
|
||||
@ -98,7 +98,7 @@ namespace osu.Game.Online.Chat
|
||||
/// Create a private messaging channel with the specified user.
|
||||
/// </summary>
|
||||
/// <param name="user">The user to create the private conversation with.</param>
|
||||
public Channel(User user)
|
||||
public Channel(APIUser user)
|
||||
{
|
||||
Type = ChannelType.PM;
|
||||
Users.Add(user);
|
||||
|
@ -11,8 +11,8 @@ using osu.Framework.Logging;
|
||||
using osu.Game.Database;
|
||||
using osu.Game.Online.API;
|
||||
using osu.Game.Online.API.Requests;
|
||||
using osu.Game.Online.API.Requests.Responses;
|
||||
using osu.Game.Overlays.Chat.Tabs;
|
||||
using osu.Game.Users;
|
||||
|
||||
namespace osu.Game.Online.Chat
|
||||
{
|
||||
@ -91,7 +91,7 @@ namespace osu.Game.Online.Chat
|
||||
/// Opens a new private channel.
|
||||
/// </summary>
|
||||
/// <param name="user">The user the private channel is opened with.</param>
|
||||
public void OpenPrivateChannel(User user)
|
||||
public void OpenPrivateChannel(APIUser user)
|
||||
{
|
||||
if (user == null)
|
||||
throw new ArgumentNullException(nameof(user));
|
||||
|
@ -2,7 +2,7 @@
|
||||
// See the LICENCE file in the repository root for full licence text.
|
||||
|
||||
using System;
|
||||
using osu.Game.Users;
|
||||
using osu.Game.Online.API.Requests.Responses;
|
||||
|
||||
namespace osu.Game.Online.Chat
|
||||
{
|
||||
@ -14,7 +14,7 @@ namespace osu.Game.Online.Chat
|
||||
Timestamp = DateTimeOffset.Now;
|
||||
Content = message;
|
||||
|
||||
Sender = User.SYSTEM_USER;
|
||||
Sender = APIUser.SYSTEM_USER;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -4,7 +4,7 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using Newtonsoft.Json;
|
||||
using osu.Game.Users;
|
||||
using osu.Game.Online.API.Requests.Responses;
|
||||
|
||||
namespace osu.Game.Online.Chat
|
||||
{
|
||||
@ -26,7 +26,7 @@ namespace osu.Game.Online.Chat
|
||||
public string Content;
|
||||
|
||||
[JsonProperty(@"sender")]
|
||||
public User Sender;
|
||||
public APIUser Sender;
|
||||
|
||||
[JsonConstructor]
|
||||
public Message()
|
||||
|
@ -12,9 +12,9 @@ using osu.Framework.Graphics.Sprites;
|
||||
using osu.Game.Configuration;
|
||||
using osu.Game.Graphics;
|
||||
using osu.Game.Online.API;
|
||||
using osu.Game.Online.API.Requests.Responses;
|
||||
using osu.Game.Overlays;
|
||||
using osu.Game.Overlays.Notifications;
|
||||
using osu.Game.Users;
|
||||
|
||||
namespace osu.Game.Online.Chat
|
||||
{
|
||||
@ -35,7 +35,7 @@ namespace osu.Game.Online.Chat
|
||||
private Bindable<bool> notifyOnUsername;
|
||||
private Bindable<bool> notifyOnPrivateMessage;
|
||||
|
||||
private readonly IBindable<User> localUser = new Bindable<User>();
|
||||
private readonly IBindable<APIUser> localUser = new Bindable<APIUser>();
|
||||
private readonly IBindableList<Channel> joinedChannels = new BindableList<Channel>();
|
||||
|
||||
[BackgroundDependencyLoader]
|
||||
|
Reference in New Issue
Block a user