Move the EventBus, and related functionality, into its own file

The size of the `web/ui_utils.js` file has increased over time, as more code has been added to (or moved into) that file. To reduce its size slightly, this patch moves the event-related functionality into a separate file.
This commit is contained in:
Jonas Jenwald 2021-12-15 17:09:16 +01:00
parent a425c9cfa5
commit 0a19ef6864
10 changed files with 489 additions and 456 deletions

View file

@ -18,10 +18,8 @@ import {
animationStarted,
apiPageLayoutToViewerModes,
apiPageModeToSidebarView,
AutomationEventBus,
AutoPrintRegExp,
DEFAULT_SCALE_VALUE,
EventBus,
getActiveOrFocusedElement,
isValidRotation,
isValidScrollMode,
@ -37,6 +35,7 @@ import {
TextLayerMode,
} from "./ui_utils.js";
import { AppOptions, compatibilityParams, OptionKind } from "./app_options.js";
import { AutomationEventBus, EventBus } from "./event_utils.js";
import {
build,
createPromiseCapability,