OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/ash/palette_delegate_chromeos.h" | 5 #include "chrome/browser/ui/ash/palette_delegate_chromeos.h" |
6 | 6 |
| 7 #include "chrome/browser/chromeos/note_taking_app_utils.h" |
| 8 #include "chrome/browser/profiles/profile_manager.h" |
| 9 |
7 namespace chromeos { | 10 namespace chromeos { |
| 11 namespace { |
| 12 |
| 13 Profile* GetProfile() { |
| 14 return ProfileManager::GetActiveUserProfile(); |
| 15 } |
| 16 |
| 17 } // namespace |
8 | 18 |
9 PaletteDelegateChromeOS::PaletteDelegateChromeOS() {} | 19 PaletteDelegateChromeOS::PaletteDelegateChromeOS() {} |
10 | 20 |
11 PaletteDelegateChromeOS::~PaletteDelegateChromeOS() {} | 21 PaletteDelegateChromeOS::~PaletteDelegateChromeOS() {} |
12 | 22 |
| 23 void PaletteDelegateChromeOS::CreateNote() { |
| 24 chromeos::LaunchNoteTakingAppForNewNote(GetProfile(), base::FilePath()); |
| 25 } |
| 26 |
| 27 bool PaletteDelegateChromeOS::HasNoteApp() { |
| 28 return chromeos::IsNoteTakingAppAvailable(GetProfile()); |
| 29 } |
| 30 |
13 } // namespace chromeos | 31 } // namespace chromeos |
OLD | NEW |