summaryrefslogtreecommitdiff
path: root/Source/WebKit2/WebProcess/IconDatabase/WebIconDatabaseProxy.h
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebKit2/WebProcess/IconDatabase/WebIconDatabaseProxy.h')
-rw-r--r--Source/WebKit2/WebProcess/IconDatabase/WebIconDatabaseProxy.h46
1 files changed, 21 insertions, 25 deletions
diff --git a/Source/WebKit2/WebProcess/IconDatabase/WebIconDatabaseProxy.h b/Source/WebKit2/WebProcess/IconDatabase/WebIconDatabaseProxy.h
index b5a13cd7b..bdf8d4cf6 100644
--- a/Source/WebKit2/WebProcess/IconDatabase/WebIconDatabaseProxy.h
+++ b/Source/WebKit2/WebProcess/IconDatabase/WebIconDatabaseProxy.h
@@ -23,8 +23,7 @@
* THE POSSIBILITY OF SUCH DAMAGE.
*/
-#ifndef WebIconDatabaseProxy_h
-#define WebIconDatabaseProxy_h
+#pragma once
#include "APIObject.h"
#include "MessageReceiver.h"
@@ -32,49 +31,46 @@
#include <wtf/HashMap.h>
#include <wtf/PassRefPtr.h>
#include <wtf/RefPtr.h>
-#include <wtf/Vector.h>
namespace WebKit {
class WebProcess;
-class WebIconDatabaseProxy : public WebCore::IconDatabaseBase, private IPC::MessageReceiver {
+class WebIconDatabaseProxy final : public WebCore::IconDatabaseBase, private IPC::MessageReceiver {
public:
- explicit WebIconDatabaseProxy(WebProcess*);
+ explicit WebIconDatabaseProxy(WebProcess&);
virtual ~WebIconDatabaseProxy();
- virtual bool isEnabled() const;
- void setEnabled(bool);
+ void setEnabled(bool) final;
- virtual void retainIconForPageURL(const String&);
- virtual void releaseIconForPageURL(const String&);
- virtual void setIconURLForPageURL(const String&, const String&);
- virtual void setIconDataForIconURL(PassRefPtr<WebCore::SharedBuffer>, const String&);
+private:
+ bool isEnabled() const final;
+
+ void retainIconForPageURL(const String&) final;
+ void releaseIconForPageURL(const String&) final;
+ void setIconURLForPageURL(const String&, const String&) final;
+ void setIconDataForIconURL(WebCore::SharedBuffer*, const String&) final;
- virtual String synchronousIconURLForPageURL(const String&);
- virtual bool synchronousIconDataKnownForIconURL(const String&);
- virtual WebCore::IconLoadDecision synchronousLoadDecisionForIconURL(const String&, WebCore::DocumentLoader*);
- virtual WebCore::Image* synchronousIconForPageURL(const String&, const WebCore::IntSize&);
+ String synchronousIconURLForPageURL(const String&) final;
+ bool synchronousIconDataKnownForIconURL(const String&) final;
+ WebCore::IconLoadDecision synchronousLoadDecisionForIconURL(const String&, WebCore::DocumentLoader*) final;
+ WebCore::Image* synchronousIconForPageURL(const String&, const WebCore::IntSize&) final;
- // Asynchronous calls we should use to replace the above when supported.
- virtual bool supportsAsynchronousMode();
- virtual void loadDecisionForIconURL(const String&, PassRefPtr<WebCore::IconLoadDecisionCallback>);
+ bool supportsAsynchronousMode() final;
+ void loadDecisionForIconURL(const String&, WebCore::IconLoadDecisionCallback&) final;
void receivedIconLoadDecision(int decision, uint64_t callbackID);
- virtual void iconDataForIconURL(const String&, PassRefPtr<WebCore::IconDataCallback>);
+ void iconDataForIconURL(const String&, WebCore::IconDataCallback&) final;
-private:
// IPC::MessageReceiver
- void didReceiveMessage(IPC::Connection*, IPC::MessageDecoder&) override;
+ void didReceiveMessage(IPC::Connection&, IPC::Decoder&) final;
// Callbacks from the UIProcess
void urlImportFinished();
- bool m_isEnabled;
- WebProcess* m_process;
+ bool m_isEnabled { false };
+ WebProcess& m_process;
HashMap<uint64_t, RefPtr<WebCore::IconLoadDecisionCallback>> m_iconLoadDecisionCallbacks;
};
} // namespace WebKit
-
-#endif // WebIconDatabaseProxy_h