Ejemplo n.º 1
0
 def __init__(self):
     Grid.__init__(self, 1, 2, StyleName='login-panel')
     self.setCellPadding(0)
     self.setCellSpacing(0)
     formatter = self.getCellFormatter()
     # formatter.setWidth(0, 0, '100%')
     formatter.setHorizontalAlignment(0, 0, 'right')
     formatter.setHorizontalAlignment(0, 1, 'right')
     self.loggedIn = False
     self.screenname = None
     self.friendsIds = None
     self.userListPanels = []
     self.oauthCookie = Cookies.getCookie(defaults.OAUTH_COOKIE)
     if self.oauthCookie:
         remote = server.TickeryService()
         id = remote.screenameFromCookie(self.oauthCookie,
                                         DisplayLoggedIn(self))
         if id < 0:
             self.setWidget(0, 1, Label('oops: getScreenameFromCookie'))
     else:
         self.notLoggedIn()
Ejemplo n.º 2
0
 def is_cookie_set(self):
     if (Cookies.getCookie(self.unique_id)):
         return True
     else:
         return False