From c1c0b3135bf36dacb8c79a14753d485a39f1c089 Mon Sep 17 00:00:00 2001 From: Gareth J Barnard Date: Sun, 2 Sep 2012 23:05:14 +0100 Subject: [PATCH] Change to 'pix:' in css for images with css class based toggling. --- Readme.txt | 29 +++++++++++++++--- format.php | 28 ----------------- module.js | 12 ++++---- {images => pix}/arrow_down.png | Bin {images => pix}/arrow_up.png | Bin {images => pix}/tc_logo_spanner.png | Bin renderer.php | 2 +- styles.css | 45 +++++++++++++++++++++++----- version.php | 2 +- 9 files changed, 71 insertions(+), 47 deletions(-) rename {images => pix}/arrow_down.png (100%) rename {images => pix}/arrow_up.png (100%) rename {images => pix}/tc_logo_spanner.png (100%) diff --git a/Readme.txt b/Readme.txt index 90440f83..91a4b2b1 100644 --- a/Readme.txt +++ b/Readme.txt @@ -42,8 +42,17 @@ Installation 8. Login as an administrator and follow standard the 'plugin' update notification. If needed, go to 'Site administration' -> 'Notifications' if this does not happen. 9. If desired, edit the colours of the 'styles.css' - which contains instructions on how to have per theme colours. -10. To change the arrow graphic you need to replace 'arrow_up.png' and 'arrow_down.png'. Reuse the graphics - if you want. Created in Paint.Net. +10. To change the arrow graphic you need to replace 'arrow_up.png' and 'arrow_down.png' in the 'pix' folder. Or override the + css by using the selectors for the various images, override the 'background' attribute: + + body.jsenabled .course-content ul.ctopics li.section .content .toggle a.toggle_open - For the 'up' arrow in the toggle - original is 24px. + body.jsenabled .course-content ul.ctopics li.section .content .toggle a.toggle_closed - For the 'down' arrow in the toggle - original is 24px. + .course-content ul.ctopics li.section .content .toggle a.toggle_closed - For the 'up' arrow in the toggle when JavaScript is disabled and the toggles default to open. + #toggle-all .content .sectionbody h4 a.on - For the 'open all sections' image - original is 24px. + #toggle-all .content .sectionbody h4 a.off - For the 'closed all sections' image - original is 24px. + #tc-set-settings - For the 'settings' image. + + If in doubt, please consult 'styles.css' in the format. 11. Put Moodle out of Maintenance Mode. Upgrade Instructions @@ -524,7 +533,7 @@ NOTE: If uninstallation fails, drop the table 'format_topcoll_layout' and the en instructions on the left. The instructions are in the 'en' langauge file as the 'formatsettingsinformation' string for translation. -30th August 2012 - Version 2.3.7.3 +2nd September 2012 - Version 2.3.7.3 1. Changes to 'renderer.php' because of MDL-28207 - thus requiring Moodle 2.3.1 2012062501.09 (Build: 20120809). 2. Implemented MDL-34798 which I reported for AJAX section moving. 3. Integrated CONTRIB-3827 to fix proliferation of CSS styles across other course formats. @@ -535,6 +544,18 @@ NOTE: If uninstallation fails, drop the table 'format_topcoll_layout' and the en 8. Implemented MDL-34917 which I reported as an improvement. 9. Make toggle titles bold and change 'all toggles' to 'all sections', from comments made on MDL-35048. 10. Cherry picked Luiggi's change https://github.com/luiggisanso/moodle-format_topcoll/commit/9bd818f5a4efb347aef4f5154ea2930526552bfc + 11. Figured out how to use 'pix:' for URL's in css for the format, so have changed so that the images are now controlled by css classes. This + means that it is now possible to override them in your theme in css. The following is the selectors for the various images, override + the 'background' attribute: + + body.jsenabled .course-content ul.ctopics li.section .content .toggle a.toggle_open - For the 'up' arrow in the toggle - original is 24px. + body.jsenabled .course-content ul.ctopics li.section .content .toggle a.toggle_closed - For the 'down' arrow in the toggle - original is 24px. + .course-content ul.ctopics li.section .content .toggle a.toggle_closed - For the 'up' arrow in the toggle when JavaScript is disabled and the toggles default to open. + #toggle-all .content .sectionbody h4 a.on - For the 'open all sections' image - original is 24px. + #toggle-all .content .sectionbody h4 a.off - For the 'closed all sections' image - original is 24px. + #tc-set-settings - For the 'settings' image. + + If in doubt, please consult 'styles.css' in the format. Thanks ------ @@ -587,6 +608,6 @@ Desired Enhancements -------------------- 1. Smoother animated toggle action. -G J Barnard MSc. BSc(Hons)(Sndw). MBCS. CEng. CITP. PGCE. - 30th August 2012. +G J Barnard MSc. BSc(Hons)(Sndw). MBCS. CEng. CITP. PGCE. - 2nd September 2012. Moodle profile: moodle.org/user/profile.php?id=442195. Web profile : about.me/gjbarnard \ No newline at end of file diff --git a/format.php b/format.php index f8452b8e..8735fe7d 100644 --- a/format.php +++ b/format.php @@ -86,34 +86,6 @@ ?>