MDL-41713 atto - implement new icons with matching UI

This commit is contained in:
Jason Fowler
2013-09-20 14:20:05 +08:00
parent e9c56bce02
commit 36973d707e
110 changed files with 215 additions and 1371 deletions
+3 -3
View File
@@ -31,18 +31,18 @@ defined('MOODLE_INTERNAL') || die();
function atto_bold_init_editor($elementid) {
global $PAGE, $OUTPUT;
$icon = $OUTPUT->pix_icon('bold', get_string('bold', 'atto_bold'), 'atto_bold', array('class'=>'icon'));
$icon = $OUTPUT->pix_icon('e/bold', get_string('bold', 'atto_bold'), 'moodle', array('class'=>'icon'));
$PAGE->requires->yui_module('moodle-atto_bold-button',
'M.atto_bold.init',
array(array('elementid'=>$elementid, 'icon'=>$icon)),
array(array('elementid'=>$elementid, 'icon'=>$icon, 'group'=>'style')),
true);
}
/**
* Return the order this plugin should be displayed in the toolbar
* @return int
* @return int the absolute position within the toolbar
*/
function atto_bold_sort_order() {
return 0;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 446 B

-68
View File
@@ -1,68 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="16"
height="16"
id="svg2"
version="1.1"
inkscape:version="0.48.3.1 r9886"
sodipodi:docname="bold.svg" preserveAspectRatio="xMinYMid meet">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="15.839192"
inkscape:cx="-8.2482624"
inkscape:cy="15.312045"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1122"
inkscape:window-height="685"
inkscape:window-x="162"
inkscape:window-y="57"
inkscape:window-maximized="0" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1036.3622)">
<text
xml:space="preserve"
style="font-size:64px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:Comic Sans MS;-inkscape-font-specification:Arial Bold"
x="7.2604713"
y="1049.6475"
id="text2984"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan2986"
x="7.2604713"
y="1049.6475"
style="font-size:14px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;fill:#999999;fill-opacity:1;font-family:Arial;-inkscape-font-specification:Arial Bold">b</tspan></text>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.3 KiB

@@ -32,7 +32,7 @@ M.atto_bold = M.atto_bold || {
document.execCommand('bold', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'bold', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'bold', params.icon, params.group, click);
}
};
@@ -1 +1 @@
YUI.add("moodle-atto_bold-button",function(e,t){M.atto_bold=M.atto_bold||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("bold",!1,null)};M.editor_atto.add_toolbar_button(e.elementid,"bold",e.icon,t)}}},"@VERSION@",{requires:["node"]});
YUI.add("moodle-atto_bold-button",function(e,t){M.atto_bold=M.atto_bold||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("bold",!1,null)};M.editor_atto.add_toolbar_button(e.elementid,"bold",e.icon,e.group,t)}}},"@VERSION@",{requires:["node"]});
@@ -32,7 +32,7 @@ M.atto_bold = M.atto_bold || {
document.execCommand('bold', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'bold', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'bold', params.icon, params.group, click);
}
};
+1 -1
View File
@@ -30,6 +30,6 @@ M.atto_bold = M.atto_bold || {
document.execCommand('bold', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'bold', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'bold', params.icon, params.group, click);
}
};
+4 -4
View File
@@ -31,21 +31,21 @@ defined('MOODLE_INTERNAL') || die();
function atto_clear_init_editor($elementid) {
global $PAGE, $OUTPUT;
$icon = $OUTPUT->pix_icon('clear',
$icon = $OUTPUT->pix_icon('e/clear_formatting',
get_string('clear', 'atto_clear'),
'atto_clear',
'moodle',
array('class'=>'icon'));
$PAGE->requires->yui_module('moodle-atto_clear-button',
'M.atto_clear.init',
array(array('elementid'=>$elementid, 'icon'=>$icon)),
array(array('elementid'=>$elementid, 'icon'=>$icon, 'group'=>'clear')),
true);
}
/**
* Return the order this plugin should be displayed in the toolbar
* @return int
* @return int the absolute position within the toolbar
*/
function atto_clear_sort_order() {
return 10;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 468 B

@@ -1,85 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="16"
height="16"
id="svg2"
version="1.1"
inkscape:version="0.48.3.1 r9886"
sodipodi:docname="clear.svg" preserveAspectRatio="xMinYMid meet">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="15.839192"
inkscape:cx="-3.8870379"
inkscape:cy="15.312045"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1122"
inkscape:window-height="685"
inkscape:window-x="162"
inkscape:window-y="57"
inkscape:window-maximized="0" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:clear />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1036.3622)">
<g
id="g3756"
transform="translate(0,-0.44194174)">
<rect
ry="0"
transform="translate(0,1036.3622)"
y="2.3629408"
x="7.0079331"
height="5.3664355"
width="2.0203052"
id="rect2982"
style="fill:#999999;fill-opacity:1;stroke:#999999;stroke-width:1;stroke-linecap:round;stroke-linejoin:bevel;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
<rect
ry="0.4152233"
y="1043.2078"
x="3.9774756"
height="2.7870839"
width="8.0812302"
id="rect2984"
style="fill:#999999;fill-opacity:1;stroke:#999999;stroke-width:0.82672101;stroke-linecap:round;stroke-linejoin:bevel;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
<rect
ry="0.053281363"
y="1045.6699"
x="4.4825521"
height="3.1562684"
width="7.0079417"
id="rect3754"
style="fill:#ffffff;fill-opacity:1;fill-rule:nonzero;stroke:#999999;stroke-width:1;stroke-linecap:round;stroke-linejoin:bevel;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
</g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.8 KiB

@@ -32,7 +32,7 @@ M.atto_clear = M.atto_clear || {
document.execCommand('removeFormat', false);
};
M.editor_atto.add_toolbar_button(params.elementid, 'clear', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'clear', params.icon, params.group, click);
}
};
@@ -1 +1 @@
YUI.add("moodle-atto_clear-button",function(e,t){M.atto_clear=M.atto_clear||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("removeFormat",!1)};M.editor_atto.add_toolbar_button(e.elementid,"clear",e.icon,t)}}},"@VERSION@",{requires:["node"]});
YUI.add("moodle-atto_clear-button",function(e,t){M.atto_clear=M.atto_clear||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("removeFormat",!1)};M.editor_atto.add_toolbar_button(e.elementid,"clear",e.icon,e.group,t)}}},"@VERSION@",{requires:["node"]});
@@ -32,7 +32,7 @@ M.atto_clear = M.atto_clear || {
document.execCommand('removeFormat', false);
};
M.editor_atto.add_toolbar_button(params.elementid, 'clear', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'clear', params.icon, params.group, click);
}
};
+1 -1
View File
@@ -30,6 +30,6 @@ M.atto_clear = M.atto_clear || {
document.execCommand('removeFormat', false);
};
M.editor_atto.add_toolbar_button(params.elementid, 'clear', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'clear', params.icon, params.group, click);
}
};
+3 -3
View File
@@ -31,18 +31,18 @@ defined('MOODLE_INTERNAL') || die();
function atto_html_init_editor($elementid) {
global $PAGE, $OUTPUT;
$icon = $OUTPUT->pix_icon('html', get_string('html', 'atto_html'), 'atto_html', array('class'=>'icon'));
$icon = $OUTPUT->pix_icon('e/source_code', get_string('html', 'atto_html'), 'moodle', array('class'=>'icon'));
$PAGE->requires->yui_module('moodle-atto_html-button',
'M.atto_html.init',
array(array('elementid'=>$elementid, 'icon'=>$icon)),
array(array('elementid'=>$elementid, 'icon'=>$icon, 'group'=>'html')),
true);
}
/**
* Return the order this plugin should be displayed in the toolbar
* @return int
* @return array groupname followed by the absolute position within the toolbar
*/
function atto_html_sort_order() {
return 15;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 466 B

-69
View File
@@ -1,69 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="16"
height="16"
id="svg2"
version="1.1"
inkscape:version="0.48.3.1 r9886"
sodipodi:docname="html.svg" preserveAspectRatio="xMinYMid meet">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="11.313709"
inkscape:cx="-8.155614"
inkscape:cy="13.234355"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1122"
inkscape:window-height="685"
inkscape:window-x="162"
inkscape:window-y="57"
inkscape:window-maximized="0" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>media/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillMedia" />
<dc:title />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1036.3622)">
<text
xml:space="preserve"
style="font-size:52.96332169000000079px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#999999;fill-opacity:1;stroke:none;font-family:Comic Sans MS;-inkscape-font-specification:Comic Sans MS"
x="10.191385"
y="836.76996"
id="text2988"
sodipodi:linespacing="125%"
transform="scale(0.79843788,1.2524456)"><tspan
sodipodi:role="line"
id="tspan2990"
x="10.191385"
y="836.76996"
style="font-size:9.93062304999999945px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;font-family:FreeMono;-inkscape-font-specification:FreeMono Bold;fill:#999999;fill-opacity:1">&lt;/&gt;</tspan></text>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.4 KiB

