Fixed saving of position and size of window; banner was resized to fit in minimal window size; Added buttons to shrink banner to provide more workspace on both themes;

pull/36/head^2
parent c87cca487c
commit 3bcb12837c

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 210 KiB

@ -546,11 +546,13 @@ void on_section_delete(GtkWidget *button, actionWidgets *widgets){
void on_resized (GtkWidget *window, GdkEventConfigure *event, dictionary *widgetsD){
actionWidgets *widgets=(actionWidgets*)widgetsD->data;
if (gtk_window_is_maximized(GTK_WINDOW(widgets->window))==0)
if (gtk_window_is_maximized(GTK_WINDOW(widgets->window))==0){
main_config.fullscreen=0;
gtk_window_get_size(GTK_WINDOW(window),&main_config.windowWidth,&main_config.windowHeight);
gtk_window_get_position(GTK_WINDOW(window),&main_config.windowPosX,&main_config.windowPosY);
}
else
main_config.fullscreen=1;
gtk_window_get_size(GTK_WINDOW(window),&main_config.windowWidth,&main_config.windowHeight);
// if (main_config.WindowTheme==1){
// if (main_config.windowWidth<1240){
// if (stld==0){
@ -1260,14 +1262,6 @@ void yon_switch_theme(dictionary **dict, dictionary *newone){
main_config.curThemeName="Main";
gtk_combo_box_set_active(GTK_COMBO_BOX(widgets->settingsThemeChooser),0);
gtk_window_present(GTK_WINDOW(widgets->CautionWindow));
gtk_widget_show(widgets->MenuItemAboutSystem);
} else if (x<1240){
gtk_window_resize(GTK_WINDOW(widgets->window),1245,y);
main_config.WindowTheme=1;
main_config.curThemeName="Gnome";
gtk_widget_show(widgets->window);
gtk_widget_hide(widgets->MenuItemAboutSystem);
}else{
main_config.WindowTheme=1;
main_config.curThemeName="Gnome";
@ -1631,7 +1625,8 @@ dictionary *yon_theme_new(dictionary **widgetss, GtkBuilder *builder, char *them
g_signal_connect(G_OBJECT(curWidgets->ButtonBackToMain), "clicked", G_CALLBACK(on_backToSettingsButton_clicked), curWidgets);
curWidgets->LabelTitle=GTK_WIDGET(gtk_builder_get_object(curWidgets->builder,"LabelTitle"));
gtk_window_set_title(GTK_WINDOW(curWidgets->window),_("UBLinux Settings Manager"));
gtk_window_move(GTK_WINDOW(curWidgets->window),main_config.windowPosX,main_config.windowPosY);
gtk_render_background(gtk_widget_get_style_context(curWidgets->workingwindow),gdk_pixbuf_new_from_file(ublinux_logo,NULL),0,0,100,100);
// Standard for all themes
curWidgets->settingsThemeChooser=GTK_WIDGET(gtk_builder_get_object(curWidgets->builder,"settingsThemeChooser"));

Binary file not shown.

Before

Width:  |  Height:  |  Size: 366 KiB

After

Width:  |  Height:  |  Size: 260 KiB

@ -39,13 +39,13 @@
<property name="can-focus">False</property>
<property name="halign">center</property>
<property name="valign">start</property>
<property name="margin-start">5</property>
<property name="margin-start">10</property>
<property name="margin-end">25</property>
<property name="margin-top">20</property>
<property name="margin-bottom">20</property>
<property name="label">You are not allowed to change theme on such low resolution!</property>
<property name="label">Changing the theme is not available due to the small screen resolution!</property>
<property name="wrap">True</property>
<property name="xalign">0.019999999552965164</property>
<property name="xalign">0</property>
</object>
<packing>
<property name="expand">True</property>
@ -364,6 +364,23 @@
</object>
</child>
</object>
<object class="GtkAspectFrame">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="label-xalign">0.20000000298023224</property>
<property name="label-yalign">0</property>
<property name="shadow-type">in</property>
<property name="yalign">0</property>
<property name="obey-child">False</property>
<child>
<object class="GtkImage">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="pixel-size">98</property>
<property name="icon-name">action-unavailable-symbolic.symbolic</property>
</object>
</child>
</object>
<object class="GtkAction" id="action1"/>
<object class="GtkAdjustment" id="adjustment1">
<property name="lower">1</property>
@ -2055,99 +2072,4 @@
</object>
</child>
</object>
<object class="GtkWindow" id="windowSettings-infoWarning">
<property name="can-focus">False</property>
<child>
<object class="GtkBox">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="orientation">vertical</property>
<child>
<object class="GtkBox">
<property name="visible">True</property>
<property name="can-focus">False</property>
<child>
<object class="GtkImage">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="valign">start</property>
<property name="margin-start">20</property>
<property name="margin-end">20</property>
<property name="margin-top">20</property>
<property name="margin-bottom">20</property>
<property name="hexpand">True</property>
<property name="icon-name">dialog-question-symbolic</property>
<property name="icon_size">6</property>
</object>
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkLabel" id="labelSettings-infoWarning">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="valign">start</property>
<property name="margin-start">10</property>
<property name="margin-end">15</property>
<property name="margin-top">20</property>
<property name="margin-bottom">20</property>
<property name="label" translatable="yes">Looks like you don't have ubl-settings-info installed on your PC.</property>
<property name="wrap">True</property>
<property name="xalign">0</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">0</property>
</packing>
</child>
<child>
<object class="GtkButton" id="buttonSettings-infoWarning">
<property name="label" translatable="yes">Ok</property>
<property name="visible">True</property>
<property name="can-focus">True</property>
<property name="receives-default">True</property>
<property name="halign">end</property>
<property name="valign">end</property>
<property name="margin-start">5</property>
<property name="margin-end">5</property>
<property name="margin-top">5</property>
<property name="margin-bottom">5</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="pack-type">end</property>
<property name="position">1</property>
</packing>
</child>
</object>
</child>
<child type="titlebar">
<object class="GtkHeaderBar">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="title" translatable="yes">Warning</property>
<property name="has-subtitle">False</property>
<child>
<object class="GtkImage">
<property name="visible">True</property>
<property name="can-focus">False</property>
<property name="pixel-size">32</property>
<property name="icon-name">dialog-question-symbolic</property>
</object>
</child>
</object>
</child>
</object>
</interface>

Loading…
Cancel
Save