JavaTM 2 Platform
Standard Ed. 5.0

java.awt
クラス PointerInfo

java.lang.Object
  上位を拡張 java.awt.PointerInfo

public class PointerInfo
extends Object

ポインタの位置を示すクラスです。ポインタの位置を示す GraphicsDevice およびポインタの座標を表す Point を提供します。

このクラスのインスタンスは MouseInfo.getPointerInfo() を介して取得する必要があります。PointerInfo インスタンスは、マウスが移動しても動的に更新されません。更新された位置を取得するには、再度 MouseInfo.getPointerInfo() を呼び出す必要があります。

導入されたバージョン:
1.5
関連項目:
MouseInfo.getPointerInfo()

メソッドの概要
 GraphicsDevice getDevice()
          この PointerInfo が作成された時点のマウスポインタの位置を示す GraphicsDevice を返します。
 Point getLocation()
          画面上のポインタの座標を表す Point を返します。
 
クラス java.lang.Object から継承されたメソッド
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

メソッドの詳細

getDevice

public GraphicsDevice getDevice()
この PointerInfo が作成された時点のマウスポインタの位置を示す GraphicsDevice を返します。

戻り値:
ポインタに対応する GraphicsDevice
導入されたバージョン:
1.5

getLocation

public Point getLocation()
画面上のポインタの座標を表す Point を返します。マルチスクリーンシステムの座標計算の詳細については MouseInfo.getPointerInfo() を参照してください。

戻り値:
マウスポインタの座標
導入されたバージョン:
1.5
関連項目:
MouseInfo, MouseInfo.getPointerInfo()

JavaTM 2 Platform
Standard Ed. 5.0

バグの報告と機能のリクエスト
さらに詳しい API リファレンスおよび開発者ドキュメントについては、Java 2 SDK SE 開発者用ドキュメントを参照してください。開発者向けの詳細な解説、概念の概要、用語の定義、バグの回避策、およびコード実例が含まれています。

Copyright 2004 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. Documentation Redistribution Policy も参照してください。