Counter Strike : Global Offensive Source Code
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

51 lines
1.4 KiB

  1. //========= Copyright � 1996-2005, Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose:
  4. //
  5. //=============================================================================//
  6. #ifndef IFILESYSTEMOPENDIALOG_H
  7. #define IFILESYSTEMOPENDIALOG_H
  8. #ifdef _WIN32
  9. #pragma once
  10. #endif
  11. #define FILESYSTEMOPENDIALOG_VERSION "FileSystemOpenDlg003"
  12. class IFileSystem;
  13. abstract_class IFileSystemOpenDialog
  14. {
  15. public:
  16. // You must call this first to set the hwnd.
  17. virtual void Init( CreateInterfaceFn factory, void *parentHwnd ) = 0;
  18. // Call this to free the dialog.
  19. virtual void Release() = 0;
  20. // Use these to configure the dialog.
  21. virtual void AddFileMask( const char *pMask ) = 0;
  22. virtual void SetInitialDir( const char *pDir, const char *pPathID = NULL ) = 0;
  23. virtual void SetFilterMdlAndJpgFiles( bool bFilter ) = 0;
  24. virtual void GetFilename( char *pOut, int outLen ) const = 0; // Get the filename they chose.
  25. // Call this to make the dialog itself. Returns true if they clicked OK and false
  26. // if they canceled it.
  27. virtual bool DoModal() = 0;
  28. // This uses the standard windows file open dialog.
  29. virtual bool DoModal_WindowsDialog() = 0;
  30. // Mark the dialog as allowing us to multi-select
  31. virtual void AllowMultiSelect( bool bAllow ) = 0;
  32. // Request the length of the buffer sufficient enough to hold the entire filename result
  33. virtual int GetFilenameBufferSize() const = 0;
  34. };
  35. #endif // IFILESYSTEMOPENDIALOG_H