Installers will support other systems again
Installer is now finished clean with wrong password Rename wg_main to wirepy
This commit is contained in:
parent
13832d916f
commit
5302aae807
@ -8,6 +8,15 @@ My standard System: Linux Mint 22 Cinnamon
|
|||||||
- for loops with lists replaced by List Comprehensions
|
- for loops with lists replaced by List Comprehensions
|
||||||
- Crypt and Decrypt Config Files in ~/.config/wire_py
|
- Crypt and Decrypt Config Files in ~/.config/wire_py
|
||||||
|
|
||||||
|
|
||||||
|
### Added
|
||||||
|
07-04-0725
|
||||||
|
|
||||||
|
- Installers will support other systems again
|
||||||
|
- Installer is now finished clean with wrong password
|
||||||
|
- Rename wg_main to wirepy
|
||||||
|
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
03-03-2025
|
03-03-2025
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
[Desktop Entry]
|
[Desktop Entry]
|
||||||
Type=Application
|
Type=Application
|
||||||
Name=Wire-Py
|
Name=Wire-Py
|
||||||
Exec=/usr/local/bin/wg_main.py
|
Exec=/usr/local/bin/wirepy.py
|
||||||
Terminal=false
|
Terminal=false
|
||||||
Categories=Network;
|
Categories=Network;
|
||||||
Icon=/usr/share/icons/wp-icons/128/wg_vpn.png
|
Icon=/usr/share/icons/wp-icons/128/wg_vpn.png
|
@ -1,4 +1,4 @@
|
|||||||
""" Classes Method and functions for lx apps """
|
''' Classes Method and functions for lx apps '''
|
||||||
|
|
||||||
import gettext
|
import gettext
|
||||||
import locale
|
import locale
|
||||||
@ -15,7 +15,7 @@ import requests
|
|||||||
|
|
||||||
|
|
||||||
APP = 'wirepy'
|
APP = 'wirepy'
|
||||||
LOCALE_DIR = "/usr/share/locale/"
|
LOCALE_DIR = '/usr/share/locale/'
|
||||||
locale.bindtextdomain(APP, LOCALE_DIR)
|
locale.bindtextdomain(APP, LOCALE_DIR)
|
||||||
gettext.bindtextdomain(APP, LOCALE_DIR)
|
gettext.bindtextdomain(APP, LOCALE_DIR)
|
||||||
gettext.textdomain(APP)
|
gettext.textdomain(APP)
|
||||||
@ -110,7 +110,7 @@ class UOS:
|
|||||||
def username():
|
def username():
|
||||||
logname = str(Path.home())[6:]
|
logname = str(Path.home())[6:]
|
||||||
file = Path.home() / '/tmp/.loguser'
|
file = Path.home() / '/tmp/.loguser'
|
||||||
with open(file, "w") as f:
|
with open(file, 'w') as f:
|
||||||
f.write(logname)
|
f.write(logname)
|
||||||
|
|
||||||
|
|
||||||
|
100
install
100
install
@ -9,29 +9,41 @@ install_file_with(){
|
|||||||
mkdir -p ~/.config/wire_py && touch ~/.config/wire_py/keys && cp -u settings ~/.config/wire_py/ && \
|
mkdir -p ~/.config/wire_py && touch ~/.config/wire_py/keys && cp -u settings ~/.config/wire_py/ && \
|
||||||
mkdir -p ~/.config/systemd/user && cp -u wg_start.service ~/.config/systemd/user/ && \
|
mkdir -p ~/.config/systemd/user && cp -u wg_start.service ~/.config/systemd/user/ && \
|
||||||
systemctl --user enable wg_start.service
|
systemctl --user enable wg_start.service
|
||||||
sudo cp -f org.sslcrypt.policy /usr/share/polkit-1/actions/ && \
|
sudo cp -f org.sslcrypt.policy /usr/share/polkit-1/actions/
|
||||||
|
if [ $? -ne 0 ]
|
||||||
|
then
|
||||||
|
systemctl --user disable wg_start.service
|
||||||
|
rm -r ~/.config/wire_py && rm -r ~/.config/systemd
|
||||||
|
exit 0
|
||||||
|
else
|
||||||
sudo apt install python3-tk && \
|
sudo apt install python3-tk && \
|
||||||
sudo cp -fv wg_main.py start_wg.py cls_mth_fc.py ssl_encrypt.py ssl_decrypt.py /usr/local/bin/ && \
|
sudo cp -fv wirepy.py start_wg.py cls_mth_fc.py ssl_encrypt.py ssl_decrypt.py /usr/local/bin/ && \
|
||||||
sudo cp -uR wp-icons lx-icons /usr/share/icons/ && sudo cp -uR TK-Themes /usr/share/ && \
|
sudo cp -uR wp-icons lx-icons /usr/share/icons/ && sudo cp -uR TK-Themes /usr/share/ && \
|
||||||
sudo cp -u languages/de/*.mo /usr/share/locale/de/LC_MESSAGES/ && \
|
sudo cp -u languages/de/*.mo /usr/share/locale/de/LC_MESSAGES/ && \
|
||||||
sudo ln -sf /usr/local/bin/wg_main.py /usr/local/bin/wirepy && \
|
|
||||||
sudo cp -f Wire-Py.desktop /usr/share/applications/
|
sudo cp -f Wire-Py.desktop /usr/share/applications/
|
||||||
|
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
install_arch_d(){
|
install_arch_d(){
|
||||||
clear
|
clear
|
||||||
|
mkdir -p ~/.config/wire_py && touch ~/.config/wire_py/keys && cp -u settings ~/.config/wire_py/ && \
|
||||||
|
mkdir -p ~/.config/systemd/user && cp -u wg_start.service ~/.config/systemd/user/ && \
|
||||||
|
systemctl --user enable wg_start.service
|
||||||
|
sudo cp -f org.sslcrypt.policy /usr/share/polkit-1/actions/
|
||||||
|
if [ $? -ne 0 ]
|
||||||
|
then
|
||||||
|
systemctl --user disable wg_start.service
|
||||||
|
rm -r ~/.config/wire_py && rm -r ~/.config/systemd
|
||||||
|
exit 0
|
||||||
|
else
|
||||||
sudo pacman -S --noconfirm tk python3 python-requests && \
|
sudo pacman -S --noconfirm tk python3 python-requests && \
|
||||||
sudo cp -u wg_main.py start_wg.py cls_mth_fc.py && \
|
sudo cp -fv wirepy.py start_wg.py cls_mth_fc.py ssl_encrypt.py ssl_decrypt.py /usr/local/bin/ && \
|
||||||
sudo mkdir -p /etc/wire_py && sudo touch /etc/wire_py/keys && sudo cp -u settings /etc/wire_py/ && \
|
|
||||||
sudo cp -uR wp-icons lx-icons /usr/share/icons/ && sudo cp -uR TK-Themes /usr/share/ && \
|
sudo cp -uR wp-icons lx-icons /usr/share/icons/ && sudo cp -uR TK-Themes /usr/share/ && \
|
||||||
sudo chown -R root:root /etc/wire_py && sudo chmod 755 /etc/wire_py && \
|
|
||||||
sudo cp -u languages/de/*.mo /usr/share/locale/de/LC_MESSAGES/ && \
|
sudo cp -u languages/de/*.mo /usr/share/locale/de/LC_MESSAGES/ && \
|
||||||
sudo ln -sf /usr/bin/wirepy.py /usr/local/bin/wirepy && \
|
sudo cp -f Wire-Py.desktop /usr/share/applications/
|
||||||
sudo cp -u org.wirepy.policy /usr/share/polkit-1/actions/ && \
|
|
||||||
sudo cp -u Wire-Py.desktop /usr/share/applications/ && \
|
fi
|
||||||
sudo cp -u org.sslcrypt.policy /usr/share/polkit-1/actions/ && \
|
|
||||||
sudo cp -u wg_start.service /lib/systemd/system/ && \
|
|
||||||
sudo systemctl enable wg_start.service
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if grep -i 'debian' /etc/os-release > /dev/null 2>&1
|
if grep -i 'debian' /etc/os-release > /dev/null 2>&1
|
||||||
@ -40,9 +52,7 @@ if grep -i 'debian' /etc/os-release > /dev/null 2>&1
|
|||||||
if grep 'sudo' /tmp/isgroup
|
if grep 'sudo' /tmp/isgroup
|
||||||
then
|
then
|
||||||
install_file_with
|
install_file_with
|
||||||
|
|
||||||
else
|
else
|
||||||
|
|
||||||
echo -e "$BLUE"The installer found that they are not in the group sudo.""
|
echo -e "$BLUE"The installer found that they are not in the group sudo.""
|
||||||
echo -e "with "$RED"su -"$BLUE" "they can enter the root shell in which they then""
|
echo -e "with "$RED"su -"$BLUE" "they can enter the root shell in which they then""
|
||||||
echo -e "enter "$GREEN""usermod -aG sudo $USER.""$BLUE""
|
echo -e "enter "$GREEN""usermod -aG sudo $USER.""$BLUE""
|
||||||
@ -50,14 +60,13 @@ if grep -i 'debian' /etc/os-release > /dev/null 2>&1
|
|||||||
read -n 1 -s -r -p $"To close the Window press a button"
|
read -n 1 -s -r -p $"To close the Window press a button"
|
||||||
clear
|
clear
|
||||||
exit 0
|
exit 0
|
||||||
fi
|
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
elif grep -i 'mint\|ubuntu\|pop|' /etc/os-release > /dev/null 2>&1
|
elif grep -i 'mint\|ubuntu\|pop|' /etc/os-release > /dev/null 2>&1
|
||||||
then
|
then
|
||||||
install_file_with
|
install_file_with
|
||||||
|
|
||||||
|
|
||||||
elif grep -i 'arch' /etc/os-release > /dev/null 2>&1
|
elif grep -i 'arch' /etc/os-release > /dev/null 2>&1
|
||||||
then
|
then
|
||||||
groups > /tmp/isgroup
|
groups > /tmp/isgroup
|
||||||
@ -85,41 +94,47 @@ elif grep -i '|manjaro\|garuda\|endeavour|' /etc/os-release > /dev/null 2>&1
|
|||||||
then
|
then
|
||||||
install_arch_d
|
install_arch_d
|
||||||
|
|
||||||
|
|
||||||
elif grep -i 'fedora' /etc/os-release > /dev/null 2>&1
|
elif grep -i 'fedora' /etc/os-release > /dev/null 2>&1
|
||||||
then
|
then
|
||||||
if ! which python3-tkinter &> /dev/null
|
clear
|
||||||
then sudo dnf install python3-tkinter -y
|
mkdir -p ~/.config/wire_py && touch ~/.config/wire_py/keys && cp -u settings ~/.config/wire_py/ && \
|
||||||
|
mkdir -p ~/.config/systemd/user && cp -u wg_start.service ~/.config/systemd/user/ && \
|
||||||
sudo cp -u wg_main.py start_wg.py cls_mth_fc.py && \
|
systemctl --user enable wg_start.service
|
||||||
sudo mkdir -p /etc/wire_py && sudo touch /etc/wire_py/keys && \
|
sudo cp -f org.sslcrypt.policy /usr/share/polkit-1/actions/
|
||||||
sudo cp -u settings /etc/wire_py/ && \
|
if [ $? -ne 0 ]
|
||||||
sudo cp -u languages/de/*.mo /usr/share/locale/de/LC_MESSAGES/ && \
|
then
|
||||||
|
systemctl --user disable wg_start.service
|
||||||
|
rm -r ~/.config/wire_py && rm -r ~/.config/systemd
|
||||||
|
exit 0
|
||||||
|
else
|
||||||
|
sudo dnf install python3-tkinter -y
|
||||||
|
sudo cp -fv wirepy.py start_wg.py cls_mth_fc.py ssl_encrypt.py ssl_decrypt.py /usr/local/bin/ && \
|
||||||
sudo cp -uR wp-icons lx-icons /usr/share/icons/ && sudo cp -uR TK-Themes /usr/share/ && \
|
sudo cp -uR wp-icons lx-icons /usr/share/icons/ && sudo cp -uR TK-Themes /usr/share/ && \
|
||||||
sudo chown -R root:root /etc/wire_py && sudo chmod 755 /etc/wire_py && \
|
sudo cp -u languages/de/*.mo /usr/share/locale/de/LC_MESSAGES/ && \
|
||||||
sudo ln -sf /usr/bin/wirepy.py /usr/local/bin/wirepy && \
|
sudo cp -f Wire-Py.desktop /usr/share/applications/
|
||||||
sudo cp -u org.wirepy.policy /usr/share/polkit-1/actions/ && \
|
|
||||||
sudo cp -u Wire-Py.desktop /usr/share/applications/ && \
|
|
||||||
sudo cp -u wg_start.service /lib/systemd/system/ && \
|
|
||||||
sudo systemctl enable wg_start.service
|
|
||||||
|
|
||||||
fi
|
fi
|
||||||
elif grep -i 'suse' /etc/os-release > /dev/null 2>&1
|
elif grep -i 'suse' /etc/os-release > /dev/null 2>&1
|
||||||
then
|
then
|
||||||
if ! which python311-tk &> /dev/null
|
clear
|
||||||
then sudo zypper install python311-tk
|
mkdir -p ~/.config/wire_py && touch ~/.config/wire_py/keys && cp -u settings ~/.config/wire_py/ && \
|
||||||
sudo cp -u wg_main.py start_wg.py cls_mth_fc.py && \
|
mkdir -p ~/.config/systemd/user && cp -u wg_start.service ~/.config/systemd/user/ && \
|
||||||
sudo mkdir -p /etc/wire_py && sudo touch /etc/wire_py/keys && \
|
systemctl --user enable wg_start.service
|
||||||
sudo cp -u settings /etc/wire_py/ && \
|
sudo cp -f org.sslcrypt.policy /usr/share/polkit-1/actions/
|
||||||
sudo cp -u languages/de/*.mo /usr/share/locale/de/LC_MESSAGES/ && \
|
if [ $? -ne 0 ]
|
||||||
|
then
|
||||||
|
systemctl --user disable wg_start.service
|
||||||
|
rm -r ~/.config/wire_py && rm -r ~/.config/systemd
|
||||||
|
exit 0
|
||||||
|
else
|
||||||
|
sudo zypper install python311-tk && \
|
||||||
|
sudo cp -fv wirepy.py start_wg.py cls_mth_fc.py ssl_encrypt.py ssl_decrypt.py /usr/local/bin/ && \
|
||||||
sudo cp -uR wp-icons lx-icons /usr/share/icons/ && sudo cp -uR TK-Themes /usr/share/ && \
|
sudo cp -uR wp-icons lx-icons /usr/share/icons/ && sudo cp -uR TK-Themes /usr/share/ && \
|
||||||
sudo chown -R root:root /etc/wire_py && sudo chmod 755 /etc/wire_py && \
|
sudo cp -u languages/de/*.mo /usr/share/locale/de/LC_MESSAGES/ && \
|
||||||
sudo ln -sf /usr/bin/wirepy.py /usr/local/bin/wirepy && \
|
sudo cp -f Wire-Py.desktop /usr/share/applications/
|
||||||
sudo cp -u org.wirepy.policy /usr/share/polkit-1/actions/ && \
|
|
||||||
sudo cp -u Wire-Py.desktop /usr/share/applications/ && \
|
|
||||||
sudo cp -u wg_start.service /lib/systemd/system/ && \
|
|
||||||
sudo systemctl enable wg_start.service
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
else
|
else
|
||||||
clear
|
clear
|
||||||
echo $"Your System could not be determined."
|
echo $"Your System could not be determined."
|
||||||
@ -127,6 +142,7 @@ else
|
|||||||
read -n 1 -s -r -p $"To close the window press a button"
|
read -n 1 -s -r -p $"To close the window press a button"
|
||||||
clear
|
clear
|
||||||
exit 0
|
exit 0
|
||||||
|
|
||||||
fi
|
fi
|
||||||
#clear
|
#clear
|
||||||
read -n 1 -s -r -p $"To close the Window press a button"
|
read -n 1 -s -r -p $"To close the Window press a button"
|
||||||
|
@ -25,13 +25,13 @@ wg_tips = Tipi.if_tip(wg_set)
|
|||||||
dirname = Path('/tmp/tlecdcwg/')
|
dirname = Path('/tmp/tlecdcwg/')
|
||||||
|
|
||||||
''' 1 = 1. Year, 09 = Month of the Year, 2924 = Day and Year of the Year '''
|
''' 1 = 1. Year, 09 = Month of the Year, 2924 = Day and Year of the Year '''
|
||||||
version = 'v. 2.03.0325'
|
version = 'v. 2.04.0725'
|
||||||
|
|
||||||
res = GiteaUpdate.api_down('https://git.ilunix.de/api/v1/repos/punix/Wire-Py/releases', version)
|
res = GiteaUpdate.api_down('https://git.ilunix.de/api/v1/repos/punix/Wire-Py/releases', version)
|
||||||
|
|
||||||
''' Translate '''
|
''' Translate '''
|
||||||
APP = 'wirepy'
|
APP = 'wirepy'
|
||||||
LOCALE_DIR = "/usr/share/locale/"
|
LOCALE_DIR = '/usr/share/locale/'
|
||||||
locale.bindtextdomain(APP, LOCALE_DIR)
|
locale.bindtextdomain(APP, LOCALE_DIR)
|
||||||
gettext.bindtextdomain(APP, LOCALE_DIR)
|
gettext.bindtextdomain(APP, LOCALE_DIR)
|
||||||
gettext.textdomain(APP)
|
gettext.textdomain(APP)
|
||||||
@ -62,7 +62,8 @@ def signalHandler(signum, frame):
|
|||||||
signal.signal(signal.SIGINT, signalHandler)
|
signal.signal(signal.SIGINT, signalHandler)
|
||||||
signal.signal(signal.SIGTERM, signalHandler)
|
signal.signal(signal.SIGTERM, signalHandler)
|
||||||
signal.signal(signal.SIGHUP, signalHandler)
|
signal.signal(signal.SIGHUP, signalHandler)
|
||||||
class MainWindow(tk.Tk):
|
|
||||||
|
class Wirepy(tk.Tk):
|
||||||
|
|
||||||
def __init__(self, *args, **kwargs):
|
def __init__(self, *args, **kwargs):
|
||||||
super().__init__(*args, **kwargs)
|
super().__init__(*args, **kwargs)
|
||||||
@ -153,7 +154,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
''' Set dark or light '''
|
''' Set dark or light '''
|
||||||
|
|
||||||
def theme_change_light():
|
def theme_change_light():
|
||||||
if self.tk.call("ttk::style", "theme", "use") == "water-dark":
|
if self.tk.call('ttk::style', 'theme', 'use') == 'water-dark':
|
||||||
''' Set light theme '''
|
''' Set light theme '''
|
||||||
self.tk.call('set_theme', 'light')
|
self.tk.call('set_theme', 'light')
|
||||||
with open(wg_set, 'r') as theme_set2:
|
with open(wg_set, 'r') as theme_set2:
|
||||||
@ -164,7 +165,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
self.color_label()
|
self.color_label()
|
||||||
|
|
||||||
def theme_change_dark():
|
def theme_change_dark():
|
||||||
if not self.tk.call("ttk::style", "theme", "use") == "water-dark":
|
if not self.tk.call('ttk::style', 'theme', 'use') == 'water-dark':
|
||||||
''' Set dark theme '''
|
''' Set dark theme '''
|
||||||
self.tk.call('set_theme', 'dark')
|
self.tk.call('set_theme', 'dark')
|
||||||
with open(wg_set, 'r') as theme_set2:
|
with open(wg_set, 'r') as theme_set2:
|
||||||
@ -178,7 +179,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
def link_btn():
|
def link_btn():
|
||||||
webbrowser.open('https://git.ilunix.de/punix/Wire-Py')
|
webbrowser.open('https://git.ilunix.de/punix/Wire-Py')
|
||||||
|
|
||||||
"""img_w, img_i, w_title, w_txt , txt2, com hand over"""
|
''' img_w, img_i, w_title, w_txt , txt2, com hand over '''
|
||||||
iw = r'/usr/share/icons/wp-icons/48/wg_vpn.png'
|
iw = r'/usr/share/icons/wp-icons/48/wg_vpn.png'
|
||||||
ii = r'/usr/share/icons/wp-icons/48/wg_msg.png'
|
ii = r'/usr/share/icons/wp-icons/48/wg_msg.png'
|
||||||
wt = _('Info')
|
wt = _('Info')
|
||||||
@ -202,11 +203,11 @@ class FrameWidgets(ttk.Frame):
|
|||||||
self.version_lb.grid(column=0, row=0, rowspan=4, padx=10)
|
self.version_lb.grid(column=0, row=0, rowspan=4, padx=10)
|
||||||
|
|
||||||
def version_enter(event):
|
def version_enter(event):
|
||||||
""" The mouse moves into the Version widget """
|
''' The mouse moves into the Version widget '''
|
||||||
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, f'Version: {version[2:]}')
|
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, f'Version: {version[2:]}')
|
||||||
|
|
||||||
def version_leave(_):
|
def version_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves from the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -214,11 +215,11 @@ class FrameWidgets(ttk.Frame):
|
|||||||
self.options_btn.grid(column=1, columnspan=1, row=0)
|
self.options_btn.grid(column=1, columnspan=1, row=0)
|
||||||
|
|
||||||
def sets_enter(event):
|
def sets_enter(event):
|
||||||
""" The mouse moves into the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('Click for Settings'))
|
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('Click for Settings'))
|
||||||
|
|
||||||
def sets_leave(_):
|
def sets_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves from the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -256,11 +257,11 @@ class FrameWidgets(ttk.Frame):
|
|||||||
self.updates_lb.configure(text=_('Update search off'))
|
self.updates_lb.configure(text=_('Update search off'))
|
||||||
|
|
||||||
def disable_enter(event):
|
def disable_enter(event):
|
||||||
""" The mouse moves into the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('Updates you have disabled'))
|
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('Updates you have disabled'))
|
||||||
|
|
||||||
def disable_leave(_):
|
def disable_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves from the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -272,11 +273,11 @@ class FrameWidgets(ttk.Frame):
|
|||||||
self.updates_lb.configure(text=_('No Updates'))
|
self.updates_lb.configure(text=_('No Updates'))
|
||||||
|
|
||||||
def congratulations_enter(event):
|
def congratulations_enter(event):
|
||||||
""" The mouse moves into the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('Congratulations! Wire-Py is up to date'))
|
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('Congratulations! Wire-Py is up to date'))
|
||||||
|
|
||||||
def congratulations_leave(_):
|
def congratulations_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -291,11 +292,11 @@ class FrameWidgets(ttk.Frame):
|
|||||||
self.update_btn.grid(column=4, columnspan=3, row=0, padx=0)
|
self.update_btn.grid(column=4, columnspan=3, row=0, padx=0)
|
||||||
|
|
||||||
def download_enter(event):
|
def download_enter(event):
|
||||||
""" The mouse moves into the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('Click to download new version'))
|
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('Click to download new version'))
|
||||||
|
|
||||||
def download_leave(_):
|
def download_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -393,7 +394,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('You must first import\na Wireguard tunnel'))
|
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('You must first import\na Wireguard tunnel'))
|
||||||
|
|
||||||
def list_empty_leave(_):
|
def list_empty_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -402,7 +403,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('Select a Tunnel'))
|
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('Select a Tunnel'))
|
||||||
|
|
||||||
def list_not_empty_leave(_):
|
def list_not_empty_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -442,7 +443,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('Click to import a Wireguard Tunnel'))
|
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('Click to import a Wireguard Tunnel'))
|
||||||
|
|
||||||
def imp_leave(_):
|
def imp_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -488,7 +489,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('No tunnels to start in the list'))
|
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('No tunnels to start in the list'))
|
||||||
|
|
||||||
def empty_list_start_leave(_):
|
def empty_list_start_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -550,7 +551,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('No tunnels to delete in the list'))
|
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('No tunnels to delete in the list'))
|
||||||
|
|
||||||
def empty_list_leave(_):
|
def empty_list_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -560,7 +561,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
_('Click to delete a Wireguard Tunnel\nSelect from the list!'))
|
_('Click to delete a Wireguard Tunnel\nSelect from the list!'))
|
||||||
|
|
||||||
def del_leave(_):
|
def del_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -580,7 +581,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('No Tunnels in List for Export'))
|
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('No Tunnels in List for Export'))
|
||||||
|
|
||||||
def empty_list_leave(_):
|
def empty_list_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -590,7 +591,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
_(' Click to export all\nWireguard Tunnel to Zipfile'))
|
_(' Click to export all\nWireguard Tunnel to Zipfile'))
|
||||||
|
|
||||||
def exp_leave(_):
|
def exp_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -608,7 +609,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
self.lb_rename.config(state='disable')
|
self.lb_rename.config(state='disable')
|
||||||
|
|
||||||
def rename_no_active_leave(_):
|
def rename_no_active_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -623,7 +624,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
_('To rename a tunnel, you need to\nselect a tunnel from the list'))
|
_('To rename a tunnel, you need to\nselect a tunnel from the list'))
|
||||||
|
|
||||||
def rename_leave(_):
|
def rename_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -729,7 +730,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
'tunnel in the list,to use the autostart'))
|
'tunnel in the list,to use the autostart'))
|
||||||
|
|
||||||
def chk_leave(_):
|
def chk_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -740,7 +741,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
_('To use the autostart, enable this Checkbox'))
|
_('To use the autostart, enable this Checkbox'))
|
||||||
|
|
||||||
def chk_a_leave(_):
|
def chk_a_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -757,7 +758,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
_('To use the autostart, a tunnel must be selected from the list'))
|
_('To use the autostart, a tunnel must be selected from the list'))
|
||||||
|
|
||||||
def chk_a_leave(_):
|
def chk_a_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -849,7 +850,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
'Checkbox'))
|
'Checkbox'))
|
||||||
|
|
||||||
def chk_a_leave(_):
|
def chk_a_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -859,7 +860,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
_('List of available tunnels'))
|
_('List of available tunnels'))
|
||||||
|
|
||||||
def list_info_leave(_):
|
def list_info_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -870,7 +871,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
'Tunnel\nSelect from the list!'))
|
'Tunnel\nSelect from the list!'))
|
||||||
|
|
||||||
def del_leave(_):
|
def del_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -881,7 +882,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
'all\nWireguard Tunnel to Zipfile'))
|
'all\nWireguard Tunnel to Zipfile'))
|
||||||
|
|
||||||
def exp_leave(_):
|
def exp_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -892,7 +893,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
'select a tunnel from the list'))
|
'select a tunnel from the list'))
|
||||||
|
|
||||||
def rename_leave(_):
|
def rename_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -1045,7 +1046,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('Click to stop selected Wireguard Tunnel'))
|
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('Click to stop selected Wireguard Tunnel'))
|
||||||
|
|
||||||
def stop_leave(_):
|
def stop_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -1062,7 +1063,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('No tunnels to start in the list'))
|
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('No tunnels to start in the list'))
|
||||||
|
|
||||||
def empty_list_start_leave(_):
|
def empty_list_start_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -1071,7 +1072,7 @@ class FrameWidgets(ttk.Frame):
|
|||||||
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('Click to start selected Wireguard Tunnel'))
|
window.my_tool_tip = MyToolTip(event.x_root, event.y_root, _('Click to start selected Wireguard Tunnel'))
|
||||||
|
|
||||||
def start_leave(_):
|
def start_leave(_):
|
||||||
""" The mouse moves from the entry widget """
|
''' The mouse moves into the entry widget '''
|
||||||
''' Remove Tool-Tip '''
|
''' Remove Tool-Tip '''
|
||||||
window.my_tool_tip.destroy()
|
window.my_tool_tip.destroy()
|
||||||
|
|
||||||
@ -1193,7 +1194,7 @@ class MyToolTip(tk.Toplevel):
|
|||||||
|
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
window = MainWindow()
|
window = Wirepy()
|
||||||
"""
|
"""
|
||||||
the hidden files are hidden in Filedialog
|
the hidden files are hidden in Filedialog
|
||||||
"""
|
"""
|
Loading…
x
Reference in New Issue
Block a user