亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? photoframe.java

?? Photoalbum,開發于J2ME
?? JAVA
?? 第 1 頁 / 共 2 頁
字號:
        this.style = style;        genFrame(style, imageX, imageY, imageWidth, imageHeight);    }    /**     * Get the style being used for borders.     * @return the style.     */    int getStyle() {        return style;    }    /**     * Notified when Canvas is made visible.     * If there is more than one image to display     * create the thread to run the animation timing.     */    protected void showNotify() {        if ((images != null) && (images.size() > 1)) {            thread = new Thread(this);            thread.start();        }    }    /**     * Notified when the Canvas is no longer visible.     * Signal the running Thread that it should stop.     */    protected void hideNotify() {        thread = null;    }    /**     * Return true if the specified rectangle does not intersect     * the clipping rectangle of the graphics object.  If it returns     * true then the object must be drawn otherwise it would be clipped     * completely.     * The checks are done     * @param g the Graphics context to check.     * @param x the x value of the upper left corner of the rectangle     * @param y the y value of the upper left corner of the rectangle     * @param w the width of the rectangle     * @param h the height of the rectangle     * @return true if the rectangle intersects the clipping region     */    boolean intersectsClip(Graphics g, int x, int y, int w, int h) {        int cx = g.getClipX();        if ((x + w) <= cx) {            return false;        }        int cw = g.getClipWidth();        if (x > (cx + cw)) {            return false;        }        int cy = g.getClipY();        if ((y + h) <= cy) {            return false;        }        int ch = g.getClipHeight();        if (y > (cy + ch)) {            return false;        }        return true;    }    /**     * Runs the animation and makes the repaint requests.     * The thread will exit when it is no longer the current     * Animation thread.     */    public void run() {        Thread mythread = Thread.currentThread();        long scheduled = System.currentTimeMillis();        statsTime = scheduled;        paintTime = scheduled;        frameCount = 0;        frameRate = 0;        /*         * The following code was changed to fix bug 4918599.         * The bug is caused by a deadlock caused by         * bad-designed use of synchronized blocks in demo.         */        while (thread == mythread) {            // Update when the next frame should be drawn            // and compute the delta till then            scheduled += speeds[speed];            long delta = scheduled - paintTime;            if (delta > 0) {                synchronized (this) {                    try {                        this.wait(delta);                    } catch (InterruptedException e) {                    }                }            }            // Advance and repaint the screen            next();            repaint();            serviceRepaints();        }    }    /**     * Paint is called whenever the canvas should be redrawn.     * It clears the canvas and draws the frame and the current     * current frame from the animation.     * @param g the Graphics context to which to draw     */    protected void paint(Graphics g) {        paintTime = System.currentTimeMillis();        if (image != null) {            // Draw the frame unless only the picture is being re-drawn            // This is the inverse of the usual clip check.            int cx = 0;            // Draw the frame unless only the picture is being re-drawn            // This is the inverse of the usual clip check.            int cy = 0;            // Draw the frame unless only the picture is being re-drawn            // This is the inverse of the usual clip check.            int cw = 0;            // Draw the frame unless only the picture is being re-drawn            // This is the inverse of the usual clip check.            int ch = 0;            if (((cx = g.getClipX()) < imageX) || ((cy = g.getClipY()) < imageY) ||                    ((cx + (cw = g.getClipWidth())) > (imageX + imageWidth)) ||                    ((cy + (ch = g.getClipHeight())) > (imageY + imageHeight))) {                g.drawImage(image, 0, 0, Graphics.LEFT | Graphics.TOP);                if (frameRate > 0) {                    g.fillRect(0, getHeight(), 60, 20);                    g.drawString("FPS = " + frameRate, 0, getHeight(),                        Graphics.BOTTOM | Graphics.LEFT);                }            }            // Draw the image if it intersects the clipping region            if ((images != null) && (index < images.size()) &&                    intersectsClip(g, imageX, imageY, imageWidth, imageHeight)) {                g.drawImage((Image)images.elementAt(index), imageX, imageY,                    Graphics.LEFT | Graphics.TOP);            }            frameCount++;            // Update Frame rate            int delta = (int)(paintTime - statsTime);            if ((delta > 1000) && (delta < 10000)) {                frameRate = (((frameCount * 1000) + 500) / delta);                frameCount = 0;                statsTime = paintTime;                repaint(); // queue full repaint to display frame rate            }        }    }    /**     * Paint the photo frame into the buffered screen image.     * This will avoid drawing each of its parts on each repaint.     * Paint will only need to put the image into the frame.     * @param style the style of frame to draw.     * @param x the x offset of the image.     * @param y the y offset of the image     * @param width the width of the animation image     * @param height the height of the animation image     */    private void genFrame(int style, int x, int y, int width, int height) {        Graphics g = image.getGraphics();        // Clear the entire image to white        g.setColor(0xffffff);        g.fillRect(0, 0, image.getWidth() + 1, image.getHeight() + 1);        // Set the origin of the image and paint the border and image.        g.translate(x, y);        paintBorder(g, style, width, height);    }    /**     * Draw a border of the selected style.     * @param g graphics context to which to draw.     * @param style of the border to display     * @param w the width reserved for the image     * @param h the height reserved of the image     * @see setStyle     */    private void paintBorder(Graphics g, int style, int w, int h) {        if (style == 1) {            g.setGrayScale(128);            g.drawRect(-1, -1, w + 1, h + 1);            g.drawRect(-2, -2, w + 3, h + 3);        }        if (style == 2) {            // Draw fancy border with image between outer and inner rectangles            if (bimage == null) {                bimage = genBorder(); // Generate the border image            }            int bw = bimage.getWidth();            int bh = bimage.getHeight();            int i;            // Draw the inner and outer solid border            g.setGrayScale(128);            g.drawRect(-1, -1, w + 1, h + 1);            g.drawRect(-bw - 2, -bh - 2, w + (bw * 2) + 3, h + (bh * 2) + 3);            // Draw it in each corner            g.drawImage(bimage, -1, -1, Graphics.BOTTOM | Graphics.RIGHT);            g.drawImage(bimage, -1, h + 1, Graphics.TOP | Graphics.RIGHT);            g.drawImage(bimage, w + 1, -1, Graphics.BOTTOM | Graphics.LEFT);            g.drawImage(bimage, w + 1, h + 1, Graphics.TOP | Graphics.LEFT);            // Draw the embedded image down left and right sides            for (i = ((h % bh) / 2); i < (h - bh); i += bh) {                g.drawImage(bimage, -1, i, Graphics.RIGHT | Graphics.TOP);                g.drawImage(bimage, w + 1, i, Graphics.LEFT | Graphics.TOP);            }            // Draw the embedded image across the top and bottom            for (i = ((w % bw) / 2); i < (w - bw); i += bw) {                g.drawImage(bimage, i, -1, Graphics.LEFT | Graphics.BOTTOM);                g.drawImage(bimage, i, h + 1, Graphics.LEFT | Graphics.TOP);            }        }    }    /**     * Create an image for the border.     * The border consists of a simple "+" drawn in a 5x5 image.     * Fill the image with white and draw the "+" as magenta.     * @return the image initialized with the pattern     */    private Image genBorder() {        Image image = Image.createImage(5, 5);        Graphics g = image.getGraphics();        g.setColor(255, 255, 255);        g.fillRect(0, 0, 5, 5);        g.setColor(128, 0, 255);        g.drawLine(2, 1, 2, 3); // vertical        g.drawLine(1, 2, 3, 2); // horizontal        return image;    }}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲婷婷在线视频| 成人性生交大片免费| 国产一区二区三区精品欧美日韩一区二区三区 | 国产精品欧美精品| 午夜不卡在线视频| 99在线精品免费| 精品日韩一区二区| 日韩精品亚洲专区| 91麻豆免费观看| 国产日本欧美一区二区| 另类小说视频一区二区| 欧美人妖巨大在线| 亚洲精品水蜜桃| kk眼镜猥琐国模调教系列一区二区| 欧美一二三四区在线| 亚洲午夜精品网| 91成人在线观看喷潮| 国产精品久久久久久亚洲伦| 国内外成人在线| 欧美成人国产一区二区| 日韩va亚洲va欧美va久久| 欧美艳星brazzers| 亚洲一二三区视频在线观看| 色吧成人激情小说| 17c精品麻豆一区二区免费| 国产aⅴ综合色| 久久久噜噜噜久久人人看 | 国产在线精品一区在线观看麻豆| 欧美日韩国产在线观看| 亚洲成人av福利| 欧美午夜精品久久久久久超碰| 亚洲精品自拍动漫在线| 在线欧美小视频| 亚洲老妇xxxxxx| 欧美日韩一区三区四区| 亚洲成年人影院| 欧美一区二区视频免费观看| 日韩经典中文字幕一区| 欧美一卡2卡3卡4卡| 日本va欧美va精品| 精品国产三级电影在线观看| 国产酒店精品激情| 国产精品天天看| 色狠狠av一区二区三区| 香蕉成人伊视频在线观看| 欧美一区欧美二区| 精品亚洲国内自在自线福利| 久久免费看少妇高潮| 懂色中文一区二区在线播放| 中文字幕成人在线观看| 色中色一区二区| 亚洲va韩国va欧美va精品| 日韩一区二区免费在线观看| 国产毛片精品国产一区二区三区| 国产日产欧美一区二区视频| 91视频在线观看| 午夜精品久久久久久久久久| 日韩一区和二区| 国产高清不卡二三区| 国产精品视频免费看| 日本丶国产丶欧美色综合| 日本不卡123| 国产精品女主播av| 在线播放国产精品二区一二区四区| 伦理电影国产精品| 国产精品久久久久aaaa| 欧美久久久一区| 国产suv精品一区二区三区| 亚洲第一成人在线| 国产精品人人做人人爽人人添| 欧美日韩精品免费| 国产成人福利片| 亚洲成在人线免费| 中文字幕欧美日韩一区| 欧美电影在哪看比较好| 不卡一区二区三区四区| 奇米精品一区二区三区在线观看 | 国产1区2区3区精品美女| 亚洲一区二区三区视频在线播放 | 国产精品性做久久久久久| 亚洲一区国产视频| 国产喂奶挤奶一区二区三区| 欧美日韩在线精品一区二区三区激情| 久久国产乱子精品免费女| 亚洲欧美日本韩国| 国产三级精品三级| 日韩一级黄色大片| 欧美中文字幕一二三区视频| 国产精品18久久久久久久久| 午夜精品福利在线| 最新热久久免费视频| 精品国产1区二区| 欧美人成免费网站| 欧美性生交片4| 91在线免费看| 成人永久aaa| 国产在线观看免费一区| 免费成人你懂的| 亚洲高清在线精品| 亚洲精品日产精品乱码不卡| 国产精品久久久久婷婷| 久久人人爽爽爽人久久久| 日韩午夜激情免费电影| 欧美日韩精品二区第二页| 91丨九色丨黑人外教| 成人白浆超碰人人人人| 国产成人精品综合在线观看| 国产一区 二区 三区一级| 久久精品国产**网站演员| 天天av天天翘天天综合网色鬼国产| 亚洲男人都懂的| 国产精品久久久久影院亚瑟| 日本一区二区三区免费乱视频| 久久日韩粉嫩一区二区三区| 欧美成人国产一区二区| 精品国产伦一区二区三区免费| 日韩视频免费直播| 久久影院视频免费| 欧美国产激情二区三区| 国产精品电影一区二区三区| 国产精品卡一卡二| 一区二区三区日韩精品视频| 亚洲图片欧美色图| 日韩精品高清不卡| 精品亚洲免费视频| 国产成人福利片| 91色九色蝌蚪| 欧美午夜精品久久久久久孕妇| 欧美日韩久久久一区| 日韩欧美一区二区免费| 久久久亚洲精品石原莉奈| 国产精品天天看| 樱桃视频在线观看一区| 日韩福利电影在线观看| 韩日精品视频一区| a亚洲天堂av| 欧美日产国产精品| 欧美zozozo| 国产精品人人做人人爽人人添| 一区二区三区产品免费精品久久75| 污片在线观看一区二区| 国产又黄又大久久| 色综合中文综合网| 激情综合网av| 成人国产免费视频| 在线视频国内一区二区| 日韩欧美国产精品| 日韩毛片精品高清免费| 婷婷成人激情在线网| 国产一区二区三区| 色欧美片视频在线观看在线视频| 6080日韩午夜伦伦午夜伦| 欧美激情综合五月色丁香| 亚洲高清中文字幕| 国产91精品欧美| 欧美日韩国产综合一区二区| 久久精品欧美一区二区三区不卡| 一卡二卡三卡日韩欧美| 国精品**一区二区三区在线蜜桃| jvid福利写真一区二区三区| 日韩一级免费观看| 亚洲激情欧美激情| 极品美女销魂一区二区三区 | 一区二区三区四区视频精品免费| 久久国产麻豆精品| 欧美午夜寂寞影院| 欧美国产成人在线| 久久er99精品| 欧美日韩综合在线免费观看| 国产精品人成在线观看免费| 毛片基地黄久久久久久天堂| 在线视频你懂得一区二区三区| 国产亚洲欧美色| 日韩二区三区在线观看| 91浏览器在线视频| 国产欧美一二三区| 国产一区二区三区高清播放| 91精品欧美一区二区三区综合在| 中文字幕日本不卡| 国产成人在线免费观看| 欧美va亚洲va香蕉在线| 午夜视频在线观看一区二区三区| 成人av动漫网站| 日本一区二区在线不卡| 久久成人精品无人区| 欧美一级理论片| 三级亚洲高清视频| 欧美午夜精品久久久久久超碰 | 欧美精彩视频一区二区三区| 老司机午夜精品| 欧美精品1区2区| 一级特黄大欧美久久久| 一本久久综合亚洲鲁鲁五月天| 亚洲国产激情av| 国产凹凸在线观看一区二区| 久久久精品蜜桃| 国产精品1024久久| 国产嫩草影院久久久久| 国产精品99久久久久| 欧美精品一区视频|