aboutsummaryrefslogtreecommitdiff
path: root/src/prepaid-manager-applet.py
diff options
context:
space:
mode:
authorGuido Günther <agx@sigxcpu.org>2020-03-31 15:13:24 +0200
committerGuido Günther <agx@sigxcpu.org>2020-03-31 15:15:31 +0200
commita163721e4850a47f26bab088ac3c41e8167f718b (patch)
treeadcb337110f80fdd0d9325d872e18fbdf5f618a4 /src/prepaid-manager-applet.py
parent805d20d132098b9123f5527ffd0a4e1b807fd5a9 (diff)
Switch to python3
Diffstat (limited to 'src/prepaid-manager-applet.py')
-rwxr-xr-xsrc/prepaid-manager-applet.py10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/prepaid-manager-applet.py b/src/prepaid-manager-applet.py
index f0fe9a3..ab47f88 100755
--- a/src/prepaid-manager-applet.py
+++ b/src/prepaid-manager-applet.py
@@ -15,6 +15,10 @@
# You should have received a copy of the GNU General Public License
# along with this program; if not, see <http://www.gnu.org/licenses/>.
+from builtins import str
+from builtins import range
+from past.utils import old_div
+from builtins import object
import gettext
import gi
from gi.repository import GObject
@@ -410,8 +414,8 @@ class PPMDialog(GObject.GObject, PPMObject):
sensitive = True
if self.code_len > 0:
- self.entry_code.set_progress_fraction(float(cur_len) /
- self.code_len)
+ self.entry_code.set_progress_fraction(old_div(float(cur_len),
+ self.code_len))
if cur_len != self.code_len:
sensitive = False
self.button_top_up.set_sensitive(sensitive)
@@ -569,7 +573,7 @@ class PPMNoModemFoundInfoBar(PPMInfoBar):
class PPMProviderAssistant(PPMObject):
- PAGE_INTRO, PAGE_COUNTRIES, PAGE_PROVIDERS, PAGE_CONFIRM = range(0, 4)
+ PAGE_INTRO, PAGE_COUNTRIES, PAGE_PROVIDERS, PAGE_CONFIRM = list(range(0, 4))
def __init__(self, main_dialog):
PPMObject.__init__(self, main_dialog, "ppm-provider-assistant")