BsMDCodeEditor.h 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. //********************************** Banshee Engine (www.banshee3d.com) **************************************************//
  2. //**************** Copyright (c) 2016 Marko Pintera ([email protected]). All rights reserved. **********************//
  3. #pragma once
  4. #include "BsEditorPrerequisites.h"
  5. #include "CodeEditor/BsCodeEditor.h"
  6. namespace bs
  7. {
  8. /** @addtogroup CodeEditor-Internal
  9. * @{
  10. */
  11. /** Code editor implementation that handles interacting with MonoDevelop. */
  12. class BS_ED_EXPORT MDCodeEditor : public CodeEditor
  13. {
  14. public:
  15. MDCodeEditor(const Path& execPath);
  16. /** @copydoc CodeEditor::openFile */
  17. void openFile(const Path& solutionPath, const Path& path, UINT32 lineNumber) const override;
  18. /** @copydoc CodeEditor::syncSolution */
  19. void syncSolution(const CodeSolutionData& data, const Path& outputPath) const override;
  20. private:
  21. Path mExecPath;
  22. };
  23. /** Code editor factory used for creating specific instances of the MonoDevelop code editor object. */
  24. class BS_ED_EXPORT MDCodeEditorFactory : public CodeEditorFactory
  25. {
  26. public:
  27. MDCodeEditorFactory();
  28. /** @copydoc CodeEditorFactory::getAvailableEditors */
  29. const Vector<CodeEditorType>& getAvailableEditors() const override { return mSupportedEditors; }
  30. /** @copydoc CodeEditorFactory::create */
  31. CodeEditor* create(CodeEditorType editor) const override;
  32. private:
  33. Path mInstallPath;
  34. Vector<CodeEditorType> mSupportedEditors;
  35. };
  36. /** @} */
  37. }