/// <summary> /// Creates a WPF control from a context /// </summary> /// <param name="windowSource">Window source to attach to</param> public System.Windows.FrameworkElement AsControl(Context context, InputBridge inputBridge) { if (_used) { throw new System.InvalidOperationException("Access object was already used before!"); } _used = true; return(InternalAsControl(context, inputBridge)); }
/// <summary> /// Runs the Context as a window /// </summary> public void AsWindow(Context context, InputBridge inputBridge) { if (_used) { throw new System.InvalidOperationException("Access object was already used before!"); } _used = true; InternalAsWindow(context, inputBridge); }
protected abstract System.Windows.FrameworkElement InternalAsControl(Context context, InputBridge inputBridge);
protected abstract void InternalAsWindow(Context context, InputBridge inputBridge);