Commit cf2d1b12 authored by Troy A. Griffitts's avatar Troy A. Griffitts

added more translations strings per Marjan Šavli. Thank you!

parent a26c634d
......@@ -165,3 +165,18 @@ Brown Dark=Brown Dark
Brown Light=Brown Light
Stone Blue Dark=Stone Blue Dark
Stone Blue Light=Stone Blue Light
with any morphology in=with any morphology in
Show all occurrences of=Show all occurrences of
# These next 2 are for search strings like: Searching for God love world in KJV
Searching for=Searching for
in=in
# These next 2 are for search strings like:
# No results found.
# 27 results found.
No=No
results found.=results found.
Connecting to server.=Connecting to server.
# These next 2 are for installing modules with strings like: Downloading 3 of 4
Downloading=Downloading
of=of
Total Progress:=Total Progress:
......@@ -991,7 +991,7 @@ console.log('setShowGospelParallels: ' + value);
},
addViewSelector: function(callback) {
var t = '';
t += '<tr><td class="menuLabel" onclick="app.toggleViewSelector(); return false;"><img src="img/ic_action_settings.png" style="height:1em;"/> <span id="viewLabel" data-english="View">View</span>: <span style="font-size:70%;" id="mainViewType">' + app.mainViewType + '</span></td></tr>';
t += '<tr><td class="menuLabel" onclick="app.toggleViewSelector(); return false;"><img src="img/ic_action_settings.png" style="height:1em;"/> <span id="viewLabel" data-english="View">View</span>: <span style="font-size:70%;" id="mainViewType" data-english="' + app.mainViewType + '">' + app.mainViewType + '</span></td></tr>';
t += '<tr><td style="width:100%;"><div class="viewSelectorPanel toshow">';
t += '<div class="subMenuItem"><input type="radio" id="viewBibles" name="viewSelector" value="Bibles" onclick="app.setViewBibles();return false;"/> <label id="viewBiblesLabel" data-english="Bibles" for="viewBibles">Bibles</label></div>';
t += '<div class="subMenuItem"><input type="radio" id="viewLanguageAssist" name="viewSelector" value="Language Assist" onclick="app.setViewLanguageAssist();return false;"/> <label id="viewLALabel" data-english="Language Assist" for="viewLanguageAssist">Language Assist</label></div>';
......@@ -1031,7 +1031,7 @@ console.log('setShowGospelParallels: ' + value);
if (app.enableBibleSync) {
t += '<tr><td class="menuLabel"><div style="display:inline-block" onclick="app.toggleBibleSyncPanel(); return false;"><img src="img/ic_action_group.png" style="height:1em;"/> <span data-english="BibleSync">BibleSync</span></div><label style="float:right;" class="switch"><input id="bibleSyncSwitch" onchange="app.toggleBibleSync(); return false;" type="checkbox"><span class="slider round"></span></label></td></tr>';
t += '<tr><td style="width:100%;"><div class="bibleSyncPanel toshow">';
t += '<div><button onclick="app.sendBibleSyncMessage(app.getCurrentVerseKey().osisRef);return false;"><span data-english="Send:">Send:</span> <span id="sendBibleSync">&nbsp;</span></button><button id="clearBibleSync" onclick="app.bibleSyncClear();return false;">Clear All</button></div>';
t += '<div><button onclick="app.sendBibleSyncMessage(app.getCurrentVerseKey().osisRef);return false;"><span data-english="Send:">Send:</span> <span id="sendBibleSync">&nbsp;</span></button><button data-english="Clear All" id="clearBibleSync" onclick="app.bibleSyncClear();return false;">Clear All</button></div>';
t += '<div id="bibleSyncResults"></div>';
t += '</div></td></tr>';
}
......@@ -1227,6 +1227,7 @@ console.log('updateMainViewSetting: ' + viewType);
app.mainViewType = viewType;
SWORD.mgr.translate(app.mainViewType, function(translated) {
$('#mainViewType').text(translated);
$('#mainViewType').attr('data-english', app.mainViewType);
});
window.localStorage.setItem('mainViewType', app.mainViewType);
$('#altDisplay').html('');
......@@ -1389,7 +1390,7 @@ console.log('updateMainViewSetting: ' + viewType);
},
openSettings: function() {
if ($('.settingsPanel').hasClass('tohide')) return;
$(".settingsPanel").animate({height: "28em"});
$(".settingsPanel").animate({height: "32em"});
$('.settingsPanel').removeClass('toshow').addClass('tohide');
},
closeSettings: function() {
......
......@@ -170,7 +170,7 @@ var installMgr = {
var buffer ='';
buffer += '<div style="margin: 0pt; padding: 0pt; width: 100%; white-space: nowrap; text-align: center; position: relative; z-index:0;">';
buffer += '&nbsp;' + text;
buffer += '&nbsp;<span data-english="'+text+'">' + text + '</span>';
if (percent > 0) { // for stupid ie
buffer += '<div style="position: absolute; top:0px; left:0px; margin: 0pt; padding: 0pt; background: transparent url(img/statusbar_green.gif) repeat-x scroll 0% 0%; overflow: visible; width: ' + percent + '%; -moz-background-clip: border; -moz-background-origin: padding; -moz-background-inline-policy: continuous; vertical-align: middle; filter:alpha(opacity=40); -khtml-opacity: 0.40; -moz-opacity: 0.40; opacity:0.40; z-index:-1;">';
......@@ -205,18 +205,23 @@ console.log('**** installMgr.installModule. disclaimer accepted. installing modu
var totalBytes = 0;
var completedBytes = 0;
$('#status').html(installMgr.getProgressHTML('Connecting to server.', 0));
app.setAppLocale();
SWORD.installMgr.remoteInstallModule(modSource, modName, function(e) {
if (e.status == "preStatus") {
lastMessage = e.message;
lastMessage = lastMessage.replace(/Downloading/g, '<span data-english="Downloading">Downloading</span>');
lastMessage = lastMessage.replace(/ of /g, ' <span data-english="of">of</span> ');
totalBytes = e.totalBytes;
completedBytes = e.completedBytes;
$('#status').html(installMgr.getProgressHTML(lastMessage + '(0%)', 0));
$('#status').html(installMgr.getProgressHTML(lastMessage', 0));
app.setAppLocale();
}
else if (e.status == "update") {
var percent = (e.completedBytes/e.totalBytes * 100).toFixed(2);
$('#status').html(installMgr.getProgressHTML(lastMessage + ' (' + percent + '%)', percent));
percent = ((completedBytes + e.completedBytes)/totalBytes * 100).toFixed(2);
$('#totalProgress').html(installMgr.getProgressHTML('Total Progress: ' + percent + '%', percent));
$('#totalProgress').html(installMgr.getProgressHTML('<span data-english="Total Progress:">Total Progress:</span> ' + percent + '%', percent));
app.setAppLocale();
}
else if (e.status == "complete") {
// only refesh source list if no subsequent processing callback
......
......@@ -95,11 +95,13 @@ console.log('********* wordSearch; mod: ' + mod + '; term:' + term + '; mod2: '
var rtol = (direction && 'RTOL' == direction.toUpperCase());
module.search('Word//Lemma./'+term+'/', module.SEARCHTYPE_ENTRYATTR, 0, null, function(e) {
if (e.status == 'update') {
$(target).html('<h3>Searching for "'+term+'" in ' + mod + '</h3>' + installMgr.getProgressHTML(e.percent + '%', e.percent));
$(target).html('<h3><span data-english="Searching for">Searching for</span> "'+term+'" <span data-english="in">in</span> ' + mod + '</h3>' + installMgr.getProgressHTML(e.percent + '%', e.percent));
app.setAppLocale(false, function() {
});
}
else if (e.status == 'complete') {
console.log('wordSearch module.search, complete. results.length: ' + e.results.length);
var t = '<h3>' + (!e.results.length ? 'No':e.results.length) + ' results found.</h3>';
var t = '<h3>' + (!e.results.length ? '<span data-english="No">No</span>':e.results.length) + ' <span data-english="results found.">results found.</span></h3>';
t += '<dl class="' + (lang?lang:'') + '">';
var resultLoop = function(results, i) {
if (!i) i = 0;
......@@ -110,7 +112,9 @@ console.log('wordSearch module.search, complete. results.length: ' + e.results.l
t += '<br/>';
t += '<br/>';
$(target).html(t);
setTimeout(function() { verseStudy.colorLemmas('x', term, morph, target); }, 50);
app.setAppLocale(false, function() {
setTimeout(function() { verseStudy.colorLemmas('x', term, morph, target); }, 50);
});
return;
}
var dispKey = results[i].key;
......@@ -152,23 +156,25 @@ console.log('wordSearch module.search, complete. results.length: ' + e.results.l
var lemma = $(word).attr('data-lemma');
var morph = $(word).attr('data-morph').replace(/-/g, '\\-');
$('#aux').html(
'<a href="#" onclick="return false;"><b style="white-space:nowrap">Show all occurrences of ' + lemma + ':</b></a>' +
'<a href="#" onclick="verseStudy.wordSearch(\''+(app.lastDisplayMods.length > 0 ? app.lastDisplayMods[0].name : '')+'\', \''+lemma+'\', \''+(app.lastDisplayMods.length > 1 ? app.lastDisplayMods[1].name : '')+'\', \''+morph+'\', \''+target+'\'); return false;">... any morphology in ' + app.lastDisplayMods[0].name + '</a>' +
'<a href="#" onclick="return false;"><b style="white-space:nowrap"><span data-english="Show all occurrences of">Show all occurrences of</span> ' + lemma + ':</b></a>' +
'<a href="#" onclick="verseStudy.wordSearch(\''+(app.lastDisplayMods.length > 0 ? app.lastDisplayMods[0].name : '')+'\', \''+lemma+'\', \''+(app.lastDisplayMods.length > 1 ? app.lastDisplayMods[1].name : '')+'\', \''+morph+'\', \''+target+'\'); return false;"><span data-english="with any morphology in">with any morphology in</span> ' + app.lastDisplayMods[0].name + '</a>' +
// '<a href="#" onclick="verseStudy.wordSearch(\''+app.lastDisplayMods[0].name+'\', \''+lemma+\'@\'+morph+'\', \''+app.lastDisplayMods[1].name+'\', \''+morph+'\', \''+target+'\'); return false;">... same morphology in ' + app.lastDisplayMods[0].name + '</a>' +
'<a href="#" onclick="verseStudy.wordSearch(\'LXX\', \''+lemma+'\', \'' + app.lastDisplayMods[0].name +'\', \''+morph+'\', \''+target+'\'); return false;">... any morphology in LXX</a>' +
'<a href="#" onclick="verseStudy.wordSearch(\'LXX\', \''+lemma+'\', \'' + app.lastDisplayMods[0].name +'\', \''+morph+'\', \''+target+'\'); return false;"><span data-english="with any morphology in">with any morphology in</span> LXX</a>' +
// '<a href="#" onclick="verseStudy.wordSearch(\'LXX\', \''+lemma+'\', \'' + app.lastDisplayMods[0].name +'\', \''+morph+'\', \''+target+'\'); return false;">... same morphology in LXX</a>' +
'');
setTimeout(function() {
var v = $('#aux');
var b = $('#variantButton');
$(v).toggleClass("show");
$(v).css({
'top': $(b).position().top + $(b).outerHeight(),
'left': $(b).position().left + $(b).outerWidth() - $(v).outerWidth()
});
app.setAppLocale(false, function() {
setTimeout(function() {
var v = $('#aux');
var b = $('#variantButton');
$(v).toggleClass("show");
$(v).css({
'top': $(b).position().top + $(b).outerHeight(),
'left': $(b).position().left + $(b).outerWidth() - $(v).outerWidth()
});
//console.log('aux.position: ' + JSON.stringify($('#aux').position()));
//console.log('aux: ' + $('#aux').outerHTML);
}, 50);
}, 50);
});
},
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment