Fixed some missing pieces in unix/container.c.
This commit is contained in:
parent
fbe7324c15
commit
1e2dee7ab3
|
@ -1,25 +1,15 @@
|
||||||
// 13 august 2014
|
// 13 august 2014
|
||||||
#include "uipriv_unix.h"
|
#include "uipriv_unix.h"
|
||||||
|
|
||||||
#define gtkXPadding 12
|
|
||||||
#define gtkYPadding 6
|
|
||||||
|
|
||||||
static void uipOSContainer_size_allocate(GtkWidget *widget, GtkAllocation *allocation)
|
static void uipOSContainer_size_allocate(GtkWidget *widget, GtkAllocation *allocation)
|
||||||
{
|
{
|
||||||
uipOSContainer *c = uipOSContainer(widget);
|
|
||||||
uiSizing d;
|
|
||||||
intmax_t x, y, width, height;
|
intmax_t x, y, width, height;
|
||||||
|
|
||||||
gtk_widget_set_allocation(GTK_WIDGET(c), allocation);
|
|
||||||
if (c->mainControl == NULL)
|
|
||||||
return;
|
|
||||||
x = allocation->x + c->marginLeft;
|
x = allocation->x + c->marginLeft;
|
||||||
y = allocation->y + c->marginTop;
|
y = allocation->y + c->marginTop;
|
||||||
width = allocation->width - (c->marginLeft + c->marginRight);
|
width = allocation->width - (c->marginLeft + c->marginRight);
|
||||||
height = allocation->height - (c->marginTop + c->marginBottom);
|
height = allocation->height - (c->marginTop + c->marginBottom);
|
||||||
d.xPadding = gtkXPadding;
|
|
||||||
d.yPadding = gtkYPadding;
|
|
||||||
uiControlResize(c->mainControl, x, y, width, height, &d);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -66,6 +66,9 @@ static void containerWidget_remove(GtkContainer *container, GtkWidget *widget)
|
||||||
complain("widget %p not found in containerWidget gtk_container_remove()", widget);
|
complain("widget %p not found in containerWidget gtk_container_remove()", widget);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#define gtkXPadding 12
|
||||||
|
#define gtkYPadding 6
|
||||||
|
|
||||||
static void containerWidget_size_allocate(GtkWidget *widget, GtkAllocation *allocation)
|
static void containerWidget_size_allocate(GtkWidget *widget, GtkAllocation *allocation)
|
||||||
{
|
{
|
||||||
containerWidget *c = containerWidget(widget);
|
containerWidget *c = containerWidget(widget);
|
||||||
|
|
Loading…
Reference in New Issue