mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-28 19:49:20 +03:00
dispatchEvent(new CustomEvent(...)) to fireEvent(...)
This commit is contained in:
parent
2d46eaa783
commit
44ee236709
9 changed files with 25 additions and 21 deletions
|
|
@ -13,7 +13,7 @@ import {
|
|||
|
||||
import { UNUSED_OPTION_VALUE } from 'Common/Consts';
|
||||
|
||||
import { doc, leftPanelDisabled, moveAction, Settings, SettingsCapa, SettingsGet } from 'Common/Globals';
|
||||
import { doc, leftPanelDisabled, moveAction, Settings, SettingsCapa, SettingsGet, fireEvent } from 'Common/Globals';
|
||||
|
||||
import { computedPaginatorHelper, showMessageComposer, folderListOptionsBuilder } from 'Common/UtilsUser';
|
||||
import { FileInfo } from 'Common/File';
|
||||
|
|
@ -683,7 +683,7 @@ export class MailMessageList extends AbstractViewRight {
|
|||
|
||||
shortcuts.add('enter,open', '', Scope.MessageList, () => {
|
||||
if (MessageUserStore.message() && this.useAutoSelect()) {
|
||||
dispatchEvent(new CustomEvent('mailbox.message-view.toggle-full-screen'));
|
||||
fireEvent('mailbox.message-view.toggle-full-screen');
|
||||
return false;
|
||||
}
|
||||
});
|
||||
|
|
|
|||
|
|
@ -23,7 +23,8 @@ import {
|
|||
Settings,
|
||||
SettingsCapa,
|
||||
getFullscreenElement,
|
||||
exitFullscreen
|
||||
exitFullscreen,
|
||||
fireEvent
|
||||
} from 'Common/Globals';
|
||||
|
||||
import { arrayLength, inFocus } from 'Common/Utils';
|
||||
|
|
@ -245,15 +246,15 @@ export class MailMessageView extends AbstractViewRight {
|
|||
}
|
||||
|
||||
goUpCommand() {
|
||||
dispatchEvent(new CustomEvent('mailbox.message-list.selector.go-up',
|
||||
{detail:SettingsUserStore.usePreviewPane() || !!currentMessage()} // bForceSelect
|
||||
));
|
||||
fireEvent('mailbox.message-list.selector.go-up',
|
||||
SettingsUserStore.usePreviewPane() || !!currentMessage() // bForceSelect
|
||||
);
|
||||
}
|
||||
|
||||
goDownCommand() {
|
||||
dispatchEvent(new CustomEvent('mailbox.message-list.selector.go-down',
|
||||
{detail:SettingsUserStore.usePreviewPane() || !!currentMessage()} // bForceSelect
|
||||
));
|
||||
fireEvent('mailbox.message-list.selector.go-down',
|
||||
SettingsUserStore.usePreviewPane() || !!currentMessage() // bForceSelect
|
||||
);
|
||||
}
|
||||
|
||||
toggleFullScreen() {
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ import { KeyboardShortcutsHelpPopupView } from 'View/Popup/KeyboardShortcutsHelp
|
|||
import { AccountPopupView } from 'View/Popup/Account';
|
||||
import { ContactsPopupView } from 'View/Popup/Contacts';
|
||||
|
||||
import { doc, Settings/*, SettingsGet*/, leftPanelDisabled } from 'Common/Globals';
|
||||
import { doc, Settings/*, SettingsGet*/, leftPanelDisabled, fireEvent } from 'Common/Globals';
|
||||
|
||||
import { ThemeStore } from 'Stores/Theme';
|
||||
|
||||
|
|
@ -49,7 +49,7 @@ export class SystemDropDownUserView extends AbstractViewRight {
|
|||
}
|
||||
|
||||
stopPlay() {
|
||||
dispatchEvent(new CustomEvent('audio.api.stop'));
|
||||
fireEvent('audio.api.stop');
|
||||
}
|
||||
|
||||
accountClick(account, event) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue