diff --git a/front_end/generated/protocol-proxy-api.d.ts b/front_end/generated/protocol-proxy-api.d.ts index 938e436d6c..4653c80f0b 100644 --- a/front_end/generated/protocol-proxy-api.d.ts +++ b/front_end/generated/protocol-proxy-api.d.ts @@ -3709,50 +3709,3 @@ declare namespace ProtocolProxyApi { export interface SchemaDispatcher extends Protocol.Dispatcher {} } -// Include the workaround for https://github.com/microsoft/TypeScript/issues/38640 -interface ProtocolProxyApiWorkaround_AccessibilityDispatcher extends ProtocolProxyApi.AccessibilityDispatcher {} -interface ProtocolProxyApiWorkaround_AnimationDispatcher extends ProtocolProxyApi.AnimationDispatcher {} -interface ProtocolProxyApiWorkaround_ApplicationCacheDispatcher extends ProtocolProxyApi.ApplicationCacheDispatcher {} -interface ProtocolProxyApiWorkaround_AuditsDispatcher extends ProtocolProxyApi.AuditsDispatcher {} -interface ProtocolProxyApiWorkaround_BackgroundServiceDispatcher extends ProtocolProxyApi.BackgroundServiceDispatcher {} -interface ProtocolProxyApiWorkaround_BrowserDispatcher extends ProtocolProxyApi.BrowserDispatcher {} -interface ProtocolProxyApiWorkaround_CSSDispatcher extends ProtocolProxyApi.CSSDispatcher {} -interface ProtocolProxyApiWorkaround_CacheStorageDispatcher extends ProtocolProxyApi.CacheStorageDispatcher {} -interface ProtocolProxyApiWorkaround_CastDispatcher extends ProtocolProxyApi.CastDispatcher {} -interface ProtocolProxyApiWorkaround_DOMDispatcher extends ProtocolProxyApi.DOMDispatcher {} -interface ProtocolProxyApiWorkaround_DOMDebuggerDispatcher extends ProtocolProxyApi.DOMDebuggerDispatcher {} -interface ProtocolProxyApiWorkaround_DOMSnapshotDispatcher extends ProtocolProxyApi.DOMSnapshotDispatcher {} -interface ProtocolProxyApiWorkaround_DOMStorageDispatcher extends ProtocolProxyApi.DOMStorageDispatcher {} -interface ProtocolProxyApiWorkaround_DatabaseDispatcher extends ProtocolProxyApi.DatabaseDispatcher {} -interface ProtocolProxyApiWorkaround_DeviceOrientationDispatcher extends ProtocolProxyApi.DeviceOrientationDispatcher {} -interface ProtocolProxyApiWorkaround_EmulationDispatcher extends ProtocolProxyApi.EmulationDispatcher {} -interface ProtocolProxyApiWorkaround_HeadlessExperimentalDispatcher extends - ProtocolProxyApi.HeadlessExperimentalDispatcher {} -interface ProtocolProxyApiWorkaround_IODispatcher extends ProtocolProxyApi.IODispatcher {} -interface ProtocolProxyApiWorkaround_IndexedDBDispatcher extends ProtocolProxyApi.IndexedDBDispatcher {} -interface ProtocolProxyApiWorkaround_InputDispatcher extends ProtocolProxyApi.InputDispatcher {} -interface ProtocolProxyApiWorkaround_InspectorDispatcher extends ProtocolProxyApi.InspectorDispatcher {} -interface ProtocolProxyApiWorkaround_LayerTreeDispatcher extends ProtocolProxyApi.LayerTreeDispatcher {} -interface ProtocolProxyApiWorkaround_LogDispatcher extends ProtocolProxyApi.LogDispatcher {} -interface ProtocolProxyApiWorkaround_MemoryDispatcher extends ProtocolProxyApi.MemoryDispatcher {} -interface ProtocolProxyApiWorkaround_NetworkDispatcher extends ProtocolProxyApi.NetworkDispatcher {} -interface ProtocolProxyApiWorkaround_OverlayDispatcher extends ProtocolProxyApi.OverlayDispatcher {} -interface ProtocolProxyApiWorkaround_PageDispatcher extends ProtocolProxyApi.PageDispatcher {} -interface ProtocolProxyApiWorkaround_PerformanceDispatcher extends ProtocolProxyApi.PerformanceDispatcher {} -interface ProtocolProxyApiWorkaround_SecurityDispatcher extends ProtocolProxyApi.SecurityDispatcher {} -interface ProtocolProxyApiWorkaround_ServiceWorkerDispatcher extends ProtocolProxyApi.ServiceWorkerDispatcher {} -interface ProtocolProxyApiWorkaround_StorageDispatcher extends ProtocolProxyApi.StorageDispatcher {} -interface ProtocolProxyApiWorkaround_SystemInfoDispatcher extends ProtocolProxyApi.SystemInfoDispatcher {} -interface ProtocolProxyApiWorkaround_TargetDispatcher extends ProtocolProxyApi.TargetDispatcher {} -interface ProtocolProxyApiWorkaround_TetheringDispatcher extends ProtocolProxyApi.TetheringDispatcher {} -interface ProtocolProxyApiWorkaround_TracingDispatcher extends ProtocolProxyApi.TracingDispatcher {} -interface ProtocolProxyApiWorkaround_FetchDispatcher extends ProtocolProxyApi.FetchDispatcher {} -interface ProtocolProxyApiWorkaround_WebAudioDispatcher extends ProtocolProxyApi.WebAudioDispatcher {} -interface ProtocolProxyApiWorkaround_WebAuthnDispatcher extends ProtocolProxyApi.WebAuthnDispatcher {} -interface ProtocolProxyApiWorkaround_MediaDispatcher extends ProtocolProxyApi.MediaDispatcher {} -interface ProtocolProxyApiWorkaround_ConsoleDispatcher extends ProtocolProxyApi.ConsoleDispatcher {} -interface ProtocolProxyApiWorkaround_DebuggerDispatcher extends ProtocolProxyApi.DebuggerDispatcher {} -interface ProtocolProxyApiWorkaround_HeapProfilerDispatcher extends ProtocolProxyApi.HeapProfilerDispatcher {} -interface ProtocolProxyApiWorkaround_ProfilerDispatcher extends ProtocolProxyApi.ProfilerDispatcher {} -interface ProtocolProxyApiWorkaround_RuntimeDispatcher extends ProtocolProxyApi.RuntimeDispatcher {} -interface ProtocolProxyApiWorkaround_SchemaDispatcher extends ProtocolProxyApi.SchemaDispatcher {} diff --git a/front_end/sdk/ChildTargetManager.js b/front_end/sdk/ChildTargetManager.js index b811947e5b..bdb3726ca8 100644 --- a/front_end/sdk/ChildTargetManager.js +++ b/front_end/sdk/ChildTargetManager.js @@ -15,7 +15,7 @@ let _lastAnonymousTargetId = 0; let _attachCallback; /** - * @implements {ProtocolProxyApiWorkaround_TargetDispatcher} + * @implements {ProtocolProxyApi.TargetDispatcher} */ export class ChildTargetManager extends SDKModel { /** diff --git a/front_end/sdk/DOMModel.js b/front_end/sdk/DOMModel.js index 4f740a157e..fa801a8f12 100644 --- a/front_end/sdk/DOMModel.js +++ b/front_end/sdk/DOMModel.js @@ -1824,7 +1824,7 @@ export const Events = { }; /** - * @implements {ProtocolProxyApiWorkaround_DOMDispatcher} + * @implements {ProtocolProxyApi.DOMDispatcher} */ class DOMDispatcher { /** diff --git a/front_end/sdk/HeapProfilerModel.js b/front_end/sdk/HeapProfilerModel.js index 024d49664d..27c53a6103 100644 --- a/front_end/sdk/HeapProfilerModel.js +++ b/front_end/sdk/HeapProfilerModel.js @@ -321,7 +321,7 @@ class NativeHeapProfile { } /** - * @implements {ProtocolProxyApiWorkaround_HeapProfilerDispatcher} + * @implements {ProtocolProxyApi.HeapProfilerDispatcher} */ class HeapProfilerDispatcher { /** diff --git a/front_end/sdk/IssuesModel.js b/front_end/sdk/IssuesModel.js index 57e3eac21a..c7da6d6304 100644 --- a/front_end/sdk/IssuesModel.js +++ b/front_end/sdk/IssuesModel.js @@ -16,7 +16,7 @@ import {Capability, SDKModel, Target} from './SDKModel.js'; // eslint-disable-l * class (usually derived from `Issue`) and passes the instances on via a dispatched event. * We chose this approach here because the lifetime of the Model is tied to the target, but DevTools * wants to preserve issues for targets (e.g. iframes) that are already gone as well. - * @implements {ProtocolProxyApiWorkaround_AuditsDispatcher} + * @implements {ProtocolProxyApi.AuditsDispatcher} */ export class IssuesModel extends SDKModel { /** diff --git a/front_end/sdk/NetworkManager.js b/front_end/sdk/NetworkManager.js index fc9b9a7857..13877c59d6 100644 --- a/front_end/sdk/NetworkManager.js +++ b/front_end/sdk/NetworkManager.js @@ -279,7 +279,7 @@ export const Fast3GConditions = { const MAX_EAGER_POST_REQUEST_BODY_LENGTH = 64 * 1024; // bytes /** - * @implements {ProtocolProxyApiWorkaround_NetworkDispatcher} + * @implements {ProtocolProxyApi.NetworkDispatcher} * @unrestricted */ export class NetworkDispatcher { diff --git a/front_end/sdk/ResourceTreeModel.js b/front_end/sdk/ResourceTreeModel.js index 260857cd8f..2a44ca0655 100644 --- a/front_end/sdk/ResourceTreeModel.js +++ b/front_end/sdk/ResourceTreeModel.js @@ -1011,7 +1011,7 @@ export class ResourceTreeFrame { } /** - * @implements {ProtocolProxyApiWorkaround_PageDispatcher} + * @implements {ProtocolProxyApi.PageDispatcher} * @unrestricted */ export class PageDispatcher { diff --git a/front_end/sdk/ScreenCaptureModel.js b/front_end/sdk/ScreenCaptureModel.js index e04d7474a7..2f058eaa7b 100644 --- a/front_end/sdk/ScreenCaptureModel.js +++ b/front_end/sdk/ScreenCaptureModel.js @@ -6,7 +6,7 @@ import {OverlayModel} from './OverlayModel.js'; import {Capability, SDKModel, Target} from './SDKModel.js'; // eslint-disable-line no-unused-vars /** - * @implements {ProtocolProxyApiWorkaround_PageDispatcher} + * @implements {ProtocolProxyApi.PageDispatcher} */ export class ScreenCaptureModel extends SDKModel { /** diff --git a/front_end/sdk/ServiceWorkerCacheModel.js b/front_end/sdk/ServiceWorkerCacheModel.js index ff5cb29100..9cb465c9b2 100644 --- a/front_end/sdk/ServiceWorkerCacheModel.js +++ b/front_end/sdk/ServiceWorkerCacheModel.js @@ -9,7 +9,7 @@ import {Capability, SDKModel, Target} from './SDKModel.js'; // eslint-disable-l import {Events as SecurityOriginManagerEvents, SecurityOriginManager} from './SecurityOriginManager.js'; /** - * @implements {ProtocolProxyApiWorkaround_StorageDispatcher} + * @implements {ProtocolProxyApi.StorageDispatcher} */ export class ServiceWorkerCacheModel extends SDKModel { /** diff --git a/scripts/build/generate_protocol_externs.py b/scripts/build/generate_protocol_externs.py index a649fb6f32..3bc7ca9a77 100644 --- a/scripts/build/generate_protocol_externs.py +++ b/scripts/build/generate_protocol_externs.py @@ -280,10 +280,6 @@ def generate_protocol_externs(output_path, file1, file2): output_file.write("/** @interface */\n") output_file.write("ProtocolProxyApi.%sDispatcher = function() {};\n" % domain_name) - # Include the workaround for https://github.com/microsoft/TypeScript/issues/38640 - output_file.write( - "var ProtocolProxyApiWorkaround_%sDispatcher = ProtocolProxyApi.%sDispatcher;\n" - % (domain_name, domain_name)) if "events" in domain: for event in domain["events"]: params = [] diff --git a/scripts/protocol_typescript/protocol_dts_generator.ts b/scripts/protocol_typescript/protocol_dts_generator.ts index b0de18245b..a012947029 100644 --- a/scripts/protocol_typescript/protocol_dts_generator.ts +++ b/scripts/protocol_typescript/protocol_dts_generator.ts @@ -402,12 +402,6 @@ const emitApi = (moduleName: string, protocolModuleName: string, domains: Protoc domains.forEach(d => emitDomainApi(d, protocolModulePrefix)); emitCloseBlock(); emitLine(); - - emitLine('// Include the workaround for https://github.com/microsoft/TypeScript/issues/38640'); - domains.forEach(d => { - emitLine( - `interface ProtocolProxyApiWorkaround_${d.domain}Dispatcher extends ProtocolProxyApi.${d.domain}Dispatcher {}`); - }); }; const flushEmitToFile = (path: string) => {