我有一个用户已经从三星Galaxy S6 Edge升级到三星Galaxy S7 Edge。
我的应用程序可以拖放扑克牌图像。
用户指出此功能在S7边缘上不起作用,但在S6边缘上起作用。
拖动工作正常,这表明onTouch()和onDrag()正在工作,但当对象被拖放时,它会返回到其原始位置,而不是所需的位置。
protected void measureDisplay() {
// get info about screen size to determine style of images to use
display = getWindowManager().getDefaultDisplay();
size = new Point();
display.getSize(size);
displayMetrics = new DisplayMetrics();
// get the density of the display
display.getMetrics(displayMetrics);
width = size.x;
height = size.y;
}
private void measureBoard(View v) {
// get the current view width and height
float viewWidth = v.getWidth();
float viewHeight = v.getHeight();
// extract the image offsets inside the view
Matrix matrix = ((ImageView) v).getImageMatrix();
float[] values = new float[9];
matrix.getValues(values);
boardLeft = values[2]; // the X offset
boardRight = viewWidth - boardLeft;
boardTop = values[5]; // the Y offset
boardBottom = viewHeight - boardTop;
cardOffsetW = (boardRight - boardLeft) / 10;
cardOffsetH = (boardBottom - boardTop) / 10;
}发布于 2016-07-22 08:21:04
至少可以通过找出用户是否安装了三星的游戏调谐器来解决幕后显示缩放的一些问题。它改变了任何“游戏”应用程序的分辨率,并且可能在从未打开过的情况下进行。
要解决此问题,请要求用户在game Tuner中为您的游戏指定分辨率(他们可以在每个应用程序的基础上执行此操作)。点击此处查看更多信息:DragEventListener not working on Samsung S7 (6.0)
我正在为我的游戏更新,这将弹出一条消息,如果他们安装了游戏调谐器。
发布于 2016-10-21 07:56:53
这个应用程序:https://play.google.com/store/apps/details?id=com.evozi.displayscaling将解决三星设备上的问题。在我们的游戏中,我们遇到了类似的问题,解决方案就是更改设置。我希望三星将提供一些下一个操作系统更新的修复,所以我们确实需要通知用户这个错误,并迫使他们改变设置。
https://stackoverflow.com/questions/36073949
复制相似问题