Exemplo n.º 1
0
        protected override void Initialize()
        {
            base.Initialize();

            packageCommandTarget  = GetService(typeof(IOleCommandTarget)) as IOleCommandTarget;
            packageCommandHandler = new DebugCommandHandler(this);
        }
        protected override async Task InitializeAsync(
            CancellationToken cancellationToken,
            IProgress <ServiceProgressData> progress)
        {
            await base.InitializeAsync(cancellationToken, progress);

            await JoinableTaskFactory.SwitchToMainThreadAsync(cancellationToken);

            packageCommandTarget = await GetServiceAsync(typeof(IOleCommandTarget)).ConfigureAwait(true) as IOleCommandTarget;

            packageCommandHandler = new DebugCommandHandler(this);
        }
        protected override void Initialize()
        {
            base.Initialize();

            // TODO: remove this, as well as ProvideAutoLoad, if and when https://github.com/ericsink/SQLitePCL.raw/issues/181 is resolved.
            var xDir = IntPtr.Size == 4 ? "x86" : "x64";

            Environment.SetEnvironmentVariable("PATH",
                                               String.Join(";", Environment.GetEnvironmentVariable("PATH"),
                                                           Path.Combine(Path.GetDirectoryName(typeof(CosmosDebugEnginePackage).Assembly.Location), xDir)));

            packageCommandTarget  = GetService(typeof(IOleCommandTarget)) as IOleCommandTarget;
            packageCommandHandler = new DebugCommandHandler(this);
        }
Exemplo n.º 4
0
        protected override async Task InitializeAsync(
            CancellationToken cancellationToken,
            IProgress <ServiceProgressData> progress)
        {
            await base.InitializeAsync(cancellationToken, progress);

            var xDir = IntPtr.Size == 4 ? "x86" : "x64";

            Environment.SetEnvironmentVariable("PATH", // add path so that it finds SQLitePCLRaw.nativelibrary
                                               String.Join(";", Environment.GetEnvironmentVariable("PATH"),
                                                           Path.Combine(Path.GetDirectoryName(typeof(CosmosDebugEnginePackage).Assembly.Location), xDir)));
            await JoinableTaskFactory.SwitchToMainThreadAsync(cancellationToken);

            packageCommandTarget = await GetServiceAsync(typeof(IOleCommandTarget)).ConfigureAwait(true) as IOleCommandTarget;

            packageCommandHandler = new DebugCommandHandler(this);
        }