Skip to content

Commit 4824a51

Browse files
committed
fix: adjust search box position for wayland dock overlap
1. Added dynamic bottom margin to search edit in fullscreen mode 2. Query dock height using DS.applet API to detect dock presence 3. Apply margin only on wayland platform (Qt.platform.pluginName === "wayland") 4. Fix visual overlap between dock and search box when dock is visible on wayland Log: Fixed search box overlapping with dock on wayland Influence: 1. Test fullscreen search box position on wayland with dock visible 2. Test fullscreen search box position on x11 to ensure no regression 3. Verify margin is applied correctly when dock height changes 4. Test with different dock sizes and positions fix: 调整 wayland 下搜索框位置以避免与任务栏重叠 1. 在搜索编辑框中添加动态底部边距 2. 使用 DS.applet API 查询任务栏高度以检测任务栏是否存在 3. 仅在 wayland 平台下应用边距(Qt.platform.pluginName === "wayland") 4. 修复 wayland 下任务栏可见时与搜索框的视觉重叠问题 Log: 修复 wayland 下搜索框与任务栏重叠问题 Influence: 1. 在 wayland 下测试任务栏可见时的全屏搜索框位置 2. 在 x11 下测试全屏搜索框位置,确保无回归 3. 验证任务栏高度变化时边距是否正确应用 4. 测试不同任务栏大小和位置 PMS: BUG-345751 BUG-345737
1 parent d6f73a7 commit 4824a51

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

qml/FullscreenFrame.qml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import QtQuick.Layouts 1.15
99
import QtQuick.Controls 2.15
1010
import QtQuick.Window 2.15
1111
import org.deepin.dtk 1.0
12-
import org.deepin.dtk.style 1.0 as DS
12+
import org.deepin.ds 1.0
1313

1414
import org.deepin.launchpad 1.0
1515
import org.deepin.launchpad.models 1.0
@@ -760,6 +760,11 @@ InputEventItem {
760760
id: searchEdit
761761

762762
Layout.alignment: Qt.AlignHCenter
763+
Layout.bottomMargin: {
764+
var dock = DS.applet("org.deepin.ds.dock")
765+
var dockHeight = (dock && dock.rootObject) ? dock.rootObject.height : 0
766+
return Qt.platform.pluginName === "wayland" ? dockHeight + 10 : 0
767+
}
763768
implicitWidth: (parent.width / 2) > 280 ? 280 : (parent.width / 2)
764769
opacity: folderGridViewPopup.visible ? 0.4 : 1
765770

0 commit comments

Comments
 (0)