Skip to content

Commit

Permalink
Merge pull request #2 from sharkykh/py3-compat
Browse files Browse the repository at this point in the history
Python 3 compatibility
  • Loading branch information
sharkykh committed Aug 7, 2018
2 parents 284b01a + 2b4254a commit 7892f7a
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 6 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ This is a small Tkinter GUI application that allows a [Trakt.tv](https://trakt.t

## Supported Python versions
* 2.7
* 3.5
* 3.6
* 3.7

## Python requirements
* [trakt.py](https://github.com/fuzeman/trakt.py)
Expand Down
9 changes: 5 additions & 4 deletions tppm/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,17 @@
from __future__ import unicode_literals

import os.path
import Tkinter as Tk
import tkMessageBox
import webbrowser
from time import sleep

import six.moves.tkinter as Tk
import six.moves.tkinter_messagebox as tkMessageBox

from trakt import Trakt
from trakt.objects import Movie, Episode, Show
from trakt.objects import Episode, Movie, Show

from . import auth
from .ui import MainUI, AuthUI
from .ui import AuthUI, MainUI


class AuthDialog(AuthUI):
Expand Down
7 changes: 6 additions & 1 deletion tppm/ui/auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,12 @@
from __future__ import absolute_import
from __future__ import unicode_literals

from Tkinter import Button, Entry, Label, StringVar
from six.moves.tkinter import (
Button,
Entry,
Label,
StringVar
)


class AuthUI(object):
Expand Down
10 changes: 9 additions & 1 deletion tppm/ui/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,15 @@
from __future__ import absolute_import
from __future__ import unicode_literals

from Tkinter import Button, Entry, Label, Listbox, Scrollbar, StringVar, TclError
from six.moves.tkinter import (
Button,
Entry,
Label,
Listbox,
Scrollbar,
StringVar,
TclError
)


# Based on: http://effbot.org/zone/tkinter-autoscrollbar.htm
Expand Down

0 comments on commit 7892f7a

Please sign in to comment.