/** @packageDocumentation
 * @module Frontstage
 */
import { IModelConnection, Tool } from "@itwin/core-frontend";
import { WidgetState } from "@itwin/appui-abstract";
import { Size, UiEvent } from "@itwin/core-react";
import { NineZoneManager } from "@itwin/appui-layout-react";
import { ContentControlActivatedEvent } from "../content/ContentControl";
import { ContentGroup } from "../content/ContentGroup";
import { ContentLayoutActivatedEvent, ContentLayoutDef } from "../content/ContentLayout";
import { NavigationAidActivatedEvent } from "../navigationaids/NavigationAidControl";
import { PanelSizeChangedEvent, PanelStateChangedEvent } from "../stagepanels/StagePanelDef";
import { WidgetChangedEventArgs, WidgetDef, WidgetEventArgs, WidgetStateChangedEvent } from "../widgets/WidgetDef";
import { ToolInformation } from "../zones/toolsettings/ToolInformation";
import { ToolUiProvider } from "../zones/toolsettings/ToolUiProvider";
import { FrontstageDef, FrontstageEventArgs, FrontstageNineZoneStateChangedEventArgs } from "./FrontstageDef";
import { FrontstageProvider } from "./FrontstageProvider";
import { FrontstageActivatedEvent, FrontstageDeactivatedEvent, FrontstageReadyEvent, ModalFrontstageChangedEvent, ModalFrontstageClosedEvent, ModalFrontstageInfo, ModalFrontstageRequestedCloseEvent, ToolActivatedEvent, ToolIconChangedEvent } from "../framework/FrameworkFrontstages";
/** Frontstage Manager class.
 * @internal
 */
