diff --git a/qtcnet-client/Forms/MainForm.cs b/qtcnet-client/Forms/MainForm.cs index 1e33012..30933be 100644 --- a/qtcnet-client/Forms/MainForm.cs +++ b/qtcnet-client/Forms/MainForm.cs @@ -278,7 +278,7 @@ namespace qtcnet_client await _gatewayService.JoinRoomAsync(new() // TODO - refactor this server side (its so bad) { Id = _roomCtrl.RoomId, - Name = _roomCtrl.Name, + Name = _roomCtrl.RoomName, }); } } diff --git a/qtcnet-client/Forms/ProfileForm.Designer.cs b/qtcnet-client/Forms/ProfileForm.Designer.cs index 8092429..a162bcc 100644 --- a/qtcnet-client/Forms/ProfileForm.Designer.cs +++ b/qtcnet-client/Forms/ProfileForm.Designer.cs @@ -170,6 +170,9 @@ pbProfileImage.SizeMode = PictureBoxSizeMode.Zoom; pbProfileImage.TabIndex = 3; pbProfileImage.TabStop = false; + pbProfileImage.MouseClick += pbProfileImage_Click; + pbProfileImage.MouseEnter += pbProfileImage_MouseEnter; + pbProfileImage.MouseLeave += pbProfileImage_MouseLeave; // // lblStatus // diff --git a/qtcnet-client/Forms/ProfileForm.cs b/qtcnet-client/Forms/ProfileForm.cs index 3f5feef..3c54e8d 100644 --- a/qtcnet-client/Forms/ProfileForm.cs +++ b/qtcnet-client/Forms/ProfileForm.cs @@ -74,9 +74,9 @@ namespace qtcnet_client.Forms // get owned store items and populate context strip var _storeItems = await _apiService.GetOwnedStoreItems(); - if(_storeItems.Success && _storeItems.Data != null) + if (_storeItems.Success && _storeItems.Data != null) { - foreach(var item in _storeItems.Data) + foreach (var item in _storeItems.Data) { // get item var _item = await _apiService.GetStoreItem(item.StoreItemId); @@ -89,8 +89,8 @@ namespace qtcnet_client.Forms } lblStatus.Visible = true; - - if(string.IsNullOrEmpty(TextStatus)) + + if (string.IsNullOrEmpty(TextStatus)) lblStatus.Text = "Enter Status Here"; lblStatus.Font = new("Segoe UI", 9, FontStyle.Bold | FontStyle.Italic); @@ -134,10 +134,10 @@ namespace qtcnet_client.Forms { // for each tag the user has, get the image associated with it from the server List _tagImages = []; - foreach(var tag in Tags) + foreach (var tag in Tags) { var _res = await _apiService.GetTagPic(tag); - if(_res.Success && _res.Data != null) + if (_res.Success && _res.Data != null) { // create a picturebox control and add it to the tag table Bitmap bm = new(new MemoryStream(_res.Data)); @@ -152,7 +152,7 @@ namespace qtcnet_client.Forms { flpTagIcons.SuspendLayout(); - foreach(var img in tagImages) + foreach (var img in tagImages) { PictureBox tagPb = new() { @@ -170,7 +170,7 @@ namespace qtcnet_client.Forms private async void ProfileForm_StoreItemToolStripClick(object? sender, EventArgs e) { - if(sender is ToolStripItem _tsi && _tsi.Tag is int _itemId) + if (sender is ToolStripItem _tsi && _tsi.Tag is int _itemId) { var _res = await _apiService.UpdateUserInformationAsync(new() { @@ -331,7 +331,7 @@ namespace qtcnet_client.Forms private void TxtStatusEdit_KeyDown(object? sender, KeyEventArgs e) { - if(sender is TextBox txtStatusEdit && e.KeyCode == Keys.Enter) + if (sender is TextBox txtStatusEdit && e.KeyCode == Keys.Enter) { lblStatus.Text = txtStatusEdit.Text; flpPfpStatus.Controls.Remove(txtStatusEdit); @@ -371,7 +371,7 @@ namespace qtcnet_client.Forms private void pbProfileImage_Click(object sender, MouseEventArgs e) { - if(UserId == _apiService.CurrentUser?.Id) + if (UserId == _apiService.CurrentUser?.Id) { Thread _fileDialogThread = new Thread(async () => { @@ -384,11 +384,11 @@ namespace qtcnet_client.Forms Title = "Select A New Profile Image" }; var _res = openFileDialog.ShowDialog(); - if(_res == DialogResult.OK) + if (_res == DialogResult.OK) { // update the current users profile image var _apiRes = await _apiService.UpdateUserProfilePic(openFileDialog.FileName); - if(_apiRes.Success) + if (_apiRes.Success) { pbProfileImage.Image = _imgFactory.GetAndCreateProfileImage(UserId, Status, CosmeticId); pbProfileImage.Invalidate(); @@ -403,7 +403,7 @@ namespace qtcnet_client.Forms private void pbProfileImage_MouseEnter(object sender, EventArgs e) { - if(UserId == _apiService.CurrentUser?.Id) + if (UserId == _apiService.CurrentUser?.Id) { Graphics g = pbProfileImage.CreateGraphics(); Rectangle rect = pbProfileImage.ClientRectangle; diff --git a/qtcnet-client/Properties/Resources.Designer.cs b/qtcnet-client/Properties/Resources.Designer.cs index 41a2cc2..af98e88 100644 --- a/qtcnet-client/Properties/Resources.Designer.cs +++ b/qtcnet-client/Properties/Resources.Designer.cs @@ -81,7 +81,7 @@ namespace qtcnet_client.Properties { } /// - /// Looks up a localized string similar to 1.0.0. + /// Looks up a localized string similar to 2.0.5.0. /// internal static string AssemblyVersion { get { diff --git a/qtcnet-client/Properties/Resources.resx b/qtcnet-client/Properties/Resources.resx index 4d8e483..b1743f3 100644 --- a/qtcnet-client/Properties/Resources.resx +++ b/qtcnet-client/Properties/Resources.resx @@ -167,7 +167,7 @@ ..\Resources\DNDIcon.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a - 1.0.0 + 2.0.5.0 ..\Resources\Tic-tac-toe.png;System.Drawing.Bitmap, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a