replace addTopChrome with uiGroup.add_actor, fixes #7
This commit is contained in:
parent
6149951ac1
commit
3443a18445
1 changed files with 3 additions and 3 deletions
|
@ -41,8 +41,8 @@ class Extension {
|
||||||
for (let monitor of Main.layoutManager.monitors) {
|
for (let monitor of Main.layoutManager.monitors) {
|
||||||
let label_1 = new St.Label({style_class: 'label-1', text: text1, opacity})
|
let label_1 = new St.Label({style_class: 'label-1', text: text1, opacity})
|
||||||
let label_2 = new St.Label({style_class: 'label-2', text: text2, opacity})
|
let label_2 = new St.Label({style_class: 'label-2', text: text2, opacity})
|
||||||
Main.layoutManager.addTopChrome(label_2, {"trackFullscreen": false})
|
Main.layoutManager.uiGroup.add_actor(label_2, {"trackFullscreen": false})
|
||||||
Main.layoutManager.addTopChrome(label_1, {"trackFullscreen": false})
|
Main.layoutManager.uiGroup.add_actor(label_1, {"trackFullscreen": false})
|
||||||
this.labels.push(label_1)
|
this.labels.push(label_1)
|
||||||
this.labels.push(label_2)
|
this.labels.push(label_2)
|
||||||
let h = Math.max(0, Math.floor(monitor.height * vl2 - label_2.height))
|
let h = Math.max(0, Math.floor(monitor.height * vl2 - label_2.height))
|
||||||
|
@ -54,7 +54,7 @@ class Extension {
|
||||||
|
|
||||||
cleanup() {
|
cleanup() {
|
||||||
for (let label of this.labels) {
|
for (let label of this.labels) {
|
||||||
Main.layoutManager.removeChrome(label)
|
Main.layoutManager.uiGroup.remove_actor(label)
|
||||||
label.destroy()
|
label.destroy()
|
||||||
}
|
}
|
||||||
this.labels = []
|
this.labels = []
|
||||||
|
|
Loading…
Reference in a new issue