except :
hildon = False
-def global_start(button, scanner):
- scanner.start()
+def global_start(button, scanner, config):
+ scanner.start( config.scan_period )
if button._id :
button.disconnect( button._id )
- button._id = button.connect("clicked", global_stop, scanner)
+ button._id = button.connect("clicked", global_stop, scanner, config)
button.set_label("Switch GPS Off")
-def global_stop(button, scanner):
+def global_stop(button, scanner, config):
scanner.stop()
if button._id :
button.disconnect( button._id )
- button._id = button.connect("clicked", global_start, scanner)
+ button._id = button.connect("clicked", global_start, scanner, config)
button.set_label("Switch GPS On")
def enable_agps(button):
button.set_label("Start scanning")
-class scanner ( wifimap.Scanner ) :
+class scanner ( wifimap.ReplayScanner ) :
def scan ( self ) :
- wifimap.Scanner.scan( self )
+ wifimap.ReplayScanner.scan( self )
self.report()
def report ( self ) :
- self.status.set_label( wifimap.Scanner.report(self) )
+ self.status.set_label( wifimap.ReplayScanner.report(self) )
start, end = self.buffer.get_bounds()
self.buffer.delete( start , end )
for mac,rss in self.scanlist.iteritems() :
# Buttons creation
button = self.Button( "Switch GPS On")
- button._id = button.connect("clicked", global_start, _scanner)
+ button._id = button.connect("clicked", global_start, _scanner, self.map.config)
buttons.pack_start(button, expand=False)
button_scan = self.Button( "Start scanning")