File tree Expand file tree Collapse file tree 2 files changed +3
-2
lines changed
Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change 11using ElectronNET . API ;
22using ElectronNET . API . Entities ;
33using Microsoft . AspNetCore . Mvc ;
4+ using System . Threading . Tasks ;
45
56namespace ElectronNET . WebApp . Controllers
67{
@@ -21,7 +22,7 @@ public IActionResult Index()
2122 await Electron . Dialog . ShowMessageBoxAsync ( options ) ;
2223 } ) ;
2324
24- Electron . App . WillQuit += ( ) => Electron . GlobalShortcut . UnregisterAll ( ) ;
25+ Electron . App . WillQuit += ( ) => Task . Run ( ( ) => Electron . GlobalShortcut . UnregisterAll ( ) ) ;
2526 }
2627
2728 return View ( ) ;
Original file line number Diff line number Diff line change 4747 await Electron .Dialog .ShowMessageBoxAsync (options );
4848} );
4949
50- Electron.App.WillQuit += () => Electron.GlobalShortcut.UnregisterAll();</code ></pre >
50+ Electron.App.WillQuit += () => Task.Run(() => Electron.GlobalShortcut.UnregisterAll() );</code ></pre >
5151
5252 <div class =" demo-protip" >
5353 <h2 >ProTip</h2 >
You can’t perform that action at this time.
0 commit comments