Skip to content

Commit

Permalink
Merge branch 'master' into dcc-icon
Browse files Browse the repository at this point in the history
  • Loading branch information
FeiWang1119 authored Jul 5, 2024
2 parents 3f51307 + 756f007 commit a40659f
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 6 deletions.
2 changes: 1 addition & 1 deletion cmake/DdeDock/DdeDockConfig.cmake.in
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
set(DDE_DOCK_INCLUDE_DIR @CMAKE_INSTALL_FULL_INCLUDEDIR@/dde-tray-loader)
set(DDE_DOCK_INCLUDE_DIR @CMAKE_INSTALL_FULL_INCLUDEDIR@/dde-dock)
include_directories("${DDE_DOCK_INCLUDE_DIR}")

2 changes: 1 addition & 1 deletion cmake/DdeTrayLoader/DdeTrayLoaderConfig.cmake.in
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
set(DDE_TRAY_LOADER_INCLUDE_DIR @CMAKE_INSTALL_FULL_INCLUDEDIR@/dde-tray-loader)
set(DDE_TRAY_LOADER_INCLUDE_DIR @CMAKE_INSTALL_FULL_INCLUDEDIR@/dde-dock)
set(DDE_TRAY_LOADER_PROTOCOL @CMAKE_INSTALL_FULL_INCLUDEDIR@/dde-tray-loader/protocol/plugin-manager-v1.xml)
include_directories("${DDE_TRAY_LOADER_INCLUDE_DIR}")
11 changes: 7 additions & 4 deletions src/tray-wayland-integration/pluginsurface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,14 @@ void PluginSurface::plugin_close()

void PluginSurface::plugin_geometry(int32_t x, int32_t y, int32_t width, int32_t height)
{
if (width > 0 && height > 0) {
m_window->setGeometry(x, y, width, height);
}
QRect rect(x, y, width, height);
if (width <= 0)
rect.setWidth(m_window->width());
if (height <= 0)
rect.setHeight(m_window->height());

Q_EMIT m_plugin->eventGeometry(QRect(x, y, width, height));
m_window->setGeometry(rect);
Q_EMIT m_plugin->eventGeometry(rect);
}

void PluginSurface::plugin_raw_global_pos(int32_t x, int32_t y)
Expand Down

0 comments on commit a40659f

Please sign in to comment.