public static void Undo(object switcherObject) { if (switcherObject != null) { HostExecutionContextManager currentHostExecutionContextManager = HostExecutionContextManager.GetCurrentHostExecutionContextManager(); if (currentHostExecutionContextManager != null) { currentHostExecutionContextManager.Revert(switcherObject); } } }
internal static Object SetHostExecutionContextInternal(HostExecutionContext hostContext) { HostExecutionContextManager hostMgr = HostExecutionContextManager.GetCurrentHostExecutionContextManager(); Object switcher = null; if (hostMgr != null) { switcher = hostMgr.SetHostExecutionContext(hostContext); } return(switcher); }
internal static object SetHostExecutionContextInternal(HostExecutionContext hostContext) { HostExecutionContextManager executionContextManager = HostExecutionContextManager.GetCurrentHostExecutionContextManager(); object obj = (object)null; if (executionContextManager != null) { obj = executionContextManager.SetHostExecutionContext(hostContext); } return(obj); }
internal static HostExecutionContext CaptureHostExecutionContext() { HostExecutionContext executionContext = (HostExecutionContext)null; HostExecutionContextManager executionContextManager = HostExecutionContextManager.GetCurrentHostExecutionContextManager(); if (executionContextManager != null) { executionContext = executionContextManager.Capture(); } return(executionContext); }
internal static object SetHostExecutionContextInternal(HostExecutionContext hostContext) { HostExecutionContextManager currentHostExecutionContextManager = HostExecutionContextManager.GetCurrentHostExecutionContextManager(); object result = null; if (currentHostExecutionContextManager != null) { result = currentHostExecutionContextManager.SetHostExecutionContext(hostContext); } return(result); }
internal static HostExecutionContext CaptureHostExecutionContext() { HostExecutionContext result = null; HostExecutionContextManager currentHostExecutionContextManager = HostExecutionContextManager.GetCurrentHostExecutionContextManager(); if (currentHostExecutionContextManager != null) { result = currentHostExecutionContextManager.Capture(); } return(result); }
internal static HostExecutionContext CaptureHostExecutionContext() { HostExecutionContext hostContext = null; // capture the host execution context HostExecutionContextManager hostMgr = HostExecutionContextManager.GetCurrentHostExecutionContextManager(); if (hostMgr != null) { hostContext = hostMgr.Capture(); } return(hostContext); }
static public void Undo(Object switcherObject) { if (switcherObject == null) { return; } // otherwise call the host HostExecutionContextManager hostMgr = HostExecutionContextManager.GetCurrentHostExecutionContextManager(); if (hostMgr != null) { hostMgr.Revert(switcherObject); } }
public static void Undo(object switcherObject) { if (switcherObject == null) { return; } HostExecutionContextManager executionContextManager = HostExecutionContextManager.GetCurrentHostExecutionContextManager(); if (executionContextManager == null) { return; } executionContextManager.Revert(switcherObject); }