mirror of
https://github.com/zen-browser/desktop.git
synced 2025-07-07 21:49:58 +02:00
style: Formatted the project, b=(no-bug), c=scripts
This commit is contained in:
parent
e65991aa03
commit
8136387a75
11 changed files with 41339 additions and 33414 deletions
|
@ -2,23 +2,24 @@
|
|||
import os
|
||||
|
||||
FILES = [
|
||||
"index.d.ts",
|
||||
"lib.gecko.darwin.d.ts",
|
||||
"lib.gecko.dom.d.ts",
|
||||
"lib.gecko.glean.d.ts",
|
||||
"lib.gecko.linux.d.ts",
|
||||
"lib.gecko.modules.d.ts",
|
||||
"lib.gecko.nsresult.d.ts",
|
||||
"lib.gecko.services.d.ts",
|
||||
"lib.gecko.tweaks.d.ts",
|
||||
"lib.gecko.win32.d.ts",
|
||||
"lib.gecko.xpcom.d.ts",
|
||||
"lib.gecko.xpidl.d.ts",
|
||||
"index.d.ts",
|
||||
"lib.gecko.darwin.d.ts",
|
||||
"lib.gecko.dom.d.ts",
|
||||
"lib.gecko.glean.d.ts",
|
||||
"lib.gecko.linux.d.ts",
|
||||
"lib.gecko.modules.d.ts",
|
||||
"lib.gecko.nsresult.d.ts",
|
||||
"lib.gecko.services.d.ts",
|
||||
"lib.gecko.tweaks.d.ts",
|
||||
"lib.gecko.win32.d.ts",
|
||||
"lib.gecko.xpcom.d.ts",
|
||||
"lib.gecko.xpidl.d.ts",
|
||||
]
|
||||
|
||||
ENGINE_PATH = os.path.join("engine", "tools", "@types")
|
||||
SRC_PATH = os.path.join("src", "zen", "@types")
|
||||
|
||||
|
||||
def update_ts_types():
|
||||
os.system("cd engine && ./mach ts build && ./mach ts update")
|
||||
# copy the files from engine/tools/@types to src/@types
|
||||
|
@ -36,6 +37,7 @@ def update_ts_types():
|
|||
f.write('/// <reference types="./zen.d.ts" />\n')
|
||||
f.write('\n')
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
update_ts_types()
|
||||
print("Updated TypeScript types.")
|
||||
|
|
1
src/zen/@types/index.d.ts
vendored
1
src/zen/@types/index.d.ts
vendored
|
@ -34,4 +34,3 @@ declare global {
|
|||
export {};
|
||||
|
||||
/// <reference types="./zen.d.ts" />
|
||||
|
||||
|
|
327
src/zen/@types/lib.gecko.darwin.d.ts
vendored
327
src/zen/@types/lib.gecko.darwin.d.ts
vendored
|
@ -5,207 +5,204 @@
|
|||
*/
|
||||
|
||||
declare global {
|
||||
// https://searchfox.org/mozilla-central/source/accessible/interfaces/nsIAccessibleMacInterface.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/accessible/interfaces/nsIAccessibleMacInterface.idl
|
||||
interface nsIAccessibleMacNSObjectWrapper extends nsISupports {}
|
||||
|
||||
interface nsIAccessibleMacNSObjectWrapper extends nsISupports {
|
||||
}
|
||||
interface nsIAccessibleMacInterface extends nsISupports {
|
||||
readonly attributeNames: string[];
|
||||
readonly parameterizedAttributeNames: string[];
|
||||
readonly actionNames: string[];
|
||||
getAttributeValue(attributeName: string): any;
|
||||
getParameterizedAttributeValue(attributeName: string, parameter: any): any;
|
||||
performAction(actionName: string): void;
|
||||
isAttributeSettable(attributeName: string): boolean;
|
||||
setAttributeValue(attributeName: string, attributeValue: any): void;
|
||||
}
|
||||
|
||||
interface nsIAccessibleMacInterface extends nsISupports {
|
||||
readonly attributeNames: string[];
|
||||
readonly parameterizedAttributeNames: string[];
|
||||
readonly actionNames: string[];
|
||||
getAttributeValue(attributeName: string): any;
|
||||
getParameterizedAttributeValue(attributeName: string, parameter: any): any;
|
||||
performAction(actionName: string): void;
|
||||
isAttributeSettable(attributeName: string): boolean;
|
||||
setAttributeValue(attributeName: string, attributeValue: any): void;
|
||||
}
|
||||
interface nsIAccessibleMacEvent extends nsISupports {
|
||||
readonly macIface: nsIAccessibleMacInterface;
|
||||
readonly data: any;
|
||||
}
|
||||
|
||||
interface nsIAccessibleMacEvent extends nsISupports {
|
||||
readonly macIface: nsIAccessibleMacInterface;
|
||||
readonly data: any;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/browser/components/migration/nsIKeychainMigrationUtils.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/browser/components/migration/nsIKeychainMigrationUtils.idl
|
||||
interface nsIKeychainMigrationUtils extends nsISupports {
|
||||
getGenericPassword(aServiceName: string, aAccountName: string): string;
|
||||
}
|
||||
|
||||
interface nsIKeychainMigrationUtils extends nsISupports {
|
||||
getGenericPassword(aServiceName: string, aAccountName: string): string;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/browser/components/shell/nsIMacShellService.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/browser/components/shell/nsIMacShellService.idl
|
||||
interface nsIMacShellService extends nsIShellService {
|
||||
showDesktopPreferences(): void;
|
||||
showSecurityPreferences(aPaneID: string): void;
|
||||
getAvailableApplicationsForProtocol(protocol: string): string[][];
|
||||
}
|
||||
|
||||
interface nsIMacShellService extends nsIShellService {
|
||||
showDesktopPreferences(): void;
|
||||
showSecurityPreferences(aPaneID: string): void;
|
||||
getAvailableApplicationsForProtocol(protocol: string): string[][];
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIMacDockSupport.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIMacDockSupport.idl
|
||||
interface nsIAppBundleLaunchOptions extends nsISupports {
|
||||
readonly addsToRecentItems: boolean;
|
||||
}
|
||||
|
||||
interface nsIAppBundleLaunchOptions extends nsISupports {
|
||||
readonly addsToRecentItems: boolean;
|
||||
}
|
||||
interface nsIMacDockSupport extends nsISupports {
|
||||
dockMenu: nsIStandaloneNativeMenu;
|
||||
activateApplication(aIgnoreOtherApplications: boolean): void;
|
||||
badgeText: string;
|
||||
setBadgeImage(aBadgeImage: imgIContainer, aPaintContext?: nsISVGPaintContext): void;
|
||||
readonly isAppInDock: boolean;
|
||||
ensureAppIsPinnedToDock(aAppPath?: string, aAppToReplacePath?: string): boolean;
|
||||
launchAppBundle(aAppBundle: nsIFile, aArgs: string[], aLaunchOptions?: nsIAppBundleLaunchOptions): void;
|
||||
}
|
||||
|
||||
interface nsIMacDockSupport extends nsISupports {
|
||||
dockMenu: nsIStandaloneNativeMenu;
|
||||
activateApplication(aIgnoreOtherApplications: boolean): void;
|
||||
badgeText: string;
|
||||
setBadgeImage(aBadgeImage: imgIContainer, aPaintContext?: nsISVGPaintContext): void;
|
||||
readonly isAppInDock: boolean;
|
||||
ensureAppIsPinnedToDock(aAppPath?: string, aAppToReplacePath?: string): boolean;
|
||||
launchAppBundle(aAppBundle: nsIFile, aArgs: string[], aLaunchOptions?: nsIAppBundleLaunchOptions): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIMacFinderProgress.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIMacFinderProgress.idl
|
||||
type nsIMacFinderProgressCanceledCallback = Callable<{
|
||||
canceled(): void;
|
||||
}>;
|
||||
|
||||
type nsIMacFinderProgressCanceledCallback = Callable<{
|
||||
canceled(): void;
|
||||
}>
|
||||
interface nsIMacFinderProgress extends nsISupports {
|
||||
init(path: string, canceledCallback: nsIMacFinderProgressCanceledCallback): void;
|
||||
updateProgress(currentProgress: u64, totalProgress: u64): void;
|
||||
end(): void;
|
||||
}
|
||||
|
||||
interface nsIMacFinderProgress extends nsISupports {
|
||||
init(path: string, canceledCallback: nsIMacFinderProgressCanceledCallback): void;
|
||||
updateProgress(currentProgress: u64, totalProgress: u64): void;
|
||||
end(): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIMacSharingService.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIMacSharingService.idl
|
||||
interface nsIMacSharingService extends nsISupports {
|
||||
getSharingProviders(pageUrl: string): any;
|
||||
shareUrl(serviceName: string, pageUrl: string, pageTitle: string): void;
|
||||
openSharingPreferences(): void;
|
||||
}
|
||||
|
||||
interface nsIMacSharingService extends nsISupports {
|
||||
getSharingProviders(pageUrl: string): any;
|
||||
shareUrl(serviceName: string, pageUrl: string, pageTitle: string): void;
|
||||
openSharingPreferences(): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIMacUserActivityUpdater.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIMacUserActivityUpdater.idl
|
||||
interface nsIMacUserActivityUpdater extends nsISupports {
|
||||
updateLocation(pageUrl: string, pageTitle: string, window: nsIBaseWindow): void;
|
||||
}
|
||||
|
||||
interface nsIMacUserActivityUpdater extends nsISupports {
|
||||
updateLocation(pageUrl: string, pageTitle: string, window: nsIBaseWindow): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIMacWebAppUtils.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIMacWebAppUtils.idl
|
||||
type nsITrashAppCallback = Callable<{
|
||||
trashAppFinished(rv: nsresult): void;
|
||||
}>;
|
||||
|
||||
type nsITrashAppCallback = Callable<{
|
||||
trashAppFinished(rv: nsresult): void;
|
||||
}>
|
||||
interface nsIMacWebAppUtils extends nsISupports {
|
||||
pathForAppWithIdentifier(bundleIdentifier: string): string;
|
||||
launchAppWithIdentifier(bundleIdentifier: string): void;
|
||||
trashApp(path: string, callback: nsITrashAppCallback): void;
|
||||
}
|
||||
|
||||
interface nsIMacWebAppUtils extends nsISupports {
|
||||
pathForAppWithIdentifier(bundleIdentifier: string): string;
|
||||
launchAppWithIdentifier(bundleIdentifier: string): void;
|
||||
trashApp(path: string, callback: nsITrashAppCallback): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIStandaloneNativeMenu.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIStandaloneNativeMenu.idl
|
||||
interface nsIStandaloneNativeMenu extends nsISupports {
|
||||
init(aElement: Element): void;
|
||||
menuWillOpen(): boolean;
|
||||
activateNativeMenuItemAt(anIndexString: string): void;
|
||||
forceUpdateNativeMenuAt(anIndexString: string): void;
|
||||
dump(): void;
|
||||
}
|
||||
|
||||
interface nsIStandaloneNativeMenu extends nsISupports {
|
||||
init(aElement: Element): void;
|
||||
menuWillOpen(): boolean;
|
||||
activateNativeMenuItemAt(anIndexString: string): void;
|
||||
forceUpdateNativeMenuAt(anIndexString: string): void;
|
||||
dump(): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarProgress.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarProgress.idl
|
||||
interface nsITaskbarProgress extends nsISupports {
|
||||
readonly STATE_NO_PROGRESS?: 0;
|
||||
readonly STATE_INDETERMINATE?: 1;
|
||||
readonly STATE_NORMAL?: 2;
|
||||
readonly STATE_ERROR?: 3;
|
||||
readonly STATE_PAUSED?: 4;
|
||||
|
||||
interface nsITaskbarProgress extends nsISupports {
|
||||
readonly STATE_NO_PROGRESS?: 0;
|
||||
readonly STATE_INDETERMINATE?: 1;
|
||||
readonly STATE_NORMAL?: 2;
|
||||
readonly STATE_ERROR?: 3;
|
||||
readonly STATE_PAUSED?: 4;
|
||||
setProgressState(state: nsTaskbarProgressState, currentValue?: u64, maxValue?: u64): void;
|
||||
}
|
||||
|
||||
setProgressState(state: nsTaskbarProgressState, currentValue?: u64, maxValue?: u64): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITouchBarHelper.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITouchBarHelper.idl
|
||||
interface nsITouchBarHelper extends nsISupports {
|
||||
readonly activeUrl: string;
|
||||
readonly activeTitle: string;
|
||||
readonly isUrlbarFocused: boolean;
|
||||
toggleFocusUrlbar(): void;
|
||||
unfocusUrlbar(): void;
|
||||
allItems: nsIArray;
|
||||
readonly document: Document;
|
||||
getTouchBarInput(aInputName: string): nsITouchBarInput;
|
||||
insertRestrictionInUrlbar(aToken: string): void;
|
||||
}
|
||||
|
||||
interface nsITouchBarHelper extends nsISupports {
|
||||
readonly activeUrl: string;
|
||||
readonly activeTitle: string;
|
||||
readonly isUrlbarFocused: boolean;
|
||||
toggleFocusUrlbar(): void;
|
||||
unfocusUrlbar(): void;
|
||||
allItems: nsIArray;
|
||||
readonly document: Document;
|
||||
getTouchBarInput(aInputName: string): nsITouchBarInput;
|
||||
insertRestrictionInUrlbar(aToken: string): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITouchBarInput.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITouchBarInput.idl
|
||||
type nsITouchBarInputCallback = Callable<{
|
||||
onCommand(): void;
|
||||
}>;
|
||||
|
||||
type nsITouchBarInputCallback = Callable<{
|
||||
onCommand(): void;
|
||||
}>
|
||||
interface nsITouchBarInput extends nsISupports {
|
||||
readonly key: string;
|
||||
title: string;
|
||||
image: nsIURI;
|
||||
type: string;
|
||||
callback: nsITouchBarInputCallback;
|
||||
color: u32;
|
||||
disabled: boolean;
|
||||
children: nsIArray;
|
||||
}
|
||||
|
||||
interface nsITouchBarInput extends nsISupports {
|
||||
readonly key: string;
|
||||
title: string;
|
||||
image: nsIURI;
|
||||
type: string;
|
||||
callback: nsITouchBarInputCallback;
|
||||
color: u32;
|
||||
disabled: boolean;
|
||||
children: nsIArray;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITouchBarUpdater.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITouchBarUpdater.idl
|
||||
interface nsITouchBarUpdater extends nsISupports {
|
||||
updateTouchBarInputs(aWindow: nsIBaseWindow, aInputs: nsITouchBarInput[]): void;
|
||||
enterCustomizeMode(): void;
|
||||
isTouchBarInitialized(): boolean;
|
||||
setTouchBarInitialized(aIsInitialized: boolean): void;
|
||||
showPopover(aWindow: nsIBaseWindow, aPopover: nsITouchBarInput, aShowing: boolean): void;
|
||||
}
|
||||
|
||||
interface nsITouchBarUpdater extends nsISupports {
|
||||
updateTouchBarInputs(aWindow: nsIBaseWindow, aInputs: nsITouchBarInput[]): void;
|
||||
enterCustomizeMode(): void;
|
||||
isTouchBarInitialized(): boolean;
|
||||
setTouchBarInitialized(aIsInitialized: boolean): void;
|
||||
showPopover(aWindow: nsIBaseWindow, aPopover: nsITouchBarInput, aShowing: boolean): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/xpcom/base/nsIMacPreferencesReader.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/xpcom/base/nsIMacPreferencesReader.idl
|
||||
interface nsIMacPreferencesReader extends nsISupports {
|
||||
policiesEnabled(): boolean;
|
||||
readPreferences(): any;
|
||||
}
|
||||
|
||||
interface nsIMacPreferencesReader extends nsISupports {
|
||||
policiesEnabled(): boolean;
|
||||
readPreferences(): any;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/xpcom/io/nsILocalFileMac.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/xpcom/io/nsILocalFileMac.idl
|
||||
interface nsILocalFileMac extends nsIFile {
|
||||
readonly fileSizeWithResFork: i64;
|
||||
launchWithDoc(aDocToLoad: nsIFile, aLaunchInBackground: boolean): void;
|
||||
openDocWithApp(aAppToOpenWith: nsIFile, aLaunchInBackground: boolean): void;
|
||||
isPackage(): boolean;
|
||||
readonly bundleDisplayName: string;
|
||||
readonly bundleIdentifier: string;
|
||||
readonly bundleContentsLastModifiedTime: i64;
|
||||
hasXAttr(aAttrName: string): boolean;
|
||||
getXAttr(aAttrName: string): u8[];
|
||||
setXAttr(aAttrName: string, aAttrValue: u8[]): void;
|
||||
delXAttr(aAttrName: string): void;
|
||||
}
|
||||
|
||||
interface nsILocalFileMac extends nsIFile {
|
||||
readonly fileSizeWithResFork: i64;
|
||||
launchWithDoc(aDocToLoad: nsIFile, aLaunchInBackground: boolean): void;
|
||||
openDocWithApp(aAppToOpenWith: nsIFile, aLaunchInBackground: boolean): void;
|
||||
isPackage(): boolean;
|
||||
readonly bundleDisplayName: string;
|
||||
readonly bundleIdentifier: string;
|
||||
readonly bundleContentsLastModifiedTime: i64;
|
||||
hasXAttr(aAttrName: string): boolean;
|
||||
getXAttr(aAttrName: string): u8[];
|
||||
setXAttr(aAttrName: string, aAttrValue: u8[]): void;
|
||||
delXAttr(aAttrName: string): void;
|
||||
}
|
||||
|
||||
interface nsIXPCComponents_Interfaces {
|
||||
nsIAccessibleMacNSObjectWrapper: nsJSIID<nsIAccessibleMacNSObjectWrapper>;
|
||||
nsIAccessibleMacInterface: nsJSIID<nsIAccessibleMacInterface>;
|
||||
nsIAccessibleMacEvent: nsJSIID<nsIAccessibleMacEvent>;
|
||||
nsIKeychainMigrationUtils: nsJSIID<nsIKeychainMigrationUtils>;
|
||||
nsIMacShellService: nsJSIID<nsIMacShellService>;
|
||||
nsIAppBundleLaunchOptions: nsJSIID<nsIAppBundleLaunchOptions>;
|
||||
nsIMacDockSupport: nsJSIID<nsIMacDockSupport>;
|
||||
nsIMacFinderProgressCanceledCallback: nsJSIID<nsIMacFinderProgressCanceledCallback>;
|
||||
nsIMacFinderProgress: nsJSIID<nsIMacFinderProgress>;
|
||||
nsIMacSharingService: nsJSIID<nsIMacSharingService>;
|
||||
nsIMacUserActivityUpdater: nsJSIID<nsIMacUserActivityUpdater>;
|
||||
nsITrashAppCallback: nsJSIID<nsITrashAppCallback>;
|
||||
nsIMacWebAppUtils: nsJSIID<nsIMacWebAppUtils>;
|
||||
nsIStandaloneNativeMenu: nsJSIID<nsIStandaloneNativeMenu>;
|
||||
nsITaskbarProgress: nsJSIID<nsITaskbarProgress>;
|
||||
nsITouchBarHelper: nsJSIID<nsITouchBarHelper>;
|
||||
nsITouchBarInputCallback: nsJSIID<nsITouchBarInputCallback>;
|
||||
nsITouchBarInput: nsJSIID<nsITouchBarInput>;
|
||||
nsITouchBarUpdater: nsJSIID<nsITouchBarUpdater>;
|
||||
nsIMacPreferencesReader: nsJSIID<nsIMacPreferencesReader>;
|
||||
nsILocalFileMac: nsJSIID<nsILocalFileMac>;
|
||||
}
|
||||
|
||||
} // global
|
||||
interface nsIXPCComponents_Interfaces {
|
||||
nsIAccessibleMacNSObjectWrapper: nsJSIID<nsIAccessibleMacNSObjectWrapper>;
|
||||
nsIAccessibleMacInterface: nsJSIID<nsIAccessibleMacInterface>;
|
||||
nsIAccessibleMacEvent: nsJSIID<nsIAccessibleMacEvent>;
|
||||
nsIKeychainMigrationUtils: nsJSIID<nsIKeychainMigrationUtils>;
|
||||
nsIMacShellService: nsJSIID<nsIMacShellService>;
|
||||
nsIAppBundleLaunchOptions: nsJSIID<nsIAppBundleLaunchOptions>;
|
||||
nsIMacDockSupport: nsJSIID<nsIMacDockSupport>;
|
||||
nsIMacFinderProgressCanceledCallback: nsJSIID<nsIMacFinderProgressCanceledCallback>;
|
||||
nsIMacFinderProgress: nsJSIID<nsIMacFinderProgress>;
|
||||
nsIMacSharingService: nsJSIID<nsIMacSharingService>;
|
||||
nsIMacUserActivityUpdater: nsJSIID<nsIMacUserActivityUpdater>;
|
||||
nsITrashAppCallback: nsJSIID<nsITrashAppCallback>;
|
||||
nsIMacWebAppUtils: nsJSIID<nsIMacWebAppUtils>;
|
||||
nsIStandaloneNativeMenu: nsJSIID<nsIStandaloneNativeMenu>;
|
||||
nsITaskbarProgress: nsJSIID<nsITaskbarProgress>;
|
||||
nsITouchBarHelper: nsJSIID<nsITouchBarHelper>;
|
||||
nsITouchBarInputCallback: nsJSIID<nsITouchBarInputCallback>;
|
||||
nsITouchBarInput: nsJSIID<nsITouchBarInput>;
|
||||
nsITouchBarUpdater: nsJSIID<nsITouchBarUpdater>;
|
||||
nsIMacPreferencesReader: nsJSIID<nsIMacPreferencesReader>;
|
||||
nsILocalFileMac: nsJSIID<nsILocalFileMac>;
|
||||
}
|
||||
} // global
|
||||
|
||||
// Typedefs from xpidl.
|
||||
type PRTime = i64;
|
||||
|
@ -223,6 +220,6 @@ type OutParam<T> = { value?: T };
|
|||
type Enums<enums> = Partial<Pick<enums, keyof enums>>;
|
||||
|
||||
/** Callable accepts either form of a [function] interface. */
|
||||
type Callable<iface> = iface | Extract<iface[keyof iface], Function>
|
||||
type Callable<iface> = iface | Extract<iface[keyof iface], Function>;
|
||||
|
||||
export {};
|
||||
|
|
40803
src/zen/@types/lib.gecko.dom.d.ts
vendored
40803
src/zen/@types/lib.gecko.dom.d.ts
vendored
File diff suppressed because it is too large
Load diff
84
src/zen/@types/lib.gecko.linux.d.ts
vendored
84
src/zen/@types/lib.gecko.linux.d.ts
vendored
|
@ -5,60 +5,58 @@
|
|||
*/
|
||||
|
||||
declare global {
|
||||
// https://searchfox.org/mozilla-central/source/browser/components/shell/nsIGNOMEShellService.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/browser/components/shell/nsIGNOMEShellService.idl
|
||||
interface nsIGNOMEShellService extends nsIShellService {
|
||||
readonly canSetDesktopBackground: boolean;
|
||||
isDefaultForScheme(aScheme: string): boolean;
|
||||
}
|
||||
|
||||
interface nsIGNOMEShellService extends nsIShellService {
|
||||
readonly canSetDesktopBackground: boolean;
|
||||
isDefaultForScheme(aScheme: string): boolean;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/browser/components/shell/nsIOpenTabsProvider.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/browser/components/shell/nsIOpenTabsProvider.idl
|
||||
interface nsIOpenTabsProvider extends nsISupports {
|
||||
getOpenTabs(): string[];
|
||||
switchToOpenTab(url: string): void;
|
||||
}
|
||||
|
||||
interface nsIOpenTabsProvider extends nsISupports {
|
||||
getOpenTabs(): string[];
|
||||
switchToOpenTab(url: string): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIApplicationChooser.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIApplicationChooser.idl
|
||||
type nsIApplicationChooserFinishedCallback = Callable<{
|
||||
done(handlerApp: nsIHandlerApp): void;
|
||||
}>;
|
||||
|
||||
type nsIApplicationChooserFinishedCallback = Callable<{
|
||||
done(handlerApp: nsIHandlerApp): void;
|
||||
}>
|
||||
interface nsIApplicationChooser extends nsISupports {
|
||||
init(parent: mozIDOMWindowProxy, title: string): void;
|
||||
open(contentType: string, applicationChooserFinishedCallback: nsIApplicationChooserFinishedCallback): void;
|
||||
}
|
||||
|
||||
interface nsIApplicationChooser extends nsISupports {
|
||||
init(parent: mozIDOMWindowProxy, title: string): void;
|
||||
open(contentType: string, applicationChooserFinishedCallback: nsIApplicationChooserFinishedCallback): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIGtkTaskbarProgress.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIGtkTaskbarProgress.idl
|
||||
interface nsIGtkTaskbarProgress extends nsITaskbarProgress {
|
||||
setPrimaryWindow(aWindow: mozIDOMWindowProxy): void;
|
||||
}
|
||||
|
||||
interface nsIGtkTaskbarProgress extends nsITaskbarProgress {
|
||||
setPrimaryWindow(aWindow: mozIDOMWindowProxy): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarProgress.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarProgress.idl
|
||||
interface nsITaskbarProgress extends nsISupports {
|
||||
readonly STATE_NO_PROGRESS?: 0;
|
||||
readonly STATE_INDETERMINATE?: 1;
|
||||
readonly STATE_NORMAL?: 2;
|
||||
readonly STATE_ERROR?: 3;
|
||||
readonly STATE_PAUSED?: 4;
|
||||
|
||||
interface nsITaskbarProgress extends nsISupports {
|
||||
readonly STATE_NO_PROGRESS?: 0;
|
||||
readonly STATE_INDETERMINATE?: 1;
|
||||
readonly STATE_NORMAL?: 2;
|
||||
readonly STATE_ERROR?: 3;
|
||||
readonly STATE_PAUSED?: 4;
|
||||
setProgressState(state: nsTaskbarProgressState, currentValue?: u64, maxValue?: u64): void;
|
||||
}
|
||||
|
||||
setProgressState(state: nsTaskbarProgressState, currentValue?: u64, maxValue?: u64): void;
|
||||
}
|
||||
|
||||
interface nsIXPCComponents_Interfaces {
|
||||
nsIGNOMEShellService: nsJSIID<nsIGNOMEShellService>;
|
||||
nsIOpenTabsProvider: nsJSIID<nsIOpenTabsProvider>;
|
||||
nsIApplicationChooserFinishedCallback: nsJSIID<nsIApplicationChooserFinishedCallback>;
|
||||
nsIApplicationChooser: nsJSIID<nsIApplicationChooser>;
|
||||
nsIGtkTaskbarProgress: nsJSIID<nsIGtkTaskbarProgress>;
|
||||
nsITaskbarProgress: nsJSIID<nsITaskbarProgress>;
|
||||
}
|
||||
|
||||
} // global
|
||||
interface nsIXPCComponents_Interfaces {
|
||||
nsIGNOMEShellService: nsJSIID<nsIGNOMEShellService>;
|
||||
nsIOpenTabsProvider: nsJSIID<nsIOpenTabsProvider>;
|
||||
nsIApplicationChooserFinishedCallback: nsJSIID<nsIApplicationChooserFinishedCallback>;
|
||||
nsIApplicationChooser: nsJSIID<nsIApplicationChooser>;
|
||||
nsIGtkTaskbarProgress: nsJSIID<nsIGtkTaskbarProgress>;
|
||||
nsITaskbarProgress: nsJSIID<nsITaskbarProgress>;
|
||||
}
|
||||
} // global
|
||||
|
||||
// Typedefs from xpidl.
|
||||
type PRTime = i64;
|
||||
|
@ -77,6 +75,6 @@ type OutParam<T> = { value?: T };
|
|||
type Enums<enums> = Partial<Pick<enums, keyof enums>>;
|
||||
|
||||
/** Callable accepts either form of a [function] interface. */
|
||||
type Callable<iface> = iface | Extract<iface[keyof iface], Function>
|
||||
type Callable<iface> = iface | Extract<iface[keyof iface], Function>;
|
||||
|
||||
export {};
|
||||
|
|
1888
src/zen/@types/lib.gecko.modules.d.ts
vendored
1888
src/zen/@types/lib.gecko.modules.d.ts
vendored
File diff suppressed because it is too large
Load diff
1
src/zen/@types/lib.gecko.nsresult.d.ts
vendored
1
src/zen/@types/lib.gecko.nsresult.d.ts
vendored
|
@ -5,7 +5,6 @@
|
|||
*/
|
||||
|
||||
interface nsIXPCComponents_Results {
|
||||
|
||||
// Error Message definitions.
|
||||
|
||||
// xpconnect specific codes (from nsIXPConnect.h)
|
||||
|
|
39
src/zen/@types/lib.gecko.tweaks.d.ts
vendored
39
src/zen/@types/lib.gecko.tweaks.d.ts
vendored
|
@ -17,21 +17,21 @@ interface ChromeWindow extends Window {
|
|||
}
|
||||
|
||||
interface Document {
|
||||
createXULElement(name: "browser"): XULBrowserElement;
|
||||
createXULElement(name: 'browser'): XULBrowserElement;
|
||||
}
|
||||
|
||||
type nsIGleanPingNoReason = {
|
||||
[K in keyof nsIGleanPing]: K extends "submit" ? (_?: never) => void : nsIGleanPing[K];
|
||||
}
|
||||
[K in keyof nsIGleanPing]: K extends 'submit' ? (_?: never) => void : nsIGleanPing[K];
|
||||
};
|
||||
|
||||
type nsIGleanPingWithReason<T> = {
|
||||
[K in keyof nsIGleanPing]: K extends "submit" ? (reason: T) => void : nsIGleanPing[K];
|
||||
}
|
||||
[K in keyof nsIGleanPing]: K extends 'submit' ? (reason: T) => void : nsIGleanPing[K];
|
||||
};
|
||||
|
||||
interface MessageListenerManagerMixin {
|
||||
// Overloads that define `data` arg as required, since it's ~always expected.
|
||||
addMessageListener(msg: string, listener: { receiveMessage(_: ReceiveMessageArgument & { data })});
|
||||
removeMessageListener(msg: string, listener: { receiveMessage(_: ReceiveMessageArgument & { data })});
|
||||
addMessageListener(msg: string, listener: { receiveMessage(_: ReceiveMessageArgument & { data }) });
|
||||
removeMessageListener(msg: string, listener: { receiveMessage(_: ReceiveMessageArgument & { data }) });
|
||||
}
|
||||
|
||||
interface MozQueryInterface {
|
||||
|
@ -52,31 +52,30 @@ interface nsISupports {
|
|||
}
|
||||
|
||||
interface nsIXPCComponents_Constructor {
|
||||
<const T, IIDs = nsIXPCComponents_Interfaces>(cid, id: T, init?): {
|
||||
<const T, IIDs = nsIXPCComponents_Interfaces>(
|
||||
cid,
|
||||
id: T,
|
||||
init?
|
||||
): {
|
||||
new (...any): nsQIResult<T extends keyof IIDs ? IIDs[T] : T>;
|
||||
(...any): nsQIResult<T extends keyof IIDs ? IIDs[T] : T>;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
interface ComponentsExceptionOptions {
|
||||
result?: number,
|
||||
stack?: nsIStackFrame,
|
||||
data?: object,
|
||||
result?: number;
|
||||
stack?: nsIStackFrame;
|
||||
data?: object;
|
||||
}
|
||||
|
||||
interface nsIException extends Exception {}
|
||||
|
||||
interface nsIXPCComponents_Exception {
|
||||
(
|
||||
message?: string,
|
||||
resultOrOptions?: number | ComponentsExceptionOptions,
|
||||
stack?: nsIStackFrame,
|
||||
data?: object
|
||||
): nsIException;
|
||||
(message?: string, resultOrOptions?: number | ComponentsExceptionOptions, stack?: nsIStackFrame, data?: object): nsIException;
|
||||
}
|
||||
|
||||
interface nsIXPCComponents_ID {
|
||||
(uuid: string): nsID
|
||||
(uuid: string): nsID;
|
||||
}
|
||||
|
||||
interface nsIXPCComponents_utils_Sandbox {
|
||||
|
@ -87,7 +86,7 @@ interface nsXPCComponents_Classes {
|
|||
[cid: string]: {
|
||||
createInstance<T>(aID: T): nsQIResult<T>;
|
||||
getService<T>(aID?: T): unknown extends T ? nsISupports : nsQIResult<T>;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
// Generic overloads.
|
||||
|
|
582
src/zen/@types/lib.gecko.win32.d.ts
vendored
582
src/zen/@types/lib.gecko.win32.d.ts
vendored
|
@ -5,39 +5,37 @@
|
|||
*/
|
||||
|
||||
declare global {
|
||||
// https://searchfox.org/mozilla-central/source/toolkit/components/aboutthirdparty/nsIAboutThirdParty.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/toolkit/components/aboutthirdparty/nsIAboutThirdParty.idl
|
||||
interface nsIInstalledApplication extends nsISupports {
|
||||
readonly name: string;
|
||||
readonly publisher: string;
|
||||
}
|
||||
|
||||
interface nsIInstalledApplication extends nsISupports {
|
||||
readonly name: string;
|
||||
readonly publisher: string;
|
||||
}
|
||||
interface nsIAboutThirdParty extends nsISupports {
|
||||
readonly ModuleType_Unknown?: 1;
|
||||
readonly ModuleType_IME?: 2;
|
||||
readonly ModuleType_ShellExtension?: 4;
|
||||
readonly ModuleType_BlockedByUser?: 8;
|
||||
readonly ModuleType_BlockedByUserAtLaunch?: 16;
|
||||
|
||||
interface nsIAboutThirdParty extends nsISupports {
|
||||
readonly ModuleType_Unknown?: 1;
|
||||
readonly ModuleType_IME?: 2;
|
||||
readonly ModuleType_ShellExtension?: 4;
|
||||
readonly ModuleType_BlockedByUser?: 8;
|
||||
readonly ModuleType_BlockedByUserAtLaunch?: 16;
|
||||
lookupModuleType(aLeafName: string): u32;
|
||||
lookupApplication(aModulePath: string): nsIInstalledApplication;
|
||||
readonly isDynamicBlocklistAvailable: boolean;
|
||||
readonly isDynamicBlocklistDisabled: boolean;
|
||||
updateBlocklist(aLeafName: string, aNewBlockStatus: boolean): Promise<any>;
|
||||
collectSystemInfo(): Promise<any>;
|
||||
loadModuleForTesting(aModulePath: string): void;
|
||||
}
|
||||
|
||||
lookupModuleType(aLeafName: string): u32;
|
||||
lookupApplication(aModulePath: string): nsIInstalledApplication;
|
||||
readonly isDynamicBlocklistAvailable: boolean;
|
||||
readonly isDynamicBlocklistDisabled: boolean;
|
||||
updateBlocklist(aLeafName: string, aNewBlockStatus: boolean): Promise<any>;
|
||||
collectSystemInfo(): Promise<any>;
|
||||
loadModuleForTesting(aModulePath: string): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/toolkit/components/aboutwindowsmessages/nsIAboutWindowsMessages.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/toolkit/components/aboutwindowsmessages/nsIAboutWindowsMessages.idl
|
||||
interface nsIAboutWindowsMessages extends nsISupports {
|
||||
getMessages(currentWindow: mozIDOMWindowProxy, messages: OutParam<string[][]>, windowTitles: OutParam<string[]>): void;
|
||||
}
|
||||
|
||||
interface nsIAboutWindowsMessages extends nsISupports {
|
||||
getMessages(currentWindow: mozIDOMWindowProxy, messages: OutParam<string[][]>, windowTitles: OutParam<string[]>): void;
|
||||
}
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/toolkit/components/alerts/nsIWindowsAlertsService.idl
|
||||
|
||||
} // global
|
||||
// https://searchfox.org/mozilla-central/source/toolkit/components/alerts/nsIWindowsAlertsService.idl
|
||||
} // global
|
||||
|
||||
declare enum nsIWindowsAlertNotification_ImagePlacement {
|
||||
eInline = 0,
|
||||
|
@ -46,62 +44,67 @@ declare enum nsIWindowsAlertNotification_ImagePlacement {
|
|||
}
|
||||
|
||||
declare global {
|
||||
namespace nsIWindowsAlertNotification {
|
||||
type ImagePlacement = nsIWindowsAlertNotification_ImagePlacement;
|
||||
}
|
||||
|
||||
namespace nsIWindowsAlertNotification {
|
||||
type ImagePlacement = nsIWindowsAlertNotification_ImagePlacement;
|
||||
}
|
||||
interface nsIWindowsAlertNotification extends nsIAlertNotification, Enums<typeof nsIWindowsAlertNotification_ImagePlacement> {
|
||||
imagePlacement: nsIWindowsAlertNotification.ImagePlacement;
|
||||
}
|
||||
|
||||
interface nsIWindowsAlertNotification extends nsIAlertNotification, Enums<typeof nsIWindowsAlertNotification_ImagePlacement> {
|
||||
imagePlacement: nsIWindowsAlertNotification.ImagePlacement;
|
||||
}
|
||||
interface nsIWindowsAlertsService extends nsIAlertsService {
|
||||
handleWindowsTag(aWindowsTag: string): Promise<any>;
|
||||
getXmlStringForWindowsAlert(aAlert: nsIAlertNotification, aWindowsTag?: string): string;
|
||||
removeAllNotificationsForInstall(): void;
|
||||
}
|
||||
|
||||
interface nsIWindowsAlertsService extends nsIAlertsService {
|
||||
handleWindowsTag(aWindowsTag: string): Promise<any>;
|
||||
getXmlStringForWindowsAlert(aAlert: nsIAlertNotification, aWindowsTag?: string): string;
|
||||
removeAllNotificationsForInstall(): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/toolkit/mozapps/defaultagent/nsIDefaultAgent.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/toolkit/mozapps/defaultagent/nsIDefaultAgent.idl
|
||||
interface nsIDefaultAgent extends nsISupports {
|
||||
registerTask(aUniqueToken: string): void;
|
||||
updateTask(aUniqueToken: string): void;
|
||||
unregisterTask(aUniqueToken: string): void;
|
||||
uninstall(aUniqueToken: string): void;
|
||||
secondsSinceLastAppRun(): i64;
|
||||
getDefaultBrowser(): string;
|
||||
getReplacePreviousDefaultBrowser(aCurrentBrowser: string): string;
|
||||
getDefaultPdfHandler(): string;
|
||||
sendPing(
|
||||
aCurrentBrowser: string,
|
||||
aPreviousBrowser: string,
|
||||
aPdfHandler: string,
|
||||
aNotificationShown: string,
|
||||
aNotificationAction: string,
|
||||
daysSinceLastAppLaunch: u32
|
||||
): void;
|
||||
setDefaultBrowserUserChoice(aAumid: string, aExtraFileExtensions: string[]): void;
|
||||
setDefaultBrowserUserChoiceAsync(aAumid: string, aExtraFileExtensions: string[]): Promise<any>;
|
||||
setDefaultExtensionHandlersUserChoice(aAumid: string, aFileExtensions: string[]): void;
|
||||
agentDisabled(): boolean;
|
||||
}
|
||||
|
||||
interface nsIDefaultAgent extends nsISupports {
|
||||
registerTask(aUniqueToken: string): void;
|
||||
updateTask(aUniqueToken: string): void;
|
||||
unregisterTask(aUniqueToken: string): void;
|
||||
uninstall(aUniqueToken: string): void;
|
||||
secondsSinceLastAppRun(): i64;
|
||||
getDefaultBrowser(): string;
|
||||
getReplacePreviousDefaultBrowser(aCurrentBrowser: string): string;
|
||||
getDefaultPdfHandler(): string;
|
||||
sendPing(aCurrentBrowser: string, aPreviousBrowser: string, aPdfHandler: string, aNotificationShown: string, aNotificationAction: string, daysSinceLastAppLaunch: u32): void;
|
||||
setDefaultBrowserUserChoice(aAumid: string, aExtraFileExtensions: string[]): void;
|
||||
setDefaultBrowserUserChoiceAsync(aAumid: string, aExtraFileExtensions: string[]): Promise<any>;
|
||||
setDefaultExtensionHandlersUserChoice(aAumid: string, aFileExtensions: string[]): void;
|
||||
agentDisabled(): boolean;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/toolkit/mozapps/defaultagent/nsIWindowsMutex.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/toolkit/mozapps/defaultagent/nsIWindowsMutex.idl
|
||||
interface nsIWindowsMutex extends nsISupports {
|
||||
tryLock(): void;
|
||||
isLocked(): boolean;
|
||||
unlock(): void;
|
||||
}
|
||||
|
||||
interface nsIWindowsMutex extends nsISupports {
|
||||
tryLock(): void;
|
||||
isLocked(): boolean;
|
||||
unlock(): void;
|
||||
}
|
||||
interface nsIWindowsMutexFactory extends nsISupports {
|
||||
createMutex(aName: string): nsIWindowsMutex;
|
||||
}
|
||||
|
||||
interface nsIWindowsMutexFactory extends nsISupports {
|
||||
createMutex(aName: string): nsIWindowsMutex;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/dom/geolocation/nsIGeolocationUIUtilsWin.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/dom/geolocation/nsIGeolocationUIUtilsWin.idl
|
||||
interface nsIGeolocationUIUtilsWin extends nsISupports {
|
||||
dismissPrompts(aBC: BrowsingContext): void;
|
||||
}
|
||||
|
||||
interface nsIGeolocationUIUtilsWin extends nsISupports {
|
||||
dismissPrompts(aBC: BrowsingContext): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/netwerk/socket/nsINamedPipeService.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/netwerk/socket/nsINamedPipeService.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/browser/components/shell/nsIWindowsShellService.idl
|
||||
|
||||
} // global
|
||||
// https://searchfox.org/mozilla-central/source/browser/components/shell/nsIWindowsShellService.idl
|
||||
} // global
|
||||
|
||||
declare enum nsIWindowsShellService_LaunchOnLoginEnabledEnumerator {
|
||||
LAUNCH_ON_LOGIN_DISABLED_BY_SETTINGS = 0,
|
||||
|
@ -111,253 +114,262 @@ declare enum nsIWindowsShellService_LaunchOnLoginEnabledEnumerator {
|
|||
}
|
||||
|
||||
declare global {
|
||||
namespace nsIWindowsShellService {
|
||||
type LaunchOnLoginEnabledEnumerator = nsIWindowsShellService_LaunchOnLoginEnabledEnumerator;
|
||||
}
|
||||
|
||||
namespace nsIWindowsShellService {
|
||||
type LaunchOnLoginEnabledEnumerator = nsIWindowsShellService_LaunchOnLoginEnabledEnumerator;
|
||||
}
|
||||
interface nsIWindowsShellService
|
||||
extends nsIShellService,
|
||||
Enums<typeof nsIWindowsShellService_LaunchOnLoginEnabledEnumerator> {
|
||||
createShortcut(
|
||||
aBinary: nsIFile,
|
||||
aArguments: string[],
|
||||
aDescription: string,
|
||||
aIconFile: nsIFile,
|
||||
aIconIndex: u16,
|
||||
aAppUserModelId: string,
|
||||
aShortcutFolder: string,
|
||||
aShortcutName: string
|
||||
): Promise<any>;
|
||||
getLaunchOnLoginShortcuts(): string[];
|
||||
pinCurrentAppToStartMenuAsync(aCheckOnly: boolean): Promise<any>;
|
||||
isCurrentAppPinnedToStartMenuAsync(): Promise<any>;
|
||||
enableLaunchOnLoginMSIXAsync(aTaskId: string): Promise<any>;
|
||||
disableLaunchOnLoginMSIXAsync(aTaskId: string): Promise<any>;
|
||||
getLaunchOnLoginEnabledMSIXAsync(aTaskId: string): Promise<any>;
|
||||
pinCurrentAppToTaskbarAsync(aPrivateBrowsing: boolean): Promise<any>;
|
||||
checkPinCurrentAppToTaskbarAsync(aPrivateBrowsing: boolean): Promise<any>;
|
||||
isCurrentAppPinnedToTaskbarAsync(aumid: string): Promise<any>;
|
||||
pinShortcutToTaskbar(aAppUserModelId: string, aShortcutPath: string): Promise<any>;
|
||||
createWindowsIcon(aFile: nsIFile, aContainer: imgIContainer): Promise<any>;
|
||||
unpinShortcutFromTaskbar(aShortcutPath: string): void;
|
||||
getTaskbarTabShortcutPath(aShortcutName: string): string;
|
||||
getTaskbarTabPins(): string[];
|
||||
classifyShortcut(aPath: string): string;
|
||||
hasPinnableShortcut(aAUMID: string, aPrivateBrowsing: boolean): Promise<any>;
|
||||
canSetDefaultBrowserUserChoice(): boolean;
|
||||
checkAllProgIDsExist(): boolean;
|
||||
checkBrowserUserChoiceHashes(): boolean;
|
||||
isDefaultHandlerFor(aFileExtensionOrProtocol: string): boolean;
|
||||
queryCurrentDefaultHandlerFor(aFileExtensionOrProtocol: string): string;
|
||||
}
|
||||
|
||||
interface nsIWindowsShellService extends nsIShellService, Enums<typeof nsIWindowsShellService_LaunchOnLoginEnabledEnumerator> {
|
||||
createShortcut(aBinary: nsIFile, aArguments: string[], aDescription: string, aIconFile: nsIFile, aIconIndex: u16, aAppUserModelId: string, aShortcutFolder: string, aShortcutName: string): Promise<any>;
|
||||
getLaunchOnLoginShortcuts(): string[];
|
||||
pinCurrentAppToStartMenuAsync(aCheckOnly: boolean): Promise<any>;
|
||||
isCurrentAppPinnedToStartMenuAsync(): Promise<any>;
|
||||
enableLaunchOnLoginMSIXAsync(aTaskId: string): Promise<any>;
|
||||
disableLaunchOnLoginMSIXAsync(aTaskId: string): Promise<any>;
|
||||
getLaunchOnLoginEnabledMSIXAsync(aTaskId: string): Promise<any>;
|
||||
pinCurrentAppToTaskbarAsync(aPrivateBrowsing: boolean): Promise<any>;
|
||||
checkPinCurrentAppToTaskbarAsync(aPrivateBrowsing: boolean): Promise<any>;
|
||||
isCurrentAppPinnedToTaskbarAsync(aumid: string): Promise<any>;
|
||||
pinShortcutToTaskbar(aAppUserModelId: string, aShortcutPath: string): Promise<any>;
|
||||
createWindowsIcon(aFile: nsIFile, aContainer: imgIContainer): Promise<any>;
|
||||
unpinShortcutFromTaskbar(aShortcutPath: string): void;
|
||||
getTaskbarTabShortcutPath(aShortcutName: string): string;
|
||||
getTaskbarTabPins(): string[];
|
||||
classifyShortcut(aPath: string): string;
|
||||
hasPinnableShortcut(aAUMID: string, aPrivateBrowsing: boolean): Promise<any>;
|
||||
canSetDefaultBrowserUserChoice(): boolean;
|
||||
checkAllProgIDsExist(): boolean;
|
||||
checkBrowserUserChoiceHashes(): boolean;
|
||||
isDefaultHandlerFor(aFileExtensionOrProtocol: string): boolean;
|
||||
queryCurrentDefaultHandlerFor(aFileExtensionOrProtocol: string): string;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/toolkit/components/taskscheduler/nsIWinTaskSchedulerService.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/toolkit/components/taskscheduler/nsIWinTaskSchedulerService.idl
|
||||
interface nsIWinTaskSchedulerService extends nsISupports {
|
||||
registerTask(aFolderName: string, aTaskName: string, aDefinitionXML: string, aUpdateExisting?: boolean): void;
|
||||
validateTaskDefinition(aDefinitionXML: string): i32;
|
||||
getTaskXML(aFolderName: string, aTaskName: string): string;
|
||||
getCurrentUserSid(): string;
|
||||
deleteTask(aFolderName: string, aTaskName: string): void;
|
||||
getFolderTasks(aFolderName: string): string[];
|
||||
createFolder(aParentFolderName: string, aSubFolderName: string): void;
|
||||
deleteFolder(aParentFolderName: string, aSubFolderName: string): void;
|
||||
}
|
||||
|
||||
interface nsIWinTaskSchedulerService extends nsISupports {
|
||||
registerTask(aFolderName: string, aTaskName: string, aDefinitionXML: string, aUpdateExisting?: boolean): void;
|
||||
validateTaskDefinition(aDefinitionXML: string): i32;
|
||||
getTaskXML(aFolderName: string, aTaskName: string): string;
|
||||
getCurrentUserSid(): string;
|
||||
deleteTask(aFolderName: string, aTaskName: string): void;
|
||||
getFolderTasks(aFolderName: string): string[];
|
||||
createFolder(aParentFolderName: string, aSubFolderName: string): void;
|
||||
deleteFolder(aParentFolderName: string, aSubFolderName: string): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIJumpListBuilder.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIJumpListBuilder.idl
|
||||
interface nsIJumpListBuilder extends nsISupports {
|
||||
obtainAndCacheFavicon(faviconURL: nsIURI): string;
|
||||
obtainAndCacheFaviconAsync(faviconURL: nsIURI): Promise<any>;
|
||||
isAvailable(): Promise<any>;
|
||||
checkForRemovals(): Promise<any>;
|
||||
populateJumpList(aTaskDescriptions: any, aCustomTitle: string, aCustomDescriptions: any): Promise<any>;
|
||||
clearJumpList(): Promise<any>;
|
||||
}
|
||||
|
||||
interface nsIJumpListBuilder extends nsISupports {
|
||||
obtainAndCacheFavicon(faviconURL: nsIURI): string;
|
||||
obtainAndCacheFaviconAsync(faviconURL: nsIURI): Promise<any>;
|
||||
isAvailable(): Promise<any>;
|
||||
checkForRemovals(): Promise<any>;
|
||||
populateJumpList(aTaskDescriptions: any, aCustomTitle: string, aCustomDescriptions: any): Promise<any>;
|
||||
clearJumpList(): Promise<any>;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIPrintSettingsWin.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIPrintSettingsWin.idl
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarOverlayIconController.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarOverlayIconController.idl
|
||||
interface nsITaskbarOverlayIconController extends nsISupports {
|
||||
setOverlayIcon(statusIcon: imgIContainer, statusDescription: string, paintContext?: nsISVGPaintContext): void;
|
||||
}
|
||||
|
||||
interface nsITaskbarOverlayIconController extends nsISupports {
|
||||
setOverlayIcon(statusIcon: imgIContainer, statusDescription: string, paintContext?: nsISVGPaintContext): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarPreview.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarPreview.idl
|
||||
interface nsITaskbarPreview extends nsISupports {
|
||||
controller: nsITaskbarPreviewController;
|
||||
tooltip: string;
|
||||
visible: boolean;
|
||||
active: boolean;
|
||||
invalidate(): void;
|
||||
}
|
||||
|
||||
interface nsITaskbarPreview extends nsISupports {
|
||||
controller: nsITaskbarPreviewController;
|
||||
tooltip: string;
|
||||
visible: boolean;
|
||||
active: boolean;
|
||||
invalidate(): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarPreviewButton.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarPreviewButton.idl
|
||||
interface nsITaskbarPreviewButton extends nsISupports {
|
||||
tooltip: string;
|
||||
dismissOnClick: boolean;
|
||||
hasBorder: boolean;
|
||||
disabled: boolean;
|
||||
image: imgIContainer;
|
||||
visible: boolean;
|
||||
}
|
||||
|
||||
interface nsITaskbarPreviewButton extends nsISupports {
|
||||
tooltip: string;
|
||||
dismissOnClick: boolean;
|
||||
hasBorder: boolean;
|
||||
disabled: boolean;
|
||||
image: imgIContainer;
|
||||
visible: boolean;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarPreviewController.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarPreviewController.idl
|
||||
type nsITaskbarPreviewCallback = Callable<{
|
||||
done(aCanvas: nsISupports, aDrawBorder: boolean): void;
|
||||
}>;
|
||||
|
||||
type nsITaskbarPreviewCallback = Callable<{
|
||||
done(aCanvas: nsISupports, aDrawBorder: boolean): void;
|
||||
}>
|
||||
interface nsITaskbarPreviewController extends nsISupports {
|
||||
readonly width: u32;
|
||||
readonly height: u32;
|
||||
readonly thumbnailAspectRatio: float;
|
||||
requestPreview(aCallback: nsITaskbarPreviewCallback): void;
|
||||
requestThumbnail(aCallback: nsITaskbarPreviewCallback, width: u32, height: u32): void;
|
||||
onClose(): void;
|
||||
onActivate(): boolean;
|
||||
onClick(button: nsITaskbarPreviewButton): void;
|
||||
}
|
||||
|
||||
interface nsITaskbarPreviewController extends nsISupports {
|
||||
readonly width: u32;
|
||||
readonly height: u32;
|
||||
readonly thumbnailAspectRatio: float;
|
||||
requestPreview(aCallback: nsITaskbarPreviewCallback): void;
|
||||
requestThumbnail(aCallback: nsITaskbarPreviewCallback, width: u32, height: u32): void;
|
||||
onClose(): void;
|
||||
onActivate(): boolean;
|
||||
onClick(button: nsITaskbarPreviewButton): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarProgress.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarProgress.idl
|
||||
interface nsITaskbarProgress extends nsISupports {
|
||||
readonly STATE_NO_PROGRESS?: 0;
|
||||
readonly STATE_INDETERMINATE?: 1;
|
||||
readonly STATE_NORMAL?: 2;
|
||||
readonly STATE_ERROR?: 3;
|
||||
readonly STATE_PAUSED?: 4;
|
||||
|
||||
interface nsITaskbarProgress extends nsISupports {
|
||||
readonly STATE_NO_PROGRESS?: 0;
|
||||
readonly STATE_INDETERMINATE?: 1;
|
||||
readonly STATE_NORMAL?: 2;
|
||||
readonly STATE_ERROR?: 3;
|
||||
readonly STATE_PAUSED?: 4;
|
||||
setProgressState(state: nsTaskbarProgressState, currentValue?: u64, maxValue?: u64): void;
|
||||
}
|
||||
|
||||
setProgressState(state: nsTaskbarProgressState, currentValue?: u64, maxValue?: u64): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarTabPreview.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarTabPreview.idl
|
||||
interface nsITaskbarTabPreview extends nsITaskbarPreview {
|
||||
title: string;
|
||||
icon: imgIContainer;
|
||||
move(aNext: nsITaskbarTabPreview): void;
|
||||
}
|
||||
|
||||
interface nsITaskbarTabPreview extends nsITaskbarPreview {
|
||||
title: string;
|
||||
icon: imgIContainer;
|
||||
move(aNext: nsITaskbarTabPreview): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarWindowPreview.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsITaskbarWindowPreview.idl
|
||||
interface nsITaskbarWindowPreview extends nsITaskbarPreview {
|
||||
readonly NUM_TOOLBAR_BUTTONS?: 7;
|
||||
|
||||
interface nsITaskbarWindowPreview extends nsITaskbarPreview {
|
||||
readonly NUM_TOOLBAR_BUTTONS?: 7;
|
||||
getButton(index: u32): nsITaskbarPreviewButton;
|
||||
enableCustomDrawing: boolean;
|
||||
}
|
||||
|
||||
getButton(index: u32): nsITaskbarPreviewButton;
|
||||
enableCustomDrawing: boolean;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIWinTaskbar.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIWinTaskbar.idl
|
||||
interface nsIWinTaskbar extends nsISupports {
|
||||
readonly available: boolean;
|
||||
readonly defaultGroupId: string;
|
||||
readonly defaultPrivateGroupId: string;
|
||||
createTaskbarTabPreview(shell: nsIDocShell, controller: nsITaskbarPreviewController): nsITaskbarTabPreview;
|
||||
getTaskbarWindowPreview(shell: nsIDocShell): nsITaskbarWindowPreview;
|
||||
getTaskbarProgress(shell: nsIDocShell): nsITaskbarProgress;
|
||||
getOverlayIconController(shell: nsIDocShell): nsITaskbarOverlayIconController;
|
||||
createJumpListBuilder(aPrivateBrowsing: boolean): nsIJumpListBuilder;
|
||||
getGroupIdForWindow(aParent: mozIDOMWindow): string;
|
||||
setGroupIdForWindow(aParent: mozIDOMWindow, aIdentifier: string): void;
|
||||
}
|
||||
|
||||
interface nsIWinTaskbar extends nsISupports {
|
||||
readonly available: boolean;
|
||||
readonly defaultGroupId: string;
|
||||
readonly defaultPrivateGroupId: string;
|
||||
createTaskbarTabPreview(shell: nsIDocShell, controller: nsITaskbarPreviewController): nsITaskbarTabPreview;
|
||||
getTaskbarWindowPreview(shell: nsIDocShell): nsITaskbarWindowPreview;
|
||||
getTaskbarProgress(shell: nsIDocShell): nsITaskbarProgress;
|
||||
getOverlayIconController(shell: nsIDocShell): nsITaskbarOverlayIconController;
|
||||
createJumpListBuilder(aPrivateBrowsing: boolean): nsIJumpListBuilder;
|
||||
getGroupIdForWindow(aParent: mozIDOMWindow): string;
|
||||
setGroupIdForWindow(aParent: mozIDOMWindow, aIdentifier: string): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIWindowsUIUtils.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/widget/nsIWindowsUIUtils.idl
|
||||
interface nsIWindowsUIUtils extends nsISupports {
|
||||
readonly systemSmallIconSize: i32;
|
||||
readonly systemLargeIconSize: i32;
|
||||
setWindowIcon(aWindow: mozIDOMWindowProxy, aSmallIcon: imgIContainer, aLargeIcon: imgIContainer): void;
|
||||
setWindowIconFromExe(aWindow: mozIDOMWindowProxy, aExe: string, aIndex: u16): void;
|
||||
setWindowIconNoData(aWindow: mozIDOMWindowProxy): void;
|
||||
readonly inWin10TabletMode: boolean;
|
||||
readonly inWin11TabletMode: boolean;
|
||||
shareUrl(shareTitle: string, urlToShare: string): void;
|
||||
}
|
||||
|
||||
interface nsIWindowsUIUtils extends nsISupports {
|
||||
readonly systemSmallIconSize: i32;
|
||||
readonly systemLargeIconSize: i32;
|
||||
setWindowIcon(aWindow: mozIDOMWindowProxy, aSmallIcon: imgIContainer, aLargeIcon: imgIContainer): void;
|
||||
setWindowIconFromExe(aWindow: mozIDOMWindowProxy, aExe: string, aIndex: u16): void;
|
||||
setWindowIconNoData(aWindow: mozIDOMWindowProxy): void;
|
||||
readonly inWin10TabletMode: boolean;
|
||||
readonly inWin11TabletMode: boolean;
|
||||
shareUrl(shareTitle: string, urlToShare: string): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/toolkit/system/windowsPackageManager/nsIWindowsPackageManager.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/toolkit/system/windowsPackageManager/nsIWindowsPackageManager.idl
|
||||
interface nsIWindowsPackageManager extends nsISupports {
|
||||
findUserInstalledPackages(prefix: string[]): string[];
|
||||
getInstalledDate(): u64;
|
||||
campaignId(): Promise<any>;
|
||||
}
|
||||
|
||||
interface nsIWindowsPackageManager extends nsISupports {
|
||||
findUserInstalledPackages(prefix: string[]): string[];
|
||||
getInstalledDate(): u64;
|
||||
campaignId(): Promise<any>;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/xpcom/ds/nsIWindowsRegKey.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/xpcom/ds/nsIWindowsRegKey.idl
|
||||
interface nsIWindowsRegKey extends nsISupports {
|
||||
readonly ROOT_KEY_CLASSES_ROOT?: 2147483648;
|
||||
readonly ROOT_KEY_CURRENT_USER?: 2147483649;
|
||||
readonly ROOT_KEY_LOCAL_MACHINE?: 2147483650;
|
||||
readonly ACCESS_BASIC?: 131072;
|
||||
readonly ACCESS_QUERY_VALUE?: 1;
|
||||
readonly ACCESS_SET_VALUE?: 2;
|
||||
readonly ACCESS_CREATE_SUB_KEY?: 4;
|
||||
readonly ACCESS_ENUMERATE_SUB_KEYS?: 8;
|
||||
readonly ACCESS_NOTIFY?: 16;
|
||||
readonly ACCESS_READ?: 131097;
|
||||
readonly ACCESS_WRITE?: 131078;
|
||||
readonly ACCESS_ALL?: 131103;
|
||||
readonly WOW64_32?: 512;
|
||||
readonly WOW64_64?: 256;
|
||||
readonly TYPE_NONE?: 0;
|
||||
readonly TYPE_STRING?: 1;
|
||||
readonly TYPE_BINARY?: 3;
|
||||
readonly TYPE_INT?: 4;
|
||||
readonly TYPE_INT64?: 11;
|
||||
|
||||
interface nsIWindowsRegKey extends nsISupports {
|
||||
readonly ROOT_KEY_CLASSES_ROOT?: 2147483648;
|
||||
readonly ROOT_KEY_CURRENT_USER?: 2147483649;
|
||||
readonly ROOT_KEY_LOCAL_MACHINE?: 2147483650;
|
||||
readonly ACCESS_BASIC?: 131072;
|
||||
readonly ACCESS_QUERY_VALUE?: 1;
|
||||
readonly ACCESS_SET_VALUE?: 2;
|
||||
readonly ACCESS_CREATE_SUB_KEY?: 4;
|
||||
readonly ACCESS_ENUMERATE_SUB_KEYS?: 8;
|
||||
readonly ACCESS_NOTIFY?: 16;
|
||||
readonly ACCESS_READ?: 131097;
|
||||
readonly ACCESS_WRITE?: 131078;
|
||||
readonly ACCESS_ALL?: 131103;
|
||||
readonly WOW64_32?: 512;
|
||||
readonly WOW64_64?: 256;
|
||||
readonly TYPE_NONE?: 0;
|
||||
readonly TYPE_STRING?: 1;
|
||||
readonly TYPE_BINARY?: 3;
|
||||
readonly TYPE_INT?: 4;
|
||||
readonly TYPE_INT64?: 11;
|
||||
close(): void;
|
||||
open(rootKey: u32, relPath: string, mode: u32): void;
|
||||
create(rootKey: u32, relPath: string, mode: u32): void;
|
||||
openChild(relPath: string, mode: u32): nsIWindowsRegKey;
|
||||
createChild(relPath: string, mode: u32): nsIWindowsRegKey;
|
||||
readonly childCount: u32;
|
||||
getChildName(index: u32): string;
|
||||
hasChild(name: string): boolean;
|
||||
readonly valueCount: u32;
|
||||
getValueName(index: u32): string;
|
||||
hasValue(name: string): boolean;
|
||||
removeChild(relPath: string): void;
|
||||
removeValue(name: string): void;
|
||||
getValueType(name: string): u32;
|
||||
readStringValue(name: string): string;
|
||||
readIntValue(name: string): u32;
|
||||
readInt64Value(name: string): u64;
|
||||
readBinaryValue(name: string): string;
|
||||
writeStringValue(name: string, data: string): void;
|
||||
writeIntValue(name: string, data: u32): void;
|
||||
writeInt64Value(name: string, data: u64): void;
|
||||
writeBinaryValue(name: string, data: string): void;
|
||||
}
|
||||
|
||||
close(): void;
|
||||
open(rootKey: u32, relPath: string, mode: u32): void;
|
||||
create(rootKey: u32, relPath: string, mode: u32): void;
|
||||
openChild(relPath: string, mode: u32): nsIWindowsRegKey;
|
||||
createChild(relPath: string, mode: u32): nsIWindowsRegKey;
|
||||
readonly childCount: u32;
|
||||
getChildName(index: u32): string;
|
||||
hasChild(name: string): boolean;
|
||||
readonly valueCount: u32;
|
||||
getValueName(index: u32): string;
|
||||
hasValue(name: string): boolean;
|
||||
removeChild(relPath: string): void;
|
||||
removeValue(name: string): void;
|
||||
getValueType(name: string): u32;
|
||||
readStringValue(name: string): string;
|
||||
readIntValue(name: string): u32;
|
||||
readInt64Value(name: string): u64;
|
||||
readBinaryValue(name: string): string;
|
||||
writeStringValue(name: string, data: string): void;
|
||||
writeIntValue(name: string, data: u32): void;
|
||||
writeInt64Value(name: string, data: u64): void;
|
||||
writeBinaryValue(name: string, data: string): void;
|
||||
}
|
||||
// https://searchfox.org/mozilla-central/source/toolkit/xre/nsIWinAppHelper.idl
|
||||
|
||||
// https://searchfox.org/mozilla-central/source/toolkit/xre/nsIWinAppHelper.idl
|
||||
interface nsIWinAppHelper extends nsISupports {
|
||||
readonly userCanElevate: boolean;
|
||||
}
|
||||
|
||||
interface nsIWinAppHelper extends nsISupports {
|
||||
readonly userCanElevate: boolean;
|
||||
}
|
||||
|
||||
interface nsIXPCComponents_Interfaces {
|
||||
nsIInstalledApplication: nsJSIID<nsIInstalledApplication>;
|
||||
nsIAboutThirdParty: nsJSIID<nsIAboutThirdParty>;
|
||||
nsIAboutWindowsMessages: nsJSIID<nsIAboutWindowsMessages>;
|
||||
nsIWindowsAlertNotification: nsJSIID<nsIWindowsAlertNotification, typeof nsIWindowsAlertNotification_ImagePlacement>;
|
||||
nsIWindowsAlertsService: nsJSIID<nsIWindowsAlertsService>;
|
||||
nsIDefaultAgent: nsJSIID<nsIDefaultAgent>;
|
||||
nsIWindowsMutex: nsJSIID<nsIWindowsMutex>;
|
||||
nsIWindowsMutexFactory: nsJSIID<nsIWindowsMutexFactory>;
|
||||
nsIGeolocationUIUtilsWin: nsJSIID<nsIGeolocationUIUtilsWin>;
|
||||
nsIWindowsShellService: nsJSIID<nsIWindowsShellService, typeof nsIWindowsShellService_LaunchOnLoginEnabledEnumerator>;
|
||||
nsIWinTaskSchedulerService: nsJSIID<nsIWinTaskSchedulerService>;
|
||||
nsIJumpListBuilder: nsJSIID<nsIJumpListBuilder>;
|
||||
nsITaskbarOverlayIconController: nsJSIID<nsITaskbarOverlayIconController>;
|
||||
nsITaskbarPreview: nsJSIID<nsITaskbarPreview>;
|
||||
nsITaskbarPreviewButton: nsJSIID<nsITaskbarPreviewButton>;
|
||||
nsITaskbarPreviewCallback: nsJSIID<nsITaskbarPreviewCallback>;
|
||||
nsITaskbarPreviewController: nsJSIID<nsITaskbarPreviewController>;
|
||||
nsITaskbarProgress: nsJSIID<nsITaskbarProgress>;
|
||||
nsITaskbarTabPreview: nsJSIID<nsITaskbarTabPreview>;
|
||||
nsITaskbarWindowPreview: nsJSIID<nsITaskbarWindowPreview>;
|
||||
nsIWinTaskbar: nsJSIID<nsIWinTaskbar>;
|
||||
nsIWindowsUIUtils: nsJSIID<nsIWindowsUIUtils>;
|
||||
nsIWindowsPackageManager: nsJSIID<nsIWindowsPackageManager>;
|
||||
nsIWindowsRegKey: nsJSIID<nsIWindowsRegKey>;
|
||||
nsIWinAppHelper: nsJSIID<nsIWinAppHelper>;
|
||||
}
|
||||
|
||||
} // global
|
||||
interface nsIXPCComponents_Interfaces {
|
||||
nsIInstalledApplication: nsJSIID<nsIInstalledApplication>;
|
||||
nsIAboutThirdParty: nsJSIID<nsIAboutThirdParty>;
|
||||
nsIAboutWindowsMessages: nsJSIID<nsIAboutWindowsMessages>;
|
||||
nsIWindowsAlertNotification: nsJSIID<nsIWindowsAlertNotification, typeof nsIWindowsAlertNotification_ImagePlacement>;
|
||||
nsIWindowsAlertsService: nsJSIID<nsIWindowsAlertsService>;
|
||||
nsIDefaultAgent: nsJSIID<nsIDefaultAgent>;
|
||||
nsIWindowsMutex: nsJSIID<nsIWindowsMutex>;
|
||||
nsIWindowsMutexFactory: nsJSIID<nsIWindowsMutexFactory>;
|
||||
nsIGeolocationUIUtilsWin: nsJSIID<nsIGeolocationUIUtilsWin>;
|
||||
nsIWindowsShellService: nsJSIID<nsIWindowsShellService, typeof nsIWindowsShellService_LaunchOnLoginEnabledEnumerator>;
|
||||
nsIWinTaskSchedulerService: nsJSIID<nsIWinTaskSchedulerService>;
|
||||
nsIJumpListBuilder: nsJSIID<nsIJumpListBuilder>;
|
||||
nsITaskbarOverlayIconController: nsJSIID<nsITaskbarOverlayIconController>;
|
||||
nsITaskbarPreview: nsJSIID<nsITaskbarPreview>;
|
||||
nsITaskbarPreviewButton: nsJSIID<nsITaskbarPreviewButton>;
|
||||
nsITaskbarPreviewCallback: nsJSIID<nsITaskbarPreviewCallback>;
|
||||
nsITaskbarPreviewController: nsJSIID<nsITaskbarPreviewController>;
|
||||
nsITaskbarProgress: nsJSIID<nsITaskbarProgress>;
|
||||
nsITaskbarTabPreview: nsJSIID<nsITaskbarTabPreview>;
|
||||
nsITaskbarWindowPreview: nsJSIID<nsITaskbarWindowPreview>;
|
||||
nsIWinTaskbar: nsJSIID<nsIWinTaskbar>;
|
||||
nsIWindowsUIUtils: nsJSIID<nsIWindowsUIUtils>;
|
||||
nsIWindowsPackageManager: nsJSIID<nsIWindowsPackageManager>;
|
||||
nsIWindowsRegKey: nsJSIID<nsIWindowsRegKey>;
|
||||
nsIWinAppHelper: nsJSIID<nsIWinAppHelper>;
|
||||
}
|
||||
} // global
|
||||
|
||||
// Typedefs from xpidl.
|
||||
type PRTime = i64;
|
||||
|
@ -375,6 +387,6 @@ type OutParam<T> = { value?: T };
|
|||
type Enums<enums> = Partial<Pick<enums, keyof enums>>;
|
||||
|
||||
/** Callable accepts either form of a [function] interface. */
|
||||
type Callable<iface> = iface | Extract<iface[keyof iface], Function>
|
||||
type Callable<iface> = iface | Extract<iface[keyof iface], Function>;
|
||||
|
||||
export {};
|
||||
|
|
30992
src/zen/@types/lib.gecko.xpcom.d.ts
vendored
30992
src/zen/@types/lib.gecko.xpcom.d.ts
vendored
File diff suppressed because it is too large
Load diff
10
src/zen/@types/lib.gecko.xpidl.d.ts
vendored
10
src/zen/@types/lib.gecko.xpidl.d.ts
vendored
|
@ -15,10 +15,12 @@ interface nsID<uuid = string> {
|
|||
* and expose constants defined on the class, including variants from enums.
|
||||
* https://searchfox.org/mozilla-central/source/js/xpconnect/src/XPCJSID.cpp#45
|
||||
*/
|
||||
type nsJSIID<iface, enums = {}> = nsID & Constants<iface> & enums & {
|
||||
new (_: never): void;
|
||||
prototype: iface;
|
||||
}
|
||||
type nsJSIID<iface, enums = {}> = nsID &
|
||||
Constants<iface> &
|
||||
enums & {
|
||||
new (_: never): void;
|
||||
prototype: iface;
|
||||
};
|
||||
|
||||
/** A union type of all known interface IIDs. */
|
||||
type nsIID = nsIXPCComponents_Interfaces[keyof nsIXPCComponents_Interfaces];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue