Fix #5 Added option description in controller tab.

This commit is contained in:
Quentin Decaunes 2019-03-02 16:09:06 +01:00
parent 7b700438c3
commit 58fff43ad1
3 changed files with 25 additions and 0 deletions

View File

@ -7,6 +7,7 @@ ready(function(){
loadLatestUsedSettings();
displayVersion();
reApplyPeriodically(require('electron-settings').get('settings.reapply_periodically'));
displayOptionDescription();
document.isStarting = false;
});

View File

@ -258,3 +258,20 @@ function reApplyPeriodically(seconds) {
document.reapplyLoop = setInterval(applyRyzenSettings, seconds * 1000);
}
/**
* Display tooltip on each options.
*/
function displayOptionDescription() {
appendLog("displayOptionDescription():");
const options_description = require('./js/options_description.json');
for (const option in options_description) {
if (options_description.hasOwnProperty(option)) {
appendLog(`- option: ${option}`);
const description = options_description[option];
const node = document.getElementById(option).parentElement.parentElement;
node.setAttribute('uk-tooltip', description);
UIkit.tooltip(node);
}
}
}

View File

@ -0,0 +1,7 @@
{
"stapm_limit_w": "Skin Temperature Aware Power Management. This will define the socket power package limit which is used to manage the device boost period.",
"ppt_fast_limit_w": "The amount of power the CPU can draw while boost levels on.",
"ppt_slow_limit_w": "The amount of power the CPU can draw while boost levels off.",
"temperature_limit_c": "The temperature the CPU can reach before boost levels off.",
"vrm_current_m_a": "The limit of current we let the motherboard deliver to the CPU."
}