Edgewall Software
Modify

Opened 20 years ago

Last modified 14 months ago

#515 new enhancement

Collapsible diff display

Reported by: jamesm@… Owned by:
Priority: normal Milestone: next-major-releases
Component: version control/changeset view Version: 0.7.1
Severity: normal Keywords: tracdiff memory
Cc: Branch:
Release Notes:
API Changes:
Internal 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 (4)

fold.js (2.9 KB ) - added by agr30@… 20 years ago.
Javascript Code
changeset.cs.patch (1.8 KB ) - added by agr30@… 20 years ago.
Patch for Template
diff.css.patch (446 bytes ) - added by agr30@… 20 years ago.
Patch for CSS
fold.2.js (3.0 KB ) - added by agr30@… 20 years ago.
Fixed fold.js

Download all attachments as: .zip

Change History (21)

comment:1 by daniel, 20 years ago

Milestone: 0.9
Priority: normallow
Severity: normalenhancement

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

comment:2 by agr30@…, 20 years ago

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.

by agr30@…, 20 years ago

Attachment: fold.js added

Javascript Code

by agr30@…, 20 years ago

Attachment: changeset.cs.patch added

Patch for Template

by agr30@…, 20 years ago

Attachment: diff.css.patch added

Patch for CSS

by agr30@…, 20 years ago

Attachment: fold.2.js added

Fixed fold.js

comment:3 by agr30@…, 20 years ago

Fixed fold.js to compensate for Internet Explorer's non-W3C compliant event model.

comment:4 by Christopher Lenz, 20 years ago

Owner: changed from Jonas Borgström to Christopher Lenz
Status: newassigned

comment:5 by agr30@…, 19 years ago

When #942 is resolved, fold.js can use the addEvent() function.

comment:6 by Christopher Lenz, 19 years ago

Milestone: 0.91.0

comment:7 by Christian Boos, 18 years ago

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 by markus, 18 years ago

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 by Christopher Lenz, 18 years ago

Owner: Christopher Lenz removed
Status: assignednew

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 by Christopher Lenz, 18 years ago

Owner: set to Christopher Lenz

(Hmm, this should've set the component default owner, but didn't)

comment:11 by Christian Boos, 18 years ago

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 by Christian Boos, 16 years ago

Keywords: memory added
Milestone: 1.00.12
Owner: changed from Christopher Lenz to Christian Boos
Priority: lownormal

#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 by Markus.Staab, 16 years ago

using jquery now this should be no prolem..

comment:14 by Christian Boos, 15 years ago

Milestone: 0.130.12

comment:15 by Remy Blank, 15 years ago

Milestone: 0.12next-minor-0.12.x

comment:16 by Christian Boos, 14 years ago

Milestone: next-minor-0.12.xnext-major-0.1X

Too big enhancement for a minor version.

comment:17 by Ryan J Ollos, 9 years ago

Owner: Christian Boos removed

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The ticket will remain with no owner.
The ticket will be disowned.
as The resolution will be set. Next status will be 'closed'.
The owner will be changed from (none) to anonymous. Next status will be 'assigned'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.