Skip to content

Instantly share code, notes, and snippets.

View wldevries's full-sized avatar

Wouter de Vries wldevries

View GitHub Profile
using System;
using System.Threading.Tasks;
namespace Microsoft.Practices.Prism.Regions
{
public static class NavigationServiceMixins
{
public static async Task<NavigationResult> GoBack(this IRegionNavigationService service)
{
var tcs = new TaskCompletionSource<NavigationResult>();
using System;
using System.Linq;
using System.Threading;
using System.Threading.Tasks;
namespace Microsoft.Practices.Prism.Regions
{
public static class NavigateAsyncMixins
{
public static async Task<NavigationResult> RequestNavigate(this INavigateAsync navigateAsync, string target, NavigationParameters navigationParameters = null)
public class Wow64RedirectDisabler : IDisposable
{
IntPtr ptr ;
public Wow64RedirectDisabler()
{
this.ptr = new IntPtr();
bool success = NativeMethods.Wow64DisableWow64FsRedirection(ref ptr);
Console.WriteLine("Disable Wow64 FS redirection success: " + success);
@wldevries
wldevries / FmodProxy.cs
Created August 7, 2014 11:52
FMOD C# wrapper usage
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
namespace ConsoleApplication2
{
class FmodProxy: IDisposable
@wldevries
wldevries / InverseThrottle.cs
Created August 7, 2014 09:13
Inverse of standard Reactive Extensions Throttle by Christopher Harris
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Reactive;
using System.Reactive.Linq;
using System.Reactive.Subjects;
namespace ObservableTests
@wldevries
wldevries / NineGridImage.cs
Last active June 20, 2018 02:09
Image.NineGrid for WPF
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Media;
using System.Windows.Media.Imaging;