Index: trunk/phase3/skins/common/edit.js |
— | — | @@ -1,7 +1,6 @@ |
2 | 2 | var currentFocused; |
3 | 3 | |
4 | | -// this function generates the actual toolbar buttons with localized text |
5 | | -// we use it to avoid creating the toolbar where javascript is not enabled |
| 4 | +// this function adds a toolbar button to the mwEditButtons list |
6 | 5 | function addButton( imageFile, speedTip, tagOpen, tagClose, sampleText, imageId ) { |
7 | 6 | // Don't generate buttons for browsers which don't fully |
8 | 7 | // support it. |
— | — | @@ -15,8 +14,7 @@ |
16 | 15 | }); |
17 | 16 | } |
18 | 17 | |
19 | | -// this function generates the actual toolbar buttons with localized text |
20 | | -// we use it to avoid creating the toolbar where JavaScript is not enabled |
| 18 | +// this function adds one toolbar button from a mwEditButtons/mwCustomEditButtons item |
21 | 19 | function mwInsertEditButton( parent, item ) { |
22 | 20 | var image = document.createElement( 'img' ); |
23 | 21 | image.width = 23; |
— | — | @@ -43,6 +41,8 @@ |
44 | 42 | return true; |
45 | 43 | } |
46 | 44 | |
| 45 | +// this function generates the actual toolbar buttons with localized text |
| 46 | +// we use it to avoid creating the toolbar where javascript is not enabled |
47 | 47 | function mwSetupToolbar() { |
48 | 48 | var toolbar = document.getElementById( 'toolbar' ); |
49 | 49 | if ( !toolbar ) { |