tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

nsGNOMEShellService.h (1331B)


      1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
      2 /* This Source Code Form is subject to the terms of the Mozilla Public
      3 * License, v. 2.0. If a copy of the MPL was not distributed with this
      4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
      5 
      6 #ifndef nsgnomeshellservice_h____
      7 #define nsgnomeshellservice_h____
      8 
      9 #include "nsIGNOMEShellService.h"
     10 #include "nsToolkitShellService.h"
     11 #include "nsString.h"
     12 #ifdef MOZ_ENABLE_DBUS
     13 #  include "nsGNOMEShellSearchProvider.h"
     14 #endif
     15 
     16 class nsIGIOService;
     17 
     18 class nsGNOMEShellService final : public nsIGNOMEShellService,
     19                                  public nsToolkitShellService {
     20 public:
     21  nsGNOMEShellService() : mAppIsInPath(false) {}
     22 
     23  NS_DECL_ISUPPORTS
     24  NS_DECL_NSISHELLSERVICE
     25  NS_DECL_NSIGNOMESHELLSERVICE
     26 
     27  nsresult Init();
     28 
     29 private:
     30  ~nsGNOMEShellService() {}
     31 
     32  bool KeyMatchesAppName(const char* aKeyValue) const;
     33  bool CheckHandlerMatchesAppName(const nsACString& handler) const;
     34  bool IsDefaultForSchemeHelper(const nsACString& aScheme,
     35                                nsIGIOService* giovfs) const;
     36 
     37 #ifdef MOZ_ENABLE_DBUS
     38  nsGNOMEShellSearchProvider mSearchProvider;
     39 #endif
     40  bool GetAppPathFromLauncher();
     41  bool mUseLocaleFilenames;
     42  nsCString mAppPath;
     43  bool mAppIsInPath;
     44 };
     45 
     46 #endif  // nsgnomeshellservice_h____