mirror of
https://github.com/jwetzell/qController.git
synced 2026-08-11 02:13:55 +00:00
Address some formatting things and update Packages
This commit is contained in:
@@ -57,7 +57,7 @@ namespace qController.ViewModels
|
||||
{
|
||||
QServerViewModel serverToRemove = null;
|
||||
|
||||
foreach(var serverGroup in ServersGrouped)
|
||||
foreach(QServerViewModel serverGroup in ServersGrouped)
|
||||
{
|
||||
if (serverGroup.host.Equals(args.server.host))
|
||||
{
|
||||
@@ -86,7 +86,7 @@ namespace qController.ViewModels
|
||||
if (!autoUpdate)
|
||||
{
|
||||
Log.Debug("[QBrowserViewModel] Manual Scan Initiated");
|
||||
this.browser.ProbeForQLabInstances();
|
||||
browser.ProbeForQLabInstances();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -19,14 +19,15 @@ namespace qController.ViewModels
|
||||
public QCueViewModel(QCue cue, bool checkPlayback)
|
||||
{
|
||||
this.cue = cue;
|
||||
if (checkPlayback)
|
||||
if (checkPlayback) {
|
||||
this.cue.workspace.CueListChangedPlaybackPosition += Workspace_CueListChangedPlaybackPosition;
|
||||
}
|
||||
this.cue.CuePropertiesUpdated += OnCuePropertiesUpdated;
|
||||
}
|
||||
|
||||
private void OnCuePropertiesUpdated(object source, QCuePropertiesUpdatedArgs args)
|
||||
{
|
||||
foreach (var property in args.properties)
|
||||
foreach (string property in args.properties)
|
||||
{
|
||||
if (property.Equals(QOSCKey.Name) || property.Equals(QOSCKey.ListName))
|
||||
{
|
||||
@@ -64,95 +65,44 @@ namespace qController.ViewModels
|
||||
IsSelected = args.cueID == cue.uid;
|
||||
}
|
||||
|
||||
public Thickness nestPadding
|
||||
{
|
||||
get
|
||||
{
|
||||
return new Thickness((cue.nestLevel - 1) * 10,0,0,0);
|
||||
}
|
||||
}
|
||||
public Thickness nestPadding => new Thickness((cue.nestLevel - 1) * 10, 0, 0, 0);
|
||||
|
||||
public string name
|
||||
{
|
||||
get
|
||||
{
|
||||
return cue.listName;
|
||||
}
|
||||
get => cue.listName;
|
||||
|
||||
set
|
||||
{
|
||||
cue.name = value;
|
||||
}
|
||||
set => cue.name = value;
|
||||
}
|
||||
|
||||
public string type
|
||||
{
|
||||
get
|
||||
{
|
||||
return QIcon.GetIconFromType(cue.type);
|
||||
}
|
||||
}
|
||||
public string type => QIcon.GetIconFromType(cue.type);
|
||||
|
||||
public string uid
|
||||
{
|
||||
get
|
||||
{
|
||||
return cue.uid;
|
||||
}
|
||||
}
|
||||
public string uid => cue.uid;
|
||||
|
||||
public string number
|
||||
{
|
||||
get
|
||||
{
|
||||
return cue.number;
|
||||
}
|
||||
get => cue.number;
|
||||
|
||||
set
|
||||
{
|
||||
cue.number = value;
|
||||
}
|
||||
set => cue.number = value;
|
||||
}
|
||||
|
||||
public string notes
|
||||
{
|
||||
get
|
||||
{
|
||||
return cue.notes;
|
||||
}
|
||||
get => cue.notes;
|
||||
|
||||
set
|
||||
{
|
||||
cue.notes = value;
|
||||
}
|
||||
set => cue.notes = value;
|
||||
}
|
||||
|
||||
public Color color
|
||||
{
|
||||
get
|
||||
{
|
||||
return Color.FromHex(cue.color.Hex);
|
||||
}
|
||||
set
|
||||
{
|
||||
cue.color = new QColor("none");
|
||||
}
|
||||
get => Color.FromHex(cue.color.Hex);
|
||||
set => cue.color = new QColor("none");
|
||||
}
|
||||
|
||||
public List<QCue> cues
|
||||
{
|
||||
get
|
||||
{
|
||||
return cue.cues;
|
||||
}
|
||||
}
|
||||
public List<QCue> cues => cue.cues;
|
||||
|
||||
public bool IsSelected
|
||||
{
|
||||
get
|
||||
{
|
||||
return isSelected;
|
||||
}
|
||||
get => isSelected;
|
||||
set
|
||||
{
|
||||
isSelected = value;
|
||||
@@ -162,10 +112,7 @@ namespace qController.ViewModels
|
||||
|
||||
public bool IsCollapsed
|
||||
{
|
||||
get
|
||||
{
|
||||
return isCollapsed;
|
||||
}
|
||||
get => isCollapsed;
|
||||
set
|
||||
{
|
||||
isCollapsed = value;
|
||||
|
||||
@@ -14,57 +14,25 @@ namespace qController.ViewModels
|
||||
public new event PropertyChangedEventHandler PropertyChanged;
|
||||
public string name
|
||||
{
|
||||
get
|
||||
{
|
||||
return server.name;
|
||||
}
|
||||
set
|
||||
{
|
||||
server.name = value;
|
||||
}
|
||||
get => server.name;
|
||||
set => server.name = value;
|
||||
}
|
||||
|
||||
public string host
|
||||
{
|
||||
get
|
||||
{
|
||||
return server.host;
|
||||
}
|
||||
}
|
||||
public string host => server.host;
|
||||
|
||||
public string version
|
||||
{
|
||||
get
|
||||
{
|
||||
if (server.version == null)
|
||||
{
|
||||
return "";
|
||||
}
|
||||
else
|
||||
{
|
||||
return $"v{server.version}";
|
||||
public string version => server.version == null ? "" : $"v{server.version}";
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public string GroupName
|
||||
{
|
||||
get
|
||||
{
|
||||
return $"{name} ({host})";
|
||||
}
|
||||
}
|
||||
public string GroupName => $"{name} ({host})";
|
||||
|
||||
public QServerViewModel(QServer server)
|
||||
{
|
||||
this.server = server;
|
||||
name = this.server.name;
|
||||
foreach (var workspace in this.server.workspaces)
|
||||
foreach (QWorkspace workspace in this.server.workspaces)
|
||||
{
|
||||
Device.BeginInvokeOnMainThread(() =>
|
||||
{
|
||||
this.Add(new QWorkspaceViewModel(workspace));
|
||||
Add(new QWorkspaceViewModel(workspace));
|
||||
});
|
||||
}
|
||||
this.server.WorkspaceAdded += Server_WorkspaceAdded;
|
||||
@@ -76,7 +44,7 @@ namespace qController.ViewModels
|
||||
{
|
||||
QWorkspaceViewModel workspaceToRemove = null;
|
||||
|
||||
foreach(var workspaceViewModel in this)
|
||||
foreach(QWorkspaceViewModel workspaceViewModel in this)
|
||||
{
|
||||
if(workspaceViewModel.workspace.uniqueID == args.workspace.uniqueID)
|
||||
{
|
||||
|
||||
@@ -10,28 +10,8 @@ namespace qController.ViewModels
|
||||
this.workspace = workspace;
|
||||
}
|
||||
|
||||
public string Name
|
||||
{
|
||||
get
|
||||
{
|
||||
return workspace.name;
|
||||
}
|
||||
set
|
||||
{
|
||||
public string Name => workspace.name;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public bool HasPasscode
|
||||
{
|
||||
get
|
||||
{
|
||||
return workspace.hasPasscode;
|
||||
}
|
||||
set
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
public bool HasPasscode => workspace.hasPasscode;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user