[Commits] [SCM] claws branch, gtk3, updated. 3.16.0-887-ge3e5a4cd4
paul at claws-mail.org
paul at claws-mail.org
Fri Dec 6 13:31:15 CET 2019
The branch, gtk3 has been updated
via e3e5a4cd40b93c5444048a19f6f8d3886084dcd2 (commit)
from 0975fd9b977c1e8a18b0f3432307d616899ad573 (commit)
Summary of changes:
src/addr_compl.c | 6 +++---
src/gtk/description_window.c | 2 +-
src/gtk/gtkcmclist.c | 6 +++---
src/mimeview.c | 2 +-
src/plugins/notification/notification_banner.c | 4 ++--
src/plugins/notification/notification_prefs.c | 2 +-
src/plugins/pdf_viewer/poppler_viewer.c | 2 +-
src/plugins/vcalendar/day-view.c | 8 +++++---
src/plugins/vcalendar/month-view.c | 8 +++++---
src/prefs_filtering_action.c | 2 +-
10 files changed, 23 insertions(+), 19 deletions(-)
- Log -----------------------------------------------------------------
commit e3e5a4cd40b93c5444048a19f6f8d3886084dcd2
Author: paul <paul at claws-mail.org>
Date: Fri Dec 6 12:31:10 2019 +0000
replace deprecated gtk_widget_size_request()
diff --git a/src/addr_compl.c b/src/addr_compl.c
index e4c187d10..c7a6d41b7 100644
--- a/src/addr_compl.c
+++ b/src/addr_compl.c
@@ -951,7 +951,7 @@ static void addrcompl_resize_window( CompletionWindow *cw ) {
gdk_window_get_geometry( gtk_widget_get_window( cw->window ), &x, &y, &width, &height );
gtk_widget_queue_resize_no_redraw(cw->list_view);
- gtk_widget_size_request( cw->list_view, &r );
+ gtk_widget_get_preferred_size( cw->list_view, &r, NULL);
/* Adjust window height to available screen space */
if( y + r.height > gdk_screen_height())
@@ -1486,10 +1486,10 @@ static void address_completion_create_completion_window( GtkEntry *entry_ )
gtk_window_move(GTK_WINDOW(window), x, y + rect.height);
/* Resize window to fit initial (empty) address list */
- gtk_widget_size_request( list_view, &r );
+ gtk_widget_get_preferred_size( list_view, &r, NULL);
gtk_widget_set_size_request( window, rect.width, r.height );
gtk_widget_show_all( window );
- gtk_widget_size_request( list_view, &r );
+ gtk_widget_get_preferred_size( list_view, &r, NULL );
/* Setup handlers */
g_signal_connect(G_OBJECT(list_view), "button_press_event",
diff --git a/src/gtk/description_window.c b/src/gtk/description_window.c
index f0548eeee..e412d88de 100644
--- a/src/gtk/description_window.c
+++ b/src/gtk/description_window.c
@@ -123,7 +123,7 @@ static void description_create(DescriptionWindow * dwindow)
gtk_label_set_yalign(GTK_LABEL(label), 0.0);
gtk_grid_attach(GTK_GRID(table), label, col, line, 1, 1);
- gtk_widget_size_request(label, &req);
+ gtk_widget_get_preferred_size(label, &req, NULL);
if(req.width > max_width[j])
max_width[j] = req.width;
}
diff --git a/src/gtk/gtkcmclist.c b/src/gtk/gtkcmclist.c
index c38305f01..904057715 100644
--- a/src/gtk/gtkcmclist.c
+++ b/src/gtk/gtkcmclist.c
@@ -5554,8 +5554,8 @@ gtk_cmclist_size_request (GtkWidget *widget,
{
GtkRequisition child_requisition;
- gtk_widget_size_request (clist->column[i].button,
- &child_requisition);
+ gtk_widget_get_preferred_size(clist->column[i].button,
+ &child_requisition, NULL);
clist->column_title_area.height =
MAX (clist->column_title_area.height,
child_requisition.height);
@@ -6217,7 +6217,7 @@ adjust_adjustments (GtkCMCList *clist,
GtkAllocation allocation;
widget = GTK_WIDGET (clist);
- gtk_widget_size_request (widget, &requisition);
+ gtk_widget_get_preferred_size(widget, &requisition, NULL);
gtk_widget_get_allocation (widget, &allocation);
if ((!clist->hadjustment &&
diff --git a/src/mimeview.c b/src/mimeview.c
index e9cfa60a4..f181e71cd 100644
--- a/src/mimeview.c
+++ b/src/mimeview.c
@@ -2703,7 +2703,7 @@ static void icon_list_append_icon (MimeView *mimeview, MimeInfo *mimeinfo)
G_CALLBACK(mimeview_drag_data_get), mimeview);
gtk_container_add(GTK_CONTAINER(grid), button);
#ifdef GENERIC_UMPC
- gtk_widget_size_request(pixmap, &r);
+ gtk_widget_get_preferred_size(pixmap, &r, NULL);
gtk_widget_set_size_request(button, -1, r.height + 4);
#endif
diff --git a/src/plugins/notification/notification_banner.c b/src/plugins/notification/notification_banner.c
index b9a48136a..e9a1aa4b0 100644
--- a/src/plugins/notification/notification_banner.c
+++ b/src/plugins/notification/notification_banner.c
@@ -194,7 +194,7 @@ static void notification_banner_create(GSList *msg_list)
gtk_widget_show_all(banner.window);
/* Scrolling */
- gtk_widget_size_request(hbox, &requisition);
+ gtk_widget_get_preferred_size(hbox, &requisition, NULL);
if(notify_config.banner_width > 0)
banner_width = notify_config.banner_width;
else
@@ -211,7 +211,7 @@ static void notification_banner_create(GSList *msg_list)
gtk_box_pack_start(GTK_BOX(hbox), second_entrybox, FALSE, FALSE, 0);
gtk_widget_show_all(banner.window);
- gtk_widget_size_request(hbox, &requisition_after);
+ gtk_widget_get_preferred_size(hbox, &requisition_after, NULL);
G_LOCK(sdata);
sdata.banner_width = requisition_after.width - requisition.width;
diff --git a/src/plugins/notification/notification_prefs.c b/src/plugins/notification/notification_prefs.c
index a2cc39e34..230514e68 100644
--- a/src/plugins/notification/notification_prefs.c
+++ b/src/plugins/notification/notification_prefs.c
@@ -791,7 +791,7 @@ static void notify_create_banner_page(PrefsPage *page, GtkWindow *window,
slider = gtk_hscale_new_with_range(10., 70., 10.);
gtk_scale_set_digits(GTK_SCALE(slider), 0);
- gtk_widget_size_request(combo, &requisition);
+ gtk_widget_get_preferred_size(combo, &requisition, NULL);
gtk_widget_set_size_request(slider, requisition.width, -1);
gtk_range_set_increments(GTK_RANGE(slider), 10., 10.);
gtk_range_set_inverted(GTK_RANGE(slider), TRUE);
diff --git a/src/plugins/pdf_viewer/poppler_viewer.c b/src/plugins/pdf_viewer/poppler_viewer.c
index 88aa02374..142e113cc 100644
--- a/src/plugins/pdf_viewer/poppler_viewer.c
+++ b/src/plugins/pdf_viewer/poppler_viewer.c
@@ -1035,7 +1035,7 @@ static void pdf_viewer_move_events_cb(GtkWidget *widget, GdkEventMotion *event,
y1 = lmapping->area.y1;
x2 = lmapping->area.x2;
y2 = lmapping->area.y2;
- gtk_widget_size_request(viewer->pdf_view, &size);
+ gtk_widget_get_preferred_size(viewer->pdf_view, &size, NULL);
upper = gtk_adjustment_get_upper(viewer->pdf_view_hadj);
switch (viewer->rotate) {
diff --git a/src/plugins/vcalendar/day-view.c b/src/plugins/vcalendar/day-view.c
index 48e295746..9902db711 100644
--- a/src/plugins/vcalendar/day-view.c
+++ b/src/plugins/vcalendar/day-view.c
@@ -613,10 +613,11 @@ static void build_day_view_header(day_win *dw, char *start_date)
/* sizes */
gtk_button_set_label(GTK_BUTTON(dw->StartDate_button)
, (const gchar *)start_date);
- gtk_widget_size_request(dw->StartDate_button, &dw->StartDate_button_req);
+ gtk_widget_get_preferred_size(dw->StartDate_button, &dw->StartDate_button_req,
+ NULL);
dw->StartDate_button_req.width += dw->StartDate_button_req.width/10;
label = gtk_label_new("00");
- gtk_widget_size_request(label, &dw->hour_req);
+ gtk_widget_get_preferred_size(label, &dw->hour_req, NULL);
if (mainwindow_get_mainwindow()) {
GtkAllocation allocation;
@@ -630,7 +631,8 @@ static void build_day_view_header(day_win *dw, char *start_date)
if (avail_d >= 7) {
avail_d = 7;
gtk_widget_set_size_request(dw->StartDate_button, avail_w / avail_d, -1);
- gtk_widget_size_request(dw->StartDate_button, &dw->StartDate_button_req);
+ gtk_widget_get_preferred_size(dw->StartDate_button, &dw->StartDate_button_req,
+ NULL);
}
/* initial values */
diff --git a/src/plugins/vcalendar/month-view.c b/src/plugins/vcalendar/month-view.c
index 9cf2d3b3f..97418d9b1 100644
--- a/src/plugins/vcalendar/month-view.c
+++ b/src/plugins/vcalendar/month-view.c
@@ -714,10 +714,11 @@ static void build_month_view_header(month_win *mw, char *start_date)
/* sizes */
gtk_button_set_label(GTK_BUTTON(mw->StartDate_button)
, (const gchar *)start_date);
- gtk_widget_size_request(mw->StartDate_button, &mw->StartDate_button_req);
+ gtk_widget_get_preferred_size(mw->StartDate_button, &mw->StartDate_button_req,
+ NULL);
mw->StartDate_button_req.width += mw->StartDate_button_req.width/10;
label = gtk_label_new("00");
- gtk_widget_size_request(label, &mw->hour_req);
+ gtk_widget_get_preferred_size(label, &mw->hour_req, NULL);
}
static void build_month_view_colours(month_win *mw)
@@ -827,7 +828,8 @@ static void build_month_view_table(month_win *mw)
gtk_widget_set_size_request(mw->StartDate_button, avail_w / avail_d,
(avail_h)/6);
- gtk_widget_size_request(mw->StartDate_button, &mw->StartDate_button_req);
+ gtk_widget_get_preferred_size(mw->StartDate_button, &mw->StartDate_button_req,
+ NULL);
/* initial values */
gtk_spin_button_set_value(GTK_SPIN_BUTTON(mw->day_spin), avail_d);
diff --git a/src/prefs_filtering_action.c b/src/prefs_filtering_action.c
index 0b77739bc..3012670f1 100644
--- a/src/prefs_filtering_action.c
+++ b/src/prefs_filtering_action.c
@@ -312,7 +312,7 @@ static void prefs_filtering_action_check_widget_width(GtkWidget *widget)
{
GtkRequisition req;
- gtk_widget_size_request(widget, &req);
+ gtk_widget_get_preferred_size(widget, &req, NULL);
if(req.width > SECOND_ROW_WIDTH)
gtk_widget_set_size_request(widget, SECOND_ROW_WIDTH, -1);
}
-----------------------------------------------------------------------
hooks/post-receive
--
Claws Mail
More information about the Commits
mailing list