-
Notifications
You must be signed in to change notification settings - Fork 147
Commit
- Loading branch information
There are no files selected for viewing
Large diffs are not rendered by default.
Large diffs are not rendered by default.
This file was deleted.
This file was deleted.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
/* executed for | ||
/wp-admin/edit-tags.php?action=edit | ||
*/ | ||
jQuery(document).ready( | ||
function(){ | ||
var qtx = qTranslateConfig.js.get_qtx(); | ||
|
||
var form = document.getElementById('edittag'); | ||
if(!form) return false; | ||
|
||
var h=qtx.addContentHookByIdB('name'); | ||
if(!h) return false; | ||
|
||
qtranxj_ce('input', {name: 'qtrans_term_field_name', type: 'hidden', className: 'hidden', value: h.name }, form, true); | ||
|
||
//var default_name=h.contents[qTranslateConfig.default_language]; | ||
var default_name=h.fields[qTranslateConfig.default_language].value; | ||
qtranxj_ce('input', {name: 'qtrans_term_field_default_name', type: 'hidden', className: 'hidden', value: default_name }, form, true); | ||
}); |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
/* executed for | ||
/wp-admin/edit-tags.php (without action=edit) | ||
*/ | ||
jQuery(document).ready( | ||
function(){ | ||
var qtx = qTranslateConfig.js.get_qtx(); | ||
|
||
var form = document.getElementById('addtag');//AjaxForm | ||
if(!form) return; | ||
|
||
var h=qtx.addContentHookByIdB('tag-name'); | ||
if(!h) return; | ||
|
||
qtranxj_ce('input', {name: 'qtrans_term_field_name', type: 'hidden', className: 'hidden', value: h.name }, form, true); | ||
|
||
//var default_name = h.contents[qTranslateConfig.default_language]; | ||
var default_name = h.fields[qTranslateConfig.default_language].value; | ||
qtranxj_ce('input', {name: 'qtrans_term_field_default_name', type: 'hidden', className: 'hidden', value: default_name }, form, true); | ||
|
||
//var theList=document.getElementById('the-list'); | ||
|
||
//remove "Quick Edit" links for now | ||
jQuery('#the-list > tr > td.name span.inline').css('display','none'); | ||
|
||
//make page to reload page on submit of a new taxonomy | ||
var submit_button = document.getElementById('submit'); | ||
if(submit_button){ | ||
submit_button.addEventListener('click',function(){ | ||
setTimeout(function(){window.location.reload();},800); | ||
//addDisplayHookRows(theList);//does not work, because the updates on theList has not yet propagated | ||
}); | ||
} | ||
|
||
}); |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
/* executed for | ||
/wp-admin/nav-menus.php | ||
*/ | ||
jQuery(document).ready( | ||
function(){ | ||
var qtx = qTranslateConfig.js.get_qtx(); | ||
|
||
var addMenuItemHooks=function(li) | ||
{ | ||
qtx.addContentHooksByClass('edit-menu-item-title',li); | ||
qtx.addContentHooksByClass('edit-menu-item-attr-title',li); | ||
qtx.addContentHooksByClass('[edit-menu-item-description',li);//must use '[:]' separator style | ||
|
||
qtx.addDisplayHooksByClass('menu-item-title',li); | ||
//qtx.addDisplayHooksByClass('item-title',li); | ||
qtx.addDisplayHooksByTagInClass('link-to-original','A',li); | ||
} | ||
|
||
var onAddMenuItem = function(menuMarkup){ | ||
var rx = /id="menu-item-(\d+)"/gi; | ||
while((matches = rx.exec(menuMarkup))){ | ||
var id = 'menu-item-'+matches[1]; | ||
var li = document.getElementById(id); | ||
if(li) addMenuItemHooks(li); | ||
} | ||
} | ||
|
||
if(wpNavMenu){ | ||
var wp_addMenuItemToBottom = wpNavMenu.addMenuItemToBottom; | ||
if( typeof wp_addMenuItemToBottom == 'function'){ | ||
wpNavMenu.addMenuItemToBottom = function( menuMarkup, req ) { | ||
wp_addMenuItemToBottom( menuMarkup, req ); | ||
onAddMenuItem(menuMarkup); | ||
}; | ||
} | ||
if( typeof wp_addMenuItemToTop == 'function'){ | ||
wpNavMenu.addMenuItemToTop = function( menuMarkup ) { | ||
wp_addMenuItemToTop( menuMarkup ); | ||
onAddMenuItem(menuMarkup); | ||
}; | ||
} | ||
} | ||
|
||
var onLanguageSwitchAfter = function(lang){ | ||
if(wpNavMenu){ | ||
if( typeof wpNavMenu.refreshKeyboardAccessibility == 'function'){ | ||
wpNavMenu.refreshKeyboardAccessibility(); | ||
} | ||
if( typeof wpNavMenu.refreshAdvancedAccessibility == 'function'){ | ||
wpNavMenu.refreshAdvancedAccessibility(); | ||
} | ||
} | ||
} | ||
onLanguageSwitchAfter(); | ||
|
||
qtx.addLanguageSwitchAfterListener(onLanguageSwitchAfter); | ||
}); |
fa87157
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@johnclause
You've changed the section titles in all languages from "General Settings" to "General", "Advanced Settings" to "Advanced" and "Custom Integration" to "Integration". This is fine.
But as you changed this in all languages, the translations should be reviewed also. No one will probably notice the original english strings is differente unless they inspect commits.
I think you should always mark this changed strings as fuzzy so that translators know they have to pay atention to it, or else it goes down under all the strings that appear to be translated a long time ago.
I'm going to simplify the pt_PT correspondent strings, but it's a good idea to go back to all languages and mark those as fuzzy.
fa87157
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just made the PL #163 to correct this in pt_PT
fa87157
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I was not sure about the best way. If I mark it fuzzy, then they are not written into .mo, but having previous translation is better than nothing. I guess, I can adjust .po with 'fuzzy' now, after .mo is already updated?
fa87157
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I disagree, it's not nothing, it's a pretty well noticable string to be translated right away. Having a previous incorrect translation means that it won't be marked to be translated. I would prefer a string not translated than a bad translated one.
Yes, for the benefit of every translator that didn't notice that change, you should mark those changed strings as fuzzy. It's not different than when you have new strings to translate, it usually take a few commits to translators fill it all.
fa87157
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I meant .mo must still have old translation until new .mo is generated, which is now achieved. I updated .po files with 'fuzzy' line on last push.