01: /*
02: *
03: *
04: * Copyright 1990-2007 Sun Microsystems, Inc. All Rights Reserved.
05: * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER
06: *
07: * This program is free software; you can redistribute it and/or
08: * modify it under the terms of the GNU General Public License version
09: * 2 only, as published by the Free Software Foundation.
10: *
11: * This program is distributed in the hope that it will be useful, but
12: * WITHOUT ANY WARRANTY; without even the implied warranty of
13: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14: * General Public License version 2 for more details (a copy is
15: * included at /legal/license.txt).
16: *
17: * You should have received a copy of the GNU General Public License
18: * version 2 along with this work; if not, write to the Free Software
19: * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
20: * 02110-1301 USA
21: *
22: * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa
23: * Clara, CA 95054 or visit www.sun.com if you need additional
24: * information or have any questions.
25: */
26:
27: package javax.microedition.lcdui;
28:
29: /**
30: * Look and Feel interface used by Canvas.
31: * <p>
32: * See <a href="doc-files/naming.html">Naming Conventions</a>
33: * for information about method naming conventions.
34: */
35: interface CanvasLF extends DisplayableLF {
36:
37: /**
38: * Notifies look and feel object that repaint of a (x, y, width, height)
39: * area is needed.
40: *
41: * @param x The x coordinate of the region to repaint
42: * @param y The y coordinate of the region to repaint
43: * @param width The width of the region to repaint
44: * @param height The height of the region to repaint
45: * @param target an optional paint target to receive the paint request
46: * when it returns via callPaint()
47: */
48: void lRepaint(int x, int y, int width, int height, Object target);
49:
50: /**
51: * Notifies that repaint of the entire Canvas look&feel is needed.
52: */
53: void lRepaint();
54:
55: /**
56: * Request serviceRepaints from current Display.
57: * SYNC NOTE: unlike most other methods, no locking is held when
58: * this function is called because Display.serviceRepaints()
59: * needs to handle its own locking.
60: */
61: void uServiceRepaints();
62:
63: /**
64: * Display calls to get key mask of all the keys that were pressed.
65: * @return keyMask The key mask of all the keys that were pressed.
66: */
67: public int uGetKeyMask();
68: }
|