export declare class InternalFrontstageManager {
    private static _initialized;
    private static _isLoading;
    private static _activeToolId;
    private static _activeFrontstageDef;
    private static _frontstageDefs;
    private static _modalFrontstages;
    private static _nineZoneManagers;
    private static _frontstageProviders;
    private static _nineZoneSize;
    private static _nestedFrontstages;
    private static _activePrimaryFrontstageDef;
    private static _toolInformationMap;
    /** This should only be called within InternalFrontstageManager and its tests.
     *  @internal
     */
    static ensureToolInformationIsSet(toolId: string): void;
    private static handleSyncToolSettingsPropertiesEvent;
    private static handleReloadToolSettingsEvent;
    /** Initializes the InternalFrontstageManager
     * @internal
    */
    static initialize(): void;
    /** Handles a Viewport change & sets the active view accordingly */
    private static _handleSelectedViewportChanged;
    /** @internal */
    static get isInitialized(): boolean;
    static set isInitialized(v: boolean);
    /** Returns true if Frontstage is loading its controls. If false the Frontstage content and controls have been created. */
    static get isLoading(): boolean;
    /** @internal */
    static get nineZoneSize(): Size | undefined;
    static set nineZoneSize(size: Size | undefined);
    /** @internal */
    static get frontstageDefs(): ReadonlyMap<string, FrontstageDef>;
    /** Get Frontstage Deactivated event. */
    static readonly onFrontstageDeactivatedEvent: FrontstageDeactivatedEvent;
    /** Get Frontstage Activated event. */
    static readonly onFrontstageActivatedEvent: FrontstageActivatedEvent;
    /** Get Frontstage Activated event. */
    static readonly onFrontstageReadyEvent: FrontstageReadyEvent;
    /** Get Modal Frontstage Changed event. */
    static readonly onModalFrontstageChangedEvent: ModalFrontstageChangedEvent;
    /** Get Modal Frontstage Closed event. */
    static readonly onModalFrontstageClosedEvent: ModalFrontstageClosedEvent;
    /** Get Modal Frontstage Requested Closed event.
     * @alpha
     */
    static readonly onCloseModalFrontstageRequestedEvent: ModalFrontstageRequestedCloseEvent;
    /** Get Tool Activated event. */
    static readonly onToolActivatedEvent: ToolActivatedEvent;
    /** Get ToolSetting Reload event. */
    static readonly onToolSettingsReloadEvent: UiEvent<void>;
    /** Get Tool Panel Opened event.
     * @internal
     */
    static readonly onToolPanelOpenedEvent: UiEvent<void>;
    /** Get Tool Icon Changed event. */
    static readonly onToolIconChangedEvent: ToolIconChangedEvent;
    /** Get Content Layout Activated event. */
    static readonly onContentLayoutActivatedEvent: ContentLayoutActivatedEvent;
    /** Get Content Control Activated event. */
    static readonly onContentControlActivatedEvent: ContentControlActivatedEvent;
    /** Get Navigation Aid Activated event. */
    static readonly onNavigationAidActivatedEvent: NavigationAidActivatedEvent;
    /** Get Widget State Changed event. */
    static readonly onWidgetStateChangedEvent: WidgetStateChangedEvent;
    /** @internal */
    static readonly onWidgetLabelChangedEvent: UiEvent<WidgetChangedEventArgs>;
    /** @internal */
    static readonly onWidgetShowEvent: UiEvent<WidgetEventArgs>;
    /** @internal */
    static readonly onWidgetExpandEvent: UiEvent<WidgetEventArgs>;
    /** @internal */
    static readonly onWidgetDefsUpdatedEvent: UiEvent<void>;
    /** @internal */
    static readonly onFrontstageNineZoneStateChangedEvent: UiEvent<FrontstageNineZoneStateChangedEventArgs>;
    /** @internal */
    static readonly onFrontstageRestoreLayoutEvent: UiEvent<FrontstageEventArgs>;
    /** Get Widget State Changed event.
     * @alpha
     */
    static readonly onPanelStateChangedEvent: PanelStateChangedEvent;
    /** @internal */
    static readonly onPanelSizeChangedEvent: PanelSizeChangedEvent;
    /** Get Nine-zone State Manager.
     * @deprecated in 3.7 Used in UI1.0 only.
     */
    static get NineZoneManager(): NineZoneManager;
    /** Clears the Frontstage map.
     */
    static clearFrontstageDefs(): void;
    /** Clears the Frontstage Providers and the defs that may have been created from them.
     */
    static clearFrontstageProviders(): void;
    private static getFrontstageKey;
    /** @internal */
    static clearFrontstageDefsForIModelId(iModelId: string | undefined): void;
    /** Add a Frontstage via a [[FrontstageProvider]].
     * @param frontstageProvider  FrontstageProvider representing the Frontstage to add
     */
    static addFrontstageProvider(frontstageProvider: FrontstageProvider): void;
    /** Find a loaded Frontstage with a given id. If the id is not provided, the active Frontstage is returned.
     * If the FrontstageDef has not been cached by FrontstageDef then it will not be found. See async function
     * `getFrontstageDef` to get a FrontstageDef.
     * @param id  Id of the Frontstage to find
     * @returns  FrontstageDef with a given id if found, or undefined if not found.
     */
    private static findFrontstageDef;
    private static findFrontstageProvider;
    /** Find a loaded Frontstage with a given id. If the id is not provided, the active Frontstage is returned. If
     * no cached FrontstageDef is found but a FrontstageProvider is registered a FrontstageDef will be created, cached, and
     * returned.
     * @param id  Id of the Frontstage to find
     * @returns  FrontstageDef with a given id if found, or undefined if not found.
     */
    static getFrontstageDef(id?: string): Promise<FrontstageDef | undefined>;
    /** Gets the active FrontstageDef. If a Frontstage is not active, undefined is returned.
     * @return  Active FrontstageDef, or undefined if one is not active.
     */
    static get activeFrontstageDef(): FrontstageDef | undefined;
    /** Gets the Id of the active FrontstageDef. If a Frontstage is not active, blank is returned.
     * @return  Id of the active FrontstageDef, or blank if one is not active.
     */
    static get activeFrontstageId(): string;
    static hasFrontstage(frontstageId: string): boolean;
    /** Sets the active FrontstageDef give the stageId.
     * @param  frontstageId  Id of the Frontstage to set active.
     * @returns A Promise that is fulfilled when the [[Frontstage]] is ready.
     */
    static setActiveFrontstage(frontstageId: string): Promise<void>;
    /** Sets the active FrontstageDef.
     * @param  frontstageDef  FrontstageDef to set active.
     * @returns A Promise that is fulfilled when the [[FrontstageDef]] is ready.
     */
    static setActiveFrontstageDef(frontstageDef: FrontstageDef | undefined): Promise<void>;
    /** Deactivates the active FrontstageDef.
     */
    static deactivateFrontstageDef(): Promise<void>;
    /** Gets the Id of the active tool. If a tool is not active, blank is returned.
     * @return  Id of the active tool, or blank if one is not active.
     */
    static get activeToolId(): string;
    /** Sets the active tool id */
    static setActiveToolId(toolId: string): void;
    /** Sets the active tool */
    static setActiveTool(tool: Tool): void;
    /** Gets the active tool's [[ToolInformation]] */
    static get activeToolInformation(): ToolInformation | undefined;
    /** Gets the Tool Setting React node of the active tool.
     * @return  Tool Setting React node of the active tool, or undefined if there is no active tool or Tool Settings for the active tool.
     * @internal
     */
    static get activeToolSettingsProvider(): ToolUiProvider | undefined;
    /** Sets the active layout, content group and active content.
     * @param contentLayoutDef  Content layout to make active
     * @param contentGroup  Content Group to make active
     */
    static setActiveLayout(contentLayoutDef: ContentLayoutDef, contentGroup: ContentGroup): Promise<void>;
    /** Sets the active layout, content group and active content.
     * @param contentGroup  Content Group to make active
     */
    static setActiveContentGroup(contentGroup: ContentGroup): Promise<void>;
    /** Opens a modal Frontstage. Modal Frontstages can be stacked.
     * @param modalFrontstage  Information about the modal Frontstage
     */
    static openModalFrontstage(modalFrontstage: ModalFrontstageInfo): void;
    private static pushModalFrontstage;
    /** Closes the top-most modal Frontstage.
     */
    static closeModalFrontstage(): void;
    private static popModalFrontstage;
    private static emitModalFrontstageChangedEvent;
    /** Updates the top-most modal Frontstage.
     */
    static updateModalFrontstage(): void;
    /** Gets the top-most modal Frontstage.
     * @returns Top-most modal Frontstage, or undefined if there is none.
     */
    static get activeModalFrontstage(): ModalFrontstageInfo | undefined;
    /** Gets the number of modal Frontstages.
     * @returns Modal Frontstage count
     */
    static get modalFrontstageCount(): number;
    /** Sets the active Navigation Aid via its Id.
     * @param navigationAidId  Id of the Navigation Aid to set as active
     * @param iModelConnection IModelConnection to query for view data
     */
    static setActiveNavigationAid(navigationAidId: string, iModelConnection: IModelConnection): void;
    /** Sets the state of the widget with the given id
     * @param widgetId  Id of the Widget for which to set the state
     * @param state     New state of the widget
     * @returns true if the widget state was set successfully, or false if not.
     */
    static setWidgetState(widgetId: string, state: WidgetState): boolean;
    /** Finds a widget with the given id in the active frontstage
     * @param widgetId  Id of the Widget to find
     * @returns The WidgetDef with the given id, or undefined if not found.
     */
    static findWidget(widgetId: string): WidgetDef | undefined;
    /** Opens a nested Frontstage. Nested Frontstages can be stacked.
     * @param nestedFrontstage  Information about the nested Frontstage
     */
    static openNestedFrontstage(nestedFrontstage: FrontstageDef): Promise<void>;
    private static pushNestedFrontstage;
    /** Closes the top-most nested Frontstage.
     */
    static closeNestedFrontstage(): Promise<void>;
    private static popNestedFrontstage;
    /** Gets the top-most nested Frontstage.
     * @returns Top-most nested Frontstage, or undefined if there is none.
     */
    static get activeNestedFrontstage(): FrontstageDef | undefined;
    /** Gets the number of nested Frontstages.
     * @returns Nested Frontstage count
     */
    static get nestedFrontstageCount(): number;
}
//# sourceMappingURL=InternalFrontstageManager.d.ts.map