-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
U.GG Aram, Fixes & Small Improvements
- U.GG Aram - Small visual changes - Fixed some memory leak - Update ReadMe - Update Version.txt - Fixed #19
- Loading branch information
Showing
92 changed files
with
3,036 additions
and
1,317 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
LoL Assist/ViewModel/Command.cs → LoL Assist/Commands/Command.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
using LoL_Assist_WAPP.ViewModels; | ||
using System.Windows.Input; | ||
using System; | ||
|
||
namespace LoL_Assist_WAPP.Commands | ||
{ | ||
public class ItemInsertedCommand: ICommand | ||
{ | ||
private readonly ItemListViewModel _viewModel; | ||
public ItemInsertedCommand(ItemListViewModel itemListingViewModel) | ||
{ | ||
_viewModel = itemListingViewModel; | ||
} | ||
|
||
public void Execute(object parameter) | ||
{ | ||
_viewModel.InsertItem(_viewModel.InsertedItemViewModel, _viewModel.TargetItemViewModel); | ||
} | ||
|
||
public event EventHandler CanExecuteChanged; | ||
|
||
public bool CanExecute(object parameter) | ||
{ | ||
return true; | ||
} | ||
protected void OnCanExecuteChanged() | ||
{ | ||
this.CanExecuteChanged?.Invoke(this, new EventArgs()); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
using LoL_Assist_WAPP.ViewModels; | ||
using System.Windows.Input; | ||
using System; | ||
|
||
namespace LoL_Assist_WAPP.Commands | ||
{ | ||
public class ItemReceivedCommand: ICommand | ||
{ | ||
private readonly ItemListViewModel _viewModel; | ||
public ItemReceivedCommand(ItemListViewModel itemListingViewModel) | ||
{ | ||
_viewModel = itemListingViewModel; | ||
} | ||
|
||
public void Execute(object parameter) | ||
{ | ||
_viewModel.AddItem(_viewModel.IncomingItemViewModel); | ||
} | ||
|
||
public event EventHandler CanExecuteChanged; | ||
|
||
public bool CanExecute(object parameter) | ||
{ | ||
return true; | ||
} | ||
protected void OnCanExecuteChanged() | ||
{ | ||
this.CanExecuteChanged?.Invoke(this, new EventArgs()); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
using LoL_Assist_WAPP.ViewModels; | ||
using System.Windows.Input; | ||
using System; | ||
|
||
namespace LoL_Assist_WAPP.Commands | ||
{ | ||
public class ItemRemovedCommand: ICommand | ||
{ | ||
private readonly ItemListViewModel _viewModel; | ||
public ItemRemovedCommand(ItemListViewModel itemListingViewModel) | ||
{ | ||
_viewModel = itemListingViewModel; | ||
} | ||
|
||
public void Execute(object parameter) | ||
{ | ||
_viewModel.RemoveItem(_viewModel.RemovedItemViewModel); | ||
} | ||
|
||
public event EventHandler CanExecuteChanged; | ||
|
||
public bool CanExecute(object parameter) | ||
{ | ||
return true; | ||
} | ||
protected void OnCanExecuteChanged() | ||
{ | ||
this.CanExecuteChanged?.Invoke(this, new EventArgs()); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
using LoLA.Networking.WebWrapper.DataDragon; | ||
using LoLA.Networking.WebWrapper.DataDragon.Data; | ||
using System.Windows.Media.Imaging; | ||
using System.Windows.Data; | ||
using System.IO; | ||
using System; | ||
|
||
namespace LoL_Assist_WAPP.Converters | ||
{ | ||
public class ChampionToImageConverter : IValueConverter | ||
{ | ||
public object Convert(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) | ||
{ | ||
object result = null; | ||
var path = DataDragonWrapper.GetChampionImagePath(Converter.ChampionNameToId(value.ToString())); | ||
|
||
if (!string.IsNullOrEmpty(path) && File.Exists(path)) | ||
{ | ||
using (var stream = File.OpenRead(path)) | ||
{ | ||
var image = new BitmapImage(); | ||
image.BeginInit(); | ||
image.CacheOption = BitmapCacheOption.OnLoad; | ||
image.StreamSource = stream; | ||
image.EndInit(); | ||
result = image; | ||
} | ||
} | ||
return result; | ||
} | ||
|
||
public object ConvertBack(object value, Type targetType, object parameter, System.Globalization.CultureInfo culture) | ||
{ | ||
throw new NotImplementedException(); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.