I think i am done

This commit is contained in:
JacobTech 2024-11-18 22:48:28 -05:00
parent f47dd7c3a0
commit fdfece9ab9
3 changed files with 25 additions and 8 deletions

View File

@ -264,6 +264,10 @@ public class TextBox : UserControl
set set
{ {
_watermark.Text = value; _watermark.Text = value;
if (string.IsNullOrEmpty(Text))
{
Pointer.Location = _label.Location;
}
} }
} }

View File

@ -402,7 +402,11 @@ public class PublicChat : UserControl
FileUpload FU = new(Channel!.Server, FilePath); FileUpload FU = new(Channel!.Server, FilePath);
FilesToUpload.Add(FU); FilesToUpload.Add(FU);
FileFlow.Controls.Add(FU); FileFlow.Controls.Add(FU);
FU.BackgroundColor = Color4.Red; FU.Clicked += o =>
{
RemoveFile(FU);
return Task.CompletedTask;
};
if (ReloadUI) TryDraw(); if (ReloadUI) TryDraw();
} }
@ -410,7 +414,6 @@ public class PublicChat : UserControl
private Task CFOnSizeChanged(IRenderObject arg) private Task CFOnSizeChanged(IRenderObject arg)
{ {
FileFlow.BackgroundColor = Color4.Green;
arg.Location = new(arg.Location.X, arg.Location.Y + OldSize - arg.Size.Y); arg.Location = new(arg.Location.X, arg.Location.Y + OldSize - arg.Size.Y);
MessageFlow.Size = new(MessageFlow.Size.X, FileFlow.Location.Y - MessageFlow.Location.Y); MessageFlow.Size = new(MessageFlow.Size.X, FileFlow.Location.Y - MessageFlow.Location.Y);
OldSize = arg.Size.Y; OldSize = arg.Size.Y;
@ -426,6 +429,8 @@ public class PublicChat : UserControl
public void RemoveFile(FileUpload FU) public void RemoveFile(FileUpload FU)
{ {
FileFlow.Controls.Remove(FU);
FilesToUpload.Remove(FU);
MessageFlow.Size = new(MessageFlow.Size.X, FileFlow.Location.Y - MessageFlow.Location.Y); MessageFlow.Size = new(MessageFlow.Size.X, FileFlow.Location.Y - MessageFlow.Location.Y);
} }

View File

@ -208,6 +208,13 @@ public class MainScreenWindow : Window
irl) irl)
.Result.Content.ReadAsStringAsync().Result != .Result.Content.ReadAsStringAsync().Result !=
FileVersionInfo.GetVersionInfo(Assembly.GetExecutingAssembly().Location).FileVersion) FileVersionInfo.GetVersionInfo(Assembly.GetExecutingAssembly().Location).FileVersion)
{
if (Globals.UpdaterSettings.AutoUpdate)
{
Globals.Download = true;
Close();
}
else
{ {
var update = new UpdateWindow(); var update = new UpdateWindow();
var result = update.ShowDialogue(this); var result = update.ShowDialogue(this);
@ -217,6 +224,7 @@ public class MainScreenWindow : Window
Close(); Close();
} }
} }
}
await LoginOnChangeToApp(); await LoginOnChangeToApp();
} }
@ -752,11 +760,11 @@ public class MainScreenWindow : Window
private Task AddButtonClicked(IRenderObject arg) private Task AddButtonClicked(IRenderObject arg)
{ {
CenterFullScreenBase aso = new(new AddServerOverlayForm()) /* CenterFullScreenBase aso = new(new AddServerOverlayForm())
{ {
AllowHoverFromBehind = false AllowHoverFromBehind = false
}; };*/
//AddServerOverlayld aso = new(); AddServerOverlayld aso = new();
aso.Clicked += AsoOnClicked; aso.Clicked += AsoOnClicked;
Controls.Add(aso); Controls.Add(aso);