Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(84)

Side by Side Diff: Source/core/loader/EmptyClients.h

Issue 1187563005: Code cleanup in core/loader/ (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/core/loader/DocumentLoader.cpp ('k') | Source/core/loader/FrameLoader.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006 Eric Seidel (eric@webkit.org) 2 * Copyright (C) 2006 Eric Seidel (eric@webkit.org)
3 * Copyright (C) 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved. 3 * Copyright (C) 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights reserved.
4 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). 4 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
5 * Copyright (C) 2012 Samsung Electronics. All rights reserved. 5 * Copyright (C) 2012 Samsung Electronics. All rights reserved.
6 * 6 *
7 * Redistribution and use in source and binary forms, with or without 7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions 8 * modification, are permitted provided that the following conditions
9 * are met: 9 * are met:
10 * 1. Redistributions of source code must retain the above copyright 10 * 1. Redistributions of source code must retain the above copyright
(...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after
159 String acceptLanguages() override; 159 String acceptLanguages() override;
160 160
161 void registerPopupOpeningObserver(PopupOpeningObserver*) override { }; 161 void registerPopupOpeningObserver(PopupOpeningObserver*) override { };
162 void unregisterPopupOpeningObserver(PopupOpeningObserver*) override { }; 162 void unregisterPopupOpeningObserver(PopupOpeningObserver*) override { };
163 }; 163 };
164 164
165 class CORE_EXPORT EmptyFrameLoaderClient : public FrameLoaderClient { 165 class CORE_EXPORT EmptyFrameLoaderClient : public FrameLoaderClient {
166 WTF_MAKE_NONCOPYABLE(EmptyFrameLoaderClient); WTF_MAKE_FAST_ALLOCATED(EmptyF rameLoaderClient); 166 WTF_MAKE_NONCOPYABLE(EmptyFrameLoaderClient); WTF_MAKE_FAST_ALLOCATED(EmptyF rameLoaderClient);
167 public: 167 public:
168 EmptyFrameLoaderClient() { } 168 EmptyFrameLoaderClient() { }
169 virtual ~EmptyFrameLoaderClient() { } 169 virtual ~EmptyFrameLoaderClient() { }
170 170
171 virtual bool hasWebView() const override { return true; } // mainly for asse rtions 171 virtual bool hasWebView() const override { return true; } // mainly for asse rtions
172 172
173 virtual bool inShadowTree() const override { return false; } 173 virtual bool inShadowTree() const override { return false; }
174 174
175 virtual Frame* opener() const override { return 0; } 175 virtual Frame* opener() const override { return 0; }
176 virtual void setOpener(Frame*) override { } 176 virtual void setOpener(Frame*) override { }
177 177
178 virtual Frame* parent() const override { return 0; } 178 virtual Frame* parent() const override { return 0; }
179 virtual Frame* top() const override { return 0; } 179 virtual Frame* top() const override { return 0; }
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
297 virtual bool canCopyCut(LocalFrame*, bool defaultValue) const override { ret urn defaultValue; } 297 virtual bool canCopyCut(LocalFrame*, bool defaultValue) const override { ret urn defaultValue; }
298 virtual bool canPaste(LocalFrame*, bool defaultValue) const override { retur n defaultValue; } 298 virtual bool canPaste(LocalFrame*, bool defaultValue) const override { retur n defaultValue; }
299 299
300 virtual bool handleKeyboardEvent() override { return false; } 300 virtual bool handleKeyboardEvent() override { return false; }
301 }; 301 };
302 302
303 class EmptyContextMenuClient final : public ContextMenuClient { 303 class EmptyContextMenuClient final : public ContextMenuClient {
304 WTF_MAKE_NONCOPYABLE(EmptyContextMenuClient); WTF_MAKE_FAST_ALLOCATED(EmptyC ontextMenuClient); 304 WTF_MAKE_NONCOPYABLE(EmptyContextMenuClient); WTF_MAKE_FAST_ALLOCATED(EmptyC ontextMenuClient);
305 public: 305 public:
306 EmptyContextMenuClient() { } 306 EmptyContextMenuClient() { }
307 virtual ~EmptyContextMenuClient() { } 307 virtual ~EmptyContextMenuClient() { }
308 virtual void showContextMenu(const ContextMenu*) override { } 308 virtual void showContextMenu(const ContextMenu*) override { }
309 virtual void clearContextMenu() override { } 309 virtual void clearContextMenu() override { }
310 }; 310 };
311 311
312 class EmptyDragClient final : public DragClient { 312 class EmptyDragClient final : public DragClient {
313 WTF_MAKE_NONCOPYABLE(EmptyDragClient); WTF_MAKE_FAST_ALLOCATED(EmptyDragClie nt); 313 WTF_MAKE_NONCOPYABLE(EmptyDragClient); WTF_MAKE_FAST_ALLOCATED(EmptyDragClie nt);
314 public: 314 public:
315 EmptyDragClient() { } 315 EmptyDragClient() { }
316 virtual ~EmptyDragClient() {} 316 virtual ~EmptyDragClient() { }
317 virtual DragDestinationAction actionMaskForDrag(DragData*) override { return DragDestinationActionNone; } 317 virtual DragDestinationAction actionMaskForDrag(DragData*) override { return DragDestinationActionNone; }
318 virtual void startDrag(DragImage*, const IntPoint&, const IntPoint&, DataTra nsfer*, LocalFrame*, bool) override { } 318 virtual void startDrag(DragImage*, const IntPoint&, const IntPoint&, DataTra nsfer*, LocalFrame*, bool) override { }
319 }; 319 };
320 320
321 CORE_EXPORT void fillWithEmptyClients(Page::PageClients&); 321 CORE_EXPORT void fillWithEmptyClients(Page::PageClients&);
322 322
323 } // namespace blink 323 } // namespace blink
324 324
325 #endif // EmptyClients_h 325 #endif // EmptyClients_h
OLDNEW
« no previous file with comments | « Source/core/loader/DocumentLoader.cpp ('k') | Source/core/loader/FrameLoader.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698