Merge pull request #239 from wavetermdev:evan/tab-drag-fix

Fix tab drag events not registering state update
This commit is contained in:
Evan Simkowitz 2024-01-18 14:40:38 -05:00 committed by GitHub
commit 613cd30c36
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 1 additions and 12 deletions

View File

@ -22,7 +22,7 @@ let MagicLayout = {
TermDescendersHeight: 3, TermDescendersHeight: 3,
TermWidthBuffer: 15, TermWidthBuffer: 15,
TabWidth: 175, TabWidth: 154,
ScreenSidebarWidthPadding: 5, ScreenSidebarWidthPadding: 5,
ScreenSidebarMinWidth: 200, ScreenSidebarMinWidth: 200,

View File

@ -21,7 +21,6 @@ class ScreenTabs extends React.Component<
{ showingScreens: Screen[]; scrollIntoViewTimeout: number } { showingScreens: Screen[]; scrollIntoViewTimeout: number }
> { > {
tabsRef: React.RefObject<any> = React.createRef(); tabsRef: React.RefObject<any> = React.createRef();
tabRefs: { [screenId: string]: React.RefObject<any> } = {};
lastActiveScreenId: string = null; lastActiveScreenId: string = null;
dragEndTimeout = null; dragEndTimeout = null;
scrollIntoViewTimeoutId = null; scrollIntoViewTimeoutId = null;
@ -169,16 +168,6 @@ class ScreenTabs extends React.Component<
// For touchpad events, do nothing and let the browser handle it // For touchpad events, do nothing and let the browser handle it
} }
@boundMethod
openScreenSettings(e: any, screen: Screen): void {
e.preventDefault();
e.stopPropagation();
mobx.action(() => {
GlobalModel.screenSettingsModal.set({ sessionId: screen.sessionId, screenId: screen.screenId });
})();
GlobalModel.modalsModel.pushModal(constants.SCREEN_SETTINGS);
}
render() { render() {
let { showingScreens } = this.state; let { showingScreens } = this.state;
let { session } = this.props; let { session } = this.props;