зеркало из https://github.com/mozilla/gecko-dev.git
Bug 837735 - Replace Cleopatra progress strings with 'Loading profile...', r=robcee
This commit is contained in:
Родитель
391096d41f
Коммит
5b718d40f8
|
@ -214,3 +214,34 @@ function enterFinishedProfileUI() {
|
|||
|
||||
toggleJavascriptOnly();
|
||||
}
|
||||
|
||||
function enterProgressUI() {
|
||||
var pane = document.createElement("div");
|
||||
var label = document.createElement("a");
|
||||
var bar = document.createElement("progress");
|
||||
var string = gStrings.getStr("profiler.loading");
|
||||
|
||||
pane.className = "profileProgressPane";
|
||||
pane.appendChild(label);
|
||||
pane.appendChild(bar);
|
||||
|
||||
var reporter = new ProgressReporter();
|
||||
reporter.addListener(function (rep) {
|
||||
var progress = rep.getProgress();
|
||||
|
||||
if (label.textContent !== string) {
|
||||
label.textContent = string;
|
||||
}
|
||||
|
||||
if (isNaN(progress)) {
|
||||
bar.removeAttribute("value");
|
||||
} else {
|
||||
bar.value = progress;
|
||||
}
|
||||
});
|
||||
|
||||
gMainArea.appendChild(pane);
|
||||
Parser.updateLogSetting();
|
||||
|
||||
return reporter;
|
||||
}
|
|
@ -72,3 +72,8 @@ profiler.start=Start
|
|||
# LOCALIZATION NOTE (profiler.stop)
|
||||
# This string is displayed on the button that stops the profiler.
|
||||
profiler.stop=Stop
|
||||
|
||||
# LOCALIZATION NOTE (profiler.loading)
|
||||
# This string is displayed above the progress bar when the profiler
|
||||
# is busy loading and parsing the report.
|
||||
profiler.loading=Loading profile…
|
Загрузка…
Ссылка в новой задаче