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
3 // found in the LICENSE file.
5 // Structs that hold data used in broadcasting notifications.
7 #ifndef CHROME_BROWSER_HISTORY_HISTORY_NOTIFICATIONS_H__
8 #define CHROME_BROWSER_HISTORY_HISTORY_NOTIFICATIONS_H__
12 #include "chrome/browser/history/history_details.h"
13 #include "components/history/core/browser/history_types.h"
14 #include "components/history/core/browser/keyword_id.h"
19 // Details for NOTIFICATION_HISTORY_TYPED_URLS_MODIFIED.
20 struct URLsModifiedDetails : public HistoryDetails {
21 URLsModifiedDetails();
22 ~URLsModifiedDetails() override;
24 // Lists the information for each of the URLs affected. The rows will have the
25 // IDs that are currently in effect in the main history database.
29 // Details for NOTIFICATION_HISTORY_URLS_DELETED.
30 struct URLsDeletedDetails : public HistoryDetails {
32 ~URLsDeletedDetails() override;
34 // Set when all history was deleted. False means just a subset was deleted.
37 // True if the data was expired due to old age. False if the data was deleted
38 // in response to an explicit user action through the History UI.
41 // The URLRows of URLs deleted. This is valid only when |all_history| is false
42 // 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
47 // 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.
49 std::set<GURL> favicon_urls;
52 // Details for HISTORY_KEYWORD_SEARCH_TERM_UPDATED.
53 struct KeywordSearchUpdatedDetails : public HistoryDetails {
54 KeywordSearchUpdatedDetails(const URLRow& url_row,
56 const base::string16& term);
57 ~KeywordSearchUpdatedDetails() override;
59 // The affected URLRow. The ID will be set to the value that is currently in
60 // effect in the main history database.
66 // Details for HISTORY_KEYWORD_SEARCH_TERM_DELETED.
67 struct KeywordSearchDeletedDetails : public HistoryDetails {
68 explicit KeywordSearchDeletedDetails(URLID url_row_id);
69 ~KeywordSearchDeletedDetails() override;
71 // The ID of the corresponding URLRow in the main history database.
75 } // namespace history
77 #endif // CHROME_BROWSER_HISTORY_HISTORY_NOTIFICATIONS_H__