예제 #1
0
 public MusicItemViewModel(DragAndDropContext dragAndDropContext, double x, double y)
 {
     DragAndDropContext = dragAndDropContext;
     ItemPath           = dragAndDropContext.MusicItemViewModel.ItemPath;
     (X, Y)             = (x, y);
     MusicItem          = new MusicItem(ItemPath, x, y);
     IsInToolbox        = false;
 }
예제 #2
0
 public MainWindowViewModel()
 {
     DragAndDropContext = new DragAndDropContext();
     DominantToolbox    = new DominantToolboxViewModel(DragAndDropContext);
     TonicToolbox       = new TonicToolboxViewModel(DragAndDropContext);
     PredominantToolbox = new PredominantToolboxViewModel(DragAndDropContext);
     MiscToolbox        = new MiscToolboxViewModel(DragAndDropContext);
     Score = new ScoreViewModel(DragAndDropContext);
 }
예제 #3
0
 public MusicItemViewModel(string itemPath, DragAndDropContext dragAndDropContext, double x, double y)
     : this(itemPath, dragAndDropContext)
 {
     if (!File.Exists(itemPath))
     {
         throw new FileNotFoundException("Music Item not found", itemPath);
     }
     (X, Y)      = (x, y);
     IsInToolbox = false;
 }
예제 #4
0
 public MainWindowViewModel()
 {
     InfoText           = new InfoText();
     DragAndDropContext = new DragAndDropContext();
     DominantToolbox    = new DominantToolboxViewModel(DragAndDropContext);
     TonicToolbox       = new TonicToolboxViewModel(DragAndDropContext);
     PredominantToolbox = new PredominantToolboxViewModel(DragAndDropContext);
     MiscToolbox        = new MiscToolboxViewModel(DragAndDropContext);
     KeyMajorToolbox    = new KeyMajorToolboxViewModel(DragAndDropContext);
     KeyMinorToolbox    = new KeyMinorToolboxViewModel(DragAndDropContext);
     Score = new ScoreViewModel(DragAndDropContext, InfoText);
 }
예제 #5
0
 public MiscToolboxViewModel(DragAndDropContext dragAndDropContext)
 {
     Miscs = new ObservableCollection <MusicItemViewModel>(FindFiles("/Assets/png/misc/")
                                                           .Select(f => new MusicItemViewModel(f, dragAndDropContext)));
 }
예제 #6
0
 public KeyMajorToolboxViewModel(DragAndDropContext dragAndDropContext)
 {
     Keys = new ObservableCollection <MusicItemViewModel>(FindFiles("/Assets/png/keys/major/")
                                                          .Select(f => new MusicItemViewModel(f, dragAndDropContext)));
 }
예제 #7
0
 public ScoreViewModel(DragAndDropContext dragAndDropContext, InfoText infoText)
 {
     ScorePagesVM       = new ObservableCollection <ScorePageViewModel>();
     DragAndDropContext = dragAndDropContext;
     InfoText           = infoText;
 }
예제 #8
0
 public DominantToolboxViewModel(DragAndDropContext dragAndDropContext)
 {
     Dominants = new ObservableCollection <MusicItemViewModel>(FindFiles("/Assets/png/dominant/")
                                                               .Select(f => new MusicItemViewModel(f, dragAndDropContext)));
 }
예제 #9
0
 public MusicItemViewModel(string itemPath, DragAndDropContext dragAndDropContext)
 {
     DragAndDropContext = dragAndDropContext;
     MusicItem          = new MusicItem(itemPath);
     ItemPath           = itemPath;
 }