1+ #!/usr/bin/python3
2+ """ Copyright© 2023-2024 LinuxUsersLinuxMint
3+ PyAppDevKit Tüm Hakları GPL(Genel Kamu Lisansı) altında korunmaktadır.
4+ PyAppDevKit All Rights Reserved under the GPL(General Public License).
5+ Bu Yazılımın Bir Kopyası GİTHUB da yayınlanmaktadır Görüntülemek için: https://github.com/LinuxUsersLinuxMint/PyAppDevKit
6+ A Copy of This Software is published on GITHUB To view: https://github.com/LinuxUsersLinuxMint/PyAppDevKit"""
7+
8+ import os , time , platform
9+ from PyAppDevKit .InfoLib .pyappdevkit_info import *
10+
11+ def error_msg (error_dialog ):
12+ print (error_dialog )
13+
14+ def exit_program_dialog_time (exit_dialog_msg ,userTime ):
15+ print (exit_dialog_msg )
16+ userTime = int (userTime )
17+ time .sleep (userTime )
18+ if platform .system () == "Windows" :
19+ os .system ("exit" )
20+ else :
21+ exit ()
22+
23+ def exit_program_time (userTime ):
24+ time .sleep (userTime )
25+ userTime = int (userTime )
26+ if platform .system () == "Windows" :
27+ os .system ("exit" )
28+ else :
29+ exit ()
30+
31+ def exit_program_dialog (exit_dialog_msg ):
32+ print (exit_dialog_msg )
33+ if platform .system () == "Windows" :
34+ os .system ("exit" )
35+ else :
36+ exit ()
37+
38+ """ Example Dialog (ExitSelectDialog): "Select the method to exit the program (0: Dialogue and Time entry, 1: Time entry only, 2: Dialogue entry only, 3: Normal exit (old style)): "
39+ Example Dialog (userTimeDialog): "After how many seconds should the program be closed?: "
40+ Example Dialog (exitDialog): "Exit program..."
41+ Example Dialog (errormsgDialog): "Invalid Command!" """
42+
43+ def all_exit (ExitSelectDialog ,userTimeDialog ,exitDialog ,errormsgDialog ):
44+ exit_select = int (input (ExitSelectDialog ))
45+ exit_select = int (exit_select )
46+ if exit_select == 0 :
47+ userTime = input (userTimeDialog )
48+ exit_program_dialog_time (exitDialog , userTime )
49+ elif exit_select == 1 :
50+ userTime = input (userTimeDialog )
51+ exit_program_time (userTime )
52+ elif exit_select == 2 :
53+ exit_program_dialog (exitDialog )
54+ elif exit_select == 3 :
55+ exit ()
56+ else :
57+ print (errormsgDialog )
58+
59+ def program_welcome_msg (welcome_msg ,cfg ):
60+ print (welcome_msg )
61+ if cfg == 1 :
62+ LibAbout ()
63+ elif cfg == 0 :
64+ pass
65+
66+ def program_info (programnamedialog ,program_name ,programversiondialog ,program_version ,programsupportosdialog ,program_support_os ,programlicencedialog ,program_licence ,programauthordialog ,program_author ,programauthorwebsitedialog ,program_author_web_site ,programreleasedatedialog ,program_rs_date ,programlastupdatedatedialog ,program_last_update_date ):
67+ print ("{0} {1}" . format (programnamedialog ,program_name ))
68+ print ("{0} {1}" . format (programversiondialog ,program_version ))
69+ print ("{0} {1}" . format (programsupportosdialog ,program_support_os ))
70+ print ("{0} {1}" . format (programlicencedialog ,program_licence ))
71+ print ("{0} {1}" . format (programauthordialog ,program_author ))
72+ print ("{0} {1}" . format (programauthorwebsitedialog ,program_author_web_site ))
73+ print ("{0} {1}" . format (programreleasedatedialog ,program_rs_date ))
74+ print ("{0} {1}" . format (programlastupdatedatedialog ,program_last_update_date ))
0 commit comments