wire-py-reformat-14-08-2024 #8

Merged
punix merged 6 commits from wire-py-reformat-14-08-2024 into main 2024-08-23 18:00:19 +02:00
4 changed files with 19 additions and 16 deletions
Showing only changes of commit b6555974ea - Show all commits

View File

@ -4,9 +4,9 @@
<option name="autoReloadType" value="SELECTIVE" /> <option name="autoReloadType" value="SELECTIVE" />
</component> </component>
<component name="ChangeListManager"> <component name="ChangeListManager">
<list default="true" id="940e1630-c825-4d4c-be80-bc11f543c122" name="Changes" comment="Set Style to Clam&#10;Improved layout of widgets"> <list default="true" id="940e1630-c825-4d4c-be80-bc11f543c122" name="Changes" comment="Remove open file function, add Show Address Labels with tk.StrVar when remove a not active Tunnel Labels of Active Tunnel removed!">
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" /> <change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/dict_to_address" beforeDir="false" afterPath="$PROJECT_DIR$/dict_to_address" afterDir="false" /> <change beforePath="$PROJECT_DIR$/dict_to_address" beforeDir="false" />
<change beforePath="$PROJECT_DIR$/main.py" beforeDir="false" afterPath="$PROJECT_DIR$/main.py" afterDir="false" /> <change beforePath="$PROJECT_DIR$/main.py" beforeDir="false" afterPath="$PROJECT_DIR$/main.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/wg_func.py" beforeDir="false" afterPath="$PROJECT_DIR$/wg_func.py" afterDir="false" /> <change beforePath="$PROJECT_DIR$/wg_func.py" beforeDir="false" afterPath="$PROJECT_DIR$/wg_func.py" afterDir="false" />
</list> </list>
@ -172,7 +172,15 @@
<option name="project" value="LOCAL" /> <option name="project" value="LOCAL" />
<updated>1724272761629</updated> <updated>1724272761629</updated>
</task> </task>
<option name="localTasksCounter" value="11" /> <task id="LOCAL-00011" summary="Remove open file function, add Show Address Labels with tk.StrVar when remove a not active Tunnel Labels of Active Tunnel removed!">
<option name="closed" value="true" />
<created>1724371229008</created>
<option name="number" value="00011" />
<option name="presentableId" value="LOCAL-00011" />
<option name="project" value="LOCAL" />
<updated>1724371229008</updated>
</task>
<option name="localTasksCounter" value="12" />
<servers /> <servers />
</component> </component>
<component name="Vcs.Log.Tabs.Properties"> <component name="Vcs.Log.Tabs.Properties">
@ -209,6 +217,7 @@
<MESSAGE value="add file dict_to_address for &#10;address a active Tunnel. Label green pack in Class.&#10;add Class to convert fileoutput as String to Dictionary" /> <MESSAGE value="add file dict_to_address for &#10;address a active Tunnel. Label green pack in Class.&#10;add Class to convert fileoutput as String to Dictionary" />
<MESSAGE value="add Class StartStopBTN to wg_func.py" /> <MESSAGE value="add Class StartStopBTN to wg_func.py" />
<MESSAGE value="Set Style to Clam&#10;Improved layout of widgets" /> <MESSAGE value="Set Style to Clam&#10;Improved layout of widgets" />
<option name="LAST_COMMIT_MESSAGE" value="Set Style to Clam&#10;Improved layout of widgets" /> <MESSAGE value="Remove open file function, add Show Address Labels with tk.StrVar when remove a not active Tunnel Labels of Active Tunnel removed!" />
<option name="LAST_COMMIT_MESSAGE" value="Remove open file function, add Show Address Labels with tk.StrVar when remove a not active Tunnel Labels of Active Tunnel removed!" />
</component> </component>
</project> </project>

View File

@ -1,3 +0,0 @@
192.168.178.158/24
192.168.178.1,
rj2cexasg9b9oydd.myfritz.net:54775

View File

@ -131,7 +131,7 @@ class FrameWidgets(ttk.Frame):
os.system('nmcli connection delete ' + str(select_tl)) os.system('nmcli connection delete ' + str(select_tl))
self.l_box.delete(self.select_tunnel[0]) self.l_box.delete(self.select_tunnel[0])
os.remove(os.environ['HOME'] + '/tester/' + str(select_tl) + '.conf') os.remove(os.environ['HOME'] + '/tester/' + str(select_tl) + '.conf')
if self.a != '': if self.a != '' and self.a == select_tl:
self.StrVar.set(value='') self.StrVar.set(value='')
StartStopBTN.button_start(self) StartStopBTN.button_start(self)
self.l_box.update() self.l_box.update()

View File

@ -187,11 +187,8 @@ class ImportTunnel:
wg_read = os.environ['HOME'] + '/tester/' + str(self.a) + '.conf' wg_read = os.environ['HOME'] + '/tester/' + str(self.a) + '.conf'
file = open(wg_read, 'r') file = open(wg_read, 'r')
data = ConToDict.covert_to_dict(file) data = ConToDict.covert_to_dict(file)
self.add = tk.StringVar()
self.add.set('Address: ' + data[0]) self.add.set('Address: ' + data[0])
self.DNS = tk.StringVar()
self.DNS.set(' DNS: ' + data[1]) self.DNS.set(' DNS: ' + data[1])
self.enp = tk.StringVar()
self.enp.set('Endpoint: ' + data[2]) self.enp.set('Endpoint: ' + data[2])
ShowAddress.show_data(self) ShowAddress.show_data(self)
file.close() file.close()