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

Side by Side Diff: chrome/browser/ui/webui/snippets_internals_message_handler.h

Issue 2167063003: Rename discard to dismiss for NTP snippets and content suggestions (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@bridgeumbiegen
Patch Set: Fix unit test Created 4 years, 5 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_UI_WEBUI_SNIPPETS_INTERNALS_MESSAGE_HANDLER_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_SNIPPETS_INTERNALS_MESSAGE_HANDLER_H_
6 #define CHROME_BROWSER_UI_WEBUI_SNIPPETS_INTERNALS_MESSAGE_HANDLER_H_ 6 #define CHROME_BROWSER_UI_WEBUI_SNIPPETS_INTERNALS_MESSAGE_HANDLER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 29 matching lines...) Expand all
40 40
41 // ntp_snippets::ContentSuggestionsService::Observer: 41 // ntp_snippets::ContentSuggestionsService::Observer:
42 void OnNewSuggestions() override; 42 void OnNewSuggestions() override;
43 void OnCategoryStatusChanged( 43 void OnCategoryStatusChanged(
44 ntp_snippets::ContentSuggestionsCategory category, 44 ntp_snippets::ContentSuggestionsCategory category,
45 ntp_snippets::ContentSuggestionsCategoryStatus new_status) override; 45 ntp_snippets::ContentSuggestionsCategoryStatus new_status) override;
46 void ContentSuggestionsServiceShutdown() override; 46 void ContentSuggestionsServiceShutdown() override;
47 47
48 void HandleRefreshContent(const base::ListValue* args); 48 void HandleRefreshContent(const base::ListValue* args);
49 void HandleClear(const base::ListValue* args); 49 void HandleClear(const base::ListValue* args);
50 void HandleClearDiscarded(const base::ListValue* args); 50 void HandleClearDismissed(const base::ListValue* args);
51 void HandleDownload(const base::ListValue* args); 51 void HandleDownload(const base::ListValue* args);
52 void HandleClearCachedSuggestions(const base::ListValue* args); 52 void HandleClearCachedSuggestions(const base::ListValue* args);
53 void HandleClearDiscardedSuggestions(const base::ListValue* args); 53 void HandleClearDismissedSuggestions(const base::ListValue* args);
54 54
55 void SendAllContent(); 55 void SendAllContent();
56 void SendSnippets(); 56 void SendSnippets();
57 void SendDiscardedSnippets(); 57 void SendDismissedSnippets();
58 void SendHosts(); 58 void SendHosts();
59 void SendContentSuggestions(); 59 void SendContentSuggestions();
60 void SendBoolean(const std::string& name, bool value); 60 void SendBoolean(const std::string& name, bool value);
61 void SendString(const std::string& name, const std::string& value); 61 void SendString(const std::string& name, const std::string& value);
62 62
63 ScopedObserver<ntp_snippets::NTPSnippetsService, 63 ScopedObserver<ntp_snippets::NTPSnippetsService,
64 ntp_snippets::NTPSnippetsServiceObserver> 64 ntp_snippets::NTPSnippetsServiceObserver>
65 ntp_snippets_service_observer_; 65 ntp_snippets_service_observer_;
66 66
67 ScopedObserver<ntp_snippets::ContentSuggestionsService, 67 ScopedObserver<ntp_snippets::ContentSuggestionsService,
68 ntp_snippets::ContentSuggestionsService::Observer> 68 ntp_snippets::ContentSuggestionsService::Observer>
69 content_suggestions_service_observer_; 69 content_suggestions_service_observer_;
70 70
71 // Tracks whether we can already send messages to the page. 71 // Tracks whether we can already send messages to the page.
72 bool dom_loaded_; 72 bool dom_loaded_;
73 73
74 ntp_snippets::NTPSnippetsService* ntp_snippets_service_; 74 ntp_snippets::NTPSnippetsService* ntp_snippets_service_;
75 ntp_snippets::ContentSuggestionsService* content_suggestions_service_; 75 ntp_snippets::ContentSuggestionsService* content_suggestions_service_;
76 76
77 DISALLOW_COPY_AND_ASSIGN(SnippetsInternalsMessageHandler); 77 DISALLOW_COPY_AND_ASSIGN(SnippetsInternalsMessageHandler);
78 }; 78 };
79 79
80 #endif // CHROME_BROWSER_UI_WEBUI_SNIPPETS_INTERNALS_MESSAGE_HANDLER_H_ 80 #endif // CHROME_BROWSER_UI_WEBUI_SNIPPETS_INTERNALS_MESSAGE_HANDLER_H_
OLDNEW
« no previous file with comments | « chrome/browser/resources/snippets_internals.js ('k') | chrome/browser/ui/webui/snippets_internals_message_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698