mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-11-10 02:40:11 +00:00
Avoid a possible division by zero. (#77820)
* gtk/gtkrange.c (gtk_range_calc_layout): Avoid a possible division by zero. (#77820)
This commit is contained in:
parent
c09a9a9fe1
commit
82a4dddf42
@ -1,3 +1,8 @@
|
||||
2002-04-25 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* gtk/gtkrange.c (gtk_range_calc_layout): Avoid a possible
|
||||
division by zero. (#77820)
|
||||
|
||||
Thu Apr 25 20:24:37 2002 Soeren Sandmann <sandmann@daimi.au.dk>
|
||||
|
||||
* gtk/gtkmenuitem.c (gtk_menu_item_size_allocate): use the child's
|
||||
|
@ -1,3 +1,8 @@
|
||||
2002-04-25 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* gtk/gtkrange.c (gtk_range_calc_layout): Avoid a possible
|
||||
division by zero. (#77820)
|
||||
|
||||
Thu Apr 25 20:24:37 2002 Soeren Sandmann <sandmann@daimi.au.dk>
|
||||
|
||||
* gtk/gtkmenuitem.c (gtk_menu_item_size_allocate): use the child's
|
||||
|
@ -1,3 +1,8 @@
|
||||
2002-04-25 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* gtk/gtkrange.c (gtk_range_calc_layout): Avoid a possible
|
||||
division by zero. (#77820)
|
||||
|
||||
Thu Apr 25 20:24:37 2002 Soeren Sandmann <sandmann@daimi.au.dk>
|
||||
|
||||
* gtk/gtkmenuitem.c (gtk_menu_item_size_allocate): use the child's
|
||||
|
@ -1,3 +1,8 @@
|
||||
2002-04-25 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* gtk/gtkrange.c (gtk_range_calc_layout): Avoid a possible
|
||||
division by zero. (#77820)
|
||||
|
||||
Thu Apr 25 20:24:37 2002 Soeren Sandmann <sandmann@daimi.au.dk>
|
||||
|
||||
* gtk/gtkmenuitem.c (gtk_menu_item_size_allocate): use the child's
|
||||
|
@ -1,3 +1,8 @@
|
||||
2002-04-25 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* gtk/gtkrange.c (gtk_range_calc_layout): Avoid a possible
|
||||
division by zero. (#77820)
|
||||
|
||||
Thu Apr 25 20:24:37 2002 Soeren Sandmann <sandmann@daimi.au.dk>
|
||||
|
||||
* gtk/gtkmenuitem.c (gtk_menu_item_size_allocate): use the child's
|
||||
|
@ -1,3 +1,8 @@
|
||||
2002-04-25 Matthias Clasen <maclas@gmx.de>
|
||||
|
||||
* gtk/gtkrange.c (gtk_range_calc_layout): Avoid a possible
|
||||
division by zero. (#77820)
|
||||
|
||||
Thu Apr 25 20:24:37 2002 Soeren Sandmann <sandmann@daimi.au.dk>
|
||||
|
||||
* gtk/gtkmenuitem.c (gtk_menu_item_size_allocate): use the child's
|
||||
|
@ -2041,8 +2041,12 @@ gtk_range_calc_layout (GtkRange *range,
|
||||
/* slider height is the fraction (page_size /
|
||||
* total_adjustment_range) times the trough height in pixels
|
||||
*/
|
||||
height = ((bottom - top) * (range->adjustment->page_size /
|
||||
(range->adjustment->upper - range->adjustment->lower)));
|
||||
|
||||
if (range->adjustment->upper - range->adjustment->lower != 0)
|
||||
height = ((bottom - top) * (range->adjustment->page_size /
|
||||
(range->adjustment->upper - range->adjustment->lower)));
|
||||
else
|
||||
height = range->min_slider_size;
|
||||
|
||||
if (height < range->min_slider_size ||
|
||||
range->slider_size_fixed)
|
||||
|
Loading…
Reference in New Issue
Block a user