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

Side by Side Diff: Source/core/page/ContextMenuController.cpp

Issue 170603003: Use nullptr_t for RefPtr, PassRefPtr and RawPtr. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Final rebase Created 6 years, 10 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/WorkerThreadableLoader.cpp ('k') | Source/core/page/DOMSelection.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, 2007 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007 Apple Inc. All rights reserved.
3 * Copyright (C) 2010 Igalia S.L 3 * Copyright (C) 2010 Igalia S.L
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 PassOwnPtr<ContextMenuController> ContextMenuController::create(Page* page, Cont extMenuClient* client) 53 PassOwnPtr<ContextMenuController> ContextMenuController::create(Page* page, Cont extMenuClient* client)
54 { 54 {
55 return adoptPtr(new ContextMenuController(page, client)); 55 return adoptPtr(new ContextMenuController(page, client));
56 } 56 }
57 57
58 void ContextMenuController::clearContextMenu() 58 void ContextMenuController::clearContextMenu()
59 { 59 {
60 m_contextMenu.clear(); 60 m_contextMenu.clear();
61 if (m_menuProvider) 61 if (m_menuProvider)
62 m_menuProvider->contextMenuCleared(); 62 m_menuProvider->contextMenuCleared();
63 m_menuProvider = 0; 63 m_menuProvider = nullptr;
64 m_hitTestResult = HitTestResult(); 64 m_hitTestResult = HitTestResult();
65 m_client->clearContextMenu(); 65 m_client->clearContextMenu();
66 } 66 }
67 67
68 void ContextMenuController::documentDetached(Document* document) 68 void ContextMenuController::documentDetached(Document* document)
69 { 69 {
70 if (Node* innerNode = m_hitTestResult.innerNode()) { 70 if (Node* innerNode = m_hitTestResult.innerNode()) {
71 // Invalidate the context menu info if its target document is detached. 71 // Invalidate the context menu info if its target document is detached.
72 if (innerNode->document() == document) 72 if (innerNode->document() == document)
73 clearContextMenu(); 73 clearContextMenu();
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
129 ASSERT(item->type() == ActionType || item->type() == CheckableActionType); 129 ASSERT(item->type() == ActionType || item->type() == CheckableActionType);
130 130
131 if (item->action() < ContextMenuItemBaseCustomTag || item->action() > Contex tMenuItemLastCustomTag) 131 if (item->action() < ContextMenuItemBaseCustomTag || item->action() > Contex tMenuItemLastCustomTag)
132 return; 132 return;
133 133
134 ASSERT(m_menuProvider); 134 ASSERT(m_menuProvider);
135 m_menuProvider->contextMenuItemSelected(item); 135 m_menuProvider->contextMenuItemSelected(item);
136 } 136 }
137 137
138 } // namespace WebCore 138 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/loader/WorkerThreadableLoader.cpp ('k') | Source/core/page/DOMSelection.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698