blob: 372ad402be7be2ec8a3172dde3c356f3a5ae0182 [file] [log] [blame]
asanka655d1112015-03-07 05:33:411// Copyright 2015 The Chromium Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef CHROME_BROWSER_PLATFORM_UTIL_INTERNAL_H_
6#define CHROME_BROWSER_PLATFORM_UTIL_INTERNAL_H_
7
8#include "chrome/browser/platform_util.h"
9
10namespace base {
11class FilePath;
12}
13
14namespace platform_util {
15namespace internal {
16
17// Called by platform_util.cc on desktop platforms to invoke platform specific
18// logic to open |path| using a suitable handler. |path| has been verified to be
Gabriel Charette40182e62019-07-25 19:36:2619// of type |type|. Called on the thread pool with
20// base::TaskShutdownBehavior::CONTINUE_ON_SHUTDOWN semantics (and thus can't
21// use global state torn down during shutdown).
asanka655d1112015-03-07 05:33:4122void PlatformOpenVerifiedItem(const base::FilePath& path, OpenItemType type);
23
24// Prevent shell or external applications from being invoked during testing.
25void DisableShellOperationsForTesting();
26
Jesse McKenna14bd4f1a2020-08-10 23:54:2927// Returns false if DisableShellOperationsForTesting() has been called.
28bool AreShellOperationsAllowed();
29
asanka655d1112015-03-07 05:33:4130} // namespace internal
31} // namespace platform_util
32
33#endif // CHROME_BROWSER_PLATFORM_UTIL_INTERNAL_H_