Esempio n. 1
0
        void IAssetMenuOperations.ShowDiff()
        {
            string selectedPath = AssetsSelection.GetSelectedPath(
                mAssetSelection.GetSelectedAssets());

            DiffInfo diffInfo = null;

            IThreadWaiter waiter = ThreadWaiter.GetWaiter(10);

            waiter.Execute(
                /*threadOperationDelegate*/ delegate
            {
                string symbolicName = GetSymbolicName(selectedPath);
                string extension    = Path.GetExtension(selectedPath);

                diffInfo = Plastic.API.BuildDiffInfoForDiffWithPrevious(
                    selectedPath, symbolicName, selectedPath, extension, mWkInfo);
            },
                /*afterOperationDelegate*/ delegate
            {
                if (waiter.Exception != null)
                {
                    ExceptionsHandler.DisplayException(waiter.Exception);
                    return;
                }

                DiffOperation.DiffWithPrevious(
                    diffInfo,
                    null,
                    null);
            });
        }
Esempio n. 2
0
        void IAssetMenuOperations.ShowHistory()
        {
            if (LaunchTool.ShowDownloadPlasticExeWindow(
                    mWkInfo,
                    mIsGluonMode,
                    TrackFeatureUseEvent.Features.InstallPlasticCloudFromShowHistory,
                    TrackFeatureUseEvent.Features.InstallPlasticEnterpriseFromShowHistory,
                    TrackFeatureUseEvent.Features.CancelPlasticInstallationFromShowHistory))
            {
                return;
            }

            AssetList assetList = mAssetSelection.GetSelectedAssets();

            Asset selectedAsset = AssetsSelection.GetSelectedAsset(
                assetList);
            string selectedPath = AssetsSelection.GetSelectedPath(
                assetList);

            WorkspaceTreeNode node = PlasticGui.Plastic.API.
                                     GetWorkspaceTreeNode(selectedPath);

            mHistoryViewLauncher.ShowHistoryView(
                node.RepSpec,
                node.RevInfo.ItemId,
                selectedPath,
                selectedAsset.isFolder);
        }
Esempio n. 3
0
        void IAssetMenuOperations.ShowHistory()
        {
            AssetList assetList = mAssetSelection.GetSelectedAssets();

            Asset selectedAsset = AssetsSelection.GetSelectedAsset(
                assetList);
            string selectedPath = AssetsSelection.GetSelectedPath(
                assetList);

            WorkspaceTreeNode node = Plastic.API.
                                     GetWorkspaceTreeNode(selectedPath);

            mHistoryViewLauncher.ShowHistoryView(
                node.RepSpec,
                node.RevInfo.ItemId,
                selectedPath,
                selectedAsset.isFolder);
        }
Esempio n. 4
0
        void IAssetMenuOperations.ShowDiff()
        {
            if (LaunchTool.ShowDownloadPlasticExeWindow(
                    mWkInfo,
                    mIsGluonMode,
                    TrackFeatureUseEvent.Features.InstallPlasticCloudFromShowDiff,
                    TrackFeatureUseEvent.Features.InstallPlasticEnterpriseFromFromShowDiff,
                    TrackFeatureUseEvent.Features.CancelPlasticInstallationFromFromShowDiff))
            {
                return;
            }

            string selectedPath = AssetsSelection.GetSelectedPath(
                mAssetSelection.GetSelectedAssets());

            DiffInfo diffInfo = null;

            IThreadWaiter waiter = ThreadWaiter.GetWaiter(10);

            waiter.Execute(
                /*threadOperationDelegate*/ delegate
            {
                string symbolicName = GetSymbolicName(selectedPath);
                string extension    = Path.GetExtension(selectedPath);

                diffInfo = PlasticGui.Plastic.API.BuildDiffInfoForDiffWithPrevious(
                    selectedPath, symbolicName, selectedPath, extension, mWkInfo);
            },
                /*afterOperationDelegate*/ delegate
            {
                if (waiter.Exception != null)
                {
                    ExceptionsHandler.DisplayException(waiter.Exception);
                    return;
                }

                DiffOperation.DiffWithPrevious(
                    diffInfo,
                    null,
                    null);
            });
        }
        void IAssetMenuOperations.ShowHistory()
        {
            if (LaunchTool.ShowDownloadPlasticExeWindow(mIsGluonMode))
            {
                return;
            }

            AssetList assetList = mAssetSelection.GetSelectedAssets();

            Asset selectedAsset = AssetsSelection.GetSelectedAsset(
                assetList);
            string selectedPath = AssetsSelection.GetSelectedPath(
                assetList);

            WorkspaceTreeNode node = Plastic.API.
                                     GetWorkspaceTreeNode(selectedPath);

            mHistoryViewLauncher.ShowHistoryView(
                node.RepSpec,
                node.RevInfo.ItemId,
                selectedPath,
                selectedAsset.isFolder);
        }