summaryrefslogtreecommitdiffstats
path: root/interfaces
diff options
context:
space:
mode:
authorMavridis Philippe <[email protected]>2024-07-08 01:04:09 +0300
committerMavridis Philippe <[email protected]>2024-07-08 01:05:01 +0300
commit87769ed51d8087ddc4a02705f39fe4f21431b66f (patch)
treecf3d12a293a24868641d8c086206da87e3c57ed3 /interfaces
parentc7b0c7b88c1bebb038bd70f4995fc35771fa83c0 (diff)
downloadxdg-desktop-portal-tde-87769ed51d8087ddc4a02705f39fe4f21431b66f.tar.gz
xdg-desktop-portal-tde-87769ed51d8087ddc4a02705f39fe4f21431b66f.zip
Added Email interface, minor refactoring
Signed-off-by: Mavridis Philippe <[email protected]>
Diffstat (limited to 'interfaces')
-rw-r--r--interfaces/CMakeLists.txt45
-rw-r--r--interfaces/interfaces.xml (renamed from interfaces/filechooser.xml)14
2 files changed, 27 insertions, 32 deletions
diff --git a/interfaces/CMakeLists.txt b/interfaces/CMakeLists.txt
index 5a45e9f..d8e44c0 100644
--- a/interfaces/CMakeLists.txt
+++ b/interfaces/CMakeLists.txt
@@ -15,43 +15,24 @@ link_directories(
${DBUS_TQT_LIBRARY_DIRS}
)
-set(interfaces filechooser)
+set(interfaces filechooser email)
+set(interface_HDRS introspectableInterface.h desktopNode.h dbusbaseNode.h)
+set(interface_SRCS introspectableInterface.cpp desktopNode.cpp dbusbaseNode.cpp)
foreach(interface IN LISTS interfaces)
- set(interface_HDRS
- introspectableInterface.h
- ${interface}Interface.h
- ${interface}Proxy.h
- desktopNode.h
- dbusbaseNode.h
- )
-
- set(interface_SRCS
- introspectableInterface.cpp
- ${interface}Interface.cpp
- ${interface}Proxy.cpp
- desktopNode.cpp
- dbusbaseNode.cpp
- )
-
- set(interface_xml ${CMAKE_CURRENT_SOURCE_DIR}/${interface}.xml)
-
- add_custom_command(
- OUTPUT ${interface_HDRS} ${interface_SRCS}
- COMMAND ${DBUSXML2QT3_EXECUTABLE} ${interface_xml}
- DEPENDS ${interface_xml}
- WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
- )
-
- add_custom_target(${interface} DEPENDS ${interface_SRCS})
-
- list(APPEND interfaces_SRCS ${interface_SRCS})
-
+ list(APPEND interface_HDRS ${interface}Interface.h ${interface}Proxy.h)
+ list(APPEND interface_SRCS ${interface}Interface.cpp ${interface}Proxy.cpp)
endforeach()
+add_custom_command(
+ OUTPUT ${interface_HDRS} ${interface_SRCS}
+ COMMAND ${DBUSXML2QT3_EXECUTABLE} ${CMAKE_CURRENT_SOURCE_DIR}/interfaces.xml
+ DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/interfaces.xml
+ WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
+)
+
tde_add_library(portalinterfaces STATIC_PIC AUTOMOC
- DEPENDENCIES ${interfaces}
- SOURCES ${interfaces_SRCS}
+ SOURCES ${interface_SRCS}
LINK ${DBUS_TQT_LIBRARIES}
)
diff --git a/interfaces/filechooser.xml b/interfaces/interfaces.xml
index 5524d45..003cdbd 100644
--- a/interfaces/filechooser.xml
+++ b/interfaces/interfaces.xml
@@ -1,5 +1,19 @@
<!DOCTYPE node PUBLIC "-//freedesktop//DTD D-BUS Object Introspection 1.0//EN" "http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd">
<node name="/org/freedesktop/portal/desktop">
+ <!-- Email -->
+ <interface name="org.freedesktop.impl.portal.Email">
+ <method name="ComposeEmail">+
+ <arg type="o" name="handle" direction="in"/>
+ <arg type="s" name="app_id" direction="in"/>
+ <arg type="s" name="parent_window" direction="in"/>
+ <arg type="a{sv}" name="options" direction="in"/>
+ <arg type="u" name="response" direction="out"/>
+ <arg type="a{sv}" name="results" direction="out"/>
+ </method>
+ <property name="version" type="u" access="read"/>
+ </interface>
+
+ <!-- FileChooser -->
<interface name="org.freedesktop.impl.portal.FileChooser">
<method name="OpenFile">
<arg name="handle" type="o" direction="in" />