Untitled
unknown
plain_text
5 months ago
1.3 kB
4
Indexable
# Add network buttons for network in networks: network_button = ctk.CTkButton( self.networks_frame, text=network['ssid'], font=("Dongle", 20), height=40, fg_color='#3a3a3c' if self.dark_mode else '#d1d1d6', hover_color='#34c759' if not self.dark_mode else '#30d158', text_color='white' if self.dark_mode else 'black', command=lambda n=network['ssid']: self.select_network(n) ) network_button.pack(fill='x', pady=5, padx=10) # If no networks found if not networks: no_networks_label = ctk.CTkLabel( self.networks_frame, text="No networks found", font=("Dongle", 24), text_color='white' if self.dark_mode else 'black' ) no_networks_label.pack(pady=10) # Run network scan in separate thread threading.Thread(target=update_networks, daemon=True).start() def close_diagnostics(self): """Clean up and close the diagnostics screen""" self.diagnostics.stop_monitoring() self.destroy()
Editor is loading...
Leave a Comment