Skip to content

Commit

Permalink
chore: Moved the Hot Reload Indicator (HotreloadStatusView) to anot…
Browse files Browse the repository at this point in the history
…her project.
  • Loading branch information
carldebilly committed Oct 31, 2024
1 parent 9fd1059 commit b693141
Show file tree
Hide file tree
Showing 16 changed files with 62 additions and 1,008 deletions.
2 changes: 1 addition & 1 deletion src/Uno.Foundation/Diagnostics/DiagnosticViewRegistry.cs
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ public static void Register(IDiagnosticView view, DiagnosticViewRegistrationMode

internal record DiagnosticViewRegistration(DiagnosticViewRegistrationMode Mode, IDiagnosticView View);

internal enum DiagnosticViewRegistrationMode
public enum DiagnosticViewRegistrationMode
{
/// <summary>
/// Diagnostic is being display on at least one window.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public partial class ClientHotReloadProcessor
/// <summary>
/// The current status of the hot-reload engine.
/// </summary>
internal Status CurrentStatus => _status.Current;
public Status CurrentStatus => _status.Current;

private readonly StatusSink _status;

Expand All @@ -39,7 +39,7 @@ public enum HotReloadSource
Manual
}

internal enum HotReloadClientResult
public enum HotReloadClientResult
{
/// <summary>
/// Successful hot-reload.
Expand Down Expand Up @@ -70,9 +70,9 @@ public record Status(

private class StatusSink(ClientHotReloadProcessor owner)
{
#if HAS_UNO_WINUI
private readonly DiagnosticView<HotReloadStatusView, Status> _view = DiagnosticView.Register<HotReloadStatusView, Status>("Hot reload", ctx => new HotReloadStatusView(ctx), static (view, status) => view.OnHotReloadStatusChanged(status));
#endif
// #if HAS_UNO_WINUI
// private readonly DiagnosticView<HotReloadStatusView, Status> _view = DiagnosticView.Register<HotReloadStatusView, Status>("Hot reload", ctx => new HotReloadStatusView(ctx), static (view, status) => view.OnHotReloadStatusChanged(status));

Check warning on line 74 in src/Uno.UI.RemoteControl/HotReload/ClientHotReloadProcessor.Common.Status.cs

View check run for this annotation

Codacy Production / Codacy Static Code Analysis

src/Uno.UI.RemoteControl/HotReload/ClientHotReloadProcessor.Common.Status.cs#L74

Remove this commented out code.
// #endif

private HotReloadState? _serverState;
private bool _isFinalServerState;
Expand Down Expand Up @@ -142,9 +142,9 @@ private void NotifyStatusChanged()
var status = BuildStatus();

Current = status;
#if HAS_UNO_WINUI
_view.Update(status);
#endif
// #if HAS_UNO_WINUI
// _view.Update(status);

Check warning on line 146 in src/Uno.UI.RemoteControl/HotReload/ClientHotReloadProcessor.Common.Status.cs

View check run for this annotation

Codacy Production / Codacy Static Code Analysis

src/Uno.UI.RemoteControl/HotReload/ClientHotReloadProcessor.Common.Status.cs#L146

Remove this commented out code.
// #endif
owner.StatusChanged?.Invoke(this, status);
}

Expand Down Expand Up @@ -208,7 +208,7 @@ internal HotReloadClientOperation(HotReloadSource source, Type[] types, Action o

public Type[] Types { get; private set; }

internal string[] CuratedTypes => _curatedTypes ??= GetCuratedTypes();
public string[] CuratedTypes => _curatedTypes ??= GetCuratedTypes();

private string[] GetCuratedTypes()
{
Expand Down
215 changes: 0 additions & 215 deletions src/Uno.UI.RemoteControl/HotReload/HotReloadStatusView.Entries.cs

This file was deleted.

This file was deleted.

Loading

0 comments on commit b693141

Please sign in to comment.