Renaming managers to backend to conform with DialCentral
authorEd Page <eopage@byu.net>
Sat, 18 Apr 2009 16:09:51 +0000 (11:09 -0500)
committerEd Page <eopage@byu.net>
Sat, 18 Apr 2009 16:09:51 +0000 (11:09 -0500)
src/file_backend.py
src/null_backend.py
src/null_view.py
src/rtm_backend.py
src/rtm_view.py

index 93cee59..7ff2627 100644 (file)
@@ -5,7 +5,7 @@ import datetime
 import toolbox
 
 
-class FileManager(object):
+class FileBackend(object):
 
        def __init__(self, filename):
                self._filename = filename
@@ -47,7 +47,7 @@ class FileManager(object):
                projDetails["isVisible"] = False
 
        def get_projects(self):
-               return (projectDetails for projectDetails in self._projects.itervalues())
+               return self._projects.itervalues()
 
        def get_project(self, projId):
                return self._projects[projId]
@@ -65,7 +65,7 @@ class FileManager(object):
                return todoList[0]
 
        def get_locations(self):
-               return (locDetails for locDetails in self._locations.itervalues())
+               return self._locations.itervalues()
 
        def get_tasks_with_details(self, projId):
                return (
index d70d55e..4828551 100644 (file)
@@ -1,4 +1,4 @@
-class NullManager(object):
+class NullBackend(object):
 
        def __init__(self, username, password, token=None):
                pass
index dc9aad5..35bb296 100644 (file)
@@ -15,7 +15,7 @@ class GtkNull(object):
                self._todoBox = widgetTree.get_widget("todoBox")
                self._todoAreaFiller = gtk.Label()
 
-               self._manager = null_backend.NullManager("", "")
+               self._manager = null_backend.NullBackend("", "")
 
        @staticmethod
        def name():
index d724d13..4aab70e 100644 (file)
@@ -12,7 +12,7 @@ def fix_url(rturl):
        return "/".join(rturl.split(r"\/"))
 
 
-class RtMilkManager(object):
+class RtmBackend(object):
        """
        Interface with rememberthemilk.com
 
@@ -250,7 +250,7 @@ class RtMilkManager(object):
        @staticmethod
        def _pack_ids(*ids):
                """
-               >>> RtMilkManager._pack_ids(123, 456)
+               >>> RtmBackend._pack_ids(123, 456)
                '123-456'
                """
                return "-".join((str(id) for id in ids))
@@ -258,7 +258,7 @@ class RtMilkManager(object):
        @staticmethod
        def _unpack_ids(ids):
                """
-               >>> RtMilkManager._unpack_ids("123-456")
+               >>> RtmBackend._unpack_ids("123-456")
                ['123', '456']
                """
                return ids.split("-")
index 27bd95a..bbbdfc3 100644 (file)
@@ -73,7 +73,7 @@ def get_token(username, apiKey, secret):
 
 def get_credentials(credentialsDialog):
        username, password = credentialsDialog.request_credentials()
-       token = get_token(username, rtm_backend.RtMilkManager.API_KEY, rtm_backend.RtMilkManager.SECRET)
+       token = get_token(username, rtm_backend.RtmBackend.API_KEY, rtm_backend.RtmBackend.SECRET)
        return username, password, token
 
 
@@ -469,7 +469,7 @@ class GtkRtMilk(object):
                credentials = self._credentials
                while True:
                        try:
-                               self._manager = rtm_backend.RtMilkManager(*credentials)
+                               self._manager = rtm_backend.RtmBackend(*credentials)
                                self._credentials = credentials
                                return # Login succeeded
                        except rtm_api.AuthStateMachine.NoData: