application_info.h 966 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. // Copyright (c) 2013 GitHub, Inc.
  2. // Use of this source code is governed by the MIT license that can be
  3. // found in the LICENSE file.
  4. #ifndef ELECTRON_SHELL_COMMON_APPLICATION_INFO_H_
  5. #define ELECTRON_SHELL_COMMON_APPLICATION_INFO_H_
  6. #include "build/build_config.h"
  7. #if BUILDFLAG(IS_WIN)
  8. #include "shell/browser/win/scoped_hstring.h"
  9. #endif
  10. #include <string>
  11. namespace electron {
  12. std::string& OverriddenApplicationName();
  13. std::string& OverriddenApplicationVersion();
  14. std::string GetPossiblyOverriddenApplicationName();
  15. std::string GetApplicationName();
  16. std::string GetApplicationVersion();
  17. // Returns the user agent of Electron.
  18. std::string GetApplicationUserAgent();
  19. bool IsAppRTL();
  20. #if BUILDFLAG(IS_WIN)
  21. PCWSTR GetRawAppUserModelID();
  22. bool GetAppUserModelID(ScopedHString* app_id);
  23. void SetAppUserModelID(const std::wstring& name);
  24. bool IsRunningInDesktopBridge();
  25. #endif
  26. } // namespace electron
  27. #endif // ELECTRON_SHELL_COMMON_APPLICATION_INFO_H_