tiling fixed

git-svn-id: http://www.neo1973-germany.de/svn@224 46df4e5c-bc4e-4628-a0fc-830ba316316d
main
fgau 16 years ago
parent 5415938d0b
commit 520c7230d4

@ -171,10 +171,19 @@ collections {
}
}
}
part {
name: "clipper";
type: RECT;
description {
rel1 { relative: 1/2 1/2; offset: -180 -180; }
rel2 { relative: 1/2 1/2; offset: 180 180; }
}
}
part {
name: "icon";
mouse_events: 0;
type: SWALLOW;
mouse_events: 0;
clip_to: "clipper";
description {
/*fixed: 1 1;*/
rel1 { relative: 1/2 1/2; offset: -180 -180; }

@ -33,21 +33,21 @@ class HonScreen(EdjeGroup):
self.image = self.evas.Image(file=self.pix)
x, y = self.image.image_size
dx, dy = self.part_size_get('icon')
# self.image.geometry = 0, 0 , 100, 100
# self.image.show()
if x * dy > y * dx:
y = y * dx / x
x = dx
else:
x = x * dy / y
y = dy
print 'x,y: ', x, y, dx, dy
# self.obj.show()
print 'x, y, dx, dy: ', x, y, dx, dy
self.image.fill = 0, 0, x, y
self.part_swallow('icon', self.image)
self.obj = self.part_object_get('clipper')
self.obj.size = x, y
self.obj.show()
print 'obj: ', self.obj
def delete(self):
self.image.hide()
EdjeGroup.hide(self)
@edje.decorators.signal_callback("mouse,up,1", "*")

Loading…
Cancel
Save