Implement wxFileType::GetOpenCommand() in wxOSX.
This method used to work in 2.8 but was unimplemented in 2.9. Restore more or less the old implementation using the data that we already have in wxMimeTypesManager anyhow. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@68563 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -56,6 +56,7 @@ private:
|
||||
bool GetMimeTypes(const wxString& uti, wxArrayString& mimeTypes);
|
||||
bool GetIcon(const wxString& uti, wxIconLocation *iconLoc);
|
||||
bool GetDescription(const wxString& uti, wxString *desc);
|
||||
bool GetApplication(const wxString& uti, wxString *command);
|
||||
|
||||
// Structure to represent file types
|
||||
typedef struct FileTypeData
|
||||
@@ -63,6 +64,7 @@ private:
|
||||
wxArrayString extensions;
|
||||
wxArrayString mimeTypes;
|
||||
wxIconLocation iconLoc;
|
||||
wxString application;
|
||||
wxString description;
|
||||
}
|
||||
FileTypeInfo;
|
||||
@@ -95,9 +97,9 @@ public:
|
||||
bool GetMimeTypes(wxArrayString& mimeTypes) const ;
|
||||
bool GetIcon(wxIconLocation *iconLoc) const ;
|
||||
bool GetDescription(wxString *desc) const ;
|
||||
bool GetOpenCommand(wxString *openCmd, const wxFileType::MessageParameters& params) const;
|
||||
|
||||
// These functions are only stubs on Mac OS X
|
||||
bool GetOpenCommand(wxString *openCmd, const wxFileType::MessageParameters& params) const;
|
||||
bool GetPrintCommand(wxString *printCmd, const wxFileType::MessageParameters& params) const;
|
||||
size_t GetAllCommands(wxArrayString *verbs, wxArrayString *commands, const wxFileType::MessageParameters& params) const;
|
||||
bool SetCommand(const wxString& cmd, const wxString& verb, bool overwriteprompt = TRUE);
|
||||
|
Reference in New Issue
Block a user