Make strings localization-friendly
Reorganize string literals and add comments to make string more friendly for translators.
This commit is contained in:
@@ -5716,7 +5716,7 @@ wxAccStatus wxDataViewCtrlAccessible::GetName(int childId, wxString* name)
|
|||||||
if ( colName.empty() )
|
if ( colName.empty() )
|
||||||
{
|
{
|
||||||
// Columns are numbered from 1.
|
// Columns are numbered from 1.
|
||||||
colName = _("Column") + wxString::Format(wxS(" %u"), col+1);
|
colName = wxString::Format(_("Column %u"), col+1);
|
||||||
}
|
}
|
||||||
itemName = colName + wxS(": ") + vs;
|
itemName = colName + wxS(": ") + vs;
|
||||||
break;
|
break;
|
||||||
@@ -5728,7 +5728,7 @@ wxAccStatus wxDataViewCtrlAccessible::GetName(int childId, wxString* name)
|
|||||||
{
|
{
|
||||||
// Return row number if no textual column found.
|
// Return row number if no textual column found.
|
||||||
// Rows are numbered from 1.
|
// Rows are numbered from 1.
|
||||||
*name = _("Row") + wxString::Format(wxS(" %i"), childId);
|
*name = wxString::Format(_("Row %i"), childId);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -5813,8 +5813,10 @@ wxAccStatus wxDataViewCtrlAccessible::GetDefaultAction(int childId, wxString* ac
|
|||||||
if ( node->HasChildren() )
|
if ( node->HasChildren() )
|
||||||
{
|
{
|
||||||
if ( node->IsOpen() )
|
if ( node->IsOpen() )
|
||||||
|
/* TRANSLATORS: Action for manipulating a tree control */
|
||||||
action = _("Collapse");
|
action = _("Collapse");
|
||||||
else
|
else
|
||||||
|
/* TRANSLATORS: Action for manipulating a tree control */
|
||||||
action = _("Expand");
|
action = _("Expand");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -5833,9 +5835,9 @@ wxAccStatus wxDataViewCtrlAccessible::GetDescription(int childId, wxString* desc
|
|||||||
|
|
||||||
if ( childId == wxACC_SELF )
|
if ( childId == wxACC_SELF )
|
||||||
{
|
{
|
||||||
*description = wxString::Format(_("This %s has %u columns"),
|
wxDataViewMainWindow* dvWnd = wxDynamicCast(dvCtrl->GetMainWindow(), wxDataViewMainWindow);
|
||||||
dvCtrl->GetName().c_str(),
|
*description = wxString::Format(_("%s (%d items)"),
|
||||||
dvCtrl->GetColumnCount());
|
dvCtrl->GetName().c_str(), dvWnd->GetRowCount());
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -5893,7 +5895,7 @@ wxAccStatus wxDataViewCtrlAccessible::GetDescription(int childId, wxString* desc
|
|||||||
if ( colName.empty() )
|
if ( colName.empty() )
|
||||||
{
|
{
|
||||||
// Columns are numbered from 1.
|
// Columns are numbered from 1.
|
||||||
colName = _("Column") + wxString::Format(wxS(" %u"), col+1);
|
colName = wxString::Format(_("Column %u"), col+1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( !itemDesc.empty() )
|
if ( !itemDesc.empty() )
|
||||||
@@ -5955,8 +5957,10 @@ wxAccStatus wxDataViewCtrlAccessible::GetKeyboardShortcut(int childId, wxString*
|
|||||||
if ( node->HasChildren() )
|
if ( node->HasChildren() )
|
||||||
{
|
{
|
||||||
if ( node->IsOpen() )
|
if ( node->IsOpen() )
|
||||||
|
/* TRANSLATORS: Keystroke for manipulating a tree control */
|
||||||
*shortcut = _("Left");
|
*shortcut = _("Left");
|
||||||
else
|
else
|
||||||
|
/* TRANSLATORS: Keystroke for manipulating a tree control */
|
||||||
*shortcut = _("Right");
|
*shortcut = _("Right");
|
||||||
|
|
||||||
return wxACC_OK;
|
return wxACC_OK;
|
||||||
|
Reference in New Issue
Block a user