mirror of
https://github.com/gyurix1968/guacamole-client.git
synced 2025-09-06 21:27:40 +00:00
Fix distort instruction (called transform() on wrong object). Store matrix.
This commit is contained in:
@@ -752,10 +752,8 @@ Guacamole.Client = function(tunnel) {
|
|||||||
// Only valid for visible layers (not buffers)
|
// Only valid for visible layers (not buffers)
|
||||||
if (layer_index >= 0) {
|
if (layer_index >= 0) {
|
||||||
|
|
||||||
// Get container element
|
|
||||||
var layer_container = getLayerContainer(layer_index).getElement();
|
|
||||||
|
|
||||||
// Set layer transform
|
// Set layer transform
|
||||||
|
var layer_container = getLayerContainer(layer_index);
|
||||||
layer_container.transform(a, b, c, d, e, f);
|
layer_container.transform(a, b, c, d, e, f);
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -1391,6 +1389,16 @@ Guacamole.Client.LayerContainer = function(index, width, height) {
|
|||||||
*/
|
*/
|
||||||
this.z = 0;
|
this.z = 0;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The affine transformation applied to this layer container. Each element
|
||||||
|
* corresponds to a value from the transformation matrix, with the first
|
||||||
|
* three values being the first row, and the last three values being the
|
||||||
|
* second row. There are six values total.
|
||||||
|
*
|
||||||
|
* @type Number[]
|
||||||
|
*/
|
||||||
|
this.matrix = [1, 0, 0, 1, 0, 0];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The width of this layer in pixels.
|
* The width of this layer in pixels.
|
||||||
* @type Number
|
* @type Number
|
||||||
@@ -1585,6 +1593,9 @@ Guacamole.Client.LayerContainer = function(index, width, height) {
|
|||||||
*/
|
*/
|
||||||
this.transform = function(a, b, c, d, e, f) {
|
this.transform = function(a, b, c, d, e, f) {
|
||||||
|
|
||||||
|
// Store matrix
|
||||||
|
layer_container.matrix = [a, b, c, d, e, f];
|
||||||
|
|
||||||
// Generate matrix transformation
|
// Generate matrix transformation
|
||||||
matrix =
|
matrix =
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user