Working on making multiple notification systems possible, removing the old "notifyicon" balloon for Windows 10.

This commit is contained in:
Robin Krom 2020-03-10 13:17:13 +01:00
commit 1ba0bf9b10
6 changed files with 189 additions and 24 deletions

View file

@ -20,7 +20,7 @@
*/
using System;
using System.Collections.Generic;
using Greenshot.Helpers;
using GreenshotPlugin.Core;
using GreenshotPlugin.Interfaces;
using GreenshotPlugin.Interfaces.Ocr;
@ -34,14 +34,14 @@ namespace GreenshotWin10Plugin
/// This is the Win10Plugin
/// </summary>
[Plugin("Win10", false)]
public class Win10Plugin : IGreenshotPlugin
public sealed class Win10Plugin : IGreenshotPlugin
{
public void Dispose()
{
Dispose(true);
}
protected void Dispose(bool disposing)
private void Dispose(bool disposing)
{
if (disposing)
{
@ -63,8 +63,10 @@ namespace GreenshotWin10Plugin
{
return false;
}
// Set this as IOcrProvider
SimpleServiceProvider.Current.AddService<IOcrProvider>(new Win10OcrProvider());
SimpleServiceProvider.Current.AddService<INotificationService>(new ToastNotificationService());
// Set this as IOcrProvider
SimpleServiceProvider.Current.AddService<IOcrProvider>(new Win10OcrProvider());
// Add the processor
SimpleServiceProvider.Current.AddService<IProcessor>(new Win10OcrProcessor());