~indicator-multiload/indicator-multiload/trunk

« back to all changes in this revision

Viewing changes to src/indicator.vala

  • Committer: Michael Hofmann
  • Date: 2013-03-08 20:53:28 UTC
  • Revision ID: mh21@mh21.de-20130308205328-36xwkxl9k8zyhsp7
Tray icon, switched on per default for testing.

Show diffs side-by-side

added added

removed removed

Lines of Context:
74
74
                    });
75
75
            });
76
76
 
77
 
        this.indicatorview = new AppIndicatorView(this.icondirectory,
 
77
        this.indicatorview = new TrayIndicatorView(this.icondirectory,
78
78
                this.menu);
79
79
        this.indicatorview.scroll_event.connect(this.scrollhandler);
80
80
    }
152
152
 
153
153
    private void updatelabelview() {
154
154
        var indicatorcount = this.labelmodel.expressions.length;
155
 
        var indicatorlabel = 0 <= this.indicator_index &&
 
155
        this.indicatorview.label = 0 <= this.indicator_index &&
156
156
            this.indicator_index < indicatorcount ?
157
157
            this.labelmodel.expression(this.indicator_index).label() : "";
158
 
        var indicatorguide = 0 <= this.indicator_index &&
 
158
        this.indicatorview.guide = 0 <= this.indicator_index &&
159
159
            this.indicator_index < indicatorcount ?
160
160
            this.labelmodel.expression(this.indicator_index).guide() : "";
161
 
        this.indicatorview.setindicatorlabel(indicatorlabel, indicatorguide);
162
161
    }
163
162
 
164
163
    private void updategraphsview() {
177
176
            });
178
177
        }
179
178
        if (!found) {
180
 
            this.indicatorview.setindicatoricon(this.lasticonwidth > 0 ?
181
 
                    this.iconname(this.currenticonindex) : "",
182
 
                    this.descriptionmodel.expression(0).label());
 
179
            this.indicatorview.icon = this.lasticonwidth > 0 ?
 
180
                    this.iconname(this.currenticonindex) : "";
183
181
        }
 
182
        this.indicatorview.description = this.descriptionmodel.expression(0).label();
184
183
    }
185
184
 
186
185
    private string iconname(uint index) {