~ubuntu-branches/ubuntu/quantal/padre/quantal

« back to all changes in this revision

Viewing changes to lib/Padre/Task/BackupUnsaved.pm

  • Committer: Package Import Robot
  • Author(s): Dominique Dumont, gregor herrmann, Dominique Dumont
  • Date: 2012-01-04 12:04:20 UTC
  • mfrom: (1.3.3)
  • Revision ID: package-import@ubuntu.com-20120104120420-i5oybqwf91m1d3il
Tags: 0.92.ds1-1
[ gregor herrmann ]
* Remove debian/source/local-options; abort-on-upstream-changes
  and unapply-patches are default in dpkg-source since 1.16.1.
* Swap order of alternative (build) dependencies after the perl
  5.14 transition.

[ Dominique Dumont ]
* Imported Upstream version 0.92.ds1
* removed fix-spelling patch (applied upstream)
* lintian-override: use wildcard to avoid listing a gazillion files
* updated size of some 'not-real-man-page' entries
* rules: remove dekstop cruft (replaced by a file provided in debian
  directory)
* control: removed Breaks statement. Add /me to uploaders. Updated
  dependencies
* rules: make sure that non-DFSG file (i.e. the cute butterfly, sigh)
  is not distributed

Show diffs side-by-side

added added

removed removed

Lines of Context:
8
8
use Padre::Constant ();
9
9
use Padre::Logger;
10
10
 
11
 
our $VERSION = '0.90';
 
11
our $VERSION = '0.92';
12
12
our @ISA     = 'Padre::Task';
13
13
 
14
14
 
23
23
        TRACE( $_[0] ) if DEBUG;
24
24
        my $self = shift;
25
25
 
 
26
        my $new_count;
 
27
 
26
28
        # Save the list of open files
27
29
        require Padre::Current;
28
 
        $self->{changes} =
29
 
                { map { $_->filename => $_->text_get, } grep { $_->is_unsaved } Padre::Current->main->documents };
 
30
        $self->{changes} = {
 
31
                map { ( $_->filename || 'NEW' . ( ++$new_count ) ) => $_->text_get, }
 
32
                grep { $_->is_modified } Padre::Current->main->documents
 
33
        };
30
34
 
31
35
        return 1;
32
36
}