diff --git a/src/components/structures/AutoHideScrollbar.js b/src/components/structures/AutoHideScrollbar.js
index a385df0401..0f93f20407 100644
--- a/src/components/structures/AutoHideScrollbar.js
+++ b/src/components/structures/AutoHideScrollbar.js
@@ -114,10 +114,15 @@ export default class AutoHideScrollbar extends React.Component {
}
}
+ getScrollTop() {
+ return this.containerRef.scrollTop;
+ }
+
render() {
return (
{ this.props.children }
diff --git a/src/components/structures/IndicatorScrollbar.js b/src/components/structures/IndicatorScrollbar.js
index c3e54ee900..e1516d1f64 100644
--- a/src/components/structures/IndicatorScrollbar.js
+++ b/src/components/structures/IndicatorScrollbar.js
@@ -59,6 +59,10 @@ export default class IndicatorScrollbar extends React.Component {
}
}
+ getScrollTop() {
+ return this._autoHideScrollbar.getScrollTop();
+ }
+
componentWillUnmount() {
if (this._scrollElement) {
this._scrollElement.removeEventListener("scroll", this.checkOverflow);