Changeset View
Standalone View
src/CMakeLists.txt
Show All 37 Lines | 35 | target_link_libraries(kio_gdrive | |||
---|---|---|---|---|---|
38 | KPim::GAPICore | 38 | KPim::GAPICore | ||
39 | KPim::GAPIDrive | 39 | KPim::GAPIDrive | ||
40 | KF5::KIOCore | 40 | KF5::KIOCore | ||
41 | KF5::KIOWidgets | 41 | KF5::KIOWidgets | ||
42 | KF5::I18n | 42 | KF5::I18n | ||
43 | ${BACKEND_LIBS}) | 43 | ${BACKEND_LIBS}) | ||
44 | 44 | | |||
45 | set_target_properties(kio_gdrive PROPERTIES OUTPUT_NAME "gdrive") | 45 | set_target_properties(kio_gdrive PROPERTIES OUTPUT_NAME "gdrive") | ||
46 | | ||||
47 | set(copyurlitemaction_SRCS | ||||
48 | gdriveurl.cpp | ||||
49 | copyurlitemaction.cpp) | ||||
50 | | ||||
51 | ecm_qt_declare_logging_category(copyurlitemaction_SRCS | ||||
52 | HEADER gdrivedebug.h | ||||
53 | IDENTIFIER GDRIVE | ||||
54 | CATEGORY_NAME kf5.kio.gdrive) | ||||
barchiesi: Is this the correct way of reusing the same logging category? | |||||
It works so it's not "wrong". The alternative is to create a private library with all the gdrive sources and link the new plugin to this library. That would also avoid to build gdriveurl.cpp twice, which this patch currently does. Question: do we really need debug in this plugin? Maybe it can be avoided. Question 2: do we really need the GDriveUrl class here? It's basically used only to compare the scheme with the "gdrive" string... elvisangelaccio: It works so it's not "wrong". The alternative is to create a private library with all the… | |||||
In this scenario I guess usage of both debug and GDriveUrl can be avoided, however the private library might need to be considered. In the future I would like to add a way to change file permissions after right clicking and to do so I will very probably need access to other parts of kio-gdrive. Any ideas? barchiesi: In this scenario I guess usage of both debug and GDriveUrl can be avoided, however the private… | |||||
I would create the library when we cannot actually avoid it. Simple as that :) elvisangelaccio: I would create the library when we cannot actually avoid it. Simple as that :) | |||||
barchiesi: I removed debug and GDriveUrl class from this plugin. | |||||
55 | | ||||
56 | kcoreaddons_add_plugin(copyurlitemaction | ||||
57 | SOURCES ${copyurlitemaction_SRCS} | ||||
58 | JSON copyurlitemaction.json | ||||
59 | INSTALL_NAMESPACE "kf5/kfileitemaction") | ||||
60 | | ||||
61 | target_link_libraries(copyurlitemaction | ||||
62 | KF5::I18n | ||||
63 | KF5::KIOWidgets) |
Is this the correct way of reusing the same logging category?