Index: chrome/browser/chromeos/note_taking_app_utils.cc |
diff --git a/chrome/browser/chromeos/note_taking_app_utils.cc b/chrome/browser/chromeos/note_taking_app_utils.cc |
index 7f12a8da4081447fc6d397c1fde54acc820fe55b..1920b8da65b212ac619ede9f8b38d650de471926 100644 |
--- a/chrome/browser/chromeos/note_taking_app_utils.cc |
+++ b/chrome/browser/chromeos/note_taking_app_utils.cc |
@@ -15,6 +15,7 @@ |
#include "base/strings/string_split.h" |
#include "chrome/browser/profiles/profile.h" |
#include "chromeos/chromeos_switches.h" |
+#include "extensions/browser/app_window/app_window.h" |
#include "extensions/browser/extension_registry.h" |
#include "extensions/common/api/app_runtime.h" |
#include "extensions/common/extension.h" |
@@ -86,4 +87,10 @@ void LaunchNoteTakingAppForNewNote(Profile* profile, |
apps::LaunchPlatformAppWithAction(profile, app, std::move(action_data), path); |
} |
+bool IsNoteTakingApp(extensions::AppWindow* app_window, Profile* profile) { |
+ DCHECK(profile); |
Daniel Erat
2016/09/27 19:15:10
DCHECK(app_window) too?
xiaoyinh(OOO Sep 11-29)
2016/09/29 20:37:43
Done.
|
+ const extensions::Extension* app = GetApp(profile); |
+ return app && (app->id() == app_window->extension_id()); |
+} |
+ |
} // namespace chromeos |