blob: f8b69a6b5b321c8bf8c5b33d0692902475564e43 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
// Copyright 2013 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.
#include "chrome/browser/profiles/avatar_menu.h"
#include <string>
#include "chrome/browser/browser_process.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/profiles/profile_manager.h"
#include "chrome/browser/ui/ash/session_util.h"
#include "ui/gfx/image/image.h"
// static
void AvatarMenu::GetImageForMenuButton(const base::FilePath& profile_path,
gfx::Image* image,
bool* is_rectangle) {
// ChromeOS avatar icon is circular.
*is_rectangle = false;
Profile* profile =
g_browser_process->profile_manager()->GetProfileByPath(profile_path);
*image = gfx::Image(GetAvatarImageForContext(profile));
}
|