D29708: Introduce EXCLUDE_DEPRECATED_BEFORE_AND_AT

2020-05-13 Thread Friedrich W. H. Kossebau
This revision was automatically updated to reflect the committed changes.
Closed by commit R241:391351a6be0e: Introduce EXCLUDE_DEPRECATED_BEFORE_AND_AT 
(authored by kossebau).

REPOSITORY
  R241 KIO

CHANGES SINCE LAST UPDATE
  https://phabricator.kde.org/D29708?vs=82730&id=82806

REVISION DETAIL
  https://phabricator.kde.org/D29708

AFFECTED FILES
  CMakeLists.txt
  autotests/CMakeLists.txt
  autotests/clipboardupdatertest.cpp
  autotests/kfilewidgettest.cpp
  autotests/krununittest.cpp
  autotests/krununittest.h
  autotests/kurlnavigatortest.cpp
  autotests/kurlnavigatortest.h
  src/core/CMakeLists.txt
  src/core/copyjob.cpp
  src/core/global.cpp
  src/core/idleslave.cpp
  src/core/job.cpp
  src/core/kfileitem.cpp
  src/core/ksambashare.cpp
  src/core/ksambashare_p.h
  src/core/ksslcertificatemanager.cpp
  src/core/ksslcertificatemanager.h
  src/core/ksslcertificatemanager_p.h
  src/core/ksslerror_p.h
  src/core/ksslerroruidata.cpp
  src/core/ktcpsocket.cpp
  src/core/scheduler.cpp
  src/core/slavebase.cpp
  src/core/slaveinterface.cpp
  src/core/statjob.cpp
  src/core/transferjob.cpp
  src/core/udsentry.cpp
  src/filewidgets/CMakeLists.txt
  src/filewidgets/kfilepreviewgenerator.cpp
  src/filewidgets/kfilewidget.cpp
  src/filewidgets/kurlnavigator.cpp
  src/kssld/kssld.cpp
  src/widgets/CMakeLists.txt
  src/widgets/accessmanager.cpp
  src/widgets/kdirmodel.cpp
  src/widgets/kpropertiesdialog.cpp
  src/widgets/krun.cpp
  src/widgets/ksslinfodialog.cpp
  src/widgets/ksslinfodialog.h
  src/widgets/kurifilter.cpp
  src/widgets/kurlrequester.cpp
  src/widgets/kurlrequester.h
  src/widgets/kurlrequesterdialog.cpp
  src/widgets/paste.cpp
  src/widgets/previewjob.cpp
  src/widgets/renamedialog.cpp
  src/widgets/sslui.cpp
  src/widgets/thumbcreator.cpp
  tests/CMakeLists.txt

To: kossebau, #frameworks, dfaure, meven, ahmadsamir
Cc: kde-frameworks-devel, LeGast00n, cblack, michaelh, ngraham, bruns


D29708: Introduce EXCLUDE_DEPRECATED_BEFORE_AND_AT

2020-05-13 Thread David Faure
dfaure added a comment.


  > there are lots of KRun::run* usages in non-deprecated API sadly in KIO :(
  
  OK, I'll fix that.

REPOSITORY
  R241 KIO

BRANCH
  excludedeprecated

REVISION DETAIL
  https://phabricator.kde.org/D29708

To: kossebau, #frameworks, dfaure, meven, ahmadsamir
Cc: kde-frameworks-devel, LeGast00n, cblack, michaelh, ngraham, bruns


D29708: Introduce EXCLUDE_DEPRECATED_BEFORE_AND_AT

2020-05-13 Thread Méven Car
meven accepted this revision.
meven added a comment.
This revision is now accepted and ready to land.


  Great stuff, this much less cleanup will be needed for KF6 !

INLINE COMMENTS

> global.cpp:99
>  
> +#if KIOCORE_BUILD_DEPRECATED_SINCE(3, 4)
>  KIOCORE_EXPORT QTime KIO::calculateRemaining(KIO::filesize_t totalSize, 
> KIO::filesize_t processedSize, KIO::filesize_t speed)

Pretty old deprecation ^^

REPOSITORY
  R241 KIO

BRANCH
  excludedeprecated

REVISION DETAIL
  https://phabricator.kde.org/D29708

To: kossebau, #frameworks, dfaure, meven, ahmadsamir
Cc: kde-frameworks-devel, LeGast00n, cblack, michaelh, ngraham, bruns


D29708: Introduce EXCLUDE_DEPRECATED_BEFORE_AND_AT

2020-05-13 Thread Friedrich W. H. Kossebau
kossebau added a comment.


  @dfaure So far I had no idea how to introduce a simple variant of the 
deprecation macros to support just disabling latest. For one would this make 
things more complex as there would be yet another approach. And things would be 
also become a bit unreliable on the library consumer side, as any version-less 
BUILD_DEPRECATED would no longer be bound to a version and thus to a certain 
set of API.
  
  And as said in the commit message, the current version-based 
EXCLUDE_DEPRECATED_BEFORE_AND_AT can also be used with KIO, if we simply just 
give no guarantee that this works with any version, but only with some, with 
better chances for future versions (if people now make sure things build 
without deprecated API and do not reintroduce the use of already deprecated 
API) :)
  
  Using this patch with EXCLUDE_DEPRECATED_BEFORE_AND_AT=CURRENT shows that 
