Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
画面にボタンがあります。その画像の x 座標と y 座標を取得したいです。その画像座標を使用して、画像を移動する必要があります。必要な助けが必要です。ありがとうございました
これを試して:
int[] loc = new int[2]; someView.getLocationOnScreen(loc); //loc[0] - x; //loc[1] - y;