Skip to content

fix: Uninstalling app in fullscreen doesn't close launcher#549

Merged
BLumia merged 1 commit into
linuxdeepin:masterfrom
wjyrich:fix-bug-315255
May 7, 2025
Merged

fix: Uninstalling app in fullscreen doesn't close launcher#549
BLumia merged 1 commit into
linuxdeepin:masterfrom
wjyrich:fix-bug-315255

Conversation

@wjyrich
Copy link
Copy Markdown
Contributor

@wjyrich wjyrich commented May 6, 2025

fix Uninstalling an app in full screen doesn't close launcher

pms-bug-315255

Summary by Sourcery

Bug Fixes:

  • Prevent launcher from closing when uninstalling an app in fullscreen mode

@sourcery-ai
Copy link
Copy Markdown

sourcery-ai Bot commented May 6, 2025

Reviewer's Guide

This pull request prevents the launcher from being hidden when an app is uninstalled from fullscreen mode by adding a conditional check in AppItemMenu.qml before hiding the LauncherController. Additionally, a call to hide the launcher via a timer in launcheritem.qml was commented out.

Sequence Diagram for Conditional Launcher Visibility on Uninstall

sequenceDiagram
    actor User
    participant AppItemMenu
    participant LauncherController

    User->>AppItemMenu: Trigger Uninstall
    AppItemMenu->>LauncherController: Get currentFrame
    alt currentFrame is not "FullscreenFrame"
        AppItemMenu->>LauncherController: Set visible = false
    else currentFrame is "FullscreenFrame"
        AppItemMenu-->>LauncherController: Do not set visible = false (Launcher remains visible)
    end
    note right of AppItemMenu: Continue with showing uninstall confirmation
Loading

File-Level Changes

Change Details Files
Conditionally hide launcher on uninstall
  • Added a check to ensure LauncherController.visible is only set to false if the currentFrame is not 'FullscreenFrame'.
qml/AppItemMenu.qml
Disable timed launcher hide on focus change
  • Commented out the call to LauncherController.hideWithTimer() in the onActiveFocusChanged handler.
shell-launcher-applet/package/launcheritem.qml

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

Copy link
Copy Markdown

@sourcery-ai sourcery-ai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @wjyrich - I've reviewed your changes - here's some feedback:

  • The commented-out code in launcheritem.qml seems unrelated to the fullscreen uninstall fix; please clarify if this change is intentional.
Here's what I looked at during the review
  • 🟢 General issues: all looks good
  • 🟢 Security: all looks good
  • 🟢 Testing: all looks good
  • 🟢 Complexity: all looks good
  • 🟢 Documentation: all looks good

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

Copy link
Copy Markdown
Member

@BLumia BLumia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

会导致失焦隐藏的行为丢失

@wjyrich wjyrich force-pushed the fix-bug-315255 branch 2 times, most recently from 19a4fc9 to 86a43f3 Compare May 6, 2025 08:43
fix Uninstalling an app in full screen doesn't close launcher

pms-bug-315255
@deepin-ci-robot
Copy link
Copy Markdown

deepin pr auto review

代码审查意见:

  1. launchercontroller.cpp文件中,hideWithTimer函数中新增的if (m_avoidHide)条件判断可能不必要,因为m_pendingHide已经被设置为true,如果m_avoidHidetrue,则setVisible(false);不会执行。建议确认逻辑是否正确,如果m_avoidHidetrue时不需要隐藏,则可以移除该条件判断。

  2. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  3. qml/AppItemMenu.qml文件中,LauncherController.setAvoidHide(true)LauncherController.setAvoidHide(false)的调用可能不正确,因为LauncherController.currentFrame的值在onTriggered事件处理函数中并没有被设置。如果LauncherController.currentFrame的值在事件处理函数中是动态变化的,那么这个逻辑可能需要重新考虑。

  4. shell-launcher-applet/package/launcheritem.qml文件中,LauncherController.setAvoidHide(true)的调用可能不正确,因为LauncherController.currentFrame的值在onVisibleChanged事件处理函数中并没有被设置。如果LauncherController.currentFrame的值在事件处理函数中是动态变化的,那么这个逻辑可能需要重新考虑。

  5. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  6. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  7. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  8. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  9. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  10. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  11. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  12. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  13. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  14. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  15. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  16. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  17. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  18. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  19. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  20. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  21. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  22. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  23. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  24. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  25. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  26. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  27. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  28. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  29. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  30. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  31. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  32. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  33. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  34. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  35. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  36. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  37. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  38. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  39. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  40. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  41. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  42. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  43. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  44. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  45. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  46. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  47. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  48. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  49. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  50. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  51. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  52. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  53. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  54. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  55. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  56. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  57. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  58. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  59. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  60. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

  61. launchercontroller.h文件中,m_avoidHide的默认值被设置为true,但在launchercontroller.cpphideWithTimer函数中并没有使用到这个默认值。如果m_avoidHide的默认值是错误的,应该修正这个默认值。

@deepin-ci-robot
Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: BLumia, wjyrich

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@BLumia BLumia merged commit 9478166 into linuxdeepin:master May 7, 2025
7 of 10 checks passed
@wjyrich wjyrich deleted the fix-bug-315255 branch June 6, 2025 00:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants