Closed (fixed)
Project:
Chaos Tool Suite (ctools)
Version:
7.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
13 May 2010 at 23:21 UTC
Updated:
10 Apr 2012 at 04:00 UTC
Currently, the modalBackdrop color and opacity are hardcoded into modal.js, making it impossible to theme. I added those options to the Drupal.settings.CToolsModal object -- in line with how the closeText, closeImage, and throbber work. Here's the change:
var opts = {
// @todo this should be elsewhere.
opacity: Drupal.settings.CToolsModal.backDropOpacity,
background: Drupal.settings.CToolsModal.backDropColor
};
...and then reflected in modal.inc
$settings = array('CToolsModal' => array(
'closeText' => t('Close Window'),
'closeImage' => theme('image', ctools_image_path('icon-close-window.png'), t('Close window'), t('Close window')),
'throbber' => theme('image', ctools_image_path('throbber.gif'), t('Loading...'), t('Loading')),
'backDropOpacity' => '.55',
'backDropColor' => '#fff'
));
| Comment | File | Size | Author |
|---|---|---|---|
| modal-opts.patch | 1.23 KB | jasonn1234 |
Comments
Comment #1
sdboyer commentedMakes total sense to me. Committed. Thanks!
Comment #3
geerlingguy commentedWas this ever forward-ported to 7.x-1.x?
Comment #4
merlinofchaos commentedIt should have been, we did a merge late in 2010. Can you verify it's not in 7.x?
Comment #5
geerlingguy commentedNevermind, it was my own dumb code not working... :)