Package com.cloud.consoleproxy.vnc.packet.server

Examples of com.cloud.consoleproxy.vnc.packet.server.Rect


            int height = is.readUnsignedShort();

            int encodingType = is.readInt();

            // Process rectangle
            Rect rect;
            switch (encodingType) {

            case RfbConstants.ENCODING_RAW: {
                rect = new RawRect(screen, x, y, width, height, is);
                break;
            }

            case RfbConstants.ENCODING_COPY_RECT: {
                rect = new CopyRect(x, y, width, height, is);
                break;
            }

            case RfbConstants.ENCODING_DESKTOP_SIZE: {
                rect = new FrameBufferSizeChangeRequest(canvas, width, height);
                if (this.clientListener != null)
                    this.clientListener.onFramebufferSizeChange(width, height);
                break;
            }

            default:
                throw new RuntimeException("Unsupported ecnoding: " + encodingType);
            }

            paint(rect, canvas);

            if (this.clientListener != null)
                this.clientListener.onFramebufferUpdate(rect.getX(), rect.getY(), rect.getWidth(), rect.getHeight());
        }

    }
View Full Code Here

TOP

Related Classes of com.cloud.consoleproxy.vnc.packet.server.Rect

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.