forked from AuroraMiddleware/gtk
Reduce rounding error. (#154658, John Cupitt)
2004-10-06 Matthias Clasen <mclasen@redhat.com> * gtk/gtkpaned.c (gtk_paned_compute_position): Reduce rounding error. (#154658, John Cupitt)
This commit is contained in:
parent
cd79561f8f
commit
002ceac808
@ -1,5 +1,8 @@
|
|||||||
2004-10-06 Matthias Clasen <mclasen@redhat.com>
|
2004-10-06 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
|
* gtk/gtkpaned.c (gtk_paned_compute_position): Reduce rounding
|
||||||
|
error. (#154658, John Cupitt)
|
||||||
|
|
||||||
* gtk/gtktreeselection.c (gtk_tree_selection_get_selected): Clear
|
* gtk/gtktreeselection.c (gtk_tree_selection_get_selected): Clear
|
||||||
the iter instead of returning it unmodified. (#154186, Jonathan Blandford)
|
the iter instead of returning it unmodified. (#154186, Jonathan Blandford)
|
||||||
|
|
||||||
|
@ -1,5 +1,8 @@
|
|||||||
2004-10-06 Matthias Clasen <mclasen@redhat.com>
|
2004-10-06 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
|
* gtk/gtkpaned.c (gtk_paned_compute_position): Reduce rounding
|
||||||
|
error. (#154658, John Cupitt)
|
||||||
|
|
||||||
* gtk/gtktreeselection.c (gtk_tree_selection_get_selected): Clear
|
* gtk/gtktreeselection.c (gtk_tree_selection_get_selected): Clear
|
||||||
the iter instead of returning it unmodified. (#154186, Jonathan Blandford)
|
the iter instead of returning it unmodified. (#154186, Jonathan Blandford)
|
||||||
|
|
||||||
|
@ -1,5 +1,8 @@
|
|||||||
2004-10-06 Matthias Clasen <mclasen@redhat.com>
|
2004-10-06 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
|
* gtk/gtkpaned.c (gtk_paned_compute_position): Reduce rounding
|
||||||
|
error. (#154658, John Cupitt)
|
||||||
|
|
||||||
* gtk/gtktreeselection.c (gtk_tree_selection_get_selected): Clear
|
* gtk/gtktreeselection.c (gtk_tree_selection_get_selected): Clear
|
||||||
the iter instead of returning it unmodified. (#154186, Jonathan Blandford)
|
the iter instead of returning it unmodified. (#154186, Jonathan Blandford)
|
||||||
|
|
||||||
|
@ -1,5 +1,8 @@
|
|||||||
2004-10-06 Matthias Clasen <mclasen@redhat.com>
|
2004-10-06 Matthias Clasen <mclasen@redhat.com>
|
||||||
|
|
||||||
|
* gtk/gtkpaned.c (gtk_paned_compute_position): Reduce rounding
|
||||||
|
error. (#154658, John Cupitt)
|
||||||
|
|
||||||
* gtk/gtktreeselection.c (gtk_tree_selection_get_selected): Clear
|
* gtk/gtktreeselection.c (gtk_tree_selection_get_selected): Clear
|
||||||
the iter instead of returning it unmodified. (#154186, Jonathan Blandford)
|
the iter instead of returning it unmodified. (#154186, Jonathan Blandford)
|
||||||
|
|
||||||
|
@ -1180,9 +1180,9 @@ gtk_paned_compute_position (GtkPaned *paned,
|
|||||||
else if (!paned->child1_resize && paned->child2_resize)
|
else if (!paned->child1_resize && paned->child2_resize)
|
||||||
paned->child1_size = child1_req;
|
paned->child1_size = child1_req;
|
||||||
else if (child1_req + child2_req != 0)
|
else if (child1_req + child2_req != 0)
|
||||||
paned->child1_size = allocation * ((gdouble)child1_req / (child1_req + child2_req));
|
paned->child1_size = allocation * ((gdouble)child1_req / (child1_req + child2_req)) + 0.5;
|
||||||
else
|
else
|
||||||
paned->child1_size = allocation * 0.5;
|
paned->child1_size = allocation * 0.5 + 0.5;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -1194,7 +1194,7 @@ gtk_paned_compute_position (GtkPaned *paned,
|
|||||||
if (paned->child1_resize && !paned->child2_resize)
|
if (paned->child1_resize && !paned->child2_resize)
|
||||||
paned->child1_size += allocation - paned->last_allocation;
|
paned->child1_size += allocation - paned->last_allocation;
|
||||||
else if (!(!paned->child1_resize && paned->child2_resize))
|
else if (!(!paned->child1_resize && paned->child2_resize))
|
||||||
paned->child1_size = allocation * ((gdouble) paned->child1_size / (paned->last_allocation));
|
paned->child1_size = allocation * ((gdouble) paned->child1_size / (paned->last_allocation)) + 0.5;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user