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

Unified Diff: chrome/browser/chromeos/app_mode/kiosk_app_icon_loader.h

Issue 2810973004: Revert of Fetch ARC Kiosk app name and icon from Android side. (Closed)
Patch Set: Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/chromeos/app_mode/kiosk_app_icon_loader.h
diff --git a/chrome/browser/chromeos/app_mode/kiosk_app_icon_loader.h b/chrome/browser/chromeos/app_mode/kiosk_app_icon_loader.h
deleted file mode 100644
index 345ee9acb96a70059fedca5a7aa19be3636ad484..0000000000000000000000000000000000000000
--- a/chrome/browser/chromeos/app_mode/kiosk_app_icon_loader.h
+++ /dev/null
@@ -1,65 +0,0 @@
-// Copyright 2017 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef CHROME_BROWSER_CHROMEOS_APP_MODE_KIOSK_APP_ICON_LOADER_H_
-#define CHROME_BROWSER_CHROMEOS_APP_MODE_KIOSK_APP_ICON_LOADER_H_
-
-#include "base/callback_forward.h"
-#include "base/memory/ref_counted_memory.h"
-#include "base/memory/weak_ptr.h"
-#include "base/optional.h"
-#include "base/sequenced_task_runner.h"
-#include "ui/gfx/image/image_skia.h"
-
-namespace base {
-class FilePath;
-}
-
-namespace chromeos {
-
-// Loads locally stored icon data and decodes it.
-class KioskAppIconLoader {
- public:
- enum LoadResult {
- SUCCESS,
- FAILED_TO_LOAD,
- FAILED_TO_DECODE,
- };
-
- class Delegate {
- public:
- virtual void OnIconLoadSuccess(const gfx::ImageSkia& icon) = 0;
- virtual void OnIconLoadFailure() = 0;
-
- protected:
- virtual ~Delegate() = default;
- };
-
- using ResultCallback =
- base::Callback<void(base::Optional<gfx::ImageSkia> result)>;
-
- explicit KioskAppIconLoader(Delegate* delegate);
-
- ~KioskAppIconLoader();
-
- void Start(const base::FilePath& icon_path);
-
- private:
- void OnImageDecodingFinished(base::Optional<gfx::ImageSkia> result);
-
- // Delegate always lives longer than this class as it's owned by delegate.
- Delegate* const delegate_;
-
- scoped_refptr<base::SequencedTaskRunner> task_runner_;
-
- gfx::ImageSkia icon_;
-
- base::WeakPtrFactory<KioskAppIconLoader> weak_factory_;
-
- DISALLOW_COPY_AND_ASSIGN(KioskAppIconLoader);
-};
-
-} // namespace chromeos
-
-#endif // CHROME_BROWSER_CHROMEOS_APP_MODE_KIOSK_APP_ICON_LOADER_H_
« no previous file with comments | « chrome/browser/chromeos/app_mode/kiosk_app_data_base.cc ('k') | chrome/browser/chromeos/app_mode/kiosk_app_icon_loader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698