ubuntu-touch-coreapps-reviewers team mailing list archive
-
ubuntu-touch-coreapps-reviewers team
-
Mailing list archive
-
Message #09740
[Merge] lp:~fboucault/music-app/startup_time into lp:music-app
Florian Boucault has proposed merging lp:~fboucault/music-app/startup_time into lp:music-app.
Commit message:
Improve startup time (by around 900ms on BQ E4.5):
- load Icons asynchronously.
- load Images asynchronously.
- load Tabs on demand and asynchronously.
Requested reviews:
Music App Developers (music-app-dev)
For more details, see:
https://code.launchpad.net/~fboucault/music-app/startup_time/+merge/301057
Improve startup time (by around 900ms on BQ E4.5):
- load Icons asynchronously.
- load Images asynchronously.
- load Tabs on demand and asynchronously.
--
Your team Music App Developers is requested to review the proposed merge of lp:~fboucault/music-app/startup_time into lp:music-app.
=== modified file 'app/components/ListItemReorderComponent.qml'
--- app/components/ListItemReorderComponent.qml 2015-08-12 23:36:44 +0000
+++ app/components/ListItemReorderComponent.qml 2016-07-25 12:37:55 +0000
@@ -33,6 +33,7 @@
name: "navigation-menu" // TODO: use proper image
height: width
width: units.gu(3)
+ asynchronous: true
}
MouseArea {
=== modified file 'app/components/MusicToolbar.qml'
--- app/components/MusicToolbar.qml 2016-01-16 17:46:59 +0000
+++ app/components/MusicToolbar.qml 2016-07-25 12:37:55 +0000
@@ -108,6 +108,7 @@
"media-playback-pause" : "media-playback-start"
objectName: "disabledSmallPlayShape"
width: height
+ asynchronous: true
}
/* Click to shuffle music */
@@ -203,6 +204,7 @@
"media-playback-pause" : "media-playback-start"
objectName: "playShape"
width: height
+ asynchronous: true
}
/* Mouse area to jump to now playing */
=== modified file 'app/components/NowPlayingToolbar.qml'
--- app/components/NowPlayingToolbar.qml 2016-03-07 20:01:22 +0000
+++ app/components/NowPlayingToolbar.qml 2016-07-25 12:37:55 +0000
@@ -54,6 +54,7 @@
name: "media-playlist-repeat"
objectName: "repeatShape"
opacity: player.repeat ? 1 : .2
+ asynchronous: true
}
}
@@ -78,6 +79,7 @@
name: "media-skip-backward"
objectName: "previousShape"
opacity: parent.enabled ? 1 : .2
+ asynchronous: true
}
}
@@ -98,6 +100,7 @@
color: parent.pressed ? UbuntuColors.blue : "white"
name: player.mediaPlayer.playbackState === MediaPlayer.PlayingState ? "media-playback-pause" : "media-playback-start"
objectName: "playShape"
+ asynchronous: true
}
}
@@ -122,6 +125,7 @@
name: "media-skip-forward"
objectName: "forwardShape"
opacity: parent.enabled ? 1 : .2
+ asynchronous: true
}
}
@@ -145,6 +149,7 @@
name: "media-playlist-shuffle"
objectName: "shuffleShape"
opacity: player.shuffle ? 1 : .2
+ asynchronous: true
}
}
=== modified file 'app/components/Walkthrough/Slide1.qml'
--- app/components/Walkthrough/Slide1.qml 2015-10-18 17:45:48 +0000
+++ app/components/Walkthrough/Slide1.qml 2016-07-25 12:37:55 +0000
@@ -41,6 +41,7 @@
source: Image {
id: centerImage
source: Qt.resolvedUrl("../../graphics/music-app@xxxxxx")
+ asynchronous: true
}
width: height
=== modified file 'app/components/Walkthrough/Slide2.qml'
--- app/components/Walkthrough/Slide2.qml 2015-08-12 23:36:44 +0000
+++ app/components/Walkthrough/Slide2.qml 2016-07-25 12:37:55 +0000
@@ -39,6 +39,7 @@
height: (parent.height - bodyText.contentHeight - introductionText.height - 4*units.gu(4))/2
fillMode: Image.PreserveAspectFit
source: Qt.resolvedUrl("../../graphics/sd_phone_icon.png")
+ asynchronous: true
}
Label {
=== modified file 'app/components/Walkthrough/Slide3.qml'
--- app/components/Walkthrough/Slide3.qml 2015-08-12 23:36:44 +0000
+++ app/components/Walkthrough/Slide3.qml 2016-07-25 12:37:55 +0000
@@ -39,6 +39,7 @@
height: (parent.height - introductionText.height - finalMessage.contentHeight - 4.5*units.gu(4))/2
fillMode: Image.PreserveAspectFit
source: Qt.resolvedUrl("../../graphics/music_download_icon.png")
+ asynchronous: true
}
Label {
=== modified file 'app/components/Walkthrough/Walkthrough.qml'
--- app/components/Walkthrough/Walkthrough.qml 2015-10-28 01:05:33 +0000
+++ app/components/Walkthrough/Walkthrough.qml 2016-07-25 12:37:55 +0000
@@ -171,6 +171,7 @@
height: width
source: listView.currentIndex == index ? "../../graphics/Ellipse@xxxxxx" : "../../graphics/Ellipse_15_opacity@xxxxxx"
width: units.gu(1.5)
+ asynchronous: true
}
}
}
@@ -187,6 +188,7 @@
name: "chevron"
visible: listView.currentIndex !== 2
width: height
+ asynchronous: true
}
MouseArea {
=== modified file 'app/music-app.qml'
--- app/music-app.qml 2016-03-04 03:14:29 +0000
+++ app/music-app.qml 2016-07-25 12:37:55 +0000
@@ -446,10 +446,8 @@
// TODO: improve in refactoring to be able detect when a track is removed
// Update playlists page
- if (playlistsPage.visible) {
+ if (tabs.selectedTab == playlistsTab) {
playlistModel.filterPlaylists()
- } else {
- playlistsPage.changed = true
}
}
}
@@ -587,7 +585,7 @@
// Go back up the stack if possible
function goBack() {
// Ensure in the case that goBack is called programmatically that any dialogs are closed
- if (mainPageStack.currentMusicPage.currentDialog !== null) {
+ if (mainPageStack.currentMusicPage && mainPageStack.currentMusicPage.currentDialog !== null) {
PopupUtils.close(mainPageStack.currentMusicPage.currentDialog)
}
@@ -711,11 +709,15 @@
id: recentTab
objectName: "recentTab"
anchors.fill: parent
- title: page.title
+ title: i18n.tr("Recent")
// Tab content begins here
- page: Recent {
- id: recentPage
+ page: Loader {
+ width: mainPageStack.width
+ height: mainPageStack.height
+ active: tabs.selectedTab == recentTab
+ source: Qt.resolvedUrl("ui/Recent.qml")
+ asynchronous: true
}
}
}
@@ -758,11 +760,15 @@
id: artistsTab
objectName: "artistsTab"
anchors.fill: parent
- title: page.title
+ title: i18n.tr("Artists")
// tab content
- page: Artists {
- id: artistsPage
+ page: Loader {
+ width: mainPageStack.width
+ height: mainPageStack.height
+ active: tabs.selectedTab == artistsTab
+ source: Qt.resolvedUrl("ui/Artists.qml")
+ asynchronous: true
}
}
@@ -775,11 +781,15 @@
id: albumsTab
objectName: "albumsTab"
anchors.fill: parent
- title: page.title
+ title: i18n.tr("Albums")
// Tab content begins here
- page: Albums {
- id: albumsPage
+ page: Loader {
+ width: mainPageStack.width
+ height: mainPageStack.height
+ active: tabs.selectedTab == albumsTab
+ source: Qt.resolvedUrl("ui/Albums.qml")
+ asynchronous: true
}
}
@@ -792,11 +802,15 @@
id: genresTab
objectName: "genresTab"
anchors.fill: parent
- title: page.title
+ title: i18n.tr("Genres")
// Tab content begins here
- page: Genres {
- id: genresPage
+ page: Loader {
+ width: mainPageStack.width
+ height: mainPageStack.height
+ active: tabs.selectedTab == genresTab
+ source: Qt.resolvedUrl("ui/Genres.qml")
+ asynchronous: true
}
}
@@ -809,11 +823,15 @@
id: songsTab
objectName: "songsTab"
anchors.fill: parent
- title: page.title
+ title: i18n.tr("Tracks")
// Tab content begins here
- page: Songs {
- id: tracksPage
+ page: Loader {
+ width: mainPageStack.width
+ height: mainPageStack.height
+ active: tabs.selectedTab == songsTab
+ source: Qt.resolvedUrl("ui/Songs.qml")
+ asynchronous: true
}
}
@@ -826,11 +844,15 @@
id: playlistsTab
objectName: "playlistsTab"
anchors.fill: parent
- title: page.title
+ title: i18n.tr("Playlists")
// Tab content begins here
- page: Playlists {
- id: playlistsPage
+ page: Loader {
+ width: mainPageStack.width
+ height: mainPageStack.height
+ active: tabs.selectedTab == playlistsTab
+ source: Qt.resolvedUrl("ui/Playlists.qml")
+ asynchronous: true
}
}
=== modified file 'app/ui/Albums.qml'
--- app/ui/Albums.qml 2016-03-07 20:01:22 +0000
+++ app/ui/Albums.qml 2016-07-25 12:37:55 +0000
@@ -44,16 +44,6 @@
}
]
- // FIXME: workaround for pad.lv/1531016 (gridview juddery)
- anchors {
- bottom: parent.bottom
- fill: undefined
- left: parent.left
- top: parent.top
- }
- height: mainPageStack.height
- width: mainPageStack.width
-
// Hack for autopilot otherwise Albums appears as MusicPage
// due to bug 1341671 it is required that there is a property so that
// qml doesn't optimise using the parent type
=== modified file 'app/ui/Artists.qml'
--- app/ui/Artists.qml 2016-03-07 20:01:22 +0000
+++ app/ui/Artists.qml 2016-07-25 12:37:55 +0000
@@ -48,16 +48,6 @@
}
]
- // FIXME: workaround for pad.lv/1531016 (gridview juddery)
- anchors {
- bottom: parent.bottom
- fill: undefined
- left: parent.left
- top: parent.top
- }
- height: mainPageStack.height
- width: mainPageStack.width
-
// Hack for autopilot otherwise Artists appears as MusicPage
// due to bug 1341671 it is required that there is a property so that
// qml doesn't optimise using the parent type
=== modified file 'app/ui/Genres.qml'
--- app/ui/Genres.qml 2016-03-07 20:01:22 +0000
+++ app/ui/Genres.qml 2016-07-25 12:37:55 +0000
@@ -44,16 +44,6 @@
}
]
- // FIXME: workaround for pad.lv/1531016 (gridview juddery)
- anchors {
- bottom: parent.bottom
- fill: undefined
- left: parent.left
- top: parent.top
- }
- height: mainPageStack.height
- width: mainPageStack.width
-
// Hack for autopilot otherwise Albums appears as MusicPage
// due to bug 1341671 it is required that there is a property so that
// qml doesn't optimise using the parent type
=== modified file 'app/ui/LibraryEmptyState.qml'
--- app/ui/LibraryEmptyState.qml 2015-12-20 00:10:13 +0000
+++ app/ui/LibraryEmptyState.qml 2016-07-25 12:37:55 +0000
@@ -75,6 +75,7 @@
height: units.gu(10)
smooth: true
source: "../graphics/music_download_icon.png"
+ asynchronous: true
}
}
@@ -93,6 +94,7 @@
height: units.gu(6)
smooth: true
source: "../graphics/div.png"
+ asynchronous: true
}
}
@@ -106,6 +108,7 @@
height: units.gu(7)
smooth: true
source: "../graphics/sd_phone_icon.png"
+ asynchronous: true
}
}
=== modified file 'app/ui/Playlists.qml'
--- app/ui/Playlists.qml 2016-03-07 20:01:22 +0000
+++ app/ui/Playlists.qml 2016-07-25 12:37:55 +0000
@@ -49,16 +49,6 @@
}
]
- // FIXME: workaround for pad.lv/1531016 (gridview juddery)
- anchors {
- bottom: parent.bottom
- fill: undefined
- left: parent.left
- top: parent.top
- }
- height: mainPageStack.height
- width: mainPageStack.width
-
property bool changed: false
property bool childrenChanged: false
=== modified file 'app/ui/Recent.qml'
--- app/ui/Recent.qml 2016-03-07 20:01:22 +0000
+++ app/ui/Recent.qml 2016-07-25 12:37:55 +0000
@@ -69,16 +69,6 @@
}
title: i18n.tr("Recent")
- // FIXME: workaround for pad.lv/1531016 (gridview juddery)
- anchors {
- bottom: parent.bottom
- fill: undefined
- left: parent.left
- top: parent.top
- }
- height: mainPageStack.height
- width: mainPageStack.width
-
property bool changed: false
property bool childrenChanged: false
Follow ups
-
[Merge] lp:~fboucault/music-app/startup_time into lp:music-app
From: noreply, 2016-10-25
-
Re: [Merge] lp:~fboucault/music-app/startup_time into lp:music-app
From: Jenkins Bot, 2016-10-25
-
[Merge] lp:~fboucault/music-app/startup_time into lp:music-app
From: Andrew Hayzen, 2016-10-25
-
Re: [Merge] lp:~fboucault/music-app/startup_time into lp:music-app
From: Andrew Hayzen, 2016-10-25
-
Re: [Merge] lp:~fboucault/music-app/startup_time into lp:music-app
From: Andrew Hayzen, 2016-10-24
-
Re: [Merge] lp:~fboucault/music-app/startup_time into lp:music-app
From: Andrew Hayzen, 2016-10-20
-
[Merge] lp:~fboucault/music-app/startup_time into lp:music-app
From: Florian Boucault, 2016-10-19
-
[Merge] lp:~fboucault/music-app/startup_time into lp:music-app
From: Florian Boucault, 2016-10-19
-
Re: [Merge] lp:~fboucault/music-app/startup_time into lp:music-app
From: Andrew Hayzen, 2016-08-05
-
Re: [Merge] lp:~fboucault/music-app/startup_time into lp:music-app
From: Andrew Hayzen, 2016-07-25
-
Re: [Merge] lp:~fboucault/music-app/startup_time into lp:music-app
From: Andrew Hayzen, 2016-07-25