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

Side by Side Diff: chrome/browser/ui/app_list/model_pref_updater.cc

Issue 853743002: First pass at fixing guest browser cookies issue. Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Delete the Profile Manager. Guest Profile doesn't write to autocomplete/history. Views still needs … Created 5 years, 10 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
« no previous file with comments | « chrome/browser/ui/app_list/app_list_syncable_service.cc ('k') | chrome/browser/ui/browser.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/app_list/model_pref_updater.h" 5 #include "chrome/browser/ui/app_list/model_pref_updater.h"
6 6
7 #include "chrome/browser/ui/app_list/app_list_prefs.h" 7 #include "chrome/browser/ui/app_list/app_list_prefs.h"
8 #include "chrome/browser/ui/app_list/extension_app_item.h" 8 #include "chrome/browser/ui/app_list/extension_app_item.h"
9 #include "ui/app_list/app_list_folder_item.h" 9 #include "ui/app_list/app_list_folder_item.h"
10 #include "ui/app_list/app_list_item.h" 10 #include "ui/app_list/app_list_item.h"
11 #include "ui/app_list/app_list_model.h" 11 #include "ui/app_list/app_list_model.h"
12 12
13 namespace app_list { 13 namespace app_list {
14 14
15 ModelPrefUpdater::ModelPrefUpdater(AppListPrefs* app_list_prefs, 15 ModelPrefUpdater::ModelPrefUpdater(AppListPrefs* app_list_prefs,
16 AppListModel* model) 16 AppListModel* model)
17 : app_list_prefs_(app_list_prefs), model_(model) { 17 : app_list_prefs_(app_list_prefs), model_(model) {
18 DLOG(ERROR) << "modelpref";
18 model_->AddObserver(this); 19 model_->AddObserver(this);
19 } 20 }
20 21
21 ModelPrefUpdater::~ModelPrefUpdater() { 22 ModelPrefUpdater::~ModelPrefUpdater() {
22 model_->RemoveObserver(this); 23 model_->RemoveObserver(this);
23 } 24 }
24 25
25 void ModelPrefUpdater::OnAppListItemAdded(AppListItem* item) { 26 void ModelPrefUpdater::OnAppListItemAdded(AppListItem* item) {
26 UpdatePrefsFromAppListItem(item); 27 UpdatePrefsFromAppListItem(item);
27 } 28 }
(...skipping 17 matching lines...) Expand all
45 NOTREACHED(); 46 NOTREACHED();
46 47
47 info.parent_id = item->folder_id(); 48 info.parent_id = item->folder_id();
48 info.position = item->position(); 49 info.position = item->position();
49 info.name = item->name(); 50 info.name = item->name();
50 51
51 app_list_prefs_->SetAppListInfo(item->id(), info); 52 app_list_prefs_->SetAppListInfo(item->id(), info);
52 } 53 }
53 54
54 } // namespace app_list 55 } // namespace app_list
OLDNEW
« no previous file with comments | « chrome/browser/ui/app_list/app_list_syncable_service.cc ('k') | chrome/browser/ui/browser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698