Changeset 1402
- Timestamp:
- 03/05/2010 07:57:04 AM (2 years ago)
- Location:
- branches/omcollab_zhongzhen2/wiki/extensions/Help
- Files:
-
- 1 added
- 1 deleted
- 2 edited
- 1 moved
-
HelpExtention.css (modified) (3 diffs)
-
Help_Guide.php (modified) (2 diffs)
-
images/background.gif (moved) (moved from branches/omcollab_zhongzhen2/wiki/extensions/Help/images/button_background.gif)
-
images/button_close.gif (added)
-
images/button_hide.gif (deleted)
Legend:
- Unmodified
- Added
- Removed
-
branches/omcollab_zhongzhen2/wiki/extensions/Help/HelpExtention.css
r1396 r1402 7 7 8 8 #wpTextbox1 { 9 width: 60%;10 9 float: left; 11 10 clear: none; 11 display: none; 12 12 } 13 13 … … 22 22 } 23 23 24 #closeButton { 25 width: 15px; 26 height: 15px; 27 position: absolute; 28 top: -7px; 29 right: -7px; 30 font-size: 11px; 31 } 32 24 33 #shadow { 25 34 background-color: #EFEFEF; 26 35 float: right; 27 36 margin: 5px; 28 width: 30%;37 width: 280px; 29 38 } 30 39 … … 38 47 .tab_normal {color: #FFF; cursor: pointer; background-color: #AEAEAE;} 39 48 40 .button_class {float: right; text-align: center; width: 7%;}49 .button_class {float: right; text-align: center; padding-right: 2px; display: none;} 41 50 .help_content {padding: 10px; display: none; color:#444;} 42 51 -
branches/omcollab_zhongzhen2/wiki/extensions/Help/Help_Guide.php
r1399 r1402 30 30 // Add javascript to Edit page 31 31 $wgOut->addHTML("<script> 32 function changeIcon(obj) { 33 var source = obj.src; 34 if (source.search('button_help') > -1) { 35 obj.src = 'extensions/Help/images/button_hide.gif'; 36 $('#shadow').css('display', 'block'); 37 $('#wpTextbox1').css('width', '60%'); 38 } 39 else { 40 obj.src = 'extensions/Help/images/button_help.gif'; 41 $('#shadow').css('display', 'none'); 42 $('#wpTextbox1').css('width', '92%'); 43 } 32 var textwidth = new Number(); 33 function showHelp() { 34 textwidth = $('#editform').width() - $('#shadow').width() - 30; 35 $('.button_class').css('display', 'none'); 36 $('#shadow').css('display', 'block'); 37 $('#wpTextbox1').css('width', textwidth.toString() + 'px'); 44 38 } 39 40 function hideHelp() { 41 textwidth = $('#editform').width() - $('.button_class').width() - 30; 42 $('.button_class').css('display', 'block'); 43 $('#shadow').css('display', 'none'); 44 $('#wpTextbox1').css('width', textwidth.toString() + 'px'); 45 } 46 47 $(window).resize(function() { 48 if ($('#shadow').css('display') == 'block') 49 textwidth = $('#editform').width() - $('#shadow').width() - 30; 50 else 51 textwidth = $('#editform').width() - $('.button_class').width() - 30; 52 $('#wpTextbox1').css('width', textwidth.toString() + 'px'); 53 }); 54 55 $(function() { 56 textwidth = $('#editform').width() - $('#shadow').width() - 30; 57 $('#wpTextbox1').css('display', 'block'); 58 $('#wpTextbox1').css('width', textwidth.toString() + 'px'); 59 }); 60 45 61 </script>"); 46 62 … … 78 94 79 95 //Help content area 80 $editPage->editFormTextBeforeContent .= '<div id="shadow"><div id="helpArea">' . $html . '</div></div>'; 96 $editPage->editFormTextBeforeContent .= '<div id="shadow"><div id="helpArea"> 97 <div id="closeButton"><img src="extensions/Help/images/button_close.gif" style="cursor: pointer; border: 0;" onclick="hideHelp()"/></div>' . $html . '</div></div>'; 81 98 // Help button 82 $editPage->editFormTextBeforeContent .= '<div class="button_class"><img src="extensions/Help/images/button_h ide.gif" style="cursor: pointer;" onclick="changeIcon(this)"/></div>';99 $editPage->editFormTextBeforeContent .= '<div class="button_class"><img src="extensions/Help/images/button_help.gif" style="cursor: pointer;" onclick="showHelp()"/></div>'; 83 100 84 101 return true;
Note: See TracChangeset
for help on using the changeset viewer.
