Added main page + started notify icon implementation.

This commit is contained in:
Patrick Fic
2020-01-16 14:37:05 -08:00
parent e34ffebf53
commit 0daf17a3f0
9 changed files with 166 additions and 9 deletions

View File

@@ -5,18 +5,18 @@ namespace BodyshopUploader.ViewModels
{
public partial class LoginViewModel : BaseViewModel
{
private ICommand _testCommand;
public ICommand TestCommand
private ICommand _openMainCommand;
public ICommand OpenMainCommand
{
get
{
if (_testCommand == null)
if (_openMainCommand == null)
{
_testCommand = new RelayCommand(
_openMainCommand = new RelayCommand(
p => true,
p => Console.WriteLine("Hi"));
p => { Views.Main m = new Views.Main(); m.Show(); });
}
return _testCommand;
return _openMainCommand;
}
}

View File

@@ -0,0 +1,26 @@
using System;
using System.Windows.Input;
namespace BodyshopUploader.ViewModels
{
public partial class MainViewModel : BaseViewModel
{
private ICommand _testCommand;
public ICommand TestCommand
{
get
{
if (_testCommand == null)
{
_testCommand = new RelayCommand(
p => true,
p =>
{
logger.Info("test command clicked");
});
}
return _testCommand;
}
}
}
}

View File

@@ -0,0 +1,18 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace BodyshopUploader.ViewModels
{
public partial class MainViewModel:BaseViewModel
{
private static NLog.Logger logger = NLog.LogManager.GetCurrentClassLogger();
public MainViewModel()
{
logger.Trace("Main VM Created.");
}
}
}

View File

@@ -0,0 +1,19 @@
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace BodyshopUploader.ViewModels
{
public partial class MainViewModel : BaseViewModel
{
private int _progress = 5;
public int Progress
{
get { return _progress; }
set { SetProperty(ref _progress, value); }
}
}
}