diff options
author | monsta <[email protected]> | 2018-01-27 23:49:15 +0300 |
---|---|---|
committer | raveit65 <[email protected]> | 2018-01-28 17:30:45 +0100 |
commit | a5205924900148d3ce7905dbe946d6b325f2abc6 (patch) | |
tree | 9a1d1a1c235500381044b8274735d094f4bb2278 /src/interface.cpp | |
parent | 06ae3f89d68c0b967e5febe7425625d114ac4308 (diff) | |
download | mate-system-monitor-a5205924900148d3ce7905dbe946d6b325f2abc6.tar.bz2 mate-system-monitor-a5205924900148d3ce7905dbe946d6b325f2abc6.tar.xz |
require GTK+ 3.22 and GLib 2.50
Diffstat (limited to 'src/interface.cpp')
-rw-r--r-- | src/interface.cpp | 57 |
1 files changed, 1 insertions, 56 deletions
diff --git a/src/interface.cpp b/src/interface.cpp index bacab98..3bd7ab6 100644 --- a/src/interface.cpp +++ b/src/interface.cpp @@ -251,11 +251,7 @@ make_title_label (const char *text) label = gtk_label_new (full); g_free (full); -#if GTK_CHECK_VERSION (3, 16, 0) gtk_label_set_xalign (GTK_LABEL (label), 0.0); -#else - gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); -#endif gtk_label_set_use_markup (GTK_LABEL (label), TRUE); return label; @@ -346,11 +342,8 @@ create_sys_view (ProcData *procdata) g_free (label_text); cpu_label = gtk_label_new (NULL); -#if GTK_CHECK_VERSION (3, 16, 0) gtk_label_set_xalign (GTK_LABEL (cpu_label), 0.0); -#else - gtk_misc_set_alignment (GTK_MISC (cpu_label), 0.0, 0.5); -#endif + gtk_box_pack_start (GTK_BOX (temp_hbox), cpu_label, TRUE, TRUE, 0); load_graph_get_labels(cpu_graph)->cpu[i] = cpu_label; @@ -406,11 +399,7 @@ create_sys_view (ProcData *procdata) label = gtk_label_new (label_text); g_free(label_text); -#if GTK_CHECK_VERSION (3, 16, 0) gtk_label_set_xalign (GTK_LABEL (label), 0.0); -#else - gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); -#endif gtk_grid_attach (GTK_GRID (grid), label, 1, 0, 7, 1); gtk_grid_attach (GTK_GRID (grid), @@ -434,11 +423,7 @@ create_sys_view (ProcData *procdata) label = gtk_label_new (label_text); g_free(label_text); -#if GTK_CHECK_VERSION (3, 16, 0) gtk_label_set_xalign (GTK_LABEL (label), 0.0); -#else - gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); -#endif gtk_grid_attach (GTK_GRID (grid), label, 1, 0, 7, 1); gtk_grid_attach (GTK_GRID (grid), @@ -497,40 +482,20 @@ create_sys_view (ProcData *procdata) label = gtk_label_new (label_text); g_free(label_text); -#if GTK_CHECK_VERSION (3, 16, 0) gtk_label_set_xalign (GTK_LABEL (label), 0.0); -#else - gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); -#endif gtk_grid_attach (GTK_GRID (grid), label, 1, 0, 1, 1); -#if GTK_CHECK_VERSION (3, 16, 0) gtk_label_set_xalign (GTK_LABEL (load_graph_get_labels(net_graph)->net_in), 1.0); -#else - gtk_misc_set_alignment (GTK_MISC (load_graph_get_labels(net_graph)->net_in), - 1.0, - 0.5); -#endif gtk_widget_set_size_request(GTK_WIDGET(load_graph_get_labels(net_graph)->net_in), 100, -1); gtk_widget_set_hexpand (load_graph_get_labels(net_graph)->net_in, TRUE); gtk_grid_attach (GTK_GRID (grid), load_graph_get_labels(net_graph)->net_in, 2, 0, 1, 1); label = gtk_label_new (_("Total Received")); -#if GTK_CHECK_VERSION (3, 16, 0) gtk_label_set_xalign (GTK_LABEL (label), 0.0); -#else - gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); -#endif gtk_grid_attach (GTK_GRID (grid), label, 1, 1, 1, 1); -#if GTK_CHECK_VERSION (3, 16, 0) gtk_label_set_xalign (GTK_LABEL (load_graph_get_labels(net_graph)->net_in_total), 1.0); -#else - gtk_misc_set_alignment (GTK_MISC (load_graph_get_labels(net_graph)->net_in_total), - 1.0, - 0.5); -#endif gtk_grid_attach (GTK_GRID (grid), load_graph_get_labels(net_graph)->net_in_total, 2, 1, 1, 1); @@ -558,40 +523,20 @@ create_sys_view (ProcData *procdata) label = gtk_label_new (label_text); g_free(label_text); -#if GTK_CHECK_VERSION (3, 16, 0) gtk_label_set_xalign (GTK_LABEL (label), 0.0); -#else - gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); -#endif gtk_grid_attach (GTK_GRID (grid), label, 1, 0, 1, 1); -#if GTK_CHECK_VERSION (3, 16, 0) gtk_label_set_xalign (GTK_LABEL (load_graph_get_labels(net_graph)->net_out), 1.0); -#else - gtk_misc_set_alignment (GTK_MISC (load_graph_get_labels(net_graph)->net_out), - 1.0, - 0.5); -#endif gtk_widget_set_size_request(GTK_WIDGET(load_graph_get_labels(net_graph)->net_out), 100, -1); gtk_widget_set_hexpand (load_graph_get_labels(net_graph)->net_out, TRUE); gtk_grid_attach (GTK_GRID (grid), load_graph_get_labels(net_graph)->net_out, 2, 0, 1, 1); label = gtk_label_new (_("Total Sent")); -#if GTK_CHECK_VERSION (3, 16, 0) gtk_label_set_xalign (GTK_LABEL (label), 0.0); -#else - gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); -#endif gtk_grid_attach (GTK_GRID (grid), label, 1, 1, 1, 1); -#if GTK_CHECK_VERSION (3, 16, 0) gtk_label_set_xalign (GTK_LABEL (load_graph_get_labels(net_graph)->net_out_total), 1.0); -#else - gtk_misc_set_alignment (GTK_MISC (load_graph_get_labels(net_graph)->net_out_total), - 1.0, - 0.5); -#endif gtk_grid_attach (GTK_GRID (grid), load_graph_get_labels(net_graph)->net_out_total, 2, 1, 1, 1); |