there are lots of KRun::run* usages in non-deprecated API sadly in KIO :(

REPOSITORY
  R241 KIO

REVISION DETAIL
  https://phabricator.kde.org/D29708

To: kossebau, #frameworks, dfaure, meven, ahmadsamir
Cc: kde-frameworks-devel, LeGast00n, cblack, michaelh, ngraham, bruns


D29708: Introduce EXCLUDE_DEPRECATED_BEFORE_AND_AT

2020-05-13 Thread Friedrich W. H. Kossebau
kossebau created this revision.
kossebau added reviewers: Frameworks, dfaure, meven, ahmadsamir.
Herald added a project: Frameworks.
Herald added a subscriber: kde-frameworks-devel.
kossebau requested review of this revision.

REVISION SUMMARY
  Not all versions of the past will work as value, mainly to be used with
  values "0" or "CURRENT". If any new deprecations are done without
  having code starting to use older deprecated API, in the future any
  versions >= 5.71.0 should work also reliably.
  
  Currently a build with EXCLUDE_DEPRECATED_BEFORE_AND_AT=CURRENT does
  not yet work, some API deprecated is still used internally by
  code behind non-deprecated API. Building with CURRENT will show by the
  failed build which those are.

TEST PLAN
  Builds with values 0, 5.70.0 (with D29707 
).

REPOSITORY
  R241 KIO

BRANCH
  excludedeprecated

REVISION DETAIL
  https://phabricator.kde.org/D29708

AFFECTED FILES
  CMakeLists.txt
  autotests/CMakeLists.txt
  autotests/clipboardupdatertest.cpp
  autotests/kfilewidgettest.cpp
  autotests/krununittest.cpp
  autotests/krununittest.h
  autotests/kurlnavigatortest.cpp
  autotests/kurlnavigatortest.h
  src/core/CMakeLists.txt
  src/core/copyjob.cpp
  src/core/global.cpp
  src/core/idleslave.cpp
  src/core/job.cpp
  src/core/kfileitem.cpp
  src/core/ksambashare.cpp
  src/core/ksambashare_p.h
  src/core/ksslcertificatemanager.cpp
  src/core/ksslcertificatemanager.h
  src/core/ksslcertificatemanager_p.h
  src/core/ksslerror_p.h
  src/core/ksslerroruidata.cpp
  src/core/ktcpsocket.cpp
  src/core/scheduler.cpp
  src/core/slavebase.cpp
  src/core/slaveinterface.cpp
  src/core/statjob.cpp
  src/core/transferjob.cpp
  src/core/udsentry.cpp
  src/filewidgets/CMakeLists.txt
  src/filewidgets/kfilepreviewgenerator.cpp
  src/filewidgets/kfilewidget.cpp
  src/filewidgets/kurlnavigator.cpp
  src/kssld/kssld.cpp
  src/widgets/CMakeLists.txt
  src/widgets/accessmanager.cpp
  src/widgets/kdirmodel.cpp
  src/widgets/kpropertiesdialog.cpp
  src/widgets/krun.cpp
  src/widgets/ksslinfodialog.cpp
  src/widgets/ksslinfodialog.h
  src/widgets/kurifilter.cpp
  src/widgets/kurlrequester.cpp
  src/widgets/kurlrequester.h
  src/widgets/kurlrequesterdialog.cpp
  src/widgets/paste.cpp
  src/widgets/previewjob.cpp
  src/widgets/renamedialog.cpp
  src/widgets/sslui.cpp
  src/widgets/thumbcreator.cpp
  tests/CMakeLists.txt

To: kossebau, #frameworks, dfaure, meven, ahmadsamir
Cc: kde-frameworks-devel, LeGast00n, cblack, michaelh, ngraham, bruns