OLD | NEW |
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 // A library to manage RLZ information for access-points shared | 5 // A library to manage RLZ information for access-points shared |
6 // across different client applications. | 6 // across different client applications. |
7 | 7 |
8 #include "rlz/lib/rlz_lib.h" | 8 #include "rlz/lib/rlz_lib.h" |
9 | 9 |
10 #include "base/strings/string_util.h" | 10 #include "base/strings/string_util.h" |
(...skipping 12 matching lines...) Expand all Loading... |
23 rlz_lib::AccessPoint access_point; | 23 rlz_lib::AccessPoint access_point; |
24 rlz_lib::Event event_type; | 24 rlz_lib::Event event_type; |
25 }; | 25 }; |
26 | 26 |
27 // Helper functions | 27 // Helper functions |
28 | 28 |
29 bool IsAccessPointSupported(rlz_lib::AccessPoint point) { | 29 bool IsAccessPointSupported(rlz_lib::AccessPoint point) { |
30 switch (point) { | 30 switch (point) { |
31 case rlz_lib::NO_ACCESS_POINT: | 31 case rlz_lib::NO_ACCESS_POINT: |
32 case rlz_lib::LAST_ACCESS_POINT: | 32 case rlz_lib::LAST_ACCESS_POINT: |
| 33 case rlz_lib::CHROME_IOS_RESERVED: |
33 | 34 |
34 case rlz_lib::MOBILE_IDLE_SCREEN_BLACKBERRY: | 35 case rlz_lib::MOBILE_IDLE_SCREEN_BLACKBERRY: |
35 case rlz_lib::MOBILE_IDLE_SCREEN_WINMOB: | 36 case rlz_lib::MOBILE_IDLE_SCREEN_WINMOB: |
36 case rlz_lib::MOBILE_IDLE_SCREEN_SYMBIAN: | 37 case rlz_lib::MOBILE_IDLE_SCREEN_SYMBIAN: |
37 // These AP's are never available on Windows PCs. | 38 // These AP's are never available on Windows PCs. |
38 return false; | 39 return false; |
39 | 40 |
40 case rlz_lib::IE_DEFAULT_SEARCH: | 41 case rlz_lib::IE_DEFAULT_SEARCH: |
41 case rlz_lib::IE_HOME_PAGE: | 42 case rlz_lib::IE_HOME_PAGE: |
42 case rlz_lib::IETB_SEARCH_BOX: | 43 case rlz_lib::IETB_SEARCH_BOX: |
(...skipping 599 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
642 if (cgi_string.size() >= cgi_size) | 643 if (cgi_string.size() >= cgi_size) |
643 return false; | 644 return false; |
644 | 645 |
645 strncpy(cgi, cgi_string.c_str(), cgi_size); | 646 strncpy(cgi, cgi_string.c_str(), cgi_size); |
646 cgi[cgi_size - 1] = 0; | 647 cgi[cgi_size - 1] = 0; |
647 | 648 |
648 return true; | 649 return true; |
649 } | 650 } |
650 | 651 |
651 } // namespace rlz_lib | 652 } // namespace rlz_lib |
OLD | NEW |