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 #include "chrome/browser/ui/ash/chrome_launcher_prefs.h" | 5 #include "chrome/browser/ui/ash/chrome_launcher_prefs.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <set> | 9 #include <set> |
10 | 10 |
11 #include "base/macros.h" | 11 #include "base/macros.h" |
12 #include "base/strings/string_number_conversions.h" | 12 #include "base/strings/string_number_conversions.h" |
13 #include "base/values.h" | 13 #include "base/values.h" |
14 #include "chrome/browser/app_mode/app_mode_utils.h" | 14 #include "chrome/browser/app_mode/app_mode_utils.h" |
15 #include "chrome/browser/chromeos/arc/arc_auth_service.h" | 15 #include "chrome/browser/chromeos/arc/arc_auth_service.h" |
16 #include "chrome/browser/chromeos/arc/arc_support_host.h" | 16 #include "chrome/browser/chromeos/arc/arc_support_host.h" |
17 #include "chrome/browser/prefs/pref_service_syncable_util.h" | 17 #include "chrome/browser/prefs/pref_service_syncable_util.h" |
18 #include "chrome/browser/ui/app_list/app_list_syncable_service.h" | 18 #include "chrome/browser/ui/app_list/app_list_syncable_service.h" |
19 #include "chrome/browser/ui/app_list/app_list_syncable_service_factory.h" | 19 #include "chrome/browser/ui/app_list/app_list_syncable_service_factory.h" |
20 #include "chrome/browser/ui/app_list/arc/arc_app_list_prefs.h" | 20 #include "chrome/browser/ui/app_list/arc/arc_app_list_prefs.h" |
21 #include "chrome/browser/ui/ash/launcher/launcher_controller_helper.h" | 21 #include "chrome/browser/ui/ash/launcher/launcher_controller_helper.h" |
22 #include "chrome/common/extensions/extension_constants.h" | 22 #include "chrome/common/extensions/extension_constants.h" |
23 #include "chrome/common/pref_names.h" | 23 #include "chrome/common/pref_names.h" |
24 #include "components/pref_registry/pref_registry_syncable.h" | 24 #include "components/pref_registry/pref_registry_syncable.h" |
25 #include "components/prefs/pref_service.h" | 25 #include "components/prefs/pref_service.h" |
26 #include "components/prefs/scoped_user_pref_update.h" | 26 #include "components/prefs/scoped_user_pref_update.h" |
27 #include "components/sync/api/string_ordinal.h" | 27 #include "components/sync/model/string_ordinal.h" |
28 #include "components/syncable_prefs/pref_service_syncable.h" | 28 #include "components/syncable_prefs/pref_service_syncable.h" |
29 #include "ui/display/display.h" | 29 #include "ui/display/display.h" |
30 #include "ui/display/screen.h" | 30 #include "ui/display/screen.h" |
31 | 31 |
32 namespace ash { | 32 namespace ash { |
33 namespace launcher { | 33 namespace launcher { |
34 | 34 |
35 namespace { | 35 namespace { |
36 | 36 |
37 // App ID of default pinned apps. | 37 // App ID of default pinned apps. |
(...skipping 665 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
703 pin_position = position_before.CreateAfter(); | 703 pin_position = position_before.CreateAfter(); |
704 else if (position_after.IsValid()) | 704 else if (position_after.IsValid()) |
705 pin_position = position_after.CreateBefore(); | 705 pin_position = position_after.CreateBefore(); |
706 else | 706 else |
707 pin_position = syncer::StringOrdinal::CreateInitialOrdinal(); | 707 pin_position = syncer::StringOrdinal::CreateInitialOrdinal(); |
708 app_service->SetPinPosition(app_id, pin_position); | 708 app_service->SetPinPosition(app_id, pin_position); |
709 } | 709 } |
710 | 710 |
711 } // namespace launcher | 711 } // namespace launcher |
712 } // namespace ash | 712 } // namespace ash |
OLD | NEW |