зеркало из https://github.com/mozilla/gecko-dev.git
50 строки
1.5 KiB
C++
50 строки
1.5 KiB
C++
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
|
|
|
#ifndef nsMIMEInfoChild_h
|
|
#define nsMIMEInfoChild_h
|
|
|
|
#include "nsMIMEInfoImpl.h"
|
|
|
|
/*
|
|
* A platform-generic nsMIMEInfo implementation to be used in child process
|
|
* generic code that needs a MIMEInfo with limited functionality.
|
|
*/
|
|
class nsChildProcessMIMEInfo : public nsMIMEInfoImpl {
|
|
public:
|
|
explicit nsChildProcessMIMEInfo(const char* aMIMEType = "")
|
|
: nsMIMEInfoImpl(aMIMEType) {}
|
|
|
|
explicit nsChildProcessMIMEInfo(const nsACString& aMIMEType)
|
|
: nsMIMEInfoImpl(aMIMEType) {}
|
|
|
|
nsChildProcessMIMEInfo(const nsACString& aType, HandlerClass aClass)
|
|
: nsMIMEInfoImpl(aType, aClass) {}
|
|
|
|
NS_IMETHOD LaunchWithFile(nsIFile* aFile) override {
|
|
return NS_ERROR_NOT_IMPLEMENTED;
|
|
};
|
|
|
|
protected:
|
|
virtual MOZ_MUST_USE nsresult LoadUriInternal(nsIURI* aURI) override {
|
|
return NS_ERROR_NOT_IMPLEMENTED;
|
|
};
|
|
|
|
#ifdef DEBUG
|
|
virtual MOZ_MUST_USE nsresult LaunchDefaultWithFile(nsIFile* aFile) override {
|
|
return NS_ERROR_UNEXPECTED;
|
|
}
|
|
#endif
|
|
static MOZ_MUST_USE nsresult OpenApplicationWithURI(nsIFile* aApplication,
|
|
const nsCString& aURI) {
|
|
return NS_ERROR_NOT_IMPLEMENTED;
|
|
}
|
|
|
|
NS_IMETHOD GetDefaultDescription(nsAString& aDefaultDescription) override {
|
|
return NS_ERROR_NOT_IMPLEMENTED;
|
|
};
|
|
};
|
|
|
|
#endif
|