Exemple #1
0
 def on_imi_session_boot_activate(self, _widget):
     """Handle imi_session_boot.activate event."""
     clients = self.get_selected_clients()
     if not clients:  # No client selected, send the command to all
         clients = self.cstore
     for client in clients:
         # Make sure that only offline computers will be sent to wol
         client = client[C_INSTANCE]
         if client.is_offline():
             wol.wake_on_lan(client.mac)
Exemple #2
0
 def wake_on_lan(self, widget):
     """Boot the selected computers with WOL"""
     clients = self.getSelectedClients()
     if len(clients) == 0:  # No client selected, send the command to all
         clients = self.cstore
     for client in clients:
         # Make sure that only offline computers will be sent to wol
         client = client[C_INSTANCE]
         if client.is_offline():
             wol.wake_on_lan(client.mac)