# Path: Wammu/Locales.py
# def ugettext(message):
#     if _TRANSLATION:
#         if six.PY2:
#             return _TRANSLATION.ugettext(message)
#         return _TRANSLATION.gettext(message)
#     return message


from Wammu.Locales import ugettext as _
from xml.sax.saxutils import escape
import Wammu.Data
import wx
import os
        if addr_full:
            addr_full += ','
        addr_full += addr_state
    if addr_country:
        if addr_full:
            addr_full += ','
        addr_full += addr_country
    if addr_full:
        contactxml += "        <address>"
        contactxml += escape(addr_full.encode('utf-8'))
        contactxml += "</address>\n"

    if contact['Date'] is not None:

        contactxml += "        <birthday>"
        contactxml += contact['Date'].strftime("%d.%m.%Y")
        contactxml += "</birthday>\n"

    contactxml += "        <folder>"
    contactxml += escape(folder.encode('utf-8'))
    contactxml += "</folder>\n"

    contactxml += "    </contact>\n"

    return contactxml

def ContactsExportXML(parent, contactsSM, contactsME):
    countSM = len(contactsSM)
    countME = len(contactsME)
    count = countSM + countME

# Path: Wammu/Locales.py
# def ugettext(message):
#     if _TRANSLATION:
#         if six.PY2:
#             return _TRANSLATION.ugettext(message)
#         return _TRANSLATION.gettext(message)
#     return message


# Path: Wammu/ContactsXML.py
from Wammu.Locales import ugettext as _
from xml.sax.saxutils import escape
import Wammu.Data
import wx
import os

        if addr_full:
            addr_full += ','
        addr_full += addr_state
    if addr_country:
        if addr_full:
            addr_full += ','
        addr_full += addr_country
    if addr_full:
        contactxml += "        <address>"
        contactxml += escape(addr_full.encode('utf-8'))
        contactxml += "</address>\n"

    if contact['Date'] is not None:

        contactxml += "        <birthday>"
        contactxml += contact['Date'].strftime("%d.%m.%Y")
        contactxml += "</birthday>\n"

    contactxml += "        <folder>"
    contactxml += escape(folder.encode('utf-8'))
    contactxml += "</folder>\n"

    contactxml += "    </contact>\n"

    return contactxml

def ContactsExportXML(parent, contactsSM, contactsME):
    countSM = len(contactsSM)
    countME = len(contactsME)
    count = countSM + countME

    wildcard = _('XML File') + ' (*.xml)|*.xml|' + _('All files') + ' (*.*)|*.*;*'