mirror of
https://invent.kde.org/network/falkon.git
synced 2024-12-20 10:46:35 +01:00
Added "broken page" image to speed dial when loading fails.
+ updated translations
This commit is contained in:
parent
65f4bf1a1b
commit
4f8454a3d9
@ -19,5 +19,6 @@
|
||||
<file>html/loading.gif</file>
|
||||
<file>html/reload.png</file>
|
||||
<file>html/qupzilla.ico</file>
|
||||
<file>html/broken-page.png</file>
|
||||
</qresource>
|
||||
</RCC>
|
||||
|
@ -166,12 +166,18 @@ void SpeedDial::thumbnailCreated(const QPixmap &image)
|
||||
QString url = thumbnailer->url().toString();
|
||||
QString fileName = m_thumbnailsDir + QCryptographicHash::hash(url.toUtf8(), QCryptographicHash::Md4).toHex() + ".png";
|
||||
|
||||
if (!image.save(fileName)) {
|
||||
qWarning() << "SpeedDial::thumbnailCreated Cannot save thumbnail to " << fileName;
|
||||
if (image.isNull()) {
|
||||
fileName = "qrc:/html/broken-page.png";
|
||||
}
|
||||
else {
|
||||
if (!image.save(fileName)) {
|
||||
qWarning() << "SpeedDial::thumbnailCreated Cannot save thumbnail to " << fileName;
|
||||
}
|
||||
|
||||
fileName = QUrl::fromLocalFile(fileName).toString();
|
||||
}
|
||||
|
||||
m_regenerateScript = true;
|
||||
fileName = QUrl::fromLocalFile(fileName).toString();
|
||||
|
||||
for (int i = 0; i < m_webFrames.count(); i++) {
|
||||
QWebFrame* frame = m_webFrames.at(i).data();
|
||||
|
@ -86,11 +86,16 @@ void PageThumbnailer::start()
|
||||
{
|
||||
m_page->mainFrame()->load(m_url);
|
||||
|
||||
connect(m_page, SIGNAL(loadFinished(bool)), this, SLOT(createThumbnail()));
|
||||
connect(m_page, SIGNAL(loadFinished(bool)), this, SLOT(createThumbnail(bool)));
|
||||
}
|
||||
|
||||
void PageThumbnailer::createThumbnail()
|
||||
void PageThumbnailer::createThumbnail(bool status)
|
||||
{
|
||||
if (!status) {
|
||||
emit thumbnailCreated(QPixmap());
|
||||
return;
|
||||
}
|
||||
|
||||
QImage image(m_page->viewportSize(), QImage::Format_ARGB32);
|
||||
QPainter painter(&image);
|
||||
m_page->mainFrame()->render(&painter);
|
||||
|
@ -56,7 +56,7 @@ signals:
|
||||
public slots:
|
||||
|
||||
private slots:
|
||||
void createThumbnail();
|
||||
void createThumbnail(bool status);
|
||||
|
||||
private:
|
||||
QWebPage* m_page;
|
||||
|
@ -4384,7 +4384,7 @@ Po přidání či odstranění cest k certifikátům je nutné k projevení změ
|
||||
<translation>Hledat "%1 .." s %2</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/webview/webview.cpp" line="887"/>
|
||||
<location filename="../src/webview/webview.cpp" line="890"/>
|
||||
<source>No Named Page</source>
|
||||
<translation>Bezejmenná stránka</translation>
|
||||
</message>
|
||||
|
@ -4380,7 +4380,7 @@ Nachdem Speicherpfade hinzugefügt oder gelöscht wurden, muss QupZilla neu gest
|
||||
<translation>Suche "%1 .." mit %2</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/webview/webview.cpp" line="887"/>
|
||||
<location filename="../src/webview/webview.cpp" line="890"/>
|
||||
<source>No Named Page</source>
|
||||
<translation>Unbekannte Seite</translation>
|
||||
</message>
|
||||
|
@ -4398,7 +4398,7 @@ Después de añadir o quitar rutas de certificados, es necesario reiniciar QupZi
|
||||
<translation>Buscar "%1 .." con %2</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/webview/webview.cpp" line="887"/>
|
||||
<location filename="../src/webview/webview.cpp" line="890"/>
|
||||
<source>No Named Page</source>
|
||||
<translation>Página en blanco</translation>
|
||||
</message>
|
||||
@ -4411,4 +4411,4 @@ Después de añadir o quitar rutas de certificados, es necesario reiniciar QupZi
|
||||
<translation>Prevenir que esta página cree diálogos adicionales</translation>
|
||||
</message>
|
||||
</context>
|
||||
</TS>
|
||||
</TS>
|
||||
|
@ -4402,7 +4402,7 @@ Dopo l'aggiunta o la rimozione dei percorsi di certificazione, è necessari
|
||||
<translation>Cerca "%1 .." con %2</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/webview/webview.cpp" line="887"/>
|
||||
<location filename="../src/webview/webview.cpp" line="890"/>
|
||||
<source>No Named Page</source>
|
||||
<translation>Pagina Senza Nome</translation>
|
||||
</message>
|
||||
|
@ -4380,7 +4380,7 @@ Na het toevoegen of verwijderen van paden, is het noodzakelijk om de browser te
|
||||
<translation>Zoek "%1 .." met %2</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/webview/webview.cpp" line="887"/>
|
||||
<location filename="../src/webview/webview.cpp" line="890"/>
|
||||
<source>No Named Page</source>
|
||||
<translation>Niet benoemde pagina</translation>
|
||||
</message>
|
||||
|
@ -4467,7 +4467,7 @@ Nachdem Speicherpfade hinzugefügt oder gelöscht wurden, muss QupZilla neu gest
|
||||
<translation>Suche "%1 .." mit %2</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/webview/webview.cpp" line="887"/>
|
||||
<location filename="../src/webview/webview.cpp" line="890"/>
|
||||
<source>No Named Page</source>
|
||||
<translation>Unbekannte Seite</translation>
|
||||
</message>
|
||||
|
@ -4377,7 +4377,7 @@ Po pridaní či odobratí ciest k certifikátom je nutné reštartovať prehliad
|
||||
<translation>Hľadať "%1 .." s %2</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/webview/webview.cpp" line="887"/>
|
||||
<location filename="../src/webview/webview.cpp" line="890"/>
|
||||
<source>No Named Page</source>
|
||||
<translation>Nepomenovaná stránka</translation>
|
||||
</message>
|
||||
|
@ -4393,7 +4393,7 @@ After adding or removing certificate paths, it is neccessary to restart QupZilla
|
||||
<translation>使用 %2搜索"%1 .." </translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../src/webview/webview.cpp" line="887"/>
|
||||
<location filename="../src/webview/webview.cpp" line="890"/>
|
||||
<source>No Named Page</source>
|
||||
<translation>无命名页面</translation>
|
||||
</message>
|
||||
|
Loading…
Reference in New Issue
Block a user