Skip to content

Commit

Permalink
Merge pull request #17344 from KDSBrowne/bbb-17331
Browse files Browse the repository at this point in the history
fix: Move Setting isForcePanning To Patch Event
  • Loading branch information
antobinary committed Apr 5, 2023
2 parents cc820ad + 8af5121 commit 173ca01
Showing 1 changed file with 4 additions and 4 deletions.
Expand Up @@ -832,6 +832,10 @@ export default function Whiteboard(props) {
},
},
);

if ((panSelected || isPanning)) {
e.isForcePanning = isPanning;
}
};

const onUndo = (app) => {
Expand Down Expand Up @@ -968,10 +972,6 @@ export default function Whiteboard(props) {
const size = ((height < SMALL_HEIGHT) || (width < SMALL_WIDTH))
? TOOLBAR_SMALL : TOOLBAR_LARGE;

if ((panSelected || isPanning) && tldrawAPI) {
tldrawAPI.isForcePanning = isPanning;
}

if (hasWBAccess || isPresenter) {
if (((height < SMALLEST_HEIGHT) || (width < SMALLEST_WIDTH))) {
tldrawAPI?.setSetting('dockPosition', 'bottom');
Expand Down

0 comments on commit 173ca01

Please sign in to comment.