sourcegit-scm / sourcegit

Windows/macOS/Linux GUI client for GIT users
MIT License
1.36k stars 135 forks source link

[FEATURE] Changes view improvements #148

Closed gigi81 closed 5 months ago

gigi81 commented 5 months ago

I wanted to suggest some improvements on the changes view:

Let me know what you think and you feel like you want to implement yourself. Happy to spend some time on it if myself you feel like something that can be eventually merged.

love-linger commented 5 months ago

You can change the display mode to List/Grid/Tree, and it will be saved into user's perference.

image

Since double click is a built-in action in TreeView to expand/collapse node, we use space on keyboard to stage/unstage selected changes in all the three display modes.

Code in Views.WorkingCopy is just used to get selected changes from different display mode, and then the interface of ViewModels.WorkingCopy can just concern about how to deal with the datas.

Automatic selection will not be added in the near future for some reasons:

gadfly3173 commented 5 months ago

Instead of staging/unstaging a file by double-clicking it, maybe consider adding a staging button to the right when hovering?

love-linger commented 5 months ago

Instead of staging/unstaging a file by double-clicking it, maybe consider adding a staging button to the right when hovering?

If there's horizontal scrollbar, it's hard to place the stage/unstage button

image image

I perfer to use double-click after replace TreeView with TreeDataGrid, since the TreeDataGrid do not use double click to expand/collapse node by default.

love-linger commented 5 months ago

I've push a new branch feature/treedatagrid.

gigi81 commented 5 months ago

Thanks @love-linger I didn't realise there was a button to change the view mode to three already. Thanks for looking into this. I will have a look at the branch and do some testing if that helps.