diff options
| author | Claudiu Popa <cpopa@cloudbasesolutions.com> | 2014-11-12 22:02:51 +0200 | 
|---|---|---|
| committer | Claudiu Popa <cpopa@cloudbasesolutions.com> | 2014-11-12 22:02:51 +0200 | 
| commit | ad83c5d56a58c9f07a713844ecbc5704090a8faa (patch) | |
| tree | 38b164d21220bf3a5815470009ca642b3f1f7a37 /gui.py | |
| parent | 4c69e9c5c5b801e7f574c53fcc7d91d745ffc4b1 (diff) | |
| download | pylint-git-ad83c5d56a58c9f07a713844ecbc5704090a8faa.tar.gz | |
Make pylint-gui work again on Python 3.
Diffstat (limited to 'gui.py')
| -rw-r--r-- | gui.py | 22 | 
1 files changed, 14 insertions, 8 deletions
| @@ -19,13 +19,19 @@ from __future__ import print_function  import os  import sys  import re -import Queue  from threading import Thread -from Tkinter import (Tk, Frame, Listbox, Entry, Label, Button, Scrollbar, -                     Checkbutton, Radiobutton, IntVar, StringVar) -from Tkinter import (TOP, LEFT, RIGHT, BOTTOM, END, X, Y, BOTH, SUNKEN, W, -                     HORIZONTAL, DISABLED, NORMAL, W) -from tkFileDialog import askopenfilename, askdirectory + +import six + +from six.moves.tkinter import ( +    Tk, Frame, Listbox, Entry, Label, Button, Scrollbar, +    Checkbutton, Radiobutton, IntVar, StringVar, +    TOP, LEFT, RIGHT, BOTTOM, END, X, Y, BOTH, SUNKEN, W, +    HORIZONTAL, DISABLED, NORMAL, W, +) +from six.moves.tkinter_tkfiledialog import ( +    askopenfilename, askdirectory, +)  import pylint.lint  from pylint.reporters.guireporter import GUIReporter @@ -119,7 +125,7 @@ class LintGui(object):          #reporter          self.reporter = None          #message queue for output from reporter -        self.msg_queue = Queue.Queue() +        self.msg_queue = six.moves.queue.Queue()          self.msgs = []          self.visible_msgs = []          self.filenames = [] @@ -376,7 +382,7 @@ class LintGui(object):                      fg_color = COLORS.get(msg_str[:3], 'black')                      self.lb_messages.itemconfigure(END, fg=fg_color) -            except Queue.Empty: +            except six.moves.queue.Empty:                  pass          return True | 