@@ -51,7 +51,7 @@ M.atto_html = M.atto_html || {
M.atto_html.ishtml = !M.atto_html.ishtml;
};
M.editor_atto.add_toolbar_button(params.elementid, 'html', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'html', params.icon, params.group, click);
}
};
@@ -1 +1 @@
YUI.add("moodle-atto_html-button",function(e,t){M.atto_html=M.atto_html||{ishtml:!1,init:function(t){var n=function(t,n){t.preventDefault();var r=e.one("#"+n),i=e.one("#"+n+"editable");M.atto_html.ishtml?(M.editor_atto.enable_all_widgets(n),i.setHTML(""),i.append(r.get("value")),r.hide(),i.show()):(M.editor_atto.disable_all_widgets(n),M.editor_atto.enable_widget(n,"html"),r.set("value",i.getHTML()),i.hide(),r.show()),M.atto_html.ishtml=!M.atto_html.ishtml};M.editor_atto.add_toolbar_button(t.elementid,"html",t.icon,n)}}},"@VERSION@",{requires:["node"]});
YUI.add("moodle-atto_html-button",function(e,t){M.atto_html=M.atto_html||{ishtml:!1,init:function(t){var n=function(t,n){t.preventDefault();var r=e.one("#"+n),i=e.one("#"+n+"editable");M.atto_html.ishtml?(M.editor_atto.enable_all_widgets(n),i.setHTML(""),i.append(r.get("value")),r.hide(),i.show()):(M.editor_atto.disable_all_widgets(n),M.editor_atto.enable_widget(n,"html"),r.set("value",i.getHTML()),i.hide(),r.show()),M.atto_html.ishtml=!M.atto_html.ishtml};M.editor_atto.add_toolbar_button(t.elementid,"html",t.icon,t.group,n)}}},"@VERSION@",{requires:["node"]});
@@ -51,7 +51,7 @@ M.atto_html = M.atto_html || {
M.atto_html.ishtml = !M.atto_html.ishtml;
};
M.editor_atto.add_toolbar_button(params.elementid, 'html', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'html', params.icon, params.group, click);
}
};
+1 -1
View File
@@ -49,6 +49,6 @@ M.atto_html = M.atto_html || {
M.atto_html.ishtml = !M.atto_html.ishtml;
};
M.editor_atto.add_toolbar_button(params.elementid, 'html', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'html', params.icon, params.group, click);
}
};
+4 -4
View File
@@ -31,9 +31,9 @@ defined('MOODLE_INTERNAL') || die();
function atto_image_init_editor($elementid) {
global $PAGE, $OUTPUT;
$icon = $OUTPUT->pix_icon('image',
$icon = $OUTPUT->pix_icon('e/insert_edit_image',
get_string('image', 'atto_image'),
'atto_image',
'moodle',
array('class'=>'icon'));
$PAGE->requires->strings_for_js(array('createimage',
@@ -46,14 +46,14 @@ function atto_image_init_editor($elementid) {
'height'), 'atto_image');
$PAGE->requires->yui_module('moodle-atto_image-button',
'M.atto_image.init',
array(array('elementid'=>$elementid, 'icon'=>$icon)),
array(array('elementid'=>$elementid, 'icon'=>$icon, 'group'=>'file')),
true);
}
/**
* Return the order this plugin should be displayed in the toolbar
* @return int
* @return int the absolute position within the toolbar
*/
function atto_image_sort_order() {
return 13;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 506 B

@@ -1,77 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="16"
height="16"
id="svg2"
version="1.1"
inkscape:version="0.48.3.1 r9886"
sodipodi:docname="image.svg" preserveAspectRatio="xMinYMid meet">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="32"
inkscape:cx="11.577509"
inkscape:cy="9.3016902"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1122"
inkscape:window-height="685"
inkscape:window-x="162"
inkscape:window-y="57"
inkscape:window-maximized="0" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1036.3622)">
<rect
style="fill:none;fill-opacity:1;fill-rule:nonzero;stroke:#999999;stroke-opacity:1"
id="rect2986"
width="14.142136"
height="13.131983"
x="1.0101526"
y="1.4159228"
transform="translate(0,1036.3622)"
ry="0.053281363" />
<path
style="fill:#999999;fill-opacity:1;stroke:none"
d="m 13.794977,1041.1242 c 0,0.9241 -0.749059,1.6732 -1.673146,1.6732 -0.9241,0 -1.673146,-0.7491 -1.673146,-1.6732 0,-0.924 0.749059,-1.6731 1.673146,-1.6731 0.9241,0 1.673146,0.7491 1.673146,1.6731 z"
id="path3761"
inkscape:connector-curvature="0" />
<path
transform="translate(0,1036.3622)"
style="fill:#999999;fill-opacity:1;fill-rule:nonzero;stroke:#999999;stroke-width:1;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
d="m 1.5711386,10.553572 c 1.7890625,-0.125 3.8205354,-3.734909 6.286004,-3.75 2.4654684,-0.015091 3.8591064,3.4375 6.4645754,3.75 0.01465,0.0018 0.02808,0.0059 0.03771,0.01557 0.0096,0.0096 0.01557,0.02295 0.01557,0.03771 l 0,3.018437 c 0,0.02952 -0.02376,0.05328 -0.05328,0.05328 l -12.7505794,0 c -0.029518,0 -0.053281,-0.02376 -0.053281,-0.05328 l 0,-3.018437 c 0,-0.01476 0.00594,-0.02808 0.015572,-0.03771 0.00963,-0.0096 0.022987,-0.01454 0.037709,-0.01557 z"
id="rect3753"
inkscape:connector-curvature="0"
sodipodi:nodetypes="szssssssssss" />
</g>
</svg>

Before

Width:  |  Height:  |  Size: 3.0 KiB

@@ -87,7 +87,7 @@ M.atto_image = M.atto_image || {
}
};
M.editor_atto.add_toolbar_button(params.elementid, 'image', params.icon, display_chooser, this);
M.editor_atto.add_toolbar_button(params.elementid, 'image', params.icon, params.group, display_chooser, this);
},
open_filepicker : function(e) {
var elementid = this.getAttribute('data-editor');
@@ -1 +1 @@
YUI.add("moodle-atto_image-button",function(e,t){M.atto_image=M.atto_image||{dialogue:null,selection:null,init:function(t){var n=function(t,n){t.preventDefault(),M.editor_atto.is_active(n)||M.editor_atto.focus(n),M.atto_image.selection=M.editor_atto.get_selection();if(M.atto_image.selection!==!1){var r;M.atto_image.dialogue?r=M.atto_image.dialogue:r=new M.core.dialogue({visible:!1,modal:!0,close:!0,draggable:!0}),r.set("bodyContent",M.atto_image.get_form_content(n)),r.set("headerContent",M.util.get_string("createimage","atto_image")),r.render(),r.centerDialogue(),M.atto_image.dialogue=r;var i=M.editor_atto.get_selection_text(),s=0,o=[];for(s=0;s<i.childNodes.length;s++){var u=i.childNodes[0];o.length===0&&(u.nodeName.toLowerCase()==="img"?o[0]=u:u.getElementsByTagName&&(o=u.getElementsByTagName("img")))}if(o.length>0){var a=e.one(o[0]),f=a.getAttribute("width"),l=a.getAttribute("height");f>0&&e.one("#atto_image_widthentry").set("value",f),l>0&&e.one("#atto_image_heightentry").set("value",l),e.one("#atto_image_preview").set("src",a.get("src")),e.one("#atto_image_preview").setStyle("display","inline"),e.one("#atto_image_altentry").set("value",a.get("alt")),e.one("#atto_image_urlentry").set("value",a.get("src"))}r.show()}};M.editor_atto.add_toolbar_button(t.elementid,"image",t.icon,n,this)},open_filepicker:function(e){var t=this.getAttribute("data-editor");e.preventDefault(),M.editor_atto.show_filepicker(t,"image",M.atto_image.filepicker_callback)},filepicker_callback:function(t){if(t.url!==""){var n=e.one("#atto_image_urlentry");n.set("value",t.url),n=e.one("#atto_image_altentry"),n.set("value",t.file);var r=new Image;r.onload=function(){e.one("#atto_image_widthentry").set("value",this.width),e.one("#atto_image_heightentry").set("value",this.height),e.one("#atto_image_preview").set("src",this.src),e.one("#atto_image_preview").setStyle("display","inline")},r.src=t.url}},set_image:function(t){t.preventDefault(),M.atto_image.dialogue.hide();var n=t.currentTarget.get("parentNode").one("#atto_image_urlentry"),r=n.get("value");n=t.currentTarget.get("parentNode").one("#atto_image_altentry");var i=n.get("value");n=t.currentTarget.get("parentNode").one("#atto_image_widthentry");var s=n.get("value");n=t.currentTarget.get("parentNode").one("#atto_image_heightentry");var o=n.get("value");if(r!==""&&i!==""){M.editor_atto.set_selection(M.atto_image.selection);var u='<img src="'+e.Escape.html(r)+'" alt="'+e.Escape.html(i)+'"';s&&(u+=' width="'+e.Escape.html(s)+'"'),o&&(u+=' height="'+e.Escape.html(o)+'"'),u+='"/>',document.selection&&document.selection.createRange().pasteHTML?document.selection.createRange().pasteHTML(u):document.execCommand("insertHTML",!1,u)}},get_form_content:function(t){var n=e.Node.create('<form class="atto_form"><label for="atto_image_urlentry">'+M.util.get_string("enterurl","atto_image")+"</label>"+'<input type="url" value="" id="atto_image_urlentry" size="32"/>'+'<label for="atto_image_altentry">'+M.util.get_string("enteralt","atto_image")+"</label>"+'<input type="text" value="" id="atto_image_altentry" size="32" required="true"/>'+'<label for="atto_image_widthentry">'+M.util.get_string("width","atto_image")+"</label>"+'<input type="text" value="" id="atto_image_widthentry" size="10"/>'+"<br/>"+'<label for="atto_image_heightentry">'+M.util.get_string("height","atto_image")+"</label>"+'<input type="text" value="" id="atto_image_heightentry" size="10"/>'+'<label for="atto_image_preview">'+M.util.get_string("preview","atto_image")+"</label>"+'<img src="#" width="200" id="atto_image_preview" alt="" style="display: none;"/>'+"<hr/>"+'<button id="openimagebrowser" data-editor="'+e.Escape.html(t)+'">'+M.util.get_string("browserepositories","atto_image")+"</button>"+"<hr/>"+'<button id="atto_image_urlentrysubmit">'+M.util.get_string("createimage","atto_image")+"</button>"+"</form>"+"<hr/>"+M.util.get_string("accessibilityhint","atto_image"));return n.one("#atto_image_urlentrysubmit").on("click",M.atto_image.set_image),n.one("#openimagebrowser").on("click",M.atto_image.open_filepicker),n}}},"@VERSION@",{requires:["node","escape"]});
YUI.add("moodle-atto_image-button",function(e,t){M.atto_image=M.atto_image||{dialogue:null,selection:null,init:function(t){var n=function(t,n){t.preventDefault(),M.editor_atto.is_active(n)||M.editor_atto.focus(n),M.atto_image.selection=M.editor_atto.get_selection();if(M.atto_image.selection!==!1){var r;M.atto_image.dialogue?r=M.atto_image.dialogue:r=new M.core.dialogue({visible:!1,modal:!0,close:!0,draggable:!0}),r.set("bodyContent",M.atto_image.get_form_content(n)),r.set("headerContent",M.util.get_string("createimage","atto_image")),r.render(),r.centerDialogue(),M.atto_image.dialogue=r;var i=M.editor_atto.get_selection_text(),s=0,o=[];for(s=0;s<i.childNodes.length;s++){var u=i.childNodes[0];o.length===0&&(u.nodeName.toLowerCase()==="img"?o[0]=u:u.getElementsByTagName&&(o=u.getElementsByTagName("img")))}if(o.length>0){var a=e.one(o[0]),f=a.getAttribute("width"),l=a.getAttribute("height");f>0&&e.one("#atto_image_widthentry").set("value",f),l>0&&e.one("#atto_image_heightentry").set("value",l),e.one("#atto_image_preview").set("src",a.get("src")),e.one("#atto_image_preview").setStyle("display","inline"),e.one("#atto_image_altentry").set("value",a.get("alt")),e.one("#atto_image_urlentry").set("value",a.get("src"))}r.show()}};M.editor_atto.add_toolbar_button(t.elementid,"image",t.icon,t.group,n,this)},open_filepicker:function(e){var t=this.getAttribute("data-editor");e.preventDefault(),M.editor_atto.show_filepicker(t,"image",M.atto_image.filepicker_callback)},filepicker_callback:function(t){if(t.url!==""){var n=e.one("#atto_image_urlentry");n.set("value",t.url),n=e.one("#atto_image_altentry"),n.set("value",t.file);var r=new Image;r.onload=function(){e.one("#atto_image_widthentry").set("value",this.width),e.one("#atto_image_heightentry").set("value",this.height),e.one("#atto_image_preview").set("src",this.src),e.one("#atto_image_preview").setStyle("display","inline")},r.src=t.url}},set_image:function(t){t.preventDefault(),M.atto_image.dialogue.hide();var n=t.currentTarget.get("parentNode").one("#atto_image_urlentry"),r=n.get("value");n=t.currentTarget.get("parentNode").one("#atto_image_altentry");var i=n.get("value");n=t.currentTarget.get("parentNode").one("#atto_image_widthentry");var s=n.get("value");n=t.currentTarget.get("parentNode").one("#atto_image_heightentry");var o=n.get("value");if(r!==""&&i!==""){M.editor_atto.set_selection(M.atto_image.selection);var u='<img src="'+e.Escape.html(r)+'" alt="'+e.Escape.html(i)+'"';s&&(u+=' width="'+e.Escape.html(s)+'"'),o&&(u+=' height="'+e.Escape.html(o)+'"'),u+='"/>',document.selection&&document.selection.createRange().pasteHTML?document.selection.createRange().pasteHTML(u):document.execCommand("insertHTML",!1,u)}},get_form_content:function(t){var n=e.Node.create('<form class="atto_form"><label for="atto_image_urlentry">'+M.util.get_string("enterurl","atto_image")+"</label>"+'<input type="url" value="" id="atto_image_urlentry" size="32"/>'+'<label for="atto_image_altentry">'+M.util.get_string("enteralt","atto_image")+"</label>"+'<input type="text" value="" id="atto_image_altentry" size="32" required="true"/>'+'<label for="atto_image_widthentry">'+M.util.get_string("width","atto_image")+"</label>"+'<input type="text" value="" id="atto_image_widthentry" size="10"/>'+"<br/>"+'<label for="atto_image_heightentry">'+M.util.get_string("height","atto_image")+"</label>"+'<input type="text" value="" id="atto_image_heightentry" size="10"/>'+'<label for="atto_image_preview">'+M.util.get_string("preview","atto_image")+"</label>"+'<img src="#" width="200" id="atto_image_preview" alt="" style="display: none;"/>'+"<hr/>"+'<button id="openimagebrowser" data-editor="'+e.Escape.html(t)+'">'+M.util.get_string("browserepositories","atto_image")+"</button>"+"<hr/>"+'<button id="atto_image_urlentrysubmit">'+M.util.get_string("createimage","atto_image")+"</button>"+"</form>"+"<hr/>"+M.util.get_string("accessibilityhint","atto_image"));return n.one("#atto_image_urlentrysubmit").on("click",M.atto_image.set_image),n.one("#openimagebrowser").on("click",M.atto_image.open_filepicker),n}}},"@VERSION@",{requires:["node","escape"]});
@@ -87,7 +87,7 @@ M.atto_image = M.atto_image || {
}
};
M.editor_atto.add_toolbar_button(params.elementid, 'image', params.icon, display_chooser, this);
M.editor_atto.add_toolbar_button(params.elementid, 'image', params.icon, params.group, display_chooser, this);
},
open_filepicker : function(e) {
var elementid = this.getAttribute('data-editor');
+1 -1
View File
@@ -85,7 +85,7 @@ M.atto_image = M.atto_image || {
}
};
M.editor_atto.add_toolbar_button(params.elementid, 'image', params.icon, display_chooser, this);
M.editor_atto.add_toolbar_button(params.elementid, 'image', params.icon, params.group, display_chooser, this);
},
open_filepicker : function(e) {
var elementid = this.getAttribute('data-editor');
+4 -4
View File
@@ -31,21 +31,21 @@ defined('MOODLE_INTERNAL') || die();
function atto_indent_init_editor($elementid) {
global $PAGE, $OUTPUT;
$icon = $OUTPUT->pix_icon('indent',
$icon = $OUTPUT->pix_icon('e/increase_indent',
get_string('indent', 'atto_indent'),
'atto_indent',
'moodle',
array('class'=>'icon'));
$PAGE->requires->yui_module('moodle-atto_indent-button',
'M.atto_indent.init',
array(array('elementid'=>$elementid, 'icon'=>$icon)),
array(array('elementid'=>$elementid, 'icon'=>$icon, 'group'=>'list')),
true);
}
/**
* Return the order this plugin should be displayed in the toolbar
* @return int
* @return int the absolute position within the toolbar
*/
function atto_indent_sort_order() {
return 5;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 439 B

@@ -1,68 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="16"
height="16"
id="svg2"
version="1.1"
inkscape:version="0.48.3.1 r9886"
sodipodi:docname="indent.svg" preserveAspectRatio="xMinYMid meet">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="15.839192"
inkscape:cx="-8.2482624"
inkscape:cy="15.312045"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1122"
inkscape:window-height="685"
inkscape:window-x="162"
inkscape:window-y="57"
inkscape:window-maximized="0" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1036.3622)">
<text
xml:space="preserve"
style="font-size:64px;font-style:normal;font-variant:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:Comic Sans MS;-inkscape-font-specification:Arial Indent"
x="7.2604713"
y="1049.6475"
id="text2984"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan2986"
x="7.2604713"
y="1049.6475"
style="font-size:14px;font-style:normal;font-variant:normal;font-stretch:normal;fill:#999999;fill-opacity:1;font-family:Arial;-inkscape-font-specification:Arial Indent">&gt;</tspan></text>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.3 KiB

@@ -32,7 +32,7 @@ M.atto_indent = M.atto_indent || {
document.execCommand('indent', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'indent', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'indent', params.icon, params.group, click);
}
};
@@ -1 +1 @@
YUI.add("moodle-atto_indent-button",function(e,t){M.atto_indent=M.atto_indent||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("indent",!1,null)};M.editor_atto.add_toolbar_button(e.elementid,"indent",e.icon,t)}}},"@VERSION@",{requires:["node"]});
YUI.add("moodle-atto_indent-button",function(e,t){M.atto_indent=M.atto_indent||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("indent",!1,null)};M.editor_atto.add_toolbar_button(e.elementid,"indent",e.icon,e.group,t)}}},"@VERSION@",{requires:["node"]});
@@ -32,7 +32,7 @@ M.atto_indent = M.atto_indent || {
document.execCommand('indent', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'indent', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'indent', params.icon, params.group, click);
}
};
+1 -1
View File
@@ -30,6 +30,6 @@ M.atto_indent = M.atto_indent || {
document.execCommand('indent', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'indent', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'indent', params.icon, params.group, click);
}
};
+4 -4
View File
@@ -31,21 +31,21 @@ defined('MOODLE_INTERNAL') || die();
function atto_italic_init_editor($elementid) {
global $PAGE, $OUTPUT;
$icon = $OUTPUT->pix_icon('italic',
$icon = $OUTPUT->pix_icon('e/italic',
get_string('italic', 'atto_italic'),
'atto_italic',
'moodle',
array('class'=>'icon'));
$PAGE->requires->yui_module('moodle-atto_italic-button',
'M.atto_italic.init',
array(array('elementid'=>$elementid, 'icon'=>$icon)),
array(array('elementid'=>$elementid, 'icon'=>$icon, 'group'=>'style')),
true);
}
/**
* Return the order this plugin should be displayed in the toolbar
* @return int
* @return int the absolute position within the toolbar
*/
function atto_italic_sort_order() {
return 1;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 418 B

@@ -1,68 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="16"
height="16"
id="svg2"
version="1.1"
inkscape:version="0.48.3.1 r9886"
sodipodi:docname="italic.svg" preserveAspectRatio="xMinYMid meet">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="15.839192"
inkscape:cx="-8.2482624"
inkscape:cy="15.312045"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1122"
inkscape:window-height="685"
inkscape:window-x="162"
inkscape:window-y="57"
inkscape:window-maximized="0" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1036.3622)">
<text
xml:space="preserve"
style="font-size:64px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:Comic Sans MS;-inkscape-font-specification:Comic Sans MS"
x="7.2604713"
y="1049.6475"
id="text2984"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan2986"
x="7.2604713"
y="1049.6475"
style="font-size:14px;font-style:italic;font-variant:normal;font-weight:normal;font-stretch:normal;font-family:Arial;-inkscape-font-specification:Arial Italic;fill:#999999;fill-opacity:1">i</tspan></text>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.4 KiB

@@ -32,7 +32,7 @@ M.atto_italic = M.atto_italic || {
document.execCommand('italic', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'italic', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'italic', params.icon, params.group, click);
}
};
@@ -1 +1 @@
YUI.add("moodle-atto_italic-button",function(e,t){M.atto_italic=M.atto_italic||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("italic",!1,null)};M.editor_atto.add_toolbar_button(e.elementid,"italic",e.icon,t)}}},"@VERSION@",{requires:["node"]});
YUI.add("moodle-atto_italic-button",function(e,t){M.atto_italic=M.atto_italic||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("italic",!1,null)};M.editor_atto.add_toolbar_button(e.elementid,"italic",e.icon,e.group,t)}}},"@VERSION@",{requires:["node"]});
@@ -32,7 +32,7 @@ M.atto_italic = M.atto_italic || {
document.execCommand('italic', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'italic', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'italic', params.icon, params.group, click);
}
};
+1 -1
View File
@@ -30,6 +30,6 @@ M.atto_italic = M.atto_italic || {
document.execCommand('italic', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'italic', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'italic', params.icon, params.group, click);
}
};
+4 -4
View File
@@ -31,9 +31,9 @@ defined('MOODLE_INTERNAL') || die();
function atto_link_init_editor($elementid) {
global $PAGE, $OUTPUT;
$icon = $OUTPUT->pix_icon('link',
$icon = $OUTPUT->pix_icon('e/insert_edit_link',
get_string('link', 'atto_link'),
'atto_link',
'moodle',
array('class'=>'icon'));
$PAGE->requires->strings_for_js(array('createlink',
@@ -44,14 +44,14 @@ function atto_link_init_editor($elementid) {
$PAGE->requires->yui_module('moodle-atto_link-button',
'M.atto_link.init',
array(array('elementid'=>$elementid, 'icon'=>$icon)),
array(array('elementid'=>$elementid, 'icon'=>$icon, 'group'=>'link')),
true);
}
/**
* Return the order this plugin should be displayed in the toolbar
* @return int
* @return int the absolute position within the toolbar
*/
function atto_link_sort_order() {
return 11;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 471 B

-80
View File
@@ -1,80 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="16"
height="16"
id="svg2"
version="1.1"
inkscape:version="0.48.3.1 r9886"
sodipodi:docname="link.svg" preserveAspectRatio="xMinYMid meet">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="22.4"
inkscape:cx="-3.7446839"
inkscape:cy="10.171143"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1440"
inkscape:window-height="872"
inkscape:window-x="0"
inkscape:window-y="0"
inkscape:window-maximized="1" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1036.3622)">
<rect
style="fill:none;stroke:#999999;stroke-width:2.89999999999999991;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
id="rect2984"
width="19.107143"
height="6.8750005"
x="-13.535714"
y="1040.9337"
ry="0.053281363" />
<rect
ry="0.053281363"
y="1040.9337"
x="10.432884"
height="6.8750005"
width="19.107143"
id="rect3754"
style="fill:none;stroke:#999999;stroke-width:2.90000010000000019;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
<rect
style="fill:none;stroke:#999999;stroke-width:2.90000010000000019;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
id="rect3756"
width="9.0510426"
height="0.26916784"
x="3.5273302"
y="1044.2031"
ry="0.053281363" />
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.6 KiB

@@ -56,7 +56,7 @@ M.atto_link = M.atto_link || {
}
};
M.editor_atto.add_toolbar_button(params.elementid, 'link', params.icon, display_chooser, this);
M.editor_atto.add_toolbar_button(params.elementid, 'link', params.icon, params.group, display_chooser, this);
},
resolve_anchors : function() {
// Find the first anchor tag in the selection.
@@ -1 +1 @@
YUI.add("moodle-atto_link-button",function(e,t){M.atto_link=M.atto_link||{dialogue:null,selection:null,init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),M.atto_link.selection=M.editor_atto.get_selection();if(M.atto_link.selection!==!1&&!M.atto_link.selection.collapsed){var n;M.atto_link.dialogue?n=M.atto_link.dialogue:n=new M.core.dialogue({visible:!1,modal:!0,close:!0,draggable:!0}),n.render(),n.set("bodyContent",M.atto_link.get_form_content(t)),n.set("headerContent",M.util.get_string("createlink","atto_link")),M.atto_link.resolve_anchors(),n.show(),M.atto_link.dialogue=n}};M.editor_atto.add_toolbar_button(e.elementid,"link",e.icon,t,this)},resolve_anchors:function(){var t=M.editor_atto.get_selection_parent_node(),n,r;if(!t)return;n=e.one(t).ancestor("a"),n&&(r=n.getAttribute("href"),r!==""&&(M.atto_link.selection=M.editor_atto.get_selection_from_node(n),e.one("#atto_link_urlentry").set("value",r)))},open_filepicker:function(e){var t=this.getAttribute("data-editor");e.preventDefault(),M.editor_atto.show_filepicker(t,"link",M.atto_link.filepicker_callback)},filepicker_callback:function(e){M.atto_link.dialogue.hide(),e.url!==""&&(M.editor_atto.set_selection(M.atto_link.selection),document.execCommand("unlink",!1,null),document.execCommand("createLink",!1,e.url))},set_link:function(e){e.preventDefault(),M.atto_link.dialogue.hide();var t=e.currentTarget.get("parentNode").one("input"),n=t.get("value");n!==""&&(M.editor_atto.set_selection(M.atto_link.selection),document.execCommand("unlink",!1,null),document.execCommand("createLink",!1,n))},get_form_content:function(t){var n=e.Node.create('<form><label for="atto_link_urlentry">'+M.util.get_string("enterurl","atto_link")+"</label><br/>"+'<input type="url" value="" id="atto_link_urlentry" size="32"/>'+"<br/>"+'<button id="openlinkbrowser" data-editor="'+e.Escape.html(t)+'">'+M.util.get_string("browserepositories","atto_link")+"</button>"+"<hr/>"+'<button id="atto_link_urlentrysubmit">'+M.util.get_string("createlink","atto_link")+"</button>"+"</form>"+"<hr/>"+M.util.get_string("accessibilityhint","atto_link"));return n.one("#atto_link_urlentrysubmit").on("click",M.atto_link.set_link),n.one("#openlinkbrowser").on("click",M.atto_link.open_filepicker),n}}},"@VERSION@",{requires:["node","escape"]});
YUI.add("moodle-atto_link-button",function(e,t){M.atto_link=M.atto_link||{dialogue:null,selection:null,init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),M.atto_link.selection=M.editor_atto.get_selection();if(M.atto_link.selection!==!1&&!M.atto_link.selection.collapsed){var n;M.atto_link.dialogue?n=M.atto_link.dialogue:n=new M.core.dialogue({visible:!1,modal:!0,close:!0,draggable:!0}),n.render(),n.set("bodyContent",M.atto_link.get_form_content(t)),n.set("headerContent",M.util.get_string("createlink","atto_link")),M.atto_link.resolve_anchors(),n.show(),M.atto_link.dialogue=n}};M.editor_atto.add_toolbar_button(e.elementid,"link",e.icon,e.group,t,this)},resolve_anchors:function(){var t=M.editor_atto.get_selection_parent_node(),n,r;if(!t)return;n=e.one(t).ancestor("a"),n&&(r=n.getAttribute("href"),r!==""&&(M.atto_link.selection=M.editor_atto.get_selection_from_node(n),e.one("#atto_link_urlentry").set("value",r)))},open_filepicker:function(e){var t=this.getAttribute("data-editor");e.preventDefault(),M.editor_atto.show_filepicker(t,"link",M.atto_link.filepicker_callback)},filepicker_callback:function(e){M.atto_link.dialogue.hide(),e.url!==""&&(M.editor_atto.set_selection(M.atto_link.selection),document.execCommand("unlink",!1,null),document.execCommand("createLink",!1,e.url))},set_link:function(e){e.preventDefault(),M.atto_link.dialogue.hide();var t=e.currentTarget.get("parentNode").one("input"),n=t.get("value");n!==""&&(M.editor_atto.set_selection(M.atto_link.selection),document.execCommand("unlink",!1,null),document.execCommand("createLink",!1,n))},get_form_content:function(t){var n=e.Node.create('<form><label for="atto_link_urlentry">'+M.util.get_string("enterurl","atto_link")+"</label><br/>"+'<input type="url" value="" id="atto_link_urlentry" size="32"/>'+"<br/>"+'<button id="openlinkbrowser" data-editor="'+e.Escape.html(t)+'">'+M.util.get_string("browserepositories","atto_link")+"</button>"+"<hr/>"+'<button id="atto_link_urlentrysubmit">'+M.util.get_string("createlink","atto_link")+"</button>"+"</form>"+"<hr/>"+M.util.get_string("accessibilityhint","atto_link"));return n.one("#atto_link_urlentrysubmit").on("click",M.atto_link.set_link),n.one("#openlinkbrowser").on("click",M.atto_link.open_filepicker),n}}},"@VERSION@",{requires:["node","escape"]});
@@ -56,7 +56,7 @@ M.atto_link = M.atto_link || {
}
};
M.editor_atto.add_toolbar_button(params.elementid, 'link', params.icon, display_chooser, this);
M.editor_atto.add_toolbar_button(params.elementid, 'link', params.icon, params.group, display_chooser, this);
},
resolve_anchors : function() {
// Find the first anchor tag in the selection.
+1 -1
View File
@@ -54,7 +54,7 @@ M.atto_link = M.atto_link || {
}
};
M.editor_atto.add_toolbar_button(params.elementid, 'link', params.icon, display_chooser, this);
M.editor_atto.add_toolbar_button(params.elementid, 'link', params.icon, params.group, display_chooser, this);
},
resolve_anchors : function() {
// Find the first anchor tag in the selection.
+4 -4
View File
@@ -29,9 +29,9 @@
function atto_media_init_editor($elementid) {
global $PAGE, $OUTPUT;
$icon = $OUTPUT->pix_icon('media',
$icon = $OUTPUT->pix_icon('e/insert_edit_video',
get_string('media', 'atto_media'),
'atto_media',
'moodle',
array('class'=>'icon'));
$PAGE->requires->strings_for_js(array('createmedia',
@@ -42,14 +42,14 @@ function atto_media_init_editor($elementid) {
'atto_media');
$PAGE->requires->yui_module('moodle-atto_media-button',
'M.atto_media.init',
array(array('elementid'=>$elementid, 'icon'=>$icon)),
array(array('elementid'=>$elementid, 'icon'=>$icon, 'group'=>'file')),
true);
}
/**
* Return the order this plugin should be displayed in the toolbar
* @return int
* @return int the absolute position within the toolbar
*/
function atto_media_sort_order() {
return 14;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 489 B

-105
View File
@@ -1,105 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="16"
height="16"
id="svg2"
version="1.1"
inkscape:version="0.48.3.1 r9886"
sodipodi:docname="media.svg" preserveAspectRatio="xMinYMid meet">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="32"
inkscape:cx="6.077509"
inkscape:cy="9.3016902"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1122"
inkscape:window-height="685"
inkscape:window-x="162"
inkscape:window-y="57"
inkscape:window-maximized="0" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>media/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillMedia" />
<dc:title />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1036.3622)">
<rect
style="fill:none;fill-opacity:1;fill-rule:nonzero;stroke:#999999;stroke-opacity:1"
id="rect2986"
width="14.142136"
height="13.131983"
x="1.0101526"
y="1.4159228"
transform="translate(0,1036.3622)"
ry="0.053281363" />
<g
id="g3766"
transform="matrix(0.84027762,0,0,0.84027762,1.3177096,166.78804)">
<path
transform="matrix(1.5411765,0,0,1.5411765,-1.938603,1033.428)"
d="M 5.71875,5.421875 C 5.71875,6.1553782 5.1241282,6.75 4.390625,6.75 3.6571218,6.75 3.0625,6.1553782 3.0625,5.421875 c 0,-0.7335032 0.5946218,-1.328125 1.328125,-1.328125 0.7335032,0 1.328125,0.5946218 1.328125,1.328125 z"
sodipodi:ry="1.328125"
sodipodi:rx="1.328125"
sodipodi:cy="5.421875"
sodipodi:cx="4.390625"
id="path3756"
style="fill:#999999;fill-opacity:1;fill-rule:nonzero;stroke:none"
sodipodi:type="arc" />
<path
sodipodi:type="arc"
style="fill:#999999;fill-opacity:1;fill-rule:nonzero;stroke:none"
id="path3760"
sodipodi:cx="4.390625"
sodipodi:cy="5.421875"
sodipodi:rx="1.328125"
sodipodi:ry="1.328125"
d="M 5.71875,5.421875 C 5.71875,6.1553782 5.1241282,6.75 4.390625,6.75 3.6571218,6.75 3.0625,6.1553782 3.0625,5.421875 c 0,-0.7335032 0.5946218,-1.328125 1.328125,-1.328125 0.7335032,0 1.328125,0.5946218 1.328125,1.328125 z"
transform="matrix(1.5411765,0,0,1.5411765,2.655147,1033.428)" />
<rect
ry="0.74078137"
y="1043.9247"
x="2.375"
height="4.8125"
width="9.625"
id="rect3762"
style="fill:#999999;fill-opacity:1;fill-rule:nonzero;stroke:none" />
<rect
ry="0.74078137"
y="1045.4247"
x="12.09375"
height="2"
width="2.03125"
id="rect3764"
style="fill:#999999;fill-opacity:1;fill-rule:nonzero;stroke:none" />
</g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 3.5 KiB

@@ -54,7 +54,7 @@ M.atto_media = M.atto_media || {
}
};
M.editor_atto.add_toolbar_button(params.elementid, 'media', params.icon, display_chooser, this);
M.editor_atto.add_toolbar_button(params.elementid, 'media', params.icon, params.group, display_chooser, this);
},
open_browser : function(e) {
var elementid = this.getAttribute('data-editor');
@@ -1 +1 @@
YUI.add("moodle-atto_media-button",function(e,t){M.atto_media=M.atto_media||{dialogue:null,selection:null,init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),M.atto_media.selection=M.editor_atto.get_selection();if(M.atto_media.selection!==!1){var n;M.atto_media.dialogue?n=M.atto_media.dialogue:n=new M.core.dialogue({visible:!1,modal:!0,close:!0,draggable:!0}),n.render(),n.set("bodyContent",M.atto_media.get_form_content(t)),n.set("headerContent",M.util.get_string("createmedia","atto_media")),n.centerDialogue(),n.show(),M.atto_media.dialogue=n}};M.editor_atto.add_toolbar_button(e.elementid,"media",e.icon,t,this)},open_browser:function(e){var t=this.getAttribute("data-editor");e.preventDefault(),M.editor_atto.show_filepicker(t,"media",M.atto_media.filepicker_callback)},filepicker_callback:function(t){if(t.url!==""){var n=e.one("#atto_media_urlentry");n.set("value",t.url),n=e.one("#atto_media_nameentry"),n.set("value",t.file)}},set_media:function(t){t.preventDefault(),M.atto_media.dialogue.hide();var n=t.currentTarget.get("parentNode").one("#atto_media_urlentry"),r=n.get("value");n=t.currentTarget.get("parentNode").one("#atto_media_nameentry");var i=n.get("value");if(r!==""&&i!==""){M.editor_atto.set_selection(M.atto_media.selection);var s='<a href="'+e.Escape.html(r)+'">'+i+"</a>";document.selection&&document.selection.createRange().pasteHTML?document.selection.createRange().pasteHTML(s):document.execCommand("insertHTML",!1,s)}},get_form_content:function(t){var n=e.Node.create('<form class="atto_form"><label for="atto_media_urlentry">'+M.util.get_string("enterurl","atto_media")+"</label>"+'<input type="url" value="" id="atto_media_urlentry" size="32"/>'+'<label for="atto_media_nameentry">'+M.util.get_string("entername","atto_media")+"</label>"+'<input type="text" value="" id="atto_media_nameentry" size="32" required="true"/>'+"<hr/>"+'<button id="openmediabrowser" data-editor="'+e.Escape.html(t)+'">'+M.util.get_string("browserepositories","atto_media")+"</button>"+"<hr/>"+'<button id="atto_media_urlentrysubmit">'+M.util.get_string("createmedia","atto_media")+"</button>"+"</form>"+"<hr/>"+M.util.get_string("accessibilityhint","atto_media"));return n.one("#atto_media_urlentrysubmit").on("click",M.atto_media.set_media),n.one("#openmediabrowser").on("click",M.atto_media.open_browser),n}}},"@VERSION@",{requires:["node","escape"]});
YUI.add("moodle-atto_media-button",function(e,t){M.atto_media=M.atto_media||{dialogue:null,selection:null,init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),M.atto_media.selection=M.editor_atto.get_selection();if(M.atto_media.selection!==!1){var n;M.atto_media.dialogue?n=M.atto_media.dialogue:n=new M.core.dialogue({visible:!1,modal:!0,close:!0,draggable:!0}),n.render(),n.set("bodyContent",M.atto_media.get_form_content(t)),n.set("headerContent",M.util.get_string("createmedia","atto_media")),n.centerDialogue(),n.show(),M.atto_media.dialogue=n}};M.editor_atto.add_toolbar_button(e.elementid,"media",e.icon,e.group,t,this)},open_browser:function(e){var t=this.getAttribute("data-editor");e.preventDefault(),M.editor_atto.show_filepicker(t,"media",M.atto_media.filepicker_callback)},filepicker_callback:function(t){if(t.url!==""){var n=e.one("#atto_media_urlentry");n.set("value",t.url),n=e.one("#atto_media_nameentry"),n.set("value",t.file)}},set_media:function(t){t.preventDefault(),M.atto_media.dialogue.hide();var n=t.currentTarget.get("parentNode").one("#atto_media_urlentry"),r=n.get("value");n=t.currentTarget.get("parentNode").one("#atto_media_nameentry");var i=n.get("value");if(r!==""&&i!==""){M.editor_atto.set_selection(M.atto_media.selection);var s='<a href="'+e.Escape.html(r)+'">'+i+"</a>";document.selection&&document.selection.createRange().pasteHTML?document.selection.createRange().pasteHTML(s):document.execCommand("insertHTML",!1,s)}},get_form_content:function(t){var n=e.Node.create('<form class="atto_form"><label for="atto_media_urlentry">'+M.util.get_string("enterurl","atto_media")+"</label>"+'<input type="url" value="" id="atto_media_urlentry" size="32"/>'+'<label for="atto_media_nameentry">'+M.util.get_string("entername","atto_media")+"</label>"+'<input type="text" value="" id="atto_media_nameentry" size="32" required="true"/>'+"<hr/>"+'<button id="openmediabrowser" data-editor="'+e.Escape.html(t)+'">'+M.util.get_string("browserepositories","atto_media")+"</button>"+"<hr/>"+'<button id="atto_media_urlentrysubmit">'+M.util.get_string("createmedia","atto_media")+"</button>"+"</form>"+"<hr/>"+M.util.get_string("accessibilityhint","atto_media"));return n.one("#atto_media_urlentrysubmit").on("click",M.atto_media.set_media),n.one("#openmediabrowser").on("click",M.atto_media.open_browser),n}}},"@VERSION@",{requires:["node","escape"]});
@@ -54,7 +54,7 @@ M.atto_media = M.atto_media || {
}
};
M.editor_atto.add_toolbar_button(params.elementid, 'media', params.icon, display_chooser, this);
M.editor_atto.add_toolbar_button(params.elementid, 'media', params.icon, params.group, display_chooser, this);
},
open_browser : function(e) {
var elementid = this.getAttribute('data-editor');
+1 -1
View File
@@ -52,7 +52,7 @@ M.atto_media = M.atto_media || {
}
};
M.editor_atto.add_toolbar_button(params.elementid, 'media', params.icon, display_chooser, this);
M.editor_atto.add_toolbar_button(params.elementid, 'media', params.icon, params.group, display_chooser, this);
},
open_browser : function(e) {
var elementid = this.getAttribute('data-editor');
+4 -4
View File
@@ -31,21 +31,21 @@ defined('MOODLE_INTERNAL') || die();
function atto_orderedlist_init_editor($elementid) {
global $PAGE, $OUTPUT;
$icon = $OUTPUT->pix_icon('orderedlist',
$icon = $OUTPUT->pix_icon('e/numbered_list',
get_string('orderedlist', 'atto_orderedlist'),
'atto_orderedlist',
'moodle',
array('class'=>'icon'));
$PAGE->requires->yui_module('moodle-atto_orderedlist-button',
'M.atto_orderedlist.init',
array(array('elementid'=>$elementid, 'icon'=>$icon)),
array(array('elementid'=>$elementid, 'icon'=>$icon, 'group'=>'list')),
true);
}
/**
* Return the order this plugin should be displayed in the toolbar
* @return int
* @return array groupname followed by the absolute position within the toolbar
*/
function atto_orderedlist_sort_order() {
return 6;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 465 B

@@ -1,80 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="16"
height="16"
id="svg2"
version="1.1"
inkscape:version="0.48.3.1 r9886"
sodipodi:docname="orderedlist.svg" preserveAspectRatio="xMinYMid meet">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="15.839192"
inkscape:cx="-8.2482624"
inkscape:cy="4.0559186"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1122"
inkscape:window-height="685"
inkscape:window-x="162"
inkscape:window-y="57"
inkscape:window-maximized="0" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1036.3622)">
<text
xml:space="preserve"
style="font-size:64px;font-style:normal;font-variant:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:Comic Sans MS;-inkscape-font-specification:Arial Ordered list"
x="6.2503185"
y="1043.1448"
id="text2984"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
x="6.2503185"
y="1043.1448"
style="font-size:9px;font-style:normal;font-variant:normal;font-stretch:normal;fill:#999999;fill-opacity:1;font-family:Arial;-inkscape-font-specification:Arial Ordered list"
id="tspan2984">1-</tspan></text>
<text
sodipodi:linespacing="125%"
id="text2987"
y="1051.6046"
x="6.2503185"
style="font-size:64px;font-style:normal;font-variant:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:Comic Sans MS;-inkscape-font-specification:Arial Ordered list"
xml:space="preserve"><tspan
id="tspan2989"
style="font-size:9px;font-style:normal;font-variant:normal;font-stretch:normal;fill:#999999;fill-opacity:1;font-family:Arial;-inkscape-font-specification:Arial Ordered list"
y="1051.6046"
x="6.2503185"
sodipodi:role="line">2-</tspan></text>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 3.1 KiB

@@ -32,7 +32,7 @@ M.atto_orderedlist = M.atto_orderedlist || {
document.execCommand('insertOrderedList', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'orderedlist', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'orderedlist', params.icon, params.group, click);
}
};
@@ -1 +1 @@
YUI.add("moodle-atto_orderedlist-button",function(e,t){M.atto_orderedlist=M.atto_orderedlist||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("insertOrderedList",!1,null)};M.editor_atto.add_toolbar_button(e.elementid,"orderedlist",e.icon,t)}}},"@VERSION@",{requires:["node"]});
YUI.add("moodle-atto_orderedlist-button",function(e,t){M.atto_orderedlist=M.atto_orderedlist||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("insertOrderedList",!1,null)};M.editor_atto.add_toolbar_button(e.elementid,"orderedlist",e.icon,e.group,t)}}},"@VERSION@",{requires:["node"]});
@@ -32,7 +32,7 @@ M.atto_orderedlist = M.atto_orderedlist || {
document.execCommand('insertOrderedList', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'orderedlist', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'orderedlist', params.icon, params.group, click);
}
};
@@ -30,6 +30,6 @@ M.atto_orderedlist = M.atto_orderedlist || {
document.execCommand('insertOrderedList', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'orderedlist', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'orderedlist', params.icon, params.group, click);
}
};
+4 -4
View File
@@ -29,21 +29,21 @@
function atto_outdent_init_editor($elementid) {
global $PAGE, $OUTPUT;
$icon = $OUTPUT->pix_icon('outdent',
$icon = $OUTPUT->pix_icon('e/decrease_indent',
get_string('outdent', 'atto_outdent'),
'atto_outdent',
'moodle',
array('class'=>'icon'));
$PAGE->requires->yui_module('moodle-atto_outdent-button',
'M.atto_outdent.init',
array(array('elementid'=>$elementid, 'icon'=>$icon)),
array(array('elementid'=>$elementid, 'icon'=>$icon, 'group'=>'list')),
true);
}
/**
* Return the order this plugin should be displayed in the toolbar
* @return int
* @return int the absolute position within the toolbar
*/
function atto_outdent_sort_order() {
return 4;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 440 B

@@ -1,68 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="16"
height="16"
id="svg2"
version="1.1"
inkscape:version="0.48.3.1 r9886"
sodipodi:docname="outdent.svg" preserveAspectRatio="xMinYMid meet">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="15.839192"
inkscape:cx="-8.2482624"
inkscape:cy="15.312045"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1122"
inkscape:window-height="685"
inkscape:window-x="162"
inkscape:window-y="57"
inkscape:window-maximized="0" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1036.3622)">
<text
xml:space="preserve"
style="font-size:64px;font-style:normal;font-variant:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:Comic Sans MS;-inkscape-font-specification:Arial Outdent"
x="7.2604713"
y="1049.6475"
id="text2984"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan2986"
x="7.2604713"
y="1049.6475"
style="font-size:14px;font-style:normal;font-variant:normal;font-stretch:normal;fill:#999999;fill-opacity:1;font-family:Arial;-inkscape-font-specification:Arial Outdent">&lt;</tspan></text>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.3 KiB

@@ -32,7 +32,7 @@ M.atto_outdent = M.atto_outdent || {
document.execCommand('outdent', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'outdent', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'outdent', params.icon, params.group, click);
}
};
@@ -1 +1 @@
YUI.add("moodle-atto_outdent-button",function(e,t){M.atto_outdent=M.atto_outdent||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("outdent",!1,null)};M.editor_atto.add_toolbar_button(e.elementid,"outdent",e.icon,t)}}},"@VERSION@",{requires:["node"]});
YUI.add("moodle-atto_outdent-button",function(e,t){M.atto_outdent=M.atto_outdent||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("outdent",!1,null)};M.editor_atto.add_toolbar_button(e.elementid,"outdent",e.icon,e.group,t)}}},"@VERSION@",{requires:["node"]});
@@ -32,7 +32,7 @@ M.atto_outdent = M.atto_outdent || {
document.execCommand('outdent', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'outdent', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'outdent', params.icon, params.group, click);
}
};
@@ -30,6 +30,6 @@ M.atto_outdent = M.atto_outdent || {
document.execCommand('outdent', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'outdent', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'outdent', params.icon, params.group, click);
}
};
+4 -4
View File
@@ -31,21 +31,21 @@ defined('MOODLE_INTERNAL') || die();
function atto_strike_init_editor($elementid) {
global $PAGE, $OUTPUT;
$icon = $OUTPUT->pix_icon('strike',
$icon = $OUTPUT->pix_icon('e/strikethrough',
get_string('strike', 'atto_strike'),
'atto_strike',
'moodle',
array('class'=>'icon'));
$PAGE->requires->yui_module('moodle-atto_strike-button',
'M.atto_strike.init',
array(array('elementid'=>$elementid, 'icon'=>$icon)),
array(array('elementid'=>$elementid, 'icon'=>$icon, 'group'=>'style')),
true);
}
/**
* Return the order this plugin should be displayed in the toolbar
* @return int
* @return int absolute position within the toolbar
*/
function atto_strike_sort_order() {
return 3;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 479 B

@@ -1,77 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="16"
height="16"
id="svg2"
version="1.1"
inkscape:version="0.48.3.1 r9886"
sodipodi:docname="strike.svg" preserveAspectRatio="xMinYMid meet">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="15.839192"
inkscape:cx="-8.2482624"
inkscape:cy="15.312045"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1122"
inkscape:window-height="685"
inkscape:window-x="162"
inkscape:window-y="57"
inkscape:window-maximized="0" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1036.3622)">
<g
id="g2985"
transform="translate(0.3788072,0.69447987)">
<text
sodipodi:linespacing="125%"
id="text2984"
y="1047.1852"
x="7.7024131"
style="font-size:64px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:Comic Sans MS;-inkscape-font-specification:Comic Sans MS"
xml:space="preserve"><tspan
style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#999999;fill-opacity:1;font-family:Arial;-inkscape-font-specification:Arial"
y="1047.1852"
x="7.7024131"
id="tspan2986"
sodipodi:role="line">s</tspan></text>
<path
inkscape:connector-curvature="0"
id="path2984"
d="m 3.0304576,1043.3971 9.6595834,0"
style="fill:none;stroke:#999999;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
</g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.7 KiB

@@ -32,7 +32,7 @@ M.atto_strike = M.atto_strike || {
document.execCommand('strikeThrough', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'strike', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'strike', params.icon, params.group, click);
}
};
@@ -1 +1 @@
YUI.add("moodle-atto_strike-button",function(e,t){M.atto_strike=M.atto_strike||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("strikeThrough",!1,null)};M.editor_atto.add_toolbar_button(e.elementid,"strike",e.icon,t)}}},"@VERSION@",{requires:["node"]});
YUI.add("moodle-atto_strike-button",function(e,t){M.atto_strike=M.atto_strike||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("strikeThrough",!1,null)};M.editor_atto.add_toolbar_button(e.elementid,"strike",e.icon,e.group,t)}}},"@VERSION@",{requires:["node"]});
@@ -32,7 +32,7 @@ M.atto_strike = M.atto_strike || {
document.execCommand('strikeThrough', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'strike', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'strike', params.icon, params.group, click);
}
};
+1 -1
View File
@@ -30,6 +30,6 @@ M.atto_strike = M.atto_strike || {
document.execCommand('strikeThrough', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'strike', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'strike', params.icon, params.group, click);
}
};
+8 -4
View File
@@ -31,9 +31,13 @@ defined('MOODLE_INTERNAL') || die();
function atto_title_init_editor($elementid) {
global $PAGE, $OUTPUT;
$icon = $OUTPUT->pix_icon('title',
$icon = $OUTPUT->pix_icon('e/styleprops',
get_string('title', 'atto_title'),
'atto_title',
'moodle',
array('class'=>'icon'));
$icon .= $OUTPUT->pix_icon('t/expanded',
get_string('title', 'atto_title'),
'moodle',
array('class'=>'icon'));
$PAGE->requires->strings_for_js(array('h3',
@@ -44,14 +48,14 @@ function atto_title_init_editor($elementid) {
'p'), 'atto_title');
$PAGE->requires->yui_module('moodle-atto_title-button',
'M.atto_title.init',
array(array('elementid'=>$elementid, 'icon'=>$icon)),
array(array('elementid'=>$elementid, 'icon'=>$icon, 'group'=>'title')),
true);
}
/**
* Return the order this plugin should be displayed in the toolbar
* @return int
* @return int the absolute position within the toolbar
*/
function atto_title_sort_order() {
return 9;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 550 B

@@ -1,87 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="32"
height="16"
id="svg2"
version="1.1"
inkscape:version="0.48.3.1 r9886"
sodipodi:docname="title.svg"
inkscape:export-filename="/home/damyonw/Documents/Moodle/instances/im/moodle/lib/editor/atto/plugins/title/pix/title.png"
inkscape:export-xdpi="90"
inkscape:export-ydpi="90" preserveAspectRatio="xMinYMid meet">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="15.839192"
inkscape:cx="10.944636"
inkscape:cy="10.261282"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1175"
inkscape:window-height="714"
inkscape:window-x="162"
inkscape:window-y="57"
inkscape:window-maximized="0" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1036.3622)">
<text
xml:space="preserve"
style="font-size:60.68878555px;font-style:normal;font-variant:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:Comic Sans MS;-inkscape-font-specification:Arial Title"
x="7.4835119"
y="1106.6505"
id="text2984"
sodipodi:linespacing="125%"
transform="scale(1.0545606,0.94826226)"><tspan
sodipodi:role="line"
id="tspan2986"
x="7.4835119"
y="1106.6505"
style="font-size:13.27567196px;font-style:normal;font-variant:normal;font-stretch:normal;fill:#999999;fill-opacity:1;font-family:Arial;-inkscape-font-specification:Arial Title">T</tspan></text>
<rect
style="fill:none;stroke:#999999;stroke-width:1;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
id="rect2984"
width="13.068849"
height="13.195118"
x="1.3889598"
y="1.2896537"
transform="translate(0,1036.3622)"
ry="0.74078137" />
<path
style="fill:#999999;fill-opacity:1;stroke:#999999;stroke-width:0.46544716;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dashoffset:0"
d="m 23.655897,1047.3429 c -3.478888,-4.407 -1.017073,-1.216 -3.777349,-4.5667 0,-0.1504 0.1952,-0.2718 0.437667,-0.2718 l 6.845979,0 c 0.242467,0 0.547252,0.1374 0.437667,0.2718 l -3.506296,4.2951 c -0.109585,0.1342 -0.1952,0.2716 -0.437668,0.2716 z"
id="rect2985"
inkscape:connector-curvature="0"
sodipodi:nodetypes="ccssssc" />
</g>
</svg>

Before

Width:  |  Height:  |  Size: 3.5 KiB

@@ -53,6 +53,7 @@ M.atto_title = M.atto_title || {
M.editor_atto.add_toolbar_menu(params.elementid,
'title',
params.icon,
params.group,
[
{'text' : h3, 'handler' : click_h3},
{'text' : h4, 'handler' : click_h4},
@@ -1 +1 @@
YUI.add("moodle-atto_title-button",function(e,t){M.atto_title=M.atto_title||{init:function(e){var t=function(e,t){M.atto_title.change_title(e,t,"<h3>")},n=function(e,t){M.atto_title.change_title(e,t,"<h4>")},r=function(e,t){M.atto_title.change_title(e,t,"<h5>")},i=function(e,t){M.atto_title.change_title(e,t,"<pre>")},s=function(e,t){M.atto_title.change_title(e,t,"<blockquote>")},o=function(e,t){M.atto_title.change_title(e,t,"<p>")},u="<h3>"+M.util.get_string("h3","atto_title")+"</h3>",a="<h4>"+M.util.get_string("h4","atto_title")+"</h4>",f="<h5>"+M.util.get_string("h5","atto_title")+"</h5>",l="<pre>"+M.util.get_string("pre","atto_title")+"</pre>",c="<p>&nbsp;&nbsp;&nbsp;&nbsp;"+M.util.get_string("blockquote","atto_title")+"</p>",h="<p>"+M.util.get_string("p","atto_title")+"</p>";M.editor_atto.add_toolbar_menu(e.elementid,"title",e.icon,[{text:u,handler:t},{text:a,handler:n},{text:f,handler:r},{text:l,handler:i},{text:c,handler:s},{text:h,handler:o}])},change_title:function(e,t,n){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("formatBlock",!1,n)}}},"@VERSION@",{requires:["node"]});
YUI.add("moodle-atto_title-button",function(e,t){M.atto_title=M.atto_title||{init:function(e){var t=function(e,t){M.atto_title.change_title(e,t,"<h3>")},n=function(e,t){M.atto_title.change_title(e,t,"<h4>")},r=function(e,t){M.atto_title.change_title(e,t,"<h5>")},i=function(e,t){M.atto_title.change_title(e,t,"<pre>")},s=function(e,t){M.atto_title.change_title(e,t,"<blockquote>")},o=function(e,t){M.atto_title.change_title(e,t,"<p>")},u="<h3>"+M.util.get_string("h3","atto_title")+"</h3>",a="<h4>"+M.util.get_string("h4","atto_title")+"</h4>",f="<h5>"+M.util.get_string("h5","atto_title")+"</h5>",l="<pre>"+M.util.get_string("pre","atto_title")+"</pre>",c="<p>&nbsp;&nbsp;&nbsp;&nbsp;"+M.util.get_string("blockquote","atto_title")+"</p>",h="<p>"+M.util.get_string("p","atto_title")+"</p>";M.editor_atto.add_toolbar_menu(e.elementid,"title",e.icon,e.group,[{text:u,handler:t},{text:a,handler:n},{text:f,handler:r},{text:l,handler:i},{text:c,handler:s},{text:h,handler:o}])},change_title:function(e,t,n){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("formatBlock",!1,n)}}},"@VERSION@",{requires:["node"]});
@@ -53,6 +53,7 @@ M.atto_title = M.atto_title || {
M.editor_atto.add_toolbar_menu(params.elementid,
'title',
params.icon,
params.group,
[
{'text' : h3, 'handler' : click_h3},
{'text' : h4, 'handler' : click_h4},
@@ -51,6 +51,7 @@ M.atto_title = M.atto_title || {
M.editor_atto.add_toolbar_menu(params.elementid,
'title',
params.icon,
params.group,
[
{'text' : h3, 'handler' : click_h3},
{'text' : h4, 'handler' : click_h4},
+4 -4
View File
@@ -31,21 +31,21 @@ defined('MOODLE_INTERNAL') || die();
function atto_underline_init_editor($elementid) {
global $PAGE, $OUTPUT;
$icon = $OUTPUT->pix_icon('underline',
$icon = $OUTPUT->pix_icon('e/underline',
get_string('underline', 'atto_underline'),
'atto_underline',
'moodle',
array('class'=>'icon'));
$PAGE->requires->yui_module('moodle-atto_underline-button',
'M.atto_underline.init',
array(array('elementid'=>$elementid, 'icon'=>$icon)),
array(array('elementid'=>$elementid, 'icon'=>$icon, 'group'=>'style')),
true);
}
/**
* Return the order this plugin should be displayed in the toolbar
* @return int
* @return int the absolute position within the toolbar
*/
function atto_underline_sort_order() {
return 2;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 430 B

@@ -1,73 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="16"
height="16"
id="svg2"
version="1.1"
inkscape:version="0.48.3.1 r9886"
sodipodi:docname="underline.svg" preserveAspectRatio="xMinYMid meet">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="15.839192"
inkscape:cx="-8.2482624"
inkscape:cy="15.312045"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1122"
inkscape:window-height="685"
inkscape:window-x="162"
inkscape:window-y="57"
inkscape:window-maximized="0" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1036.3622)">
<text
xml:space="preserve"
style="font-size:64px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;text-align:center;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:middle;fill:#000000;fill-opacity:1;stroke:none;font-family:Comic Sans MS;-inkscape-font-specification:Comic Sans MS"
x="8.0812206"
y="1047.1852"
id="text2984"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan2986"
x="8.0812206"
y="1047.1852"
style="font-size:14px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;fill:#999999;fill-opacity:1;font-family:Arial;-inkscape-font-specification:Arial">u</tspan></text>
<path
style="fill:none;stroke:#999999;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
d="m 3.5986684,1048.4479 9.6595836,0"
id="path2984"
inkscape:connector-curvature="0" />
</g>
</svg>

Before

Width:  |  Height:  |  Size: 2.6 KiB

@@ -32,7 +32,7 @@ M.atto_underline = M.atto_underline || {
document.execCommand('underline', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'underline', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'underline', params.icon, params.group, click);
}
};
@@ -1 +1 @@
YUI.add("moodle-atto_underline-button",function(e,t){M.atto_underline=M.atto_underline||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("underline",!1,null)};M.editor_atto.add_toolbar_button(e.elementid,"underline",e.icon,t)}}},"@VERSION@",{requires:["node"]});
YUI.add("moodle-atto_underline-button",function(e,t){M.atto_underline=M.atto_underline||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("underline",!1,null)};M.editor_atto.add_toolbar_button(e.elementid,"underline",e.icon,e.group,t)}}},"@VERSION@",{requires:["node"]});
@@ -32,7 +32,7 @@ M.atto_underline = M.atto_underline || {
document.execCommand('underline', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'underline', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'underline', params.icon, params.group, click);
}
};
@@ -30,6 +30,6 @@ M.atto_underline = M.atto_underline || {
document.execCommand('underline', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'underline', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'underline', params.icon, params.group, click);
}
};
+4 -4
View File
@@ -29,21 +29,21 @@
function atto_unlink_init_editor($elementid) {
global $PAGE, $OUTPUT;
$icon = $OUTPUT->pix_icon('unlink',
$icon = $OUTPUT->pix_icon('e/remove_link',
get_string('unlink', 'atto_unlink'),
'atto_unlink',
'moodle',
array('class'=>'icon'));
$PAGE->requires->yui_module('moodle-atto_unlink-button',
'M.atto_unlink.init',
array(array('elementid'=>$elementid, 'icon'=>$icon)),
array(array('elementid'=>$elementid, 'icon'=>$icon, 'group'=>'link')),
true);
}
/**
* Return the order this plugin should be displayed in the toolbar
* @return int
* @return int the absolute position within the toolbar
*/
function atto_unlink_sort_order() {
return 12;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 534 B

@@ -1,92 +0,0 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="16"
height="16"
id="svg2"
version="1.1"
inkscape:version="0.48.3.1 r9886"
sodipodi:docname="unlink.svg" preserveAspectRatio="xMinYMid meet">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="15.839192"
inkscape:cx="-8.5976985"
inkscape:cy="1.7715312"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1440"
inkscape:window-height="872"
inkscape:window-x="0"
inkscape:window-y="0"
inkscape:window-maximized="1" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-1036.3622)">
<g
id="g3812">
<rect
ry="0.053281363"
y="1040.9337"
x="-13.535714"
height="6.8750005"
width="19.107143"
id="rect2984"
style="fill:none;stroke:#999999;stroke-width:2.90000010000000019;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0" />
<path
id="rect3756"
transform="translate(0,1036.3622)"
d="m 1.875,7.84375 c -0.029518,0 -0.03125,0.032982 -0.03125,0.0625 l 0,0.1875 c 0,0.029518 0.00173,0.0625 0.03125,0.0625 l 5.03125,0 0,-0.3125 z"
style="fill:none;stroke:#999999;stroke-width:2.89999999999999991;stroke-linecap:round;stroke-linejoin:bevel;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
inkscape:connector-curvature="0"
sodipodi:nodetypes="ssssccs" />
</g>
<g
id="g3808"
transform="matrix(0.92557914,0.37855417,-0.37855417,0.92557914,396.7365,74.82763)">
<rect
style="fill:none;stroke:#999999;stroke-width:2.90000010000000019;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
id="rect3754"
width="19.107143"
height="6.8750005"
x="10.432884"
y="1040.9337"
ry="0.053281363" />
<path
inkscape:connector-curvature="0"
style="fill:none;stroke:#999999;stroke-width:2.9000001;stroke-linecap:round;stroke-linejoin:bevel;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0"
d="m 13.973214,1044.206 c 0.02952,0 0.03125,0.033 0.03125,0.063 l 0,0.1875 c 0,0.03 -0.0017,0.063 -0.03125,0.063 l -4.4838532,-0.2046 0,-0.3125 4.4838532,0.2046 z"
id="path3806"
sodipodi:nodetypes="cssscccc" />
</g>
</g>
</svg>

Before

Width:  |  Height:  |  Size: 3.4 KiB

@@ -32,7 +32,7 @@ M.atto_unlink = M.atto_unlink || {
document.execCommand('unlink', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'unlink', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'unlink', params.icon, params.group, click);
}
};
@@ -1 +1 @@
YUI.add("moodle-atto_unlink-button",function(e,t){M.atto_unlink=M.atto_unlink||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("unlink",!1,null)};M.editor_atto.add_toolbar_button(e.elementid,"unlink",e.icon,t)}}},"@VERSION@",{requires:["node"]});
YUI.add("moodle-atto_unlink-button",function(e,t){M.atto_unlink=M.atto_unlink||{init:function(e){var t=function(e,t){e.preventDefault(),M.editor_atto.is_active(t)||M.editor_atto.focus(t),document.execCommand("unlink",!1,null)};M.editor_atto.add_toolbar_button(e.elementid,"unlink",e.icon,e.group,t)}}},"@VERSION@",{requires:["node"]});
@@ -32,7 +32,7 @@ M.atto_unlink = M.atto_unlink || {
document.execCommand('unlink', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'unlink', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'unlink', params.icon, params.group, click);
}
};
+1 -1
View File
@@ -30,6 +30,6 @@ M.atto_unlink = M.atto_unlink || {
document.execCommand('unlink', false, null);
};
M.editor_atto.add_toolbar_button(params.elementid, 'unlink', params.icon, click);
M.editor_atto.add_toolbar_button(params.elementid, 'unlink', params.icon, params.group, click);
}
};
@@ -29,21 +29,21 @@
function atto_unorderedlist_init_editor($elementid) {
global $PAGE, $OUTPUT;
$icon = $OUTPUT->pix_icon('unorderedlist',
$icon = $OUTPUT->pix_icon('e/bullet_list',
get_string('unorderedlist', 'atto_unorderedlist'),
'atto_unorderedlist',
'moodle',
array('class'=>'icon'));
$PAGE->requires->yui_module('moodle-atto_unorderedlist-button',
'M.atto_unorderedlist.init',
array(array('elementid'=>$elementid, 'icon'=>$icon)),
array(array('elementid'=>$elementid, 'icon'=>$icon, 'group'=>'list')),
true);
}
/**
* Return the order this plugin should be displayed in the toolbar
* @return int
* @return int the absolute position within the toolbar
*/
function atto_unorderedlist_sort_order() {
return 7;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 441 B

Some files were not shown because too many files have changed in this diff Show More