diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..0611a0e
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,6 @@
+UBTime
+main.cpp
+ubl-settings-datetime.glade~
+test.cpp
+ubl-settings-datetime
+a.out
\ No newline at end of file
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..9ca9003
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,71 @@
+#!/usr/bin/make -f
+
+pkgname=ubl-settings-datetime
+
+all: uninstall init build check install clean
+
+init:
+ mkdir -p /usr/share/${pkgname}/{images,ui,reg}/;
+
+uninstall:
+ @for size in 16 32 48; do \
+ rm -f "/usr/share/icons/hicolor/$${size}x$${size}/apps/ublinux-datetime-settings.svg"; \
+ rm -f "/usr/share/icons/hicolor/$${size}x$${size}/apps/ublinux-datetime-settings.png"; \
+ done;
+ @for file_po in *.po; do \
+ lang=$${file_po##*_};lang=$${lang%.*}; \
+ file_mo=$${file_po##*/}; file_mo="$${file_mo%_*.po}.mo"; \
+ path_file_mo="/usr/share/locale/$${lang}/LC_MESSAGES/$${file_mo}"; \
+ rm -f "/usr/share/locale/$${lang}/LC_MESSAGES/$${file_mo}"; \
+ done;
+ rm -f /usr/bin/${pkgname}; \
+ rm -rf /usr/bin/${pkgname}/reg; \
+ rm -f /usr/share/${pkgname}/ui/${pkgname}.glade; \
+ rm -f /usr/share/applications/${pkgname}.desktop; \
+ rm -f /usr/share/${pkgname}/images/ublinux-datetime-settings.svg; \
+ rm -f /usr/share/${pkgname}/images/ublinux-datetime-settings.png; \
+ rm -f /usr/share/polkit-1/actions/org.freedesktop.policykit.${pkgname}.pkexec.policy; \
+
+build:
+ echo "Build"; \
+ g++ -O2 -std=c++20 -lstdc++ -o ubl-settings-datetime ubl-settings-datetime.cpp `pkg-config --cflags --libs gtkmm-3.0` -Wl,-export-dynamic -g; \
+
+check:
+ echo "Check"; \
+
+install:
+ @for size in 16 32 48; do \
+ install -dm755 /usr/share/icons/hicolor/$${size}x$${size}/apps; \
+ rsvg-convert -w $$size -h $$size -f svg --keep-image-data ${pkgname}.svg -o "/usr/share/icons/hicolor/$${size}x$${size}/apps/$${pkgname}.svg"; \
+ done;
+ @for file_po in *.po; do \
+ lang=$${file_po##*_};lang=$${lang%.*}; \
+ install -dm755 /usr/share/locale/$${lang}/LC_MESSAGES; \
+ file_mo=$${file_po##*/}; file_mo="$${file_mo%_*.po}.mo"; \
+ path_file_mo="/usr/share/locale/$${lang}/LC_MESSAGES/$${file_mo}"; \
+ echo $$file_po; \
+ msgfmt "$${file_po}" -v -f -o "$${path_file_mo}"; \
+ done;
+ install -vDm0755 ${pkgname} -t /usr/bin/; \
+ install -vDm0644 ${pkgname}.glade -t /usr/share/${pkgname}/ui/; \
+ install -vDm0644 ${pkgname}.desktop -t /usr/share/applications/; \
+ install -vDm0644 ubl-settings-datetime.svg -t /usr/share/icons/hicolor/scalable/apps/
+ install -vDm0644 ubl-settings-datetime.svg -t /usr/share/${pkgname}/images/; \
+ install -vDm0644 ubl-settings-datetime.png -t /usr/share/${pkgname}/images/; \
+ install -vDm0644 org.freedesktop.policykit.${pkgname}.pkexec.policy -t /usr/share/polkit-1/actions/;
+ install -vDm0644 reg/Africa -t /usr/share/${pkgname}/reg/; \
+ install -vDm0644 reg/America -t /usr/share/${pkgname}/reg/; \
+ install -vDm0644 reg/Antarctica -t /usr/share/${pkgname}/reg/; \
+ install -vDm0644 reg/Arctic -t /usr/share/${pkgname}/reg/; \
+ install -vDm0644 reg/Asia -t /usr/share/${pkgname}/reg/; \
+ install -vDm0644 reg/Atlantic -t /usr/share/${pkgname}/reg/; \
+ install -vDm0644 reg/Australia -t /usr/share/${pkgname}/reg/; \
+ install -vDm0644 reg/Brazil -t /usr/share/${pkgname}/reg/; \
+ install -vDm0644 reg/Chile -t /usr/share/${pkgname}/reg/; \
+ install -vDm0644 reg/Europe -t /usr/share/${pkgname}/reg/; \
+ install -vDm0644 reg/Indian -t /usr/share/${pkgname}/reg/; \
+ install -vDm0644 reg/Mexico -t /usr/share/${pkgname}/reg/; \
+ install -vDm0644 reg/US -t /usr/share/${pkgname}/reg/;
+clean:
+ echo "Clean";
+
\ No newline at end of file
diff --git a/README.md b/README.md
index 8ab6612..ccab309 100644
--- a/README.md
+++ b/README.md
@@ -1,2 +1,8 @@
# ubl-settings-datetime
+
+
+- [ ] Локализация
+- [x] Makefile
+- [ ] Парсинг TimeZone C++
+
diff --git a/org.freedesktop.policykit.ubl-settings-datetime.pkexec.policy b/org.freedesktop.policykit.ubl-settings-datetime.pkexec.policy
new file mode 100644
index 0000000..eb3e5c8
--- /dev/null
+++ b/org.freedesktop.policykit.ubl-settings-datetime.pkexec.policy
@@ -0,0 +1,24 @@
+
+
+
+
+ UBSoft
+ https://ublinux.ru
+
+
+ Run ubl-settings-datetime as root
+ Запуск ubl-settings-datetime с правами root
+ Authentication is required to run the ubl-settings-datetime
+ Требуется авторизация для запуска ubl-settings-datetime с правами root
+
+ auth_admin
+ auth_admin
+ auth_admin
+
+ /home/superadmin/Документы/Проект/ubconfig_new/ubl-settings-datetime/
+ true
+
+
+
diff --git a/reg/Africa b/reg/Africa
new file mode 100644
index 0000000..6afdb1c
--- /dev/null
+++ b/reg/Africa
@@ -0,0 +1,54 @@
+(UTC +00) Lome
+(UTC +00) Bissau
+(UTC +00) Sao_Tome
+(UTC +00) Abidjan
+(UTC +00) Accra
+(UTC +00) Banjul
+(UTC +00) Conakry
+(UTC +00) Ouagadougou
+(UTC +00) Nouakchott
+(UTC +00) Timbuktu
+(UTC +00) Dakar
+(UTC +00) Monrovia
+(UTC +00) Freetown
+(UTC +00) Bamako
+(UTC +01) El_Aaiun
+(UTC +01) Lagos
+(UTC +01) Porto-Novo
+(UTC +01) Algiers
+(UTC +01) Douala
+(UTC +01) Brazzaville
+(UTC +01) Libreville
+(UTC +01) Casablanca
+(UTC +01) Niamey
+(UTC +01) Tunis
+(UTC +01) Luanda
+(UTC +01) Malabo
+(UTC +01) Ceuta
+(UTC +01) Kinshasa
+(UTC +01) Bangui
+(UTC +01) Ndjamena
+(UTC +02) Juba
+(UTC +02) Maseru
+(UTC +02) Khartoum
+(UTC +02) Lubumbashi
+(UTC +02) Tripoli
+(UTC +02) Mbabane
+(UTC +02) Kigali
+(UTC +02) Gaborone
+(UTC +02) Windhoek
+(UTC +02) Maputo
+(UTC +02) Cairo
+(UTC +02) Johannesburg
+(UTC +02) Bujumbura
+(UTC +02) Lusaka
+(UTC +02) Harare
+(UTC +02) Blantyre
+(UTC +03) Djibouti
+(UTC +03) Dar_es_Salaam
+(UTC +03) Kampala
+(UTC +03) Addis_Ababa
+(UTC +03) Mogadishu
+(UTC +03) Asmera
+(UTC +03) Asmara
+(UTC +03) Nairobi
diff --git a/reg/America b/reg/America
new file mode 100644
index 0000000..4eac7b5
--- /dev/null
+++ b/reg/America
@@ -0,0 +1,147 @@
+(UTC -10) Atka
+(UTC -10) Adak
+(UTC -09) Anchorage
+(UTC -09) Metlakatla
+(UTC -09) Juneau
+(UTC -09) Sitka
+(UTC -09) Nome
+(UTC -09) Yakutat
+(UTC -08) Tijuana
+(UTC -08) Santa_Isabel
+(UTC -08) Vancouver
+(UTC -08) Ensenada
+(UTC -08) Los_Angeles
+(UTC -07) Ciudad_Juarez
+(UTC -07) Dawson
+(UTC -07) Hermosillo
+(UTC -07) Phoenix
+(UTC -07) Whitehorse
+(UTC -07) Edmonton
+(UTC -07) Creston
+(UTC -07) Inuvik
+(UTC -07) Mazatlan
+(UTC -07) Shiprock
+(UTC -07) Yellowknife
+(UTC -07) Fort_Nelson
+(UTC -07) Denver
+(UTC -07) Boise
+(UTC -07) Dawson_Creek
+(UTC -07) Cambridge_Bay
+(UTC -06) North_Dakota
+(UTC -06) Knox_IN
+(UTC -06) Costa_Rica
+(UTC -06) Menominee
+(UTC -06) El_Salvador
+(UTC -06) Regina
+(UTC -06) Guatemala
+(UTC -06) Resolute
+(UTC -06) Monterrey
+(UTC -06) Chicago
+(UTC -06) Winnipeg
+(UTC -06) Indiana
+(UTC -06) Rankin_Inlet
+(UTC -06) Merida
+(UTC -06) Tegucigalpa
+(UTC -06) Managua
+(UTC -06) Belize
+(UTC -06) Rainy_River
+(UTC -06) Bahia_Banderas
+(UTC -06) Ojinaga
+(UTC -06) Chihuahua
+(UTC -06) Swift_Current
+(UTC -06) Mexico_City
+(UTC -06) Matamoros
+(UTC -05) Jamaica
+(UTC -05) Montreal
+(UTC -05) Havana
+(UTC -05) Grand_Turk
+(UTC -05) Iqaluit
+(UTC -05) Louisville
+(UTC -05) Guayaquil
+(UTC -05) Lima
+(UTC -05) Coral_Harbour
+(UTC -05) Detroit
+(UTC -05) Port-au-Prince
+(UTC -05) Fort_Wayne
+(UTC -05) Eirunepe
+(UTC -05) Indianapolis
+(UTC -05) Rio_Branco
+(UTC -05) Cancun
+(UTC -05) Nipigon
+(UTC -05) Toronto
+(UTC -05) Panama
+(UTC -05) Indiana
+(UTC -05) New_York
+(UTC -05) Kentucky
+(UTC -05) Pangnirtung
+(UTC -05) Thunder_Bay
+(UTC -05) Bogota
+(UTC -05) Cayman
+(UTC -05) Atikokan
+(UTC -05) Porto_Acre
+(UTC -05) Nassau
+(UTC -04) Anguilla
+(UTC -04) Guadeloupe
+(UTC -04) Puerto_Rico
+(UTC -04) Porto_Velho
+(UTC -04) Guyana
+(UTC -04) Lower_Princes
+(UTC -04) St_Lucia
+(UTC -04) Port_of_Spain
+(UTC -04) Dominica
+(UTC -04) Manaus
+(UTC -04) Thule
+(UTC -04) St_Vincent
+(UTC -04) St_Barthelemy
+(UTC -04) Grenada
+(UTC -04) Marigot
+(UTC -04) Goose_Bay
+(UTC -04) Martinique
+(UTC -04) La_Paz
+(UTC -04) Cuiaba
+(UTC -04) Tortola
+(UTC -04) Virgin
+(UTC -04) Santo_Domingo
+(UTC -04) Antigua
+(UTC -04) Curacao
+(UTC -04) Barbados
+(UTC -04) Blanc-Sablon
+(UTC -04) Aruba
+(UTC -04) Kralendijk
+(UTC -04) Montserrat
+(UTC -04) Campo_Grande
+(UTC -04) Caracas
+(UTC -04) St_Thomas
+(UTC -04) Glace_Bay
+(UTC -04) St_Kitts
+(UTC -04) Moncton
+(UTC -04) Boa_Vista
+(UTC -04) Halifax
+(UTC -03) Buenos_Aires
+(UTC -03) Santarem
+(UTC -03) Araguaina
+(UTC -03) Belem
+(UTC -03) St_Johns
+(UTC -03) Nuuk
+(UTC -03) Cordoba
+(UTC -03) Catamarca
+(UTC -03) Rosario
+(UTC -03) Jujuy
+(UTC -03) Montevideo
+(UTC -03) Punta_Arenas
+(UTC -03) Cayenne
+(UTC -03) Sao_Paulo
+(UTC -03) Santiago
+(UTC -03) Paramaribo
+(UTC -03) Miquelon
+(UTC -03) Godthab
+(UTC -03) Maceio
+(UTC -03) Fortaleza
+(UTC -03) Argentina
+(UTC -03) Mendoza
+(UTC -03) Recife
+(UTC -03) Bahia
+(UTC -03) Asuncion
+(UTC -02) Noronha
+(UTC -01) Scoresbysund
+(UTC +00) Danmarkshavn
diff --git a/reg/Antarctica b/reg/Antarctica
new file mode 100644
index 0000000..2f99849
--- /dev/null
+++ b/reg/Antarctica
@@ -0,0 +1,12 @@
+(UTC -03) Rothera
+(UTC -03) Palmer
+(UTC +00) Troll
+(UTC +03) Syowa
+(UTC +05) Mawson
+(UTC +06) Vostok
+(UTC +07) Davis
+(UTC +10) DumontDUrville
+(UTC +11) Casey
+(UTC +11) Macquarie
+(UTC +13) McMurdo
+(UTC +13) South_Pole
diff --git a/reg/Arctic b/reg/Arctic
new file mode 100644
index 0000000..feba77b
--- /dev/null
+++ b/reg/Arctic
@@ -0,0 +1 @@
+(UTC +01) Longyearbyen
diff --git a/reg/Asia b/reg/Asia
new file mode 100644
index 0000000..57ce91b
--- /dev/null
+++ b/reg/Asia
@@ -0,0 +1,99 @@
+(UTC +02) Beirut
+(UTC +02) Famagusta
+(UTC +02) Nicosia
+(UTC +02) Hebron
+(UTC +02) Tel_Aviv
+(UTC +02) Jerusalem
+(UTC +02) Gaza
+(UTC +03) Amman
+(UTC +03) Bahrain
+(UTC +03) Tehran
+(UTC +03) Baghdad
+(UTC +03) Istanbul
+(UTC +03) Kuwait
+(UTC +03) Riyadh
+(UTC +03) Qatar
+(UTC +03) Damascus
+(UTC +03) Aden
+(UTC +04) Yerevan
+(UTC +04) Baku
+(UTC +04) Dubai
+(UTC +04) Kabul
+(UTC +04) Muscat
+(UTC +04) Tbilisi
+(UTC +05) Kathmandu
+(UTC +05) Samarkand
+(UTC +05) Ashgabat
+(UTC +05) Karachi
+(UTC +05) Katmandu
+(UTC +05) Calcutta
+(UTC +05) Tashkent
+(UTC +05) Yekaterinburg
+(UTC +05) Oral
+(UTC +05) Dushanbe
+(UTC +05) Atyrau
+(UTC +05) Aqtobe
+(UTC +05) Aqtau
+(UTC +05) Qyzylorda
+(UTC +05) Ashkhabad
+(UTC +05) Colombo
+(UTC +05) Kolkata
+(UTC +06) Dhaka
+(UTC +06) Thimphu
+(UTC +06) Rangoon
+(UTC +06) Kashgar
+(UTC +06) Qostanay
+(UTC +06) Almaty
+(UTC +06) Urumqi
+(UTC +06) Yangon
+(UTC +06) Dacca
+(UTC +06) Thimbu
+(UTC +06) Omsk
+(UTC +06) Bishkek
+(UTC +07) Ho_Chi_Minh
+(UTC +07) Phnom_Penh
+(UTC +07) Vientiane
+(UTC +07) Bangkok
+(UTC +07) Krasnoyarsk
+(UTC +07) Novokuznetsk
+(UTC +07) Barnaul
+(UTC +07) Jakarta
+(UTC +07) Saigon
+(UTC +07) Hovd
+(UTC +07) Novosibirsk
+(UTC +07) Tomsk
+(UTC +07) Pontianak
+(UTC +08) Harbin
+(UTC +08) Chungking
+(UTC +08) Ulan_Bator
+(UTC +08) Brunei
+(UTC +08) Singapore
+(UTC +08) Choibalsan
+(UTC +08) Chongqing
+(UTC +08) Macau
+(UTC +08) Ujung_Pandang
+(UTC +08) Manila
+(UTC +08) Kuala_Lumpur
+(UTC +08) Makassar
+(UTC +08) Kuching
+(UTC +08) Macao
+(UTC +08) Shanghai
+(UTC +08) Taipei
+(UTC +08) Ulaanbaatar
+(UTC +08) Irkutsk
+(UTC +08) Hong_Kong
+(UTC +09) Khandyga
+(UTC +09) Seoul
+(UTC +09) Jayapura
+(UTC +09) Chita
+(UTC +09) Pyongyang
+(UTC +09) Yakutsk
+(UTC +09) Tokyo
+(UTC +09) Dili
+(UTC +10) Vladivostok
+(UTC +10) Ust-Nera
+(UTC +11) Srednekolymsk
+(UTC +11) Sakhalin
+(UTC +11) Magadan
+(UTC +12) Anadyr
+(UTC +12) Kamchatka
diff --git a/reg/Atlantic b/reg/Atlantic
new file mode 100644
index 0000000..57a99bf
--- /dev/null
+++ b/reg/Atlantic
@@ -0,0 +1,12 @@
+(UTC -04) Bermuda
+(UTC -03) Stanley
+(UTC -02) South_Georgia
+(UTC -01) Cape_Verde
+(UTC -01) Azores
+(UTC +00) Faeroe
+(UTC +00) Faroe
+(UTC +00) St_Helena
+(UTC +00) Reykjavik
+(UTC +00) Canary
+(UTC +00) Madeira
+(UTC +01) Jan_Mayen
diff --git a/reg/Australia b/reg/Australia
new file mode 100644
index 0000000..d762891
--- /dev/null
+++ b/reg/Australia
@@ -0,0 +1,23 @@
+(UTC +08) Perth
+(UTC +08) Eucla
+(UTC +08) West
+(UTC +09) Darwin
+(UTC +09) North
+(UTC +10) Yancowinna
+(UTC +10) South
+(UTC +10) Lindeman
+(UTC +10) Broken_Hill
+(UTC +10) Adelaide
+(UTC +10) Queensland
+(UTC +10) Brisbane
+(UTC +11) Victoria
+(UTC +11) Hobart
+(UTC +11) ACT
+(UTC +11) Tasmania
+(UTC +11) LHI
+(UTC +11) Currie
+(UTC +11) Canberra
+(UTC +11) Sydney
+(UTC +11) Melbourne
+(UTC +11) Lord_Howe
+(UTC +11) NSW
diff --git a/reg/Brazil b/reg/Brazil
new file mode 100644
index 0000000..79213f9
--- /dev/null
+++ b/reg/Brazil
@@ -0,0 +1,4 @@
+(UTC -05) Acre
+(UTC -04) West
+(UTC -03) East
+(UTC -02) DeNoronha
diff --git a/reg/Chile b/reg/Chile
new file mode 100644
index 0000000..c72cae0
--- /dev/null
+++ b/reg/Chile
@@ -0,0 +1,2 @@
+(UTC -05) EasterIsland
+(UTC -03) Continental
diff --git a/reg/Europe b/reg/Europe
new file mode 100644
index 0000000..a6a7a52
--- /dev/null
+++ b/reg/Europe
@@ -0,0 +1,64 @@
+(UTC +00) Jersey
+(UTC +00) Dublin
+(UTC +00) Belfast
+(UTC +00) Guernsey
+(UTC +00) London
+(UTC +00) Lisbon
+(UTC +00) Isle_of_Man
+(UTC +01) Ljubljana
+(UTC +01) Stockholm
+(UTC +01) Skopje
+(UTC +01) Oslo
+(UTC +01) Sarajevo
+(UTC +01) Tirane
+(UTC +01) Zagreb
+(UTC +01) Vienna
+(UTC +01) Andorra
+(UTC +01) Madrid
+(UTC +01) Podgorica
+(UTC +01) Copenhagen
+(UTC +01) Monaco
+(UTC +01) Belgrade
+(UTC +01) Budapest
+(UTC +01) Brussels
+(UTC +01) Amsterdam
+(UTC +01) Berlin
+(UTC +01) Zurich
+(UTC +01) Bratislava
+(UTC +01) Prague
+(UTC +01) Malta
+(UTC +01) Rome
+(UTC +01) Luxembourg
+(UTC +01) Vaduz
+(UTC +01) Paris
+(UTC +01) Warsaw
+(UTC +01) Vatican
+(UTC +01) Busingen
+(UTC +01) Gibraltar
+(UTC +01) San_Marino
+(UTC +02) Sofia
+(UTC +02) Vilnius
+(UTC +02) Helsinki
+(UTC +02) Mariehamn
+(UTC +02) Riga
+(UTC +02) Bucharest
+(UTC +02) Kyiv
+(UTC +02) Kiev
+(UTC +02) Athens
+(UTC +02) Zaporozhye
+(UTC +02) Tallinn
+(UTC +02) Kaliningrad
+(UTC +02) Uzhgorod
+(UTC +02) Chisinau
+(UTC +02) Nicosia
+(UTC +02) Tiraspol
+(UTC +03) Simferopol
+(UTC +03) Istanbul
+(UTC +03) Moscow
+(UTC +03) Kirov
+(UTC +03) Minsk
+(UTC +03) Volgograd
+(UTC +04) Ulyanovsk
+(UTC +04) Samara
+(UTC +04) Astrakhan
+(UTC +04) Saratov
diff --git a/reg/Indian b/reg/Indian
new file mode 100644
index 0000000..cbb5827
--- /dev/null
+++ b/reg/Indian
@@ -0,0 +1,11 @@
+(UTC +03) Comoro
+(UTC +03) Antananarivo
+(UTC +03) Mayotte
+(UTC +04) Mauritius
+(UTC +04) Reunion
+(UTC +04) Mahe
+(UTC +05) Maldives
+(UTC +05) Kerguelen
+(UTC +06) Chagos
+(UTC +06) Cocos
+(UTC +07) Christmas
diff --git a/reg/Mexico b/reg/Mexico
new file mode 100644
index 0000000..af4773f
--- /dev/null
+++ b/reg/Mexico
@@ -0,0 +1,3 @@
+(UTC -08) BajaNorte
+(UTC -07) BajaSur
+(UTC -06) General
diff --git a/reg/US b/reg/US
new file mode 100644
index 0000000..7c1cbd3
--- /dev/null
+++ b/reg/US
@@ -0,0 +1,12 @@
+(UTC -11) Samoa
+(UTC -10) Aleutian
+(UTC -10) Hawaii
+(UTC -09) Alaska
+(UTC -08) Pacific
+(UTC -07) Mountain
+(UTC -07) Arizona
+(UTC -06) Indiana-Starke
+(UTC -06) Central
+(UTC -05) East-Indiana
+(UTC -05) Michigan
+(UTC -05) Eastern
diff --git a/screen_app.png b/screen_app.png
new file mode 100644
index 0000000..39c88a4
Binary files /dev/null and b/screen_app.png differ
diff --git a/ubl-settings-datetime.cpp b/ubl-settings-datetime.cpp
new file mode 100644
index 0000000..fd83206
--- /dev/null
+++ b/ubl-settings-datetime.cpp
@@ -0,0 +1,677 @@
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include
+#include