Merge pull request 'master' (#9) from YanTheKaller/ubl-settings-manager:master into develop

Reviewed-on: #9
pull/29/head
Dmitry Razumov 3 years ago
commit 6369a17a3e

4
.gitignore vendored

@ -6,6 +6,7 @@ msgformat.py
calendarApp.glade
calendarApp.glade~
ubl-settings-manager.glade~
*ubl-settings-manager.glade#
ubl-settings-manager
**base.mo
home/
@ -13,4 +14,5 @@ css/
.config/
images/
locale/
ui/
ui/
ubl-settings-manager_ru.pos

@ -10,8 +10,9 @@ CMAKE_COMMAND = cmake
#CMAKE_BUILD_DIR = $(MAKEFILE_PATH)compile
CMAKE_SOURCE_DIR = ./source
CMAKE_BUILD_DIR = ./compile
DEPENDS = cmake
PKGNAME = $(MAKEFILE_DIR)
#PKGNAME = check-hostalive
#PKGNAME = ubl-settings-manager
default_target: all
@ -19,7 +20,12 @@ all: init build
init:
@echo "Initialize ..."; \
echo "-- Build path: ${CMAKE_BUILD_DIR}"
version="$$(cat VERSION.md)"; \
version=$${version:8}; \
search="s/string version_application.*"; \
replace="string version_application = \"$${version}\";"; \
sed -i -e "$$search/$$replace/gi" source/ubl-settings-manager.h; \
echo "-- Build path: ${CMAKE_BUILD_DIR}"
depend:
@echo "Check depends ..."; \
@ -77,10 +83,15 @@ uninstall:
done
@$(RM) "/usr/bin/${PKGNAME}"
@$(RM) "/usr/share/applications/${PKGNAME}.desktop"
@$(RM) "/usr/share/icons/hicolor/scalable/apps/${PKGNAME}.png"
@$(RM) "/usr/share/icons/hicolor/scalable/apps/${PKGNAME}.svg"
@$(RM) "/etc/ubconfig-main.conf"
@$(RM) "~/ubconfig-main.conf"
@$(RM) "/usr/share/icons/hicolor/scalable/apps/ru.ublinux.${PKGNAME}.svg"
@$(RM) "/usr/share/${PKGNAME}/ui/ublinux-logo.svg"
@$(RM) "/usr/share/${PKGNAME}/ui/${PKGNAME}.glade"
@$(RM) "/usr/share/${PKGNAME}/css/${PKGNAME}.css"
@$(RM) "/usr/share/${PKGNAME}/ui/${PKGNAME}-banner.png"
@$(RM) -d "/usr/share/${PKGNAME}/css"
@$(RM) -d "/usr/share/${PKGNAME}/ui"
@$(RM) -d "/usr/share/${PKGNAME}"
@$(RM) "/etc/xdg/${PKGNAME}/${PKGNAME}.conf"
@gtk-update-icon-cache -fiq /usr/share/icons/hicolor/ &>/dev/null
@update-desktop-database --quiet 2>/dev/null
@touch /usr/share/applications
@ -98,23 +109,23 @@ install: check uninstall
done
@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"; \
rsvg-convert -w $${SIZE} -h $${SIZE} -f svg --keep-image-data ru.ublinux.${PKGNAME}.svg -o "/usr/share/icons/hicolor/$${SIZE}x$${SIZE}/apps/ru.ublinux.${PKGNAME}.svg"; \
done
@install -dm755 /usr/share/icons/hicolor/scalable/apps
@install -Dm644 -t /usr/share/icons/hicolor/scalable/apps/ ${PKGNAME}.svg
@install -dm755 /usr/share/icons/hicolor/scalable/status
@install -Dm644 -t /usr/share/icons/hicolor/scalable/apps/ ru.ublinux.${PKGNAME}.svg
@install -Dm755 -t /usr/bin/ ${CMAKE_BUILD_DIR}/${PKGNAME}
@install -Dm644 -t /usr/share/applications/ ${PKGNAME}.desktop
@install -Dm644 -t /usr/share/applications/ ${PKGNAME}.desktop
@install -Dm755 /usr/share/${PKGNAME}/ -d ui
@install -Dm755 /usr/share/${PKGNAME}/ -d css
@install -Dm644 -t /usr/share/${PKGNAME}/ui/ ${PKGNAME}.glade
@install -Dm644 -t /usr/share/${PKGNAME}/css/ ${PKGNAME}.css
@install -Dm644 -t /etc/ ubconfig-main.conf
chmod 766 /etc/ubconfig-main.conf
@install -Dm655 -t ~/.config/ ubconfig-main.conf
@install -Dm644 -t /usr/share/icons/hicolor/scalable/apps/ ${PKGNAME}.png
@install -Dm644 -t /usr/share/${PKGNAME}/ui/ ublinux-logo.svg
@install -Dm766 -t /etc/xdg/${PKGNAME}/ ${PKGNAME}.conf
@install -Dm644 -t /usr/share/${PKGNAME}/ui/ ${PKGNAME}-banner.png
@gtk-update-icon-cache -fiq /usr/share/icons/hicolor/ &>/dev/null
@update-desktop-database --quiet 2>/dev/null
@touch /usr/share/applications
@echo "Install: OK ${USER}"
@echo "Install: OK"
clean:
@echo "Clean ..."
@ -123,7 +134,13 @@ clean:
echo "Clean: error, compile directory exist ${CMAKE_BUILD_DIR}"; \
else \
echo "Clean: OK"; \
fi
fi; \
version="$$(cat VERSION.md)"; \
version=$${version:8}; \
search="s/string version_application.*"; \
echo $$search; \
replace="string version_application = ;"; \
sed -i -e "$$search/$$replace/gi" source/ubl-settings-manager.h; \
help:
@echo "The following are some of the valid targets for this Makefile:"

@ -0,0 +1 @@
VERSION 1.1

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 210 KiB

@ -9,7 +9,7 @@ link_directories(${GTK_LIBRARY_DIRS})
add_definitions(${GTK_CFLAGS_OTHER})
#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pedantic -Wall -Wextra -Werror -Wmissing-declarations -fdiagnostics-color=always -std=c++2a")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pedantic -Wall -Wextra -Werror -Wmissing-declarations -fdiagnostics-color=always")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pedantic -Wall -Wextra -Werror -Wmissing-declarations -fdiagnostics-color=always -lm")
set(SOURCE_FILES
ubl-settings-manager.c

File diff suppressed because it is too large Load Diff

@ -2,24 +2,24 @@
#define UBL_SETTINGS_MANAGER
#include <gtk/gtk.h>
#include <time.h>
#define GladePath "/usr/share/ubl-settings-manager/ui/ubl-settings-manager.glade"
#define CssPath "/usr/share/ubl-settings-manager/css/ubl-settings-manager.css"
#define GlobalConfigPath "/etc/ubconfig-main.conf"
#define UserConfigPath "/.config/ubl-settings-manager/ubconfig-main.conf"
#define AppIconPath "/usr/share/icons/hicolor/32x32/apps/ublinux-ubconfig.svg"
#define AppBannerPath "/usr/share/icons/hicolor/scalable/apps/ubl-settings-manager.png"
#define GlobalConfigPath "/etc/xdg/ubl-settings-manager/ubl-settings-manager.conf"
#define UserConfigPath "/.config/ubl-settings-manager/ubl-settings-manager.conf"
#define AppIconPath "ru.ublinux.ubl-settings-manager"
#define AppBannerPath "/usr/share/ubl-settings-manager/ui/ubl-settings-manager-banner.png"
#define DesktopPath "/usr/share/applications/"
#define IconPicturesPath "/usr/share/icons/hicolor/scalable/apps/"
#define ErrIconPicturePath "/usr/share/icons/Faenza/emblems/32/emblem-important.png"
#define PictureFormatMain ".svg"
#define PictureFormatExtra ".png"
#define ublinux_logo "/usr/share/ubl-settings-manager/ui/ublinux-logo.svg"
#define LocalePath "/usr/share/locale"
#define LocaleName "ubl-settings-manager"
#define LogoPath "/usr/share/icons/hicolor/scalable/apps/ubl-settings-manager.svg"
#define ubl_settings_infoPath "ubl-settings-info"
#define ubl_settings_infoPathLaunch "ubl-settings-info --socket-id="
typedef char* string;
string version_application = ;
typedef struct apps{
char *Name;
@ -31,6 +31,11 @@ typedef struct apps{
int DualPluggable;
} apps;
typedef struct {
char *command;
int *exitcode;
} thread_output;
typedef struct dictionary {
char *key;
void *data;
@ -47,6 +52,7 @@ typedef struct IVGrapgicals{
GtkWidget *IV;
GtkWidget *label;
GtkWidget *sep;
GtkCellRendererPixbuf *iconRender;
} IVGraphicals;
typedef struct IconSection{
@ -61,12 +67,18 @@ typedef struct {
int windowPosY;
int WindowTheme;
char *curThemeName;
int iconsize;
int Mainiconsize;
int Gnomeiconsize;
int iconSegmentSize;
dictionary *sections;
int labelSize;
int MainlabelSize;
int GnomelabelSize;
int *currentThemeLabelSize;
int *currentThemeIconSize;
int labelDensity;
char *lastUser;
int changed;
int fullscreen;
} config;
typedef struct {
@ -145,7 +157,9 @@ typedef struct {
int appssize;
apps *applist;
GtkWidget *icvpack;
GtkWidget *infoWarningWindow;
GtkWidget *infoWarningButton;
GtkWidget *infoWarningLabel;
} actionWidgets;
@ -166,9 +180,9 @@ void on_ButtonOpenHelp_activated(GtkWidget *button, GtkBuilder *builder);
void on_backToSettingsButton_clicked(GtkWidget *button,actionWidgets *sctb);
void on_CancelHelpButton_activated(GtkWidget *button,GtkBuilder *builder);
void on_ReadHelpButton_activated(GtkWidget *button, GtkBuilder *builder);
void launch_app_with_arguments(char *name, char *args);
void launch_app(char *name);
void py_launch_app(char *name,char *args);
int launch_app_with_arguments(char *name, char *args);
int launch_app(char *name);
int py_launch_app(char *name,char *args);
int on_settings_accept(GtkWidget *button, dictionary **widgetsDs);
void on_paned_move(GtkPaned* self, GtkScrollType* scroll_type, actionWidgets *widgets);
int on_settingsOpen(GtkWidget *button, actionWidgets *widgets);
@ -188,7 +202,7 @@ dictionary *yon_theme_new(dictionary **widgetss, GtkBuilder *builder, char *them
char *yon_char_get_augumented(char *source, char *append);
char *yon_cut(char *source, int size, int startpos);
int yon_set_sections(IconSection *section);
void yon_set_default_sections(dictionary **section);
void yon_set_default_sections(dictionary *section);
char *yon_char_divide_search(char *source, char* dividepos, int delete_divider);
char *yon_char_divide(char *source, int dividepos);
dictionary *yon_section_new(dictionary *section, char *section_name, char *categories);
@ -203,7 +217,12 @@ void yon_dictionary_make_first(dictionary *dict);
dictionary *yon_create_icon_section_list(dictionary *sections);
int yon_show_icon_views(dictionary *IVS,actionWidgets *widgets);
void yon_icon_size_convert(int mode);
void on_about_system(GtkWidget *button, actionWidgets *widgets);
char *yon_char_new(char *chr);
void launch(char *command);
int launch(thread_output *thread);
float yon_time_average(dictionary *times);
void yon_time_reg_for_average(dictionary *listofregs, int size, time_t tm);
void yon_dictionary_switch_to_last(dictionary **dict);
dictionary *yon_dictionary_create_conneced(dictionary *targetdict);
int yon_get_icon_size(int size);
#endif

Before

Width:  |  Height:  |  Size: 366 KiB

After

Width:  |  Height:  |  Size: 366 KiB

@ -4,9 +4,11 @@ WindowPosY=0
WindowWidth=800
WindowHeight=600
WindowTheme=0
IconSize=2
MainIconSize=3
GnomeIconSize=3
IconSegmentSize=250
LabelSize=12
MainLabelSize=12
GnomeLabelSize=12
LabelDensity=0
User=

@ -6,9 +6,14 @@ background-color: #404040;
#GnomeIcon{
border-style:solid;
border-bottom-width: 1px;
border-image: linear-gradient(90deg, #aaaaaa 0%, #dcddde 100%);
border-image: linear-gradient(90deg, alpha(@theme_text_color,0.4) 55%, alpha(@theme_bg_color, 0) 100%);
border-image-slice: 1;
}
#SepIcon{
background-color: alpha(@theme_text_color, 0.6);
}
#iconlabel {
font-size:14px;
font-weight: bold;
@ -19,3 +24,86 @@ background-color: #404040;
border-width:1px;
border-radius:5px;
}
.noborder {
border: none;
}
.menu:hover {
border-color:alpha(@theme_text_color, 0.01);
}
.menu {
border-color:alpha(@theme_text_color, 0.01);
}
.menu:hover >* {
border-color:alpha(@theme_text_color, 0.01);
}
.menuitembottom{
margin-top:0px;
margin-bottom:3px;
}
.menuitemmiddle{
margin-top:0px;
margin-bottom:0px;
}
.menuitemtop{
margin-bottom:0px;
}
.menuitemtop *{
margin:2px 2px 0 2px;
padding: 5px 10px 3px 5px;
}
.menuitemmiddle *{
margin:0 2px 0 2px;
padding: 3px 10px 3px 5px;
}
.menuitembottom *{
margin:0 2px 2px 2px;
padding: 3px 10px 5px 5px;
}
.menuitemtop:hover {
background:@theme_bg_color;
}
.menuitemmiddle:hover {
background:@theme_bg_color;
}
.menuitembottom:hover {
background:@theme_bg_color;
}
.menuitemtop:hover* {
margin:2px 2px 0 2px;
padding: 5px 10px 3px 5px;
background:@theme_selected_bg_color;
border-radius:2px;
}
.menuitemmiddle:hover* {
margin:0 2px 0 2px;
padding: 3px 10px 3px 5px;
background:@theme_selected_bg_color;
border-radius:2px;
}
.menuitembottom:hover* {
margin:0 2px 2px 2px;
padding: 3px 10px 5px 5px;
background:@theme_selected_bg_color;
border-radius:2px;
}
.workingbg, #workingbg {
background-color:@theme_base_color;
}
.workingbg.view.cell:selected {
background-color:@theme_selected_bg_color;
}
.workingbg.view.cell:hover {
background-color:darker(@theme_selected_bg_color);
color:@theme_selected_text_color;
border-radius:3px;
}
.bkim {
transition: 200ms ease-out;
background-image: none;
}

@ -8,7 +8,7 @@ Comment=ubl-settings-manager
Comment[ru]=Приложение для управления настройками UBLinux
Type=Application
Exec=ubl-settings-manager
Icon=ublinux-ubconfig
Icon=ubl-settings-manager
Terminal=false
X-XfcePluggable=false
Categories=XFCE;GTK;Settings;DesktopSettings;X-XFCE-SettingsDialog;X-XFCE-SystemSettings;

File diff suppressed because it is too large Load Diff

@ -6,88 +6,101 @@
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Project-Id-Version: 1.2\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2023-02-09 16:45+0600\n"
"POT-Creation-Date: 2023-03-13 10:24+0600\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
"Language: \n"
"Language: ru\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
#: ubl-settings-manager.c:1338
msgid "Back to settings"
msgstr "Назад"
#: source/ubl-settings-manager.c:730
msgid "Settings manager for UBLinux"
msgstr "Менеджер настроек для UBLinux"
#: ubl-settings-manager.c:1418
#: source/ubl-settings-manager.c:731 source/ubl-settings-manager.c:1615
#: source/ubl-settings-manager.c:1630 source/ubl-settings-manager.c:1685
msgid "UBLinux Settings Manager"
msgstr "Настройки UBLinux"
#: ubl-settings-manager.c:1419
#: source/ubl-settings-manager.c:733
msgid "Project Home Page"
msgstr "Домашняя станица проекта"
#: source/ubl-settings-manager.c:1614
msgid "Back to all settings"
msgstr "Назад ко всем настройкам"
#: source/ubl-settings-manager.c:1686
msgid "Icon size"
msgstr "Размер иконок"
#: ubl-settings-manager.c:1420
#: source/ubl-settings-manager.c:1687
msgid "Window theme"
msgstr "Выбор темы"
#: ubl-settings-manager.c:1421
#: source/ubl-settings-manager.c:1688
msgid "Would you like to read documentation in the Web?"
msgstr "Вы хотите прочитать руководство в сети?"
#: ubl-settings-manager.c:1422
#: source/ubl-settings-manager.c:1689
msgid ""
"You will be redirected to documentation site, where user help pages are "
"translated and supported by community."
msgstr "Вы будете перенаправлены на сайт с документацией, где страницы помощи переводятся и поддерживаются сообществом."
#: ubl-settings-manager.c:1423
#: source/ubl-settings-manager.c:1690
msgid "Read online"
msgstr "Прочитать онлайн"
#: ubl-settings-manager.c:1424
#: source/ubl-settings-manager.c:1691
msgid "Cancel"
msgstr "Отменить"
#: ubl-settings-manager.c:1425
#: source/ubl-settings-manager.c:1692
msgid "Close"
msgstr "Закрыть"
#: ubl-settings-manager.c:1426
#: source/ubl-settings-manager.c:1693
msgid "Save and apply"
msgstr "Сохранить и применить"
#: ubl-settings-manager.c:1427
#: source/ubl-settings-manager.c:1694
msgid "Always redirect"
msgstr "Всегда перенаправлять"
#: ubl-settings-manager.c:1428
#: source/ubl-settings-manager.c:1695
msgid "Settings"
msgstr "Настройки"
#: ubl-settings-manager.c:1429
#: source/ubl-settings-manager.c:1696
msgid "About..."
msgstr "О программе"
#: ubl-settings-manager.c:1430
#: source/ubl-settings-manager.c:1697
msgid "Looks like you don't have ubl-settings-info installed on your PC."
msgstr "В вашей системе не обнаружен UBLinux Settings Info."
#: source/ubl-settings-manager.c:1697
msgid "About system"
msgstr "О системе"
#: ubl-settings-manager.c:1431
#: source/ubl-settings-manager.c:1719
msgid "Sections management"
msgstr "Настройка разделов"
#: source/ubl-settings-manager.c:1698
msgid "Understood"
msgstr "Понятно"
#: ubl-settings-manager.c:1432
msgid "Section management"
msgstr "Точная настройка"
#: ubl-settings-manager.c:1508
#: source/ubl-settings-manager.c:1782
msgid "Standard theme"
msgstr "Основная тема"
msgstr "Стандартная тема"
#: ubl-settings-manager.c:1509
#: source/ubl-settings-manager.c:1783
msgid "GNOME theme"
msgstr "GNOME тема"

Before

Width:  |  Height:  |  Size: 14 KiB

After

Width:  |  Height:  |  Size: 14 KiB

Loading…
Cancel
Save