Commit c1f526c0 authored by Yann Leboulanger's avatar Yann Leboulanger

fix import order to be able to run tests

parent 98e1ab56
......@@ -36,31 +36,11 @@ import pango
import os
import sys
import vcard
import dialogs
import logging
log = logging.getLogger('gajim.gtkgui_helpers')
HAS_PYWIN32 = True
if os.name == 'nt':
try:
import win32file
import win32con
import pywintypes
except ImportError:
HAS_PYWIN32 = False
from common import i18n
from common import gajim
from common import helpers
gtk.glade.bindtextdomain(i18n.APP, i18n.DIR)
gtk.glade.textdomain(i18n.APP)
screen_w = gtk.gdk.screen_width()
screen_h = gtk.gdk.screen_height()
gtk_icon_theme = gtk.icon_theme_get_default()
gtk_icon_theme.append_search_path(gajim.ICONS_DIR)
......@@ -82,6 +62,27 @@ def get_icon_path(icon_name, size=16):
except gobject.GError, e:
log.error("Unable to find icon %s: %s" % (icon_name, str(e)))
import vcard
import dialogs
HAS_PYWIN32 = True
if os.name == 'nt':
try:
import win32file
import win32con
import pywintypes
except ImportError:
HAS_PYWIN32 = False
from common import helpers
gtk.glade.bindtextdomain(i18n.APP, i18n.DIR)
gtk.glade.textdomain(i18n.APP)
screen_w = gtk.gdk.screen_width()
screen_h = gtk.gdk.screen_height()
def add_image_to_menuitem(menuitem, icon_name):
img = gtk.Image()
path_img = get_icon_path(icon_name)
......
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