manager.h 939 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. /*
  2. * Plugins manager - The peTI-NESulator Project
  3. * plugins.h
  4. *
  5. * Created by Manoel TRAPIER on 02/04/07.
  6. * Copyright (c) 2003-2008 986Corp. All rights reserved.
  7. *
  8. * $LastChangedDate$
  9. * $Author$
  10. * $HeadURL$
  11. * $Revision$
  12. *
  13. */
  14. #ifndef PLUGINS_H
  15. #define PLUGINS_H
  16. #include <types.h>
  17. /* Function pointer for prototyping function that plugins may export */
  18. typedef int (*PluginInit) (void);
  19. typedef int (*PluginDeinit) (void);
  20. typedef void (*PluginKeypress) (void);
  21. #ifdef __TINES_PLUGINS__
  22. /* Available functions for plugins */
  23. int plugin_install_keypressHandler(byte key, PluginKeypress);
  24. int plugin_remove_keypressHandler(byte key, PluginKeypress);
  25. #else /* __TINES_PLUGINS__ */
  26. /* Available functions outside of plugins */
  27. int plugin_keypress(byte key);
  28. /* Real Prototype: TBD */
  29. void plugin_list();
  30. int plugin_load(int id);
  31. int plugin_unload(int id);
  32. #endif /* __TINES_PLUGINS__ */
  33. #endif /* PLUGINS_H */