Commit 50c5d909 authored by Eitan Isaacson's avatar Eitan Isaacson

accerciser.spec.in

macaroon/pyreqs.py
plugins/event_monitor.py
plugins/interface_view.py
plugins/script_recorder.py
plugins/validate.py
po/he.po
pyreqs.py
src/lib/accerciser/accerciser.py
src/lib/accerciser/i18n.py.in: Removed all mentions of glade. Explicitly add translation domain to gtk.Builder instances.
parent e1ffeca0
......@@ -21,7 +21,6 @@ Requires: gnome-python2-gconf >= 2.12
Requires: gnome-python2-libwnck >= 2.14
Requires: pygtk2 >= 2.8
Requires: python >= 2.4
Requires: pygtk2-libglade >= 2.8
Requires: at-spi >= 1.7
Requires: gnome-python2 >= 2.12
Requires: glib2 >= 2.10
......
......@@ -24,7 +24,7 @@ except KeyError:
pass
# test for python modules
modules = ['pygtk', 'gtk', 'gtk.glade', 'gtk.gdk', 'wnck']
modules = ['pygtk', 'gtk', 'gtk.gdk', 'wnck']
for name in modules:
try:
m = __import__(name)
......
......@@ -16,7 +16,7 @@ import gobject
import os.path
import gettext, os, sys, locale
from accerciser.plugin import ViewportPlugin
from accerciser.i18n import _, N_
from accerciser.i18n import _, N_, DOMAIN
import pango
from gtk import keysyms, gdk
......@@ -69,6 +69,7 @@ class EventMonitor(ViewportPlugin):
keysyms.t, gdk.MOD1_MASK | gdk.CONTROL_MASK)]
self.source_filter = None
self.main_xml = gtk.Builder()
self.main_xml.set_translation_domain(DOMAIN)
self.main_xml.add_from_file(UI_FILE)
vpaned = self.main_xml.get_object('monitor_vpaned')
self.plugin_area.add(vpaned)
......
......@@ -18,7 +18,7 @@ import pango
from gobject import markup_escape_text
from accerciser.plugin import ViewportPlugin
from accerciser.icons import getIcon
from accerciser.i18n import _, N_
from accerciser.i18n import _, N_, DOMAIN
from xml.dom import minidom
UI_FILE = os.path.join(os.path.dirname(__file__),
......@@ -51,6 +51,7 @@ class InterfaceViewer(ViewportPlugin):
del dom
ui_xml = gtk.Builder()
ui_xml.set_translation_domain(DOMAIN)
ui_xml.add_from_file(UI_FILE)
frame = ui_xml.get_object('iface_view_frame')
self.label_role = ui_xml.get_object('label_role')
......
......@@ -6,7 +6,7 @@ from gtk import keysyms
import gtksourceview2
import threading
import wnck
from accerciser.i18n import N_, _
from accerciser.i18n import N_, _, DOMAIN
from Queue import Queue
UI_FILE = os.path.join(os.path.dirname(__file__),
......@@ -190,6 +190,7 @@ class ScriptRecorder(ViewportPlugin):
self.text_view.set_editable(True)
self.text_view.set_cursor_visible(True)
xml = gtk.Builder()
xml.set_translation_domain(DOMAIN)
xml.add_from_file(UI_FILE)
vbox = xml.get_object('main_vbox')
sw = xml.get_object('textview_sw')
......
......@@ -19,7 +19,7 @@ import glob
import imp
import webbrowser
from accerciser.plugin import ViewportPlugin
from accerciser.i18n import _, N_
from accerciser.i18n import _, N_, DOMAIN
import pyatspi
UI_FILE = os.path.join(os.path.dirname(__file__), 'validate.ui')
......@@ -170,6 +170,7 @@ class ValidatorViewport(ViewportPlugin):
self.url = None
self.main_xml = gtk.Builder()
self.main_xml.set_translation_domain(DOMAIN)
self.main_xml.add_from_file(UI_FILE)
frame = self.main_xml.get_object('main vbox')
self.plugin_area.add(frame)
......
This diff is collapsed.
......@@ -25,7 +25,7 @@ except KeyError:
pass
# test for python modules
modules = ['pygtk', 'gtk', 'gtk.glade', 'gtk.gdk', 'wnck', 'pyatspi']
modules = ['pygtk', 'gtk', 'gtk.gdk', 'wnck', 'pyatspi']
for name in modules:
try:
m = __import__(name)
......
......@@ -17,7 +17,6 @@ import pygtk
pygtk.require('2.0')
import gtk
import gobject
import gtk.glade
import gtk.gdk
import os, sys, locale
from icons import getIcon
......@@ -41,11 +40,6 @@ from prefs_dialog import AccerciserPreferencesDialog
from main_window import AccerciserMainWindow
import ui_manager
GLADE_FILENAME = os.path.join(sys.prefix, 'share', 'accerciser', 'glade',
'accerciser.glade')
if not os.path.exists(GLADE_FILENAME):
GLADE_FILENAME = os.path.join(os.getcwd(), 'accerciser.glade')
GCONF_GENERAL = '/apps/accerciser/general'
class Main(Tools):
......
......@@ -23,7 +23,7 @@ available under the terms of the BSD license which accompanies
this distribution, and is available at
U{http://www.opensource.org/licenses/bsd-license.php}
'''
import sys, locale, gettext, os.path, gtk.glade
import sys, locale, gettext, os.path
from gettext import gettext as translate_func
def bind(domain, locale_dir):
......@@ -44,8 +44,6 @@ def bind(domain, locale_dir):
@return: Bound method ugettext on the translation object
@rtype: callable
'''
gtk.glade.bindtextdomain(domain, locale_dir)
gtk.glade.textdomain(domain)
try:
t = gettext.translation(domain, locale_dir)
return t.ugettext
......
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