~indicator-multiload/indicator-multiload/trunk

« back to all changes in this revision

Viewing changes to src/icondata.vala

  • Committer: Michael Hofmann
  • Date: 2011-05-07 21:31:34 UTC
  • Revision ID: mh21@piware.de-20110507213134-81xrb5jjkkwju1h2
Fix disk usage plot by using /sys directly instead of libgtop.

Show diffs side-by-side

added added

removed removed

Lines of Context:
52
52
        this.scalerminimum = scalerminimum;
53
53
    }
54
54
 
55
 
    // needs to add data points to the traces and update the menuitems
 
55
    // needs to
 
56
    // - add data points to the traces
 
57
    // - update the menuitems
 
58
    // - call update_scale
56
59
    public abstract void update();
57
60
 
58
61
    // Fast attack, slow decay
64
67
    //   - it is never smaller than the peak value in the plot
65
68
    //   - after the current peak leaves the plot, the scaling factor gets
66
69
    //     reduced slowly
67
 
    // call this method at the end of update()
68
70
    protected virtual void update_scale() {
69
71
        double currentpeak = this.scalerminimum;
70
72
        for (uint i = 0, isize = this.trace_length; i < isize; ++i) {