diff options
| author | AAGaming <aagaming@riseup.net> | 2023-12-12 22:21:25 -0500 |
|---|---|---|
| committer | AAGaming <aagaming@riseup.net> | 2023-12-29 18:40:52 -0500 |
| commit | 5fd5b2f08cd39a26eecab8901c1d39020c056ac1 (patch) | |
| tree | c63c493cf26d3143d89e0b8645327149e201bd4d /frontend/src/tabs-hook.old.tsx | |
| parent | 87d7e15951232ace425e5107df2300ba8baf749a (diff) | |
| download | decky-loader-5fd5b2f08cd39a26eecab8901c1d39020c056ac1.tar.gz decky-loader-5fd5b2f08cd39a26eecab8901c1d39020c056ac1.zip | |
fix: Adjust tabs and toaster hooks to work on react 18, also half-fix Valve Internal
Diffstat (limited to 'frontend/src/tabs-hook.old.tsx')
| -rw-r--r-- | frontend/src/tabs-hook.old.tsx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/frontend/src/tabs-hook.old.tsx b/frontend/src/tabs-hook.old.tsx index 5b511596..982f6f09 100644 --- a/frontend/src/tabs-hook.old.tsx +++ b/frontend/src/tabs-hook.old.tsx @@ -1,5 +1,5 @@ // TabsHook for versions before the Desktop merge -import { Patch, afterPatch, sleep } from 'decky-frontend-lib'; +import { Patch, afterPatch, getReactRoot, sleep } from 'decky-frontend-lib'; import { memo } from 'react'; import NewTabsHook from './tabs-hook'; @@ -35,7 +35,7 @@ class TabsHook extends NewTabsHook { init() { const self = this; - const tree = (document.getElementById('root') as any)._reactRootContainer._internalRoot.current; + const tree = getReactRoot(document.getElementById('root') as any); let scrollRoot: any; async function findScrollRoot(currentNode: any, iters: number): Promise<any> { if (iters >= 30) { |
