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

Side by Side Diff: components/search_engines/template_url_data.h

Issue 2498053002: Add field to monitor last visited time for each search engine (Closed)
Patch Set: Add unit test for last_visited field. Created 4 years, 1 month 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 COMPONENTS_SEARCH_ENGINES_TEMPLATE_URL_DATA_H_ 5 #ifndef COMPONENTS_SEARCH_ENGINES_TEMPLATE_URL_DATA_H_
6 #define COMPONENTS_SEARCH_ENGINES_TEMPLATE_URL_DATA_H_ 6 #define COMPONENTS_SEARCH_ENGINES_TEMPLATE_URL_DATA_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 // 75 //
76 // NOTE: this may be 0, which indicates the TemplateURL was created before we 76 // NOTE: this may be 0, which indicates the TemplateURL was created before we
77 // started tracking creation time. 77 // started tracking creation time.
78 base::Time date_created; 78 base::Time date_created;
79 79
80 // The last time this TemplateURL was modified by a user, since creation. 80 // The last time this TemplateURL was modified by a user, since creation.
81 // 81 //
82 // NOTE: Like date_created above, this may be 0. 82 // NOTE: Like date_created above, this may be 0.
83 base::Time last_modified; 83 base::Time last_modified;
84 84
85 // Date when this TemplateURL was last visited.
86 //
87 // NOTE: Like data_created above, this may be 0.
Peter Kasting 2016/11/21 03:35:08 Nit: I'd change this to "NOTE: This may be 0 if th
ltian 2016/11/28 22:08:02 Done.
88 base::Time last_visited;
89
85 // True if this TemplateURL was automatically created by the administrator via 90 // True if this TemplateURL was automatically created by the administrator via
86 // group policy. 91 // group policy.
87 bool created_by_policy; 92 bool created_by_policy;
88 93
89 // Number of times this TemplateURL has been explicitly used to load a URL. 94 // Number of times this TemplateURL has been explicitly used to load a URL.
90 // We don't increment this for uses as the "default search engine" since 95 // We don't increment this for uses as the "default search engine" since
91 // that's not really "explicit" usage and incrementing would result in pinning 96 // that's not really "explicit" usage and incrementing would result in pinning
92 // the user's default search engine(s) to the top of the list of searches on 97 // the user's default search engine(s) to the top of the list of searches on
93 // the New Tab page, de-emphasizing the omnibox as "where you go to search". 98 // the New Tab page, de-emphasizing the omnibox as "where you go to search".
94 int usage_count; 99 int usage_count;
(...skipping 15 matching lines...) Expand all
110 115
111 private: 116 private:
112 // Private so we can enforce using the setters and thus enforce that these 117 // Private so we can enforce using the setters and thus enforce that these
113 // fields are never empty. 118 // fields are never empty.
114 base::string16 short_name_; 119 base::string16 short_name_;
115 base::string16 keyword_; 120 base::string16 keyword_;
116 std::string url_; 121 std::string url_;
117 }; 122 };
118 123
119 #endif // COMPONENTS_SEARCH_ENGINES_TEMPLATE_URL_DATA_H_ 124 #endif // COMPONENTS_SEARCH_ENGINES_TEMPLATE_URL_DATA_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698