Marble

RemoteIconLoader.h
1 // SPDX-License-Identifier: LGPL-2.1-or-later
2 //
3 // SPDX-FileCopyrightText: 2014 Abhinav Gangwar <[email protected]>
4 //
5 
6 #ifndef MARBLE_REMOTEICONLOADER_H
7 #define MARBLE_REMOTEICONLOADER_H
8 
9 #include <QObject>
10 
11 class QString;
12 class QByteArray;
13 class QImage;
14 class QUrl;
15 
16 namespace Marble
17 {
18 class RemoteIconLoaderPrivate;
19 
20 class RemoteIconLoader : public QObject
21 {
22  Q_OBJECT;
23 public:
24  explicit RemoteIconLoader( QObject *parent = nullptr );
25  ~RemoteIconLoader() override;
26 
27  /**
28  * Handles the icon request for passed url( whether icon is available
29  * in cache or on disk or it should gor for a download
30  */
31  QImage load( const QUrl& url );
32 
33 Q_SIGNALS:
34  /**
35  * Signal to indicate that image has been downloaded
36  * and is ready to be display now
37  */
38  void iconReady();
39 
40 private Q_SLOTS:
41  void storeIcon( const QByteArray&, const QString& );
42 
43 private:
44  RemoteIconLoaderPrivate *d;
45 };
46 
47 }
48 
49 #endif // MARBLE_REMOTEICONLOADER_H
Q_OBJECTQ_OBJECT
Q_SLOTSQ_SLOTS
QAction * load(const QObject *recvr, const char *slot, QObject *parent)
Binds a QML item to a specific geodetic location in screen coordinates.
Q_SIGNALSQ_SIGNALS
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Mon Oct 2 2023 03:52:09 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.