1

I am trying to animate an existing actor in gnome-shell. I have tried in a few ways and each time I am able to change the actor location but I am unable to change the actor size.

This is one of the ways I have tried and the actor is changing it's position but don't change the size.

Tweener.addTween(boxa,
{  x1: targetX,
    y1: targetY,
   x2: targetX+targetWidth,
   y2: targetY+targetHeight,
   time: 2,
   transition: "easeOutElastic",
   onUpdate: function (_actor) { _actor.set_position(this.x1, this.y1); 
                                 _actor.set_width(this.x2 - this.x1); 
                                 _actor.set_height(this.y2 - this.y1); 
                                 log("TWEENER x1:" + this.x1 + " x2:"+ this.x2 + " y1:"+ this.y1 + " y2:"+ this.y2)},
   onUpdateParams: [actor],
   onComplete: function (_actor) {shellwm.completed_maximize(_actor)},
   onCompleteParams: [actor]
});

I have also tried using set_width and set_hight directly without success and there are no errors.

palaviv
  • 41
  • 5

0 Answers0