1234567891011121314151617181920212223242526272829303132333435363738 |
- --- a/usr/lib/linuxmint/mintlocale/im.py
- +++ b/usr/lib/linuxmint/mintlocale/im.py
- @@ -1,10 +1,8 @@
- #!/usr/bin/python3
- -import apt
- import codecs
- import gettext
- import locale
- -import mintcommon.aptdaemon
- import os
- try:
- @@ -19,6 +17,13 @@
- from gi.repository import Gtk, GObject, Gdk, XApp
- from ImConfig.ImConfig import ImConfig
- +
- +# Used to detect Debian derivatives (we don't want to show APT features in other distros)
- +IS_DEBIAN = os.path.exists("/etc/debian_version")
- +
- +if IS_DEBIAN:
- + import apt
- + import mintcommon.aptdaemon
- # i18n
- APP = 'mintlocale'
- @@ -38,7 +43,8 @@
- self.app = app
- self.packages = []
- self.missing_packages = []
- - self.apt = mintcommon.aptdaemon.APT(self.app.window)
- + if IS_DEBIAN:
- + self.apt = mintcommon.aptdaemon.APT(self.app.window)
- self.button = button
- self.button.connect('clicked', self.install)
- self.button.set_sensitive(False)
|