init.php 581 B

12345678910111213141516171819202122232425262728293031323334
  1. <?php
  2. class Toggle_Sidebar extends Plugin {
  3. private $host;
  4. function about() {
  5. return array(1.0,
  6. "Adds a main toolbar button to toggle sidebar",
  7. "fox");
  8. }
  9. function init($host) {
  10. $this->host = $host;
  11. $host->add_hook($host::HOOK_MAIN_TOOLBAR_BUTTON, $this);
  12. }
  13. function hook_main_toolbar_button() {
  14. ?>
  15. <button dojoType="dijit.form.Button" onclick="collapse_feedlist()">
  16. <img src="plugins/toggle_sidebar/application_side_list.png"
  17. title="<?php echo __('Collapse feedlist') ?>">
  18. </button>
  19. <?php
  20. }
  21. function api_version() {
  22. return 2;
  23. }
  24. }
  25. ?>