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

Side by Side Diff: chrome/browser/history/history_notifications.h

Issue 808123003: Eliminate sending NOTIFICATION_HISTORY_KEYWORD_SEARCH_TERM_UPDATED (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: update unittest Created 5 years, 11 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // Structs that hold data used in broadcasting notifications. 5 // Structs that hold data used in broadcasting notifications.
6 6
7 #ifndef CHROME_BROWSER_HISTORY_HISTORY_NOTIFICATIONS_H__ 7 #ifndef CHROME_BROWSER_HISTORY_HISTORY_NOTIFICATIONS_H__
8 #define CHROME_BROWSER_HISTORY_HISTORY_NOTIFICATIONS_H__ 8 #define CHROME_BROWSER_HISTORY_HISTORY_NOTIFICATIONS_H__
9 9
10 #include <set> 10 #include <set>
11 11
12 #include "chrome/browser/history/history_details.h" 12 #include "chrome/browser/history/history_details.h"
13 #include "components/history/core/browser/history_types.h" 13 #include "components/history/core/browser/history_types.h"
14 #include "components/history/core/browser/keyword_id.h"
15 #include "url/gurl.h" 14 #include "url/gurl.h"
16 15
17 namespace history { 16 namespace history {
18 17
19 // Details for NOTIFICATION_HISTORY_TYPED_URLS_MODIFIED. 18 // Details for NOTIFICATION_HISTORY_TYPED_URLS_MODIFIED.
20 struct URLsModifiedDetails : public HistoryDetails { 19 struct URLsModifiedDetails : public HistoryDetails {
21 URLsModifiedDetails(); 20 URLsModifiedDetails();
22 ~URLsModifiedDetails() override; 21 ~URLsModifiedDetails() override;
23 22
24 // Lists the information for each of the URLs affected. The rows will have the 23 // Lists the information for each of the URLs affected. The rows will have the
(...skipping 17 matching lines...) Expand all
42 // indicating that a subset of history has been deleted. The rows will have 41 // indicating that a subset of history has been deleted. The rows will have
43 // the IDs that had been in effect before the deletion in the main history 42 // the IDs that had been in effect before the deletion in the main history
44 // database. 43 // database.
45 URLRows rows; 44 URLRows rows;
46 45
47 // The list of deleted favicon urls. This is valid only when |all_history| is 46 // The list of deleted favicon urls. This is valid only when |all_history| is
48 // false, indicating that a subset of history has been deleted. 47 // false, indicating that a subset of history has been deleted.
49 std::set<GURL> favicon_urls; 48 std::set<GURL> favicon_urls;
50 }; 49 };
51 50
52 // Details for HISTORY_KEYWORD_SEARCH_TERM_UPDATED.
53 struct KeywordSearchUpdatedDetails : public HistoryDetails {
54 KeywordSearchUpdatedDetails(const URLRow& url_row,
55 KeywordID keyword_id,
56 const base::string16& term);
57 ~KeywordSearchUpdatedDetails() override;
58
59 // The affected URLRow. The ID will be set to the value that is currently in
60 // effect in the main history database.
61 URLRow url_row;
62 KeywordID keyword_id;
63 base::string16 term;
64 };
65
66 // Details for HISTORY_KEYWORD_SEARCH_TERM_DELETED. 51 // Details for HISTORY_KEYWORD_SEARCH_TERM_DELETED.
67 struct KeywordSearchDeletedDetails : public HistoryDetails { 52 struct KeywordSearchDeletedDetails : public HistoryDetails {
68 explicit KeywordSearchDeletedDetails(URLID url_row_id); 53 explicit KeywordSearchDeletedDetails(URLID url_row_id);
69 ~KeywordSearchDeletedDetails() override; 54 ~KeywordSearchDeletedDetails() override;
70 55
71 // The ID of the corresponding URLRow in the main history database. 56 // The ID of the corresponding URLRow in the main history database.
72 URLID url_row_id; 57 URLID url_row_id;
73 }; 58 };
74 59
75 } // namespace history 60 } // namespace history
76 61
77 #endif // CHROME_BROWSER_HISTORY_HISTORY_NOTIFICATIONS_H__ 62 #endif // CHROME_BROWSER_HISTORY_HISTORY_NOTIFICATIONS_H__
OLDNEW
« no previous file with comments | « chrome/browser/history/history_backend_unittest.cc ('k') | chrome/browser/history/history_notifications.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698