__init__.py 1.3 KB

1234567891011121314151617181920212223242526272829303132
  1. # UI module
  2. # Copyright (C) 2010-2011 Sebastian Spaeth & contributors
  3. #
  4. # This program is free software; you can redistribute it and/or modify
  5. # it under the terms of the GNU General Public License as published by
  6. # the Free Software Foundation; either version 2 of the License, or
  7. # (at your option) any later version.
  8. #
  9. # This program is distributed in the hope that it will be useful,
  10. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. # GNU General Public License for more details.
  13. #
  14. # You should have received a copy of the GNU General Public License
  15. # along with this program; if not, write to the Free Software
  16. # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
  17. from offlineimap.ui.UIBase import getglobalui, setglobalui
  18. from offlineimap.ui import TTY, Noninteractive, Machine
  19. UI_LIST = {'ttyui': TTY.TTYUI,
  20. 'basic': Noninteractive.Basic,
  21. 'quiet': Noninteractive.Quiet,
  22. 'syslog': Noninteractive.Syslog,
  23. 'machineui': Machine.MachineUI}
  24. # add Blinkenlights UI if it imports correctly (curses installed)
  25. try:
  26. from offlineimap.ui import Curses
  27. UI_LIST['blinkenlights'] = Curses.Blinkenlights
  28. except ImportError:
  29. pass