Warn on incompatible wxDirDialog styles

This commit is contained in:
Ian McInerney
2020-06-02 10:36:53 +01:00
committed by Vadim Zeitlin
parent 7230acd110
commit ade5030c56
4 changed files with 11 additions and 1 deletions

View File

@@ -88,7 +88,12 @@ public:
virtual void SetPath(const wxString& path) { m_path = path; }
virtual wxString GetMessage() const { return m_message; }
virtual wxString GetPath() const { return m_path; }
virtual wxString GetPath() const
{
wxCHECK_MSG( !HasFlag(wxDD_MULTIPLE), wxString(), "When using wxDD_MULTIPLE, must call GetPaths() instead" );
return m_path;
}
virtual void GetPaths(wxArrayString& paths) const { paths.Empty(); paths.Add(m_path); }
protected: