Skip to content

Commit

Permalink
remove unused vars (#97)
Browse files Browse the repository at this point in the history
  • Loading branch information
Himanshu-Singh-Chauhan authored Nov 4, 2024
1 parent b91b021 commit 8b746b1
Showing 1 changed file with 17 additions and 17 deletions.
34 changes: 17 additions & 17 deletions src/vs/workbench/contrib/update/browser/update.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import * as nls from 'vs/nls';
import severity from 'vs/base/common/severity';
import { Disposable, MutableDisposable } from 'vs/base/common/lifecycle';
import { URI } from 'vs/base/common/uri';
// import { URI } from 'vs/base/common/uri';
import { IActivityService, NumberBadge, IBadge, ProgressBadge } from 'vs/workbench/services/activity/common/activity';
import { IInstantiationService, ServicesAccessor } from 'vs/platform/instantiation/common/instantiation';
import { IOpenerService } from 'vs/platform/opener/common/opener';
Expand All @@ -16,7 +16,7 @@ import { IUpdateService, State as UpdateState, StateType, IUpdate, DisablementRe
import { INotificationService, Severity } from 'vs/platform/notification/common/notification';
import { IDialogService } from 'vs/platform/dialogs/common/dialogs';
import { IBrowserWorkbenchEnvironmentService } from 'vs/workbench/services/environment/browser/environmentService';
import { ReleaseNotesManager } from 'vs/workbench/contrib/update/browser/releaseNotesEditor';
// import { ReleaseNotesManager } from 'vs/workbench/contrib/update/browser/releaseNotesEditor';
import { isMacintosh, isWeb, isWindows } from 'vs/base/common/platform';
import { IConfigurationService } from 'vs/platform/configuration/common/configuration';
import { RawContextKey, IContextKey, IContextKeyService, ContextKeyExpr } from 'vs/platform/contextkey/common/contextkey';
Expand All @@ -36,7 +36,7 @@ export const MAJOR_MINOR_UPDATE_AVAILABLE = new RawContextKey<boolean>('majorMin
export const RELEASE_NOTES_URL = new RawContextKey<string>('releaseNotesUrl', '');
export const DOWNLOAD_URL = new RawContextKey<string>('downloadUrl', '');

let releaseNotesManager: ReleaseNotesManager | undefined = undefined;
// let releaseNotesManager: ReleaseNotesManager | undefined = undefined;

export function showReleaseNotesInEditor(instantiationService: IInstantiationService, version: string, useCurrentFile: boolean) {
// if (!releaseNotesManager) {
Expand All @@ -46,17 +46,17 @@ export function showReleaseNotesInEditor(instantiationService: IInstantiationSer
// return releaseNotesManager.show(version, useCurrentFile);
}

async function openLatestReleaseNotesInBrowser(accessor: ServicesAccessor) {
// const openerService = accessor.get(IOpenerService);
// const productService = accessor.get(IProductService);
// async function openLatestReleaseNotesInBrowser(accessor: ServicesAccessor) {
// const openerService = accessor.get(IOpenerService);
// const productService = accessor.get(IProductService);

// if (productService.releaseNotesUrl) {
// const uri = URI.parse(productService.releaseNotesUrl);
// await openerService.open(uri);
// } else {
// throw new Error(nls.localize('update.noReleaseNotesOnline', "This version of {0} does not have release notes online", productService.nameLong));
// }
}
// if (productService.releaseNotesUrl) {
// const uri = URI.parse(productService.releaseNotesUrl);
// await openerService.open(uri);
// } else {
// throw new Error(nls.localize('update.noReleaseNotesOnline', "This version of {0} does not have release notes online", productService.nameLong));
// }
// }

async function showReleaseNotes(accessor: ServicesAccessor, version: string) {
// const instantiationService = accessor.get(IInstantiationService);
Expand Down Expand Up @@ -128,10 +128,10 @@ export class ProductContribution implements IWorkbenchContribution {
return;
}

const lastVersion = parseVersion(storageService.get(ProductContribution.KEY, StorageScope.APPLICATION, ''));
const currentVersion = parseVersion(productService.version);
const shouldShowReleaseNotes = configurationService.getValue<boolean>('update.showReleaseNotes');
const releaseNotesUrl = productService.releaseNotesUrl;
// const lastVersion = parseVersion(storageService.get(ProductContribution.KEY, StorageScope.APPLICATION, ''));
// const currentVersion = parseVersion(productService.version);
// const shouldShowReleaseNotes = configurationService.getValue<boolean>('update.showReleaseNotes');
// const releaseNotesUrl = productService.releaseNotesUrl;

// was there a major/minor update? if so, open release notes
// if (shouldShowReleaseNotes && !environmentService.skipReleaseNotes && releaseNotesUrl && lastVersion && currentVersion && isMajorMinorUpdate(lastVersion, currentVersion)) {
Expand Down

0 comments on commit 8b746b1

Please sign in to comment.