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

Side by Side Diff: chrome/browser/ui/app_list/arc/arc_app_icon.h

Issue 2894443002: arc: Set custom icon in shelf for ARC apps. (Closed)
Patch Set: rebase Created 3 years, 7 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/BUILD.gn ('k') | chrome/browser/ui/app_list/arc/arc_app_icon.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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 CHROME_BROWSER_UI_APP_LIST_ARC_ARC_APP_ICON_H_ 5 #ifndef CHROME_BROWSER_UI_APP_LIST_ARC_ARC_APP_ICON_H_
6 #define CHROME_BROWSER_UI_APP_LIST_ARC_ARC_APP_ICON_H_ 6 #define CHROME_BROWSER_UI_APP_LIST_ARC_ARC_APP_ICON_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 // done to avoid two problems. Problems come because icons are decoded at a 51 // done to avoid two problems. Problems come because icons are decoded at a
52 // separate process created by ImageDecoder. ImageDecoder has 5 seconds delay 52 // separate process created by ImageDecoder. ImageDecoder has 5 seconds delay
53 // to stop since the last request (see its kBatchModeTimeoutSeconds for more 53 // to stop since the last request (see its kBatchModeTimeoutSeconds for more
54 // details). This is unacceptably long for unit tests because the test 54 // details). This is unacceptably long for unit tests because the test
55 // framework waits until external process is finished. Another problem happens 55 // framework waits until external process is finished. Another problem happens
56 // when we issue a decoding request, but the process has not started its 56 // when we issue a decoding request, but the process has not started its
57 // processing yet by the time when a test exits. This might cause situation 57 // processing yet by the time when a test exits. This might cause situation
58 // when g_one_utility_thread_lock from in_process_utility_thread.cc gets 58 // when g_one_utility_thread_lock from in_process_utility_thread.cc gets
59 // released in an acquired state which is crash condition in debug builds. 59 // released in an acquired state which is crash condition in debug builds.
60 static void DisableSafeDecodingForTesting(); 60 static void DisableSafeDecodingForTesting();
61 static bool IsSafeDecodingDisabledForTesting();
61 62
62 private: 63 private:
63 friend class ArcAppIconLoader; 64 friend class ArcAppIconLoader;
64 friend class ArcAppModelBuilder; 65 friend class ArcAppModelBuilder;
65 66
66 class Source; 67 class Source;
67 class DecodeRequest; 68 class DecodeRequest;
68 struct ReadResult; 69 struct ReadResult;
69 70
70 // Icon loading is performed in several steps. It is initiated by 71 // Icon loading is performed in several steps. It is initiated by
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 104
104 // Contains pending image decode requests. 105 // Contains pending image decode requests.
105 std::vector<std::unique_ptr<DecodeRequest>> decode_requests_; 106 std::vector<std::unique_ptr<DecodeRequest>> decode_requests_;
106 107
107 base::WeakPtrFactory<ArcAppIcon> weak_ptr_factory_; 108 base::WeakPtrFactory<ArcAppIcon> weak_ptr_factory_;
108 109
109 DISALLOW_COPY_AND_ASSIGN(ArcAppIcon); 110 DISALLOW_COPY_AND_ASSIGN(ArcAppIcon);
110 }; 111 };
111 112
112 #endif // CHROME_BROWSER_UI_APP_LIST_ARC_ARC_APP_ICON_H_ 113 #endif // CHROME_BROWSER_UI_APP_LIST_ARC_ARC_APP_ICON_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/BUILD.gn ('k') | chrome/browser/ui/app_list/arc/arc_app_icon.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698