D15840: [Folder View] Remember selected item when navigating in subfolders

2018-10-10 Thread Thomas Surrel
This revision was automatically updated to reflect the committed changes. Closed by commit R119:6736bdaa4bbd: [Folder View] Remember selected item when navigating in subfolders (authored by thsurrel). REPOSITORY R119 Plasma Desktop CHANGES SINCE LAST UPDATE https://phabricator.kde.org/D15840

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-10-10 Thread Eike Hein
hein accepted this revision. hein added a comment. This revision is now accepted and ready to land. No worries, thanks for the patch :) REPOSITORY R119 Plasma Desktop BRANCH arc_folderview3 (branched from master) REVISION DETAIL https://phabricator.kde.org/D15840 To: thsurrel, #plasma

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-10-10 Thread Thomas Surrel
thsurrel updated this revision to Diff 43266. thsurrel added a comment. I'm not sure how I managed to lose this bit when preparing this. Thanks for your patience, hein, I have been doing a pretty poor job on this patch. REPOSITORY R119 Plasma Desktop CHANGES SINCE LAST UPDATE https://p

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-10-09 Thread Eike Hein
hein added inline comments. INLINE COMMENTS > FolderView.qml:194 > function doCd(row) { > -history.push(url); > +history.push({"url": url, "index": gridView.currentIndex, > "contentY": gridView.contentY}); > updateHistory(); You're still storing contentY here. REP

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-10-09 Thread Thomas Surrel
thsurrel updated this revision to Diff 43190. thsurrel added a comment. Use gridView.visibleArea REPOSITORY R119 Plasma Desktop CHANGES SINCE LAST UPDATE https://phabricator.kde.org/D15840?vs=43158&id=43190 BRANCH arc_folderview3 (branched from master) REVISION DETAIL https://phabri

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-10-08 Thread Eike Hein
hein added inline comments. INLINE COMMENTS > FolderView.qml:1119 > +setSelected(positioner.map(gridView.currentIndex)); > +gridView.contentY = Math.min(lastPosition.contentY, > gridView.contentY); > } I don't think this works as intended

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-10-08 Thread Thomas Surrel
thsurrel updated this revision to Diff 43158. thsurrel added a comment. Limit index and position to the current gridview state, in case some elements have disappeared since we visited the parent folder. REPOSITORY R119 Plasma Desktop CHANGES SINCE LAST UPDATE https://phabricator.kde.org

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-10-08 Thread Eike Hein
hein added a comment. In D15840#337571 , @thsurrel wrote: > In D15840#337446 , @hein wrote: > > > I like the goal here, but it's not a given the stored index is still valid when navigating back - the

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-10-06 Thread Thomas Surrel
thsurrel added a comment. In D15840#337446 , @hein wrote: > I like the goal here, but it's not a given the stored index is still valid when navigating back - the folder contents could have changed. It'd be hygienic to bound the access when poppi

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-10-06 Thread Thomas Surrel
thsurrel updated this revision to Diff 42966. thsurrel added a comment. Pop all history info at once when navigating back REPOSITORY R119 Plasma Desktop CHANGES SINCE LAST UPDATE https://phabricator.kde.org/D15840?vs=42624&id=42966 BRANCH arc_folderview3 (branched from master) REVISIO

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-10-05 Thread Eike Hein
hein added a comment. I like the goal here, but it's not a given the stored index is still valid when navigating back - the folder contents could have changed. It'd be hygienic to bound the access when popping from the history. REPOSITORY R119 Plasma Desktop REVISION DETAIL https://phab

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-10-01 Thread Thomas Surrel
thsurrel added inline comments. INLINE COMMENTS > anthonyfieroni wrote in FolderView.qml:1114 > Ok, then just embed Folder View in the panel (by right click on the panel, > panel options -> add widgets or drag'n'drop it in) then navigate to check > that should it goback to be applied as well.

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-10-01 Thread Anthony Fieroni
anthonyfieroni added inline comments. INLINE COMMENTS > thsurrel wrote in FolderView.qml:1114 > My understanding was that the gridView.model could be undefined only if the > FolderModel was not ready. But if we navigated into a subfolder and we are > asking to go back, than the FolderModel had

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-10-01 Thread Thomas Surrel
thsurrel added inline comments. INLINE COMMENTS > anthonyfieroni wrote in FolderView.qml:1114 > Do we have grodView.model after back clicked? If we do in expanded view > (that's when Folder View is embedded in the panel) goingBack will not be > performed. My understanding was that the gridView

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-10-01 Thread Anthony Fieroni
anthonyfieroni added inline comments. INLINE COMMENTS > FolderView.qml:1114 > onListingCompleted: { > if (!gridView.model && plasmoid.expanded) { > gridView.model = positioner; Do we have grodView.model after back clicked? If we do in expanded v

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-09-30 Thread Nathaniel Graham
ngraham added a comment. Gotta add `BUG: 359310` to the Summary section, not a comment. REPOSITORY R119 Plasma Desktop REVISION DETAIL https://phabricator.kde.org/D15840 To: thsurrel, #plasma Cc: ngraham, plasma-devel, ragreen, Pitel, ZrenBot, lesliezhai, ali-mohamed, jensreuterberg, ab

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-09-30 Thread Thomas Surrel
thsurrel updated this revision to Diff 42624. thsurrel added a comment. [Folder View] Restore scrolling position when going back BUG: 359310 REPOSITORY R119 Plasma Desktop CHANGES SINCE LAST UPDATE https://phabricator.kde.org/D15840?vs=42568&id=42624 BRANCH arc_folderview3 (branch

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-09-30 Thread Thomas Surrel
thsurrel added a comment. Having a second look, this bug is related: https://bugs.kde.org/show_bug.cgi?id=359310 As it is, my patch does not fix that though, so far it remembers the selected item but not the scroll position. I will try to improve my patch to fix both issues. REPOSITORY

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-09-29 Thread Nathaniel Graham
ngraham added a comment. Does this bug a bugzilla ticket? REPOSITORY R119 Plasma Desktop REVISION DETAIL https://phabricator.kde.org/D15840 To: thsurrel, #plasma Cc: ngraham, plasma-devel, ragreen, Pitel, ZrenBot, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, apol, mart

D15840: [Folder View] Remember selected item when navigating in subfolders

2018-09-29 Thread Thomas Surrel
thsurrel created this revision. thsurrel added a reviewer: Plasma. Herald added a project: Plasma. Herald added a subscriber: plasma-devel. thsurrel requested review of this revision. REVISION SUMMARY When using the folder view in a panel as a popup, being in list view mode, getting into subfo