Remove need for polkit, launch any ArchUpdater update through terminal
ArchUpdater: rely on `TERMINAL` environment variable README: Add explanation for the `TERMINAL` environment variable
This commit is contained in:
parent
5ab76c98e5
commit
299add4a15
19 changed files with 1232 additions and 799 deletions
|
|
@ -11,7 +11,7 @@ Singleton {
|
|||
function scale(aScreen) {
|
||||
try {
|
||||
if (aScreen !== undefined && aScreen.name !== undefined) {
|
||||
return getMonitorScale(aScreen.name)
|
||||
return scaleByName(aScreen.name)
|
||||
}
|
||||
} catch (e) {
|
||||
|
||||
|
|
@ -20,46 +20,21 @@ Singleton {
|
|||
return 1.0
|
||||
}
|
||||
|
||||
// -------------------------------------------
|
||||
function getMonitorScale(aScreenName) {
|
||||
function scaleByName(aScreenName) {
|
||||
try {
|
||||
var monitors = Settings.data.ui.monitorsScaling
|
||||
if (monitors !== undefined) {
|
||||
for (var i = 0; i < monitors.length; i++) {
|
||||
if (monitors[i].name !== undefined && monitors[i].name === aScreenName) {
|
||||
return monitors[i].scale
|
||||
}
|
||||
if (Settings.data.monitorsScaling !== undefined) {
|
||||
if (Settings.data.monitorsScaling[aScreenName] !== undefined) {
|
||||
return Settings.data.monitorsScaling[aScreenName]
|
||||
}
|
||||
}
|
||||
} catch (e) {
|
||||
|
||||
//Logger.warn(e)
|
||||
}
|
||||
|
||||
return 1.0
|
||||
}
|
||||
|
||||
// -------------------------------------------
|
||||
function setMonitorScale(aScreenName, scale) {
|
||||
try {
|
||||
var monitors = Settings.data.ui.monitorsScaling
|
||||
if (monitors !== undefined) {
|
||||
for (var i = 0; i < monitors.length; i++) {
|
||||
if (monitors[i].name !== undefined && monitors[i].name === aScreenName) {
|
||||
monitors[i].scale = scale
|
||||
return
|
||||
}
|
||||
}
|
||||
}
|
||||
monitors.push({
|
||||
"name": aScreenName,
|
||||
"scale": scale
|
||||
})
|
||||
} catch (e) {
|
||||
|
||||
//Logger.warn(e)
|
||||
}
|
||||
}
|
||||
|
||||
// -------------------------------------------
|
||||
// Dynamic scaling based on resolution
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue