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

Side by Side Diff: chrome/browser/ui/app_list/fast_show_pickler.h

Issue 23684003: Introduce FastShowPickler which will be used for app list cold start. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Pickle type needs to be complete Created 7 years, 3 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/ui/app_list/fast_show_pickler.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_UI_APP_LIST_FAST_SHOW_PICKLER_H_
6 #define CHROME_BROWSER_UI_APP_LIST_FAST_SHOW_PICKLER_H_
7
8 #include <string>
9
10 #include "base/memory/scoped_ptr.h"
11 #include "base/pickle.h"
12 #include "ui/app_list/app_list_model.h"
13
14 // Functions for pickling/unpickling AppListModel for fast show. Fast show is
15 // where the app list is put on the screen using data retrieved from a cache
16 // before the extension system has loaded.
17 class FastShowPickler {
18 public:
19 // The version that this pickler understands.
20 static const int kVersion;
21
22 // Pickles a subset of the data in |model| that is useful for doing a fast
23 // show of the app list.
24 static scoped_ptr<Pickle> PickleAppListModelForFastShow(
25 app_list::AppListModel* model);
26
27 // Given a Pickle created by PickleAppListModelForFastShow(), this creates an
28 // AppListModel that represents it.
29 static scoped_ptr<app_list::AppListModel> UnpickleAppListModelForFastShow(
30 Pickle* pickle);
31
32 // Copies parts that are needed to show the app list quickly on startup from
33 // |src| to |dest|.
34 static void CopyOver(
35 app_list::AppListModel* src, app_list::AppListModel* dest);
36 };
37
38 #endif // CHROME_BROWSER_UI_APP_LIST_FAST_SHOW_PICKLER_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/app_list/fast_show_pickler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698