From 7ea13a35ff06c7dfaa200e41158936e28ba68157 Mon Sep 17 00:00:00 2001 From: Akinwale Ariwodola Date: Sun, 26 Aug 2018 08:50:32 +0100 Subject: [PATCH 1/3] show animated activity indicator after the user presses the Play button --- app/src/component/button/view.js | 5 +- app/src/component/fileDownloadButton/view.js | 7 ++- app/src/page/file/view.js | 66 +++++++++++--------- buildozer.spec.sample | 2 +- buildozer.spec.travis | 2 +- buildozer.spec.vagrant | 2 +- 6 files changed, 48 insertions(+), 36 deletions(-) diff --git a/app/src/component/button/view.js b/app/src/component/button/view.js index d0bdde34..ec3745eb 100644 --- a/app/src/component/button/view.js +++ b/app/src/component/button/view.js @@ -12,7 +12,8 @@ export default class Button extends React.PureComponent { text, icon, theme, - onPress + onPress, + onLayout } = this.props; let styles = [buttonStyle.button, buttonStyle.row]; @@ -41,7 +42,7 @@ export default class Button extends React.PureComponent { } return ( - + {icon && } {text && (text.trim().length > 0) && {text}} diff --git a/app/src/component/fileDownloadButton/view.js b/app/src/component/fileDownloadButton/view.js index fe05f737..2f9fbe87 100644 --- a/app/src/component/fileDownloadButton/view.js +++ b/app/src/component/fileDownloadButton/view.js @@ -42,7 +42,8 @@ class FileDownloadButton extends React.PureComponent { loading, doPause, style, - openFile + openFile, + onButtonLayout } = this.props; if (loading || downloading) { @@ -67,6 +68,7 @@ class FileDownloadButton extends React.PureComponent { return (