Ticket #515 (new enhancement)
Opened 8 years ago
Last modified 2 years ago
Collapsible diff display
| Reported by: | jamesm@… | Owned by: | cboos |
|---|---|---|---|
| Priority: | normal | Milestone: | next-major-0.1X |
| Component: | version control/changeset view | Version: | 0.7.1 |
| Severity: | normal | Keywords: | tracdiff memory |
| Cc: | |||
| Release Notes: | |||
| API Changes: | |||
Description
It would be nice to have a button on each diff section to collapse each the diff section/file. In this way you could display only the file diff you are interested in rather than having to display all the diffs.
Attachments
Change History
comment:1 Changed 8 years ago by daniel
- Milestone set to 0.9
- Priority changed from normal to low
- Severity changed from normal to enhancement
comment:2 Changed 7 years ago by agr30@…
I have given it a try and wrote some javascript to do this. Works on Opera 7.5 and Mozilla 0.9 on Linux, needs to be tested on other setups by someone.
The look has to be pimped up obviuosly.
See the attached files.
comment:3 Changed 7 years ago by agr30@…
Fixed fold.js to compensate for Internet Explorer's non-W3C compliant event model.
comment:4 Changed 7 years ago by cmlenz
- Owner changed from jonas to cmlenz
- Status changed from new to assigned
comment:5 Changed 7 years ago by agr30@…
When #942 is resolved, fold.js can use the addEvent() function.
comment:6 Changed 7 years ago by cmlenz
- Milestone changed from 0.9 to 1.0
comment:7 Changed 6 years ago by cboos
- Keywords tracdiff added
This might be done together with #2591.
Note that if you simply hide the elements
which are already in the page, you won't
get any performance increase: for that,
the diff should remain empty until the
show triggers the load of additional
data (the AJAX way).
If you only want to focus the attention
on changes that happened on a specific file,
see also #2078.
comment:8 Changed 6 years ago by markus
for that, the diff should remain empty until the show triggers the load of additional data
Does that mean all diffs are collapsed when entering the changeset view?
comment:9 Changed 6 years ago by cmlenz
- Owner cmlenz deleted
- Status changed from assigned to new
I don't think collapsing all diffs by default would be a good idea. Currently, I can quickly get a good overview of the changes just by scrolling through the page. I wouldn't want to first have to expand every diff to see what was actually changed.
Using AJAX here would basically mean the changeset view would be useless without AJAX. I don't think that is acceptable for such an essential feature.
And finally, having the diffs expanded by default, but collapsible by the viewer, doesn't really make much sense at all IMHO. But then again, I've never understood why people think that code folding was such a great feature in editors :-P
comment:10 Changed 6 years ago by cmlenz
- Owner set to cmlenz
(Hmm, this should've set the component default owner, but didn't)
comment:11 Changed 6 years ago by cboos
cmlenz, the AJAX suggestion was meant for big changesets only.
The fallback when Javascript/AJAX isn't available would be a
link to the restricted changeset (cf. #2591).
comment:12 Changed 4 years ago by cboos
- Keywords memory added
- Milestone changed from 1.0 to 0.12
- Owner changed from cmlenz to cboos
- Priority changed from low to normal
#7070 asked for this feature again.
I actually have a patch to add a Hide button to each diff, in addition to the Tabular and Unified buttons, and a second patch to add those 3 buttons at the top of the diff list. That's a start, but I have yet to add some logic for downloading the diff content on demand, when needed for big changesets.
comment:13 Changed 4 years ago by Markus.Staab
using jquery now this should be no prolem..
comment:14 Changed 3 years ago by cboos
- Milestone changed from 0.13 to 0.12
comment:15 Changed 2 years ago by rblank
- Milestone changed from 0.12 to next-minor-0.12.x
comment:16 Changed 2 years ago by cboos
- Milestone changed from next-minor-0.12.x to next-major-0.1X
Too big enhancement for a minor version.



This is a neat idea. Some javascript to do the trick would be quite sufficient.