Package: com.multiversesocial.hyperview
Class: com.multiversesocial.hyperview.Gadget
Source: src/com/multiversesocial/hyperview/Gadget.java
A Gadget is a Gob(), but can have a Dispatch() Object attached. todo move all initialization to init
cursor.gifpublic class Gadget extends Gob implements HyperConstants
| Declaration | Value / initializer | Description | Source |
|---|---|---|---|
Color backColor | No comment in source; assigned in cleanUp(); used in toString(). | ||
Font conFont | No comment in source; assigned in Gadget(), cleanUp(); used in makeBitmap(), toString(). | ||
Graphics cursorGraphics | No comment in source; assigned in cleanUp(); used in toString(). | ||
int cursorHeight | No comment in source; assigned in Gadget(); used in drawCursor(). | ||
Image cursorImage | No comment in source; assigned in cleanUp(); used in toString(). | ||
String cursorName | No comment in source; assigned in Gadget(), cleanUp(); used in toString(). | ||
int cursorScrollXOffset | No comment in source; assigned in Gadget(); used in toString(). | ||
int cursorScrollYOffset | No comment in source; assigned in Gadget(). | ||
int cursorWidth | No comment in source; assigned in Gadget(); used in drawCursor(), toString(). | ||
int cursorX | No comment in source; assigned in Gadget(); used in drawCursor(), toString(). | ||
int cursorY | No comment in source; assigned in Gadget(); used in drawCursor(), toString(). | ||
volatile int displayInfo | No comment in source; assigned in Gadget(); used in toString(). | ||
Color fGColor | No comment in source; assigned in Gadget(), cleanUp(); used in toString(). | ||
byte flipCount | No comment in source; assigned in Gadget(); used in toString(). | ||
int font | No comment in source; assigned in Gadget(), makeBitmap(); used in toString(). | ||
volatile int gadFlags | No comment in source; assigned in Gadget(), setEnabled(), addDispatch(), onMouseOver(), keyReleaseENA() …; used in isEnabled(), drawCursor(), makeBitmap(), toString(). | ||
volatile int gadFlags2 | No comment in source; assigned in Gadget(); used in toString(). | ||
int gadNumber | No comment in source; assigned in Gadget(); used in toString(). | ||
HyperKeyboard keyboard | = null | No comment in source; assigned in Gadget(), cleanUp(). | |
int lastCursorX | No comment in source; assigned in Gadget(); used in toString(). | ||
int lastCursorY | No comment in source; assigned in Gadget(); used in toString(). | ||
Color lineColorA | 3 colors Bright, Medium , dark | ||
Color lineColorB | Active GetString gets A,B otherwise B,C | ||
Color lineColorC | No comment in source; assigned in drawOutline(), drawOutline2(), cleanUp(); used in toString(). | ||
boolean locked | No comment in source; assigned in Gadget(). | ||
Dispatch method | No comment in source; assigned in addDispatch(); used in Gadget(), toString(). | ||
Titlebar parentTitlebar | No comment in source; assigned in Gadget(), cleanUp(). | ||
int stringHeight | No comment in source; assigned in Gadget(), makeBitmap(); used in toString(). | ||
int stringWidth | No comment in source; assigned in Gadget(), makeBitmap(); used in toString(). | ||
int stringX | No comment in source; assigned in Gadget(), makeBitmap(); used in setName(), toString(). | ||
int stringY | No comment in source; assigned in Gadget(), makeBitmap(); used in setName(), toString(). | ||
Color tc1 | scratch color references | ||
Color tc2 | No comment in source; assigned in makeBitmap(), cleanUp(). | ||
Color tc3 | No comment in source; assigned in makeBitmap(), cleanUp(). | ||
Color tc4 | No comment in source; assigned in makeBitmap(), cleanUp(). |
| Signature | Description | Source |
|---|---|---|
public Gadget() | 24 statement(s); calls super(); creates Color. | |
public Gadget(String tName) | 1 statement(s); calls this(). | |
public Gadget(HyperView tView, String tName) | 1 statement(s); calls this(). | |
public Gadget(String tName, int pX, int pY) | 1 statement(s); calls this(), HyperView.getCurView(). | |
public Gadget(String tName, int pX, int pY, Font tmpFont) | 1 statement(s); calls this(), HyperView.getCurView(). | |
public Gadget(HyperView tView, String tString, int pX, int pY, int tWidth, int tHeight) | 1 statement(s); calls this(). | |
public Gadget(String tString, int pX, int pY, int tWidth, int tHeight) | 1 statement(s); calls this(), HyperView.getCurView(). | |
public Gadget(Dispatch tDispatch, String tName, int pX, int pY) | 1 statement(s); calls this(). | |
public Gadget(HyperView tView, String tName, int pX, int pY) | 1 statement(s); calls this(). | |
public Gadget(HyperView tView, String tName, int pX, int pY, Font tmpFont) | 1 statement(s); calls this(). | |
public Gadget(HyperView tView, String tName, int pX, int pY, int tWidth, int tHeight, Font tmpFont) | 1 statement(s); calls this(). | |
public Gadget(HyperView tView, String tName, int pX, int pY, int tWidth, int tHeight, int tGobFlags, int tGadFlags, Font tmpFont) | 1 statement(s); calls this(). | |
public Gadget(HyperView tView, String tName, Titlebar tTilebar, int pX, int pY, int tWidth, int tHeight, int tGobFlags, int tGadFlags, Font tmpFont) | 51 statement(s); calls super(), HyperView.getCurView(), System.exit(), addDispatch(), makeBitmap() …; creates Color, Dispatch. |
| Signature | Description | Source |
|---|---|---|
public void addDispatch(Dispatch d) | 2 statement(s). | |
public void allKeyMsgENA() | 1 statement(s). | |
public void cleanUp() | 16 statement(s); calls super.cleanUp(), cursorImage.flush(), cursorGraphics.dispose(). | |
public void drawCursor() | 4 statement(s); calls graphics.setColor(), graphics.fillRect(), Math.max(). | |
public void drawOutline() | 8 statement(s); calls lineColorA.darker(), lineColorB.darker(), graphics.setColor(), graphics.drawLine(). | |
public void drawOutline2() | 8 statement(s); calls lineColorA.darker(), lineColorB.darker(), graphics.setColor(), graphics.drawLine(). | |
public Color getForeground() | Returns curView.color[fGPen]. | |
public void inKey() | 1 statement(s); calls curView.hyperViewOut(). | |
public void inString(String str) | 1 statement(s); calls curView.hyperViewOut(). | |
public boolean isEnabled() | 1 statement(s). | |
public boolean isShowing() | 1 statement(s). | |
public boolean isVisible() | Returns this.isShowing(). | |
public void keyReleaseENA() | 1 statement(s). | |
public void keyTypedENA() | 1 statement(s). | |
public void layerDisable() | 1 statement(s). | |
public void layerENA() | 1 statement(s). | |
public void makeBitmap(Font tmpFont) | 25 statement(s); calls curView.screenGraphics.getFontMetrics(), fm.stringWidth(), fm.getHeight(), curView.createImage(), gobPic.getGraphics() …; creates URL. | |
public void mouseWheelMoved(MouseWheelEvent e) | 1 statement(s); calls e.getWheelRotation(). | |
public void onMouseOver() | stubs to keep javac happy | |
public void setEnabled(boolean b) | 1 statement(s). | |
public void setForeground(int c) | Sets this.fGPen = c. | |
public void setName(String tStr) | 7 statement(s); calls graphics.setColor(), graphics.fillRect(), graphics.drawString(). | |
public void setVisible(boolean b) | 1 statement(s). | |
public void toFront() | 1 statement(s); calls curView.gadgetToFront(), curView.blitterLock.notifyAll(). | |
public String toString() | 86 statement(s); calls sb.append(), method.toString(), cursorImage.toString(), cursorGraphics.toString(), conFont.toString() …; creates StringBuilder. | |
public void updateText() | 1 statement(s); calls curView.statusText(). |
Fields: asynchGraphics1, asynchGraphics2, asynchImage1, asynchImage2, attachedGob, attachedIndex, backGround, bgMemoryImageSource, bGPen, bottomMax, clickX, clickY, collisionClassMask, curAttached, currentZIndex, curView, depth, destGob, destGraphics, dispatchHoldCount, drawMode, dX, dY, dZ, fgMemoryImageSource, fGPen, gobEventFlags, gobFlags, gobFlags2, gobGadIndex, gobHx, gobHy, gobHz, gobName, gobNumber, gobOrbitRadius, gobPic, gobTypeFlags, graphics, gravity, height, heightBase, hSin, hyp, infoString, lClickX, lClickY, leftMin, maxAttached, memoryCounter, moveNum, mX, mX2, mY, mY2, oldX, oldY, oldZ, orbitGob, rightMax, scanLine, selectGraphics, selectImage, selectTime, spline, tint, topMin, totalAttached, width, widthBase, wSin, x, x2, y, y2, z
Methods: addGob(Gob), addSpline(Spline), center(), collisionOff(), collisionOn(), disable(), enable(), getGraphics(), getImageFromJar(String), getPixels(), gobZInit(), initScanline(int), inView(), isInView(), isMemoryImageSource(), move(int, int), move(Gadget, int, int), moveNext(), onClick(), onDisplay(), onRelease(), printGobAttr(HyperView), printScanLines(), remGob(), remove(), zENA(), zOff()
Fields: attachment, index, linkFlags, name, next, parentList, prev
Methods: inList()
instantiation — ChannelControlPane.java, line 90
89 //
90 newChannelGadget = new Gadget(" New ",438,29);
subclass — BasicPane.java, line 5
5 public class BasicPane extends Gadget
6 {
declaration — ColorPop.java, line 12
12 Gadget okGadget;
Supplies the input hooks a ported applet’s pane overrides: inKey(), onMouseOver(), mouseWheelMoved(), plus onClick()/onRelease() from Gob and addDispatch(). See the Applet Migration Guide.