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

fix: treeland适配,调用login1 的session lock触发锁屏 #693

Merged
merged 1 commit into from
Dec 2, 2024

Conversation

fly602
Copy link
Contributor

@fly602 fly602 commented Nov 29, 2024

treeland适配,调用login1 的session lock触发锁屏

Log: treeland适配,调用login1 的session lock触发锁屏
pms: BUG-281261

treeland适配,调用login1 的session lock触发锁屏

Log: treeland适配,调用login1 的session lock触发锁屏
pms: BUG-281261
@deepin-ci-robot
Copy link

deepin pr auto review

代码审查意见:

  1. keybinding1/manager_handlers.go文件中,isTreeLand函数被多次调用,建议将其封装为一个全局函数,以减少重复代码和提高代码的可维护性。

  2. keybinding1/special_keycode.gosession/power1/manager.go文件中,注释掉了一些代码,建议在代码中添加TODO注释,以便后续开发人员了解这些代码的意图和待办事项。

  3. session/power1/manager.go文件中,注释掉了一些关于kwinHanleIdleOffCh的代码,建议在代码中添加TODO注释,以便后续开发人员了解这些代码的意图和待办事项。

  4. session/power1/manager_events.go文件中,handleBeforeSuspend函数中添加了对m.UseWayland的判断,但是没有对m.SleepLock.Get()的判断,可能会导致在某些情况下无法正确锁定会话。

  5. session/power1/power_save_plan.go文件中,makeSystemSleep函数中添加了对psp.manager.UseWayland的判断,但是没有对psp.manager.doSuspendByFront()的调用,可能会导致在某些情况下无法正确进入待机状态。

  6. session/power1/utils.go文件中,doLock函数中添加了对m.UseWayland的判断,但是没有对m.currentSession.Lock(0)的调用,可能会导致在某些情况下无法正确锁定会话。

总体来说,代码中存在一些重复代码和待办事项,建议进行优化和整理,以提高代码的可读性和可维护性。

@deepin-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: ECQZXC, fly602

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

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

@fly602 fly602 merged commit 9403198 into linuxdeepin:master Dec 2, 2024
14 of 16 checks passed
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