Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
Joao Oliveira
Okular
Commits
f1ba0d29
Commit
f1ba0d29
authored
Jul 03, 2019
by
Albert Astals Cid
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/Applications/19.04'
parents
fe12cf59
cf7d847a
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
3 deletions
+6
-3
core/document.cpp
core/document.cpp
+5
-2
shell/shell.cpp
shell/shell.cpp
+1
-1
No files found.
core/document.cpp
View file @
f1ba0d29
...
...
@@ -1303,6 +1303,7 @@ void DocumentPrivate::sendGeneratorPixmapRequest()
QRect
requestRect
=
r
->
isTile
()
?
r
->
normalizedRect
().
geometry
(
r
->
width
(),
r
->
height
()
)
:
QRect
(
0
,
0
,
r
->
width
(),
r
->
height
()
);
TilesManager
*
tilesManager
=
r
->
d
->
tilesManager
();
const
double
normalizedArea
=
r
->
normalizedRect
().
width
()
*
r
->
normalizedRect
().
height
();
// If it's a preload but the generator is not threaded no point in trying to preload
if
(
r
->
preload
()
&&
!
m_generator
->
hasFeature
(
Generator
::
Threaded
)
)
...
...
@@ -1328,8 +1329,10 @@ void DocumentPrivate::sendGeneratorPixmapRequest()
m_pixmapRequestsStack
.
pop_back
();
delete
r
;
}
// If the requested area is above 8000000 pixels, switch on the tile manager
else
if
(
!
tilesManager
&&
m_generator
->
hasFeature
(
Generator
::
TiledRendering
)
&&
(
long
)
r
->
width
()
*
(
long
)
r
->
height
()
>
8000000L
)
// If the requested area is above 8000000 pixels, and we're not rendering most of the page, switch on the tile manager
else
if
(
!
tilesManager
&&
m_generator
->
hasFeature
(
Generator
::
TiledRendering
)
&&
(
long
)
r
->
width
()
*
(
long
)
r
->
height
()
>
8000000L
&&
normalizedArea
<
0.75
&&
normalizedArea
!=
0
)
{
// if the image is too big. start using tiles
qCDebug
(
OkularCoreDebug
).
nospace
()
<<
"Start using tiles on page "
<<
r
->
pageNumber
()
...
...
shell/shell.cpp
View file @
f1ba0d29
...
...
@@ -573,7 +573,7 @@ bool Shell::queryClose()
if
(
m_tabs
.
count
()
>
1
)
{
const
QString
dontAskAgainName
=
QStringLiteral
(
"ShowTabWarning"
);
KMessageBox
::
ButtonCode
dummy
;
KMessageBox
::
ButtonCode
dummy
=
KMessageBox
::
Yes
;
if
(
shouldBeShownYesNo
(
dontAskAgainName
,
dummy
))
{
QDialog
*
dialog
=
new
QDialog
(
this
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment