Remove deprecated functions. Porting is needed anyways

This commit is contained in:
Sune Vuorela 2023-12-22 23:25:44 +00:00 committed by Albert Astals Cid
parent 9fee222d24
commit 611dea4c0d
4 changed files with 1 additions and 19 deletions

View File

@ -561,11 +561,6 @@ TextRequestPrivate *TextRequestPrivate::get(const TextRequest *req)
return req->d;
}
PixmapRequest::PixmapRequest(DocumentObserver *observer, int pageNumber, int width, int height, int priority, PixmapRequestFeatures features)
: PixmapRequest(observer, pageNumber, width, height, qApp->devicePixelRatio(), priority, features)
{
}
PixmapRequest::PixmapRequest(DocumentObserver *observer, int pageNumber, int width, int height, qreal dpr, int priority, PixmapRequestFeatures features)
: d(new PixmapRequestPrivate)
{

View File

@ -616,18 +616,6 @@ public:
enum PixmapRequestFeature { NoFeature = 0, Asynchronous = 1, Preload = 2 };
Q_DECLARE_FLAGS(PixmapRequestFeatures, PixmapRequestFeature)
/**
* Creates a new pixmap request.
*
* @param observer The observer.
* @param pageNumber The page number.
* @param width The width of the page in logical pixels.
* @param height The height of the page in logical pixels.
* @param priority The priority of the request.
* @param features The features of generation.
*/
[[deprecated("This PixmapRequest constructor is deprecated, use the one including the device pixel ratio")]] PixmapRequest(DocumentObserver *observer, int pageNumber, int width, int height, int priority, PixmapRequestFeatures features);
/**
* Creates a new pixmap request.
*

View File

@ -48,7 +48,6 @@ public:
TextSelection = 8, ///< Text selection has been changed
Annotations = 16, ///< Annotations have been changed
BoundingBox = 32, ///< Bounding boxes have been changed
NeedSaveAs = 64 ///< Set when "Save" is needed or annotation/form changes will be lost @since 0.15 (KDE 4.9) @deprecated
};
/**

View File

@ -313,7 +313,7 @@ void PageItem::requestPixmap()
// Ideally we would do one or the other but for now this is good enough
paint();
{
auto request = new Okular::PixmapRequest(observer, m_viewPort.pageNumber, width() * dpr, height() * dpr, priority, Okular::PixmapRequest::Asynchronous);
auto request = new Okular::PixmapRequest(observer, m_viewPort.pageNumber, width(), height(), dpr, priority, Okular::PixmapRequest::Asynchronous);
request->setNormalizedRect(Okular::NormalizedRect(0, 0, 1, 1));
const Okular::Document::PixmapRequestFlag prf = Okular::Document::NoOption;
m_documentItem.data()->document()->requestPixmaps({request}, prf);