Back to index

system-config-printer  1.3.9+20120706
Public Member Functions | Public Attributes
asyncipp.UI Class Reference

List of all members.

Public Member Functions

def __init__
def destroy
def connect_clicked
def connected
def connect_failed
def get_devices
def get_devices_reply
def get_devices_error

Public Attributes

 get_devices_button
 conn

Detailed Description

Definition at line 639 of file asyncipp.py.


Constructor & Destructor Documentation

def asyncipp.UI.__init__ (   self)

Definition at line 640 of file asyncipp.py.

00640 
00641         def __init__ (self):
00642             w = gtk.Window ()
00643             w.connect ("destroy", self.destroy)
00644             b = gtk.Button ("Connect")
00645             b.connect ("clicked", self.connect_clicked)
00646             vbox = gtk.VBox ()
00647             vbox.pack_start (b)
00648             w.add (vbox)
00649             self.get_devices_button = gtk.Button ("Get Devices")
00650             self.get_devices_button.connect ("clicked", self.get_devices)
00651             self.get_devices_button.set_sensitive (False)
00652             vbox.pack_start (self.get_devices_button)
00653             self.conn = None
00654             w.show_all ()

Here is the call graph for this function:


Member Function Documentation

def asyncipp.UI.connect_clicked (   self,
  button 
)

Definition at line 663 of file asyncipp.py.

00663 
00664         def connect_clicked (self, button):
00665             if self.conn:
00666                 self.conn.destroy ()
00667 
00668             self.conn = IPPAuthConnection (reply_handler=self.connected,
00669                                            error_handler=self.connect_failed)

Here is the call graph for this function:

Here is the caller graph for this function:

def asyncipp.UI.connect_failed (   self,
  conn,
  exc 
)

Definition at line 674 of file asyncipp.py.

00674 
00675         def connect_failed (self, conn, exc):
00676             debugprint ("Exc %s" % exc)
00677             self.get_devices_button.set_sensitive (False)
00678             self.conn.destroy ()

Here is the caller graph for this function:

def asyncipp.UI.connected (   self,
  conn,
  result 
)

Definition at line 670 of file asyncipp.py.

00670 
00671         def connected (self, conn, result):
00672             debugprint ("Success: %s" % result)
00673             self.get_devices_button.set_sensitive (True)

Here is the caller graph for this function:

def asyncipp.UI.destroy (   self,
  window 
)

Definition at line 655 of file asyncipp.py.

00655 
00656         def destroy (self, window):
00657             try:
00658                 self.conn.destroy ()
00659             except AttributeError:
00660                 pass
00661 
00662             gtk.main_quit ()

Here is the caller graph for this function:

def asyncipp.UI.get_devices (   self,
  button 
)

Definition at line 679 of file asyncipp.py.

00679 
00680         def get_devices (self, button):
00681             button.set_sensitive (False)
00682             debugprint ("Getting devices")
00683             self.conn.getDevices (reply_handler=self.get_devices_reply,
00684                                   error_handler=self.get_devices_error)

Here is the call graph for this function:

def asyncipp.UI.get_devices_error (   self,
  conn,
  exc 
)

Definition at line 693 of file asyncipp.py.

00693 
00694         def get_devices_error (self, conn, exc):
00695             if conn != self.conn:
00696                 debugprint ("Ignoring stale error")
00697                 return
00698 
00699             debugprint ("Error getting devices: %s" % exc)
00700             self.get_devices_button.set_sensitive (True)
00701 
    UI ()

Here is the caller graph for this function:

def asyncipp.UI.get_devices_reply (   self,
  conn,
  result 
)

Definition at line 685 of file asyncipp.py.

00685 
00686         def get_devices_reply (self, conn, result):
00687             if conn != self.conn:
00688                 debugprint ("Ignoring stale reply")
00689                 return
00690 
00691             debugprint ("Got devices: %s" % result)
00692             self.get_devices_button.set_sensitive (True)

Here is the caller graph for this function:


Member Data Documentation

Definition at line 652 of file asyncipp.py.

Definition at line 648 of file asyncipp.py.


The documentation for this class was generated from the following file: