colorbox_style.js 661 B

123456789101112131415161718192021222324252627
  1. /**
  2. * @file
  3. * Colorbox module style js.
  4. */
  5. (function ($) {
  6. Drupal.behaviors.initColorboxDefaultStyle = {
  7. attach: function (context, settings) {
  8. $(context).bind('cbox_complete', function () {
  9. // Only run if there is a title.
  10. if ($('#cboxTitle:empty', context).length == false) {
  11. $('#cboxLoadedContent img', context).bind('mouseover', function () {
  12. $('#cboxTitle', context).slideDown();
  13. });
  14. $('#cboxOverlay', context).bind('mouseover', function () {
  15. $('#cboxTitle', context).slideUp();
  16. });
  17. }
  18. else {
  19. $('#cboxTitle', context).hide();
  20. }
  21. });
  22. }
  23. };
  24. })(jQuery);