Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG]: HoverCameraController和按钮冲突 #305

Open
OriIIusion opened this issue Sep 19, 2023 · 1 comment
Open

[BUG]: HoverCameraController和按钮冲突 #305

OriIIusion opened this issue Sep 19, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@OriIIusion
Copy link
Contributor

Bug描述

HoverCameraController在使用时,如果鼠标拖动到了UIButton上再松开鼠标,这时移动鼠标(没按住左右键),HoverCameraController仍然在起作用。

Bug复现流程

通过以下步骤产生bug:

  1. 在官方教程的用户界面-按钮或者多面板示例中
  2. 场景空白处按下鼠标左键开始旋转视角,将鼠标拖动到按钮或者多面板示例的面板上,松开左键。
  3. 这时再移动鼠标,视角仍然在变动,必须在场景空白处再点一下左键,才能恢复正常。

期待的结果

当未按下鼠标左键移动鼠标时,HoverCameraController不应该起作用。

测试引擎版本:

2023年9月19日 官网示例

个人猜测

当鼠标在按钮热区内抬起时,HoverCameraController的抬起事件被按钮截获,导致移动鼠标时仍然以为左键被按下,导致本BUG的发生。

@OriIIusion
Copy link
Contributor Author

以gui分类下的Sample_UIMultiPanel为例。
修复了以下Bug
1.在空白处按下鼠标左键开始旋转,当鼠标移动到UI上时,HoverController不起作用了,无法继续旋转。
2.在空白处按下鼠标左键开始旋转,当鼠标移动到UI上时松开鼠标,当鼠标移出UI时,会出现鼠标未按下HoverController仍然造成旋转的Bug。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant