loleaflet/build/deps.js | 7 loleaflet/css/loleaflet.css | 30 + loleaflet/images/copy.svg | 439 +++++++++++++++++++++++++ loleaflet/images/cut.svg | 419 ++++++++++++++++++++++++ loleaflet/images/paste.svg | 464 +++++++++++++++++++++++++++ loleaflet/src/control/Control.MobileInput.js | 252 ++++++++++++++ loleaflet/src/map/Map.js | 8 7 files changed, 1617 insertions(+), 2 deletions(-)
New commits: commit c3db4078cbe1a5496bbe9e862587e3a52f64a99a Author: Henry Castro <hcas...@collabora.com> AuthorDate: Sun Aug 26 11:55:35 2018 -0400 Commit: Henry Castro <hcas...@collabora.com> CommitDate: Sun Aug 26 14:30:31 2018 -0400 loleaflet: mobile: add control to handle events cut/copy/paste Change-Id: I8f500b17d9479a846afd59c42775e11d3f298248 diff --git a/loleaflet/build/deps.js b/loleaflet/build/deps.js index 93f4bb0de..241d8b0cd 100644 --- a/loleaflet/build/deps.js +++ b/loleaflet/build/deps.js @@ -293,6 +293,13 @@ var deps = { desc: 'Column Header bar' }, + ControlMobileInput: { + src: ['control/Control.js', + 'control/Control.MobileInput.js'], + heading: 'Controls', + desc: 'Mobile Input' + }, + ControlRowHeader: { src: ['control/Control.js', 'control/Control.RowHeader.js'], diff --git a/loleaflet/css/loleaflet.css b/loleaflet/css/loleaflet.css index bcaf442f5..4264bb836 100644 --- a/loleaflet/css/loleaflet.css +++ b/loleaflet/css/loleaflet.css @@ -140,6 +140,24 @@ body { overflow: auto; } +.loleaflet-mobile-table { + background-color: transparent; + border-collapse: separate; + border-spacing: 0; + border: none; +} + +.loleaflet-mobile-button { + width: 40px; + height: 40px; + display: inline-block; +} + +.loleaflet-mobile-input { + width: 100px; + height: 25px; +} + /* Important to override context-menu-icon's font-family here otherwise, jquery-contextmenu.css * will try to load its own font file which is not available in dist/ */ .context-menu-icon::before { @@ -259,6 +277,18 @@ body { background: url('images/lc_rejecttrackedchange.svg') no-repeat center !important; } +.loleaflet-mobile-copy { + background: url('images/copy.svg') no-repeat center !important; +} + +.loleaflet-mobile-cut { + background: url('images/cut.svg') no-repeat center !important; +} + +.loleaflet-mobile-paste { + background: url('images/paste.svg') no-repeat center !important; +} + .loleaflet-annotation-menu, .loleaflet-annotation-menu-redline { background: url('images/submenu.svg') no-repeat center !important; } diff --git a/loleaflet/images/copy.svg b/loleaflet/images/copy.svg new file mode 100644 index 000000000..1f34318f6 --- /dev/null +++ b/loleaflet/images/copy.svg @@ -0,0 +1,439 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<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:xlink="http://www.w3.org/1999/xlink" + id="svg5018" + height="32" + width="32" + version="1.1"> + <defs + id="defs5020"> + <linearGradient + id="linearGradient4087"> + <stop + offset="0" + style="stop-color:#ffffff;stop-opacity:1" + id="stop4089" /> + <stop + offset="0.51153916" + style="stop-color:#ffffff;stop-opacity:0.23529412" + id="stop4091" /> + <stop + offset="0.58522105" + style="stop-color:#ffffff;stop-opacity:0.15686275" + id="stop4093" /> + <stop + offset="1" + style="stop-color:#ffffff;stop-opacity:0.39215687" + id="stop4095" /> + </linearGradient> + <linearGradient + gradientTransform="matrix(0.39222363,0,0,-0.36562471,4.8278194,25.163568)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient3242-7-3-8-0-4-58-06" + id="linearGradient3162" + y2="-1.1839229" + x2="27.974298" + y1="36.127529" + x1="27.974298" /> + <radialGradient + gradientTransform="matrix(-0.38351555,0,0,-0.25567694,22.275669,31.384178)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient8662" + id="radialGradient3173" + fy="36.421127" + fx="24.837126" + r="15.644737" + cy="36.421127" + cx="24.837126" /> + <linearGradient + id="linearGradient8662"> + <stop + offset="0" + style="stop-color:#000000;stop-opacity:1" + id="stop8664" /> + <stop + offset="1" + style="stop-color:#000000;stop-opacity:0" + id="stop8666" /> + </linearGradient> + <linearGradient + gradientTransform="matrix(0.0352071,0,0,0.0082353,-0.724852,26.980547)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient5048-9" + id="linearGradient3175" + y2="609.50507" + x2="302.85715" + y1="366.64789" + x1="302.85715" /> + <linearGradient + id="linearGradient5048-9"> + <stop + offset="0" + style="stop-color:#000000;stop-opacity:0" + id="stop5050-3" /> + <stop + offset="0.5" + style="stop-color:#000000;stop-opacity:1" + id="stop5056-7" /> + <stop + offset="1" + style="stop-color:#000000;stop-opacity:0" + id="stop5052-4" /> + </linearGradient> + <radialGradient + gradientTransform="matrix(-0.01204859,0,0,0.0082353,10.761206,26.980564)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient5060-2" + id="radialGradient3177" + fy="486.64789" + fx="605.71429" + r="117.14286" + cy="486.64789" + cx="605.71429" /> + <linearGradient + id="linearGradient5060-2"> + <stop + offset="0" + style="stop-color:#000000;stop-opacity:1" + id="stop5062-5" /> + <stop + offset="1" + style="stop-color:#000000;stop-opacity:0" + id="stop5064-4" /> + </linearGradient> + <radialGradient + gradientTransform="matrix(0.01204859,0,0,0.0082353,13.238793,26.980564)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient5060-2" + id="radialGradient3179" + fy="486.64789" + fx="605.71429" + r="117.14286" + cy="486.64789" + cx="605.71429" /> + <linearGradient + gradientTransform="matrix(0.48571543,0,0,0.45629666,0.3428289,8.3488617)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient3600-4-4" + id="linearGradient3181" + y2="47.013336" + x2="25.132275" + y1="0.98520643" + x1="25.132275" /> + <linearGradient + id="linearGradient3600-4-4"> + <stop + offset="0" + style="stop-color:#f4f4f4;stop-opacity:1" + id="stop3602-7-3" /> + <stop + offset="1" + style="stop-color:#dbdbdb;stop-opacity:1" + id="stop3604-6-0" /> + </linearGradient> + <linearGradient + gradientTransform="matrix(0.39221364,0,0,0.42702571,29.199296,7.8403287)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient3104-5-8" + id="linearGradient3183" + y2="2.9062471" + x2="-51.786404" + y1="50.786446" + x1="-51.786404" /> + <linearGradient + id="linearGradient3104-5-8"> + <stop + offset="0" + style="stop-color:#a0a0a0;stop-opacity:1" + id="stop3106-6-6" /> + <stop + offset="1" + style="stop-color:#bebebe;stop-opacity:1" + id="stop3108-9-8" /> + </linearGradient> + <linearGradient + gradientTransform="matrix(0.40540511,0,0,0.51351351,2.2696871,7.6756805)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient3977-8" + id="linearGradient3185" + y2="43" + x2="23.99999" + y1="5.5641499" + x1="23.99999" /> + <linearGradient + id="linearGradient3977-8"> + <stop + offset="0" + style="stop-color:#ffffff;stop-opacity:1" + id="stop3979-4" /> + <stop + offset="0.03626217" + style="stop-color:#ffffff;stop-opacity:0.23529412" + id="stop3981-3" /> + <stop + offset="0.95056331" + style="stop-color:#ffffff;stop-opacity:0.15686275" + id="stop3983-1" /> + <stop + offset="1" + style="stop-color:#ffffff;stop-opacity:0.39215687" + id="stop3985-4" /> + </linearGradient> + <linearGradient + gradientTransform="matrix(0.0352071,0,0,0.0082353,-0.724852,26.980547)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient5048-9-6" + id="linearGradient3175-8" + y2="609.50507" + x2="302.85715" + y1="366.64789" + x1="302.85715" /> + <linearGradient + id="linearGradient5048-9-6"> + <stop + offset="0" + style="stop-color:#000000;stop-opacity:0" + id="stop5050-3-8" /> + <stop + offset="0.5" + style="stop-color:#000000;stop-opacity:1" + id="stop5056-7-3" /> + <stop + offset="1" + style="stop-color:#000000;stop-opacity:0" + id="stop5052-4-8" /> + </linearGradient> + <radialGradient + gradientTransform="matrix(-0.01204859,0,0,0.0082353,10.761206,26.980564)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient5060-2-3" + id="radialGradient3177-3" + fy="486.64789" + fx="605.71429" + r="117.14286" + cy="486.64789" + cx="605.71429" /> + <linearGradient + id="linearGradient5060-2-3"> + <stop + offset="0" + style="stop-color:#000000;stop-opacity:1" + id="stop5062-5-3" /> + <stop + offset="1" + style="stop-color:#000000;stop-opacity:0" + id="stop5064-4-8" /> + </linearGradient> + <radialGradient + gradientTransform="matrix(0.01204859,0,0,0.0082353,13.238793,26.980564)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient5060-2-3" + id="radialGradient3179-0" + fy="486.64789" + fx="605.71429" + r="117.14286" + cy="486.64789" + cx="605.71429" /> + <linearGradient + gradientTransform="matrix(0.48571543,0,0,0.45629666,0.3428289,8.3488617)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient3600-4-4-7" + id="linearGradient3181-4" + y2="47.013336" + x2="25.132275" + y1="0.98520643" + x1="25.132275" /> + <linearGradient + id="linearGradient3600-4-4-7"> + <stop + offset="0" + style="stop-color:#f4f4f4;stop-opacity:1" + id="stop3602-7-3-6" /> + <stop + offset="1" + style="stop-color:#dbdbdb;stop-opacity:1" + id="stop3604-6-0-8" /> + </linearGradient> + <linearGradient + gradientTransform="matrix(0.39221364,0,0,0.42702571,29.199296,7.8403287)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient3104-5-8-0" + id="linearGradient3183-9" + y2="2.9062471" + x2="-51.786404" + y1="50.786446" + x1="-51.786404" /> + <linearGradient + id="linearGradient3104-5-8-0"> + <stop + offset="0" + style="stop-color:#a0a0a0;stop-opacity:1" + id="stop3106-6-6-6" /> + <stop + offset="1" + style="stop-color:#bebebe;stop-opacity:1" + id="stop3108-9-8-8" /> + </linearGradient> + <linearGradient + id="linearGradient3977-8-9"> + <stop + offset="0" + style="stop-color:#ffffff;stop-opacity:1" + id="stop3979-4-0" /> + <stop + offset="0.03626217" + style="stop-color:#ffffff;stop-opacity:0.23529412" + id="stop3981-3-3" /> + <stop + offset="0.95056331" + style="stop-color:#ffffff;stop-opacity:0.15686275" + id="stop3983-1-3" /> + <stop + offset="1" + style="stop-color:#ffffff;stop-opacity:0.39215687" + id="stop3985-4-3" /> + </linearGradient> + <linearGradient + gradientTransform="matrix(0.40540511,0,0,0.51351351,2.2696871,7.6756805)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient3977-8-9" + id="linearGradient5016" + y2="43" + x2="23.99999" + y1="5.5641499" + x1="23.99999" /> + <radialGradient + cx="24.837126" + cy="36.421127" + r="15.644737" + fx="24.837126" + fy="36.421127" + id="radialGradient3449" + xlink:href="#linearGradient8662" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(-0.70660609,0,0,-0.47076982,-0.754985,39.964493)" /> + <linearGradient + x1="38.940514" + y1="15.991243" + x2="20.576487" + y2="15.991243" + id="linearGradient3855" + xlink:href="#linearGradient4087" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0,-0.39571558,0.42801014,0,6.4033107,30.903618)" /> + <linearGradient + id="linearGradient3242-7-3-8-0-4-58-06"> + <stop + id="stop3244-5-8-5-6-4-3-8" + style="stop-color:#cdf87e;stop-opacity:1" + offset="0" /> + <stop + id="stop3246-9-5-1-5-3-0-7" + style="stop-color:#a2e34f;stop-opacity:1" + offset="0.26238" /> + <stop + id="stop3248-7-2-0-7-5-35-9" + style="stop-color:#68b723;stop-opacity:1" + offset="0.66093999" /> + <stop + id="stop3250-8-2-8-5-6-40-4" + style="stop-color:#1d7e0d;stop-opacity:1" + offset="1" /> + </linearGradient> + </defs> + <metadata + id="metadata5023"> + <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 + transform="translate(0,-6.999996)" + id="layer1-8-7"> + <rect + width="16.999998" + height="2" + x="3.5000007" + y="30" + id="rect2879-0-3" + style="display:inline;overflow:visible;visibility:visible;opacity:0.15;fill:url(#linearGradient3175-8);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;marker:none" /> + <path + d="m 3.4999999,30.000085 c 0,0 0,1.999891 0,1.999891 C 2.8795275,32.003776 2,31.551901 2,30.999901 2,30.447902 2.6924,30.000085 3.4999999,30.000085 Z" + id="path2881-6-2" + style="display:inline;overflow:visible;visibility:visible;opacity:0.15;fill:url(#radialGradient3177-3);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;marker:none" /> + <path + d="m 20.5,30.000085 c 0,0 0,1.999891 0,1.999891 0.620472,0.0038 1.5,-0.448075 1.5,-1.000075 0,-0.551999 -0.692402,-0.999816 -1.5,-0.999816 z" + id="path2883-8-6" + style="display:inline;overflow:visible;visibility:visible;opacity:0.15;fill:url(#radialGradient3179-0);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;marker:none" /> + <path + d="m 3.4999601,9.4999569 c 3.8955809,0 17.0000589,0.00136 17.0000589,0.00136 l 2.1e-5,20.9987161 c 0,0 -11.3333862,0 -17.0000799,0 0,-7.000018 0,-14.000035 0,-21.0000538 z" + id="path4160-3-9-5" + style="display:inline;fill:url(#linearGradient3181-4);fill-opacity:1;stroke:url(#linearGradient3183-9);stroke-width:0.99992186;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + <path + d="m 19.5,29.5 -15.0000004,0 0,-19 L 19.5,10.5 Z" + id="rect6741-1-2-2" + style="fill:none;stroke:url(#linearGradient5016);stroke-width:1;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </g> + <path + d="m 10,6.0000003 c 2.520657,0 10.999987,0.0012 10.999987,0.0012 L 21,24.000003 c 0,0 -7.333334,0 -11,0 0,-5.999983 0,-11.999966 0,-17.9999507 z" + id="path4160-3-9-6" + style="display:inline;opacity:0.05;fill:#000000;fill-opacity:1;stroke:none" /> + <g + transform="translate(8.0000004,-2)" + id="layer1-8"> + <rect + width="16.999998" + height="2" + x="3.5000007" + y="30" + id="rect2879-0" + style="display:inline;overflow:visible;visibility:visible;opacity:0.15;fill:url(#linearGradient3175);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;marker:none" /> + <path + d="m 3.4999999,30.000085 c 0,0 0,1.999891 0,1.999891 C 2.8795275,32.003776 2,31.551901 2,30.999901 2,30.447902 2.6924,30.000085 3.4999999,30.000085 Z" + id="path2881-6" + style="display:inline;overflow:visible;visibility:visible;opacity:0.15;fill:url(#radialGradient3177);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;marker:none" /> + <path + d="m 20.5,30.000085 c 0,0 0,1.999891 0,1.999891 0.620472,0.0038 1.5,-0.448075 1.5,-1.000075 0,-0.551999 -0.692402,-0.999816 -1.5,-0.999816 z" + id="path2883-8" + style="display:inline;overflow:visible;visibility:visible;opacity:0.15;fill:url(#radialGradient3179);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;marker:none" /> + <path + d="m 3.4999601,9.4999569 c 3.8955809,0 17.0000589,0.00136 17.0000589,0.00136 l 2.1e-5,20.9987161 c 0,0 -11.3333862,0 -17.0000799,0 0,-7.000018 0,-14.000035 0,-21.0000538 z" + id="path4160-3-9" + style="display:inline;fill:url(#linearGradient3181);fill-opacity:1;stroke:url(#linearGradient3183);stroke-width:0.99992186;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + <path + d="m 19.5,29.5 -15.0000004,0 0,-19 L 19.5,10.5 Z" + id="rect6741-1-2" + style="fill:none;stroke:url(#linearGradient3185);stroke-width:1;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </g> + <path + d="m 6.750245,22.072131 a 6,4.0000002 0 1 1 12,0 6,4.0000002 0 0 1 -12,0 z" + id="path3501" + style="display:inline;overflow:visible;visibility:visible;opacity:0.14117647;fill:url(#radialGradient3173);fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;marker:none" /> + <path + d="m 10.832248,11.017552 c -4.9802216,3.367056 -2.0511186,9.550728 3.5,9.5 l 0,3.000485 7,-5 -7,-5 0,2.976351 c -3.580248,0.139062 -5.5595156,-3.12742 -3,-5.476836 z" + id="path3503" + style="display:block;overflow:visible;visibility:visible;fill:url(#linearGradient3162);fill-opacity:1.0;fill-rule:nonzero;stroke:none;stroke-width:0.96392483;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:7;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker:none" /> + <path + d="m 9.8755864,12.759279 c -1.756852,2.058862 -0.225017,7.434574 5.3950626,6.699241 l 0.0616,2.197396 4.369328,-3.137879 -4.369328,-3.064428 0,2.059765 C 9.1648074,17.842539 9.3507614,13.59157 9.8755874,12.759279 Z" + id="path3505" + style="display:block;overflow:visible;visibility:visible;opacity:0.8;fill:none;stroke:url(#linearGradient3855);stroke-width:0.96400005;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:7;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker:none;color:#000000;clip-rule:nonzero;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill-opacity:1;fill-rule:nonzero;filter-blend-mode:normal;filter-gaussianBlur-deviation:0;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" /> + <path + d="m -29.359717,22.818517 a 11.054667,7.3650752 0 1 1 22.109334,0 11.054667,7.3650752 0 0 1 -22.109334,0 z" + id="path3501-0" + style="display:inline;overflow:visible;visibility:visible;opacity:0.14117647;fill:url(#radialGradient3449);fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;marker:none" /> + <path + d="m 10.832248,11.017552 c -4.9802216,3.367056 -2.0511186,9.550728 3.5,9.5 l 0,3.000485 6.999999,-5 -6.999999,-5 0,2.976351 c -3.580248,0.139062 -5.5595156,-3.12742 -3,-5.476836 z" + id="path3503-4" + style="display:inline;overflow:visible;visibility:visible;fill:none;fill-opacity:1;fill-rule:nonzero;stroke:#0f5a00;stroke-width:1;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker:none;color:#000000;clip-rule:nonzero;opacity:0.5;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;filter-blend-mode:normal;filter-gaussianBlur-deviation:0;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" /> +</svg> diff --git a/loleaflet/images/cut.svg b/loleaflet/images/cut.svg new file mode 100644 index 000000000..de044bb49 --- /dev/null +++ b/loleaflet/images/cut.svg @@ -0,0 +1,419 @@ +<?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:xlink="http://www.w3.org/1999/xlink" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + width="32" + height="32" + id="svg4296" + version="1.1" + inkscape:version="0.48.4 r9939" + sodipodi:docname="edit-cut.svg"> + <defs + id="defs4298"> + <linearGradient + id="linearGradient3810"> + <stop + style="stop-color:#a60101;stop-opacity:1;" + offset="0" + id="stop3812" /> + <stop + style="stop-color:#5f0101;stop-opacity:1;" + offset="1" + id="stop3814" /> + </linearGradient> + <linearGradient + id="linearGradient3774"> + <stop + style="stop-color:#444444;stop-opacity:1;" + offset="0" + id="stop3776" /> + <stop + style="stop-color:#9e9e9e;stop-opacity:1;" + offset="1" + id="stop3778" /> + </linearGradient> + <linearGradient + id="linearGradient3764"> + <stop + style="stop-color:#d1d1d1;stop-opacity:1;" + offset="0" + id="stop3766" /> + <stop + style="stop-color:#eaeaea;stop-opacity:1;" + offset="1" + id="stop3768" /> + </linearGradient> + <linearGradient + id="linearGradient2264"> + <stop + id="stop2266" + offset="0" + style="stop-color:#d7e866;stop-opacity:1;" /> + <stop + id="stop2268" + offset="1" + style="stop-color:#8cab2a;stop-opacity:1;" /> + </linearGradient> + <linearGradient + gradientTransform="matrix(0.5384199,0,0,0.5384199,-0.922077,-1.4604985)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient3781" + id="linearGradient2494" + y2="45.074459" + x2="24.481066" + y1="5.0808945" + x1="24.481066" /> + <linearGradient + id="linearGradient3781"> + <stop + offset="0" + style="stop-color:#ffffff;stop-opacity:1" + id="stop3783" /> + <stop + offset="1" + style="stop-color:#ffffff;stop-opacity:0" + id="stop3785" /> + </linearGradient> + <linearGradient + gradientTransform="matrix(1.0862728,0,0,1.0862481,-55.56661,15.813638)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient4873" + id="linearGradient2497" + y2="5.4675598" + x2="63.397362" + y1="-12.489107" + x1="63.397362" /> + <linearGradient + id="linearGradient4873"> + <stop + offset="0" + style="stop-color:#ffffff;stop-opacity:1" + id="stop4875" /> + <stop + offset="1" + style="stop-color:#ffffff;stop-opacity:0" + id="stop4877" /> + </linearGradient> + <radialGradient + gradientTransform="matrix(0,1.2316137,-1.6257082,0,18.486581,-28.720783)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient3242" + id="radialGradient2500" + fy="3.9900031" + fx="23.895569" + r="20.397499" + cy="3.9900031" + cx="23.895569" /> + <linearGradient + id="linearGradient3242"> + <stop + offset="0" + style="stop-color:#f8b17e;stop-opacity:1" + id="stop3244" /> + <stop + offset="0.26238" + style="stop-color:#e35d4f;stop-opacity:1" + id="stop3246" /> + <stop + offset="0.66093999" + style="stop-color:#c6262e;stop-opacity:1" + id="stop3248" /> + <stop + offset="1" + style="stop-color:#690b54;stop-opacity:1" + id="stop3250" /> + </linearGradient> + <linearGradient + gradientTransform="matrix(0.5160413,0,0,0.5160413,-0.384991,-0.3849911)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient2490" + id="linearGradient2502" + y2="3.0816143" + x2="18.379412" + y1="44.980297" + x1="18.379412" /> + <linearGradient + id="linearGradient2490"> + <stop + offset="0" + style="stop-color:#791235;stop-opacity:1" + id="stop2492" /> + <stop + offset="1" + style="stop-color:#dd3b27;stop-opacity:1" + id="stop2494" /> + </linearGradient> + <radialGradient + gradientTransform="matrix(1.1294118,0,0,0.2823525,-58.729414,19.694118)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient8838" + id="radialGradient2478" + fy="4.625" + fx="62.625" + r="10.625" + cy="4.625" + cx="62.625" /> + <linearGradient + id="linearGradient8838"> + <stop + offset="0" + style="stop-color:#000000;stop-opacity:1" + id="stop8840" /> + <stop + offset="1" + style="stop-color:#000000;stop-opacity:0" + id="stop8842" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient3781" + id="linearGradient3975" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0.5384199,0,0,0.5384199,-44.014327,1034.0991)" + x1="24.481066" + y1="5.0808945" + x2="24.481066" + y2="45.074459" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4873" + id="linearGradient3978" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(1.0862728,0,0,1.0862481,-98.65886,1051.3732)" + x1="63.397362" + y1="-12.489107" + x2="63.397362" + y2="5.4675598" /> + <radialGradient + inkscape:collect="always" + xlink:href="#linearGradient3242" + id="radialGradient3981" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0,1.2316137,-1.6257082,0,-24.605669,1006.8388)" + cx="23.895569" + cy="3.9900031" + fx="23.895569" + fy="3.9900031" + r="20.397499" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient2490" + id="linearGradient3983" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0.5160413,0,0,0.5160413,-43.477241,1035.1746)" + x1="18.379412" + y1="44.980297" + x2="18.379412" + y2="3.0816143" /> + <radialGradient + inkscape:collect="always" + xlink:href="#linearGradient3810" + id="radialGradient3040" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(-0.55698928,1.3924728,-2.4995652,-0.99982634,61.594656,1040.8163)" + cx="12" + cy="15.166395" + fx="12" + fy="15.166395" + r="4.0006957" /> + <radialGradient + inkscape:collect="always" + xlink:href="#linearGradient8838" + id="radialGradient3043" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0.5647059,0,0,0.2823525,-16.364705,1047.0563)" + cx="62.625" + cy="4.625" + fx="62.625" + fy="4.625" + r="10.625" /> + <radialGradient + inkscape:collect="always" + xlink:href="#linearGradient8838" + id="radialGradient3046" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0.5647059,0,0,0.2823525,-24.364705,1047.0563)" + cx="62.625" + cy="4.625" + fx="62.625" + fy="4.625" + r="10.625" /> + <radialGradient + inkscape:collect="always" + xlink:href="#linearGradient3764" + id="radialGradient3049" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0.84316722,-1.6450613,2.5294719,1.2338023,-2622.8354,-220.09736)" + cx="14.999991" + cy="1039.7" + fx="14.999991" + fy="1039.7" + r="3.5266583" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient3774" + id="linearGradient3051" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(1.4867883,0,0,1.4504113,-2.5980652,-472.3925)" + x1="17" + y1="1042.3622" + x2="15" + y2="1038.3622" /> + <radialGradient + inkscape:collect="always" + xlink:href="#linearGradient3764" + id="radialGradient3054" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(-0.84316728,-1.6450614,-2.5294721,1.2338024,2653.8356,-220.09745)" + cx="14.999991" + cy="1039.7" + fx="14.999991" + fy="1039.7" + r="3.5266583" /> + <radialGradient + inkscape:collect="always" + xlink:href="#linearGradient3810" + id="radialGradient3058" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(-1.9795548,0.28278205,-0.24994327,-1.749674,285.6389,2844.6513)" + cx="9" + cy="1035.5266" + fx="9" + fy="1035.5266" + r="4.0006957" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient3774" + id="linearGradient3853" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(1.4867883,0,0,1.4504113,-2.5980652,-472.3925)" + x1="17" + y1="1042.3622" + x2="15" + y2="1038.3622" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient3774" + id="linearGradient3857" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(-1.4867884,0,0,1.4504114,33.598067,-472.3926)" + x1="17" + y1="1042.3622" + x2="15" + y2="1038.3622" /> + </defs> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="17.42054" + inkscape:cx="8.140317" + inkscape:cy="22.365314" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="true" + inkscape:snap-global="false" + inkscape:window-width="1320" + inkscape:window-height="1079" + inkscape:window-x="297" + inkscape:window-y="25" + inkscape:window-maximized="0"> + <inkscape:grid + type="xygrid" + id="grid4315" + empspacing="5" + visible="true" + enabled="true" + snapvisiblegridlinesonly="true" /> + </sodipodi:namedview> + <metadata + id="metadata4301"> + <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,-1020.3622)"> + <path + sodipodi:nodetypes="cccc" + inkscape:connector-curvature="0" + id="path3782" + d="m 16.5,1038.011 -7.879978,-14.214 c 0,0 -3.620022,11.5652 7.879978,18.5652 z" + style="fill:url(#radialGradient3054);fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" /> + <path + sodipodi:nodetypes="cc" + inkscape:connector-curvature="0" + id="path3859" + d="m 8.741698,1025.0836 7.664206,13.8875" + style="opacity:0.8;fill:none;stroke:#ffffff;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" /> + <path + style="fill:none;stroke:url(#linearGradient3857);stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" + d="m 16.5,1038.011 -7.879978,-14.214 c 0,0 -3.620022,11.5652 7.879978,18.5652 z" + id="path3855" + inkscape:connector-curvature="0" + sodipodi:nodetypes="cccc" /> + <path + style="fill:url(#radialGradient3049);fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" + d="m 14.5,1038.011 7.879978,-14.214 c 0,0 4.620022,10.5652 -7.879978,18.5652 z" + id="path2990" + inkscape:connector-curvature="0" + sodipodi:nodetypes="cccc" /> + <path + inkscape:connector-curvature="0" + d="m 17,1048.3622 c 0,1.6569 -2.686291,3 -6,3 -3.3137085,0 -6,-1.3431 -6,-3 0,-1.6569 2.6862915,-3 6,-3 3.313709,0 6,1.3431 6,3 l 0,0 z" + id="path8836" + style="opacity:0.4;fill:url(#radialGradient3046);fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:0.99999988;marker:none;visibility:visible;display:inline;overflow:visible" /> + <path + style="opacity:0.4;fill:url(#radialGradient3043);fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:0.99999988;marker:none;visibility:visible;display:inline;overflow:visible" + id="path4007" + d="m 25,1048.3622 c 0,1.6569 -2.686291,3 -6,3 -3.313709,0 -6,-1.3431 -6,-3 0,-1.6569 2.686291,-3 6,-3 3.313709,0 6,1.3431 6,3 l 0,0 z" + inkscape:connector-curvature="0" /> + <path + style="fill:#ee5050;fill-opacity:1;stroke:url(#radialGradient3040);stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" + d="m 18.001391,1041.3622 c -0.684728,0.1472 -1.54059,1.1088 -1.5,3.5 0.05092,2.9996 2.187468,4 3.5,4 1.312532,0 3.5,-1.0415 3.5,-4 0,-2.9586 -4.815272,-3.6472 -5.5,-3.5 z m 0.4375,1.875 c 0,0 5.23936,0.8914 2.25,3.125 -2.688286,2.0087 -2.25,-3.125 -2.25,-3.125 z" + id="path3788" + inkscape:connector-curvature="0" /> + <path + style="fill:none;stroke:#ffffff;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;opacity:0.8" + d="M 22.405904,4.7214022 14.741698,18.608856" + id="path3079" + inkscape:connector-curvature="0" + transform="translate(0,1020.3622)" + sodipodi:nodetypes="cc" /> + <path + sodipodi:nodetypes="cccc" + inkscape:connector-curvature="0" + id="path3851" + d="m 14.5,1038.011 7.879978,-14.214 c 0,0 4.620022,10.5652 -7.879978,18.5652 z" + style="fill:none;stroke:url(#linearGradient3853);stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" /> + <g + id="g3798" + transform="translate(4,6.9999917)"> + <path + inkscape:connector-curvature="0" + id="path3793" + d="m 8.5625,1034.3622 c -1.3803873,0.074 -5.0625,0.9112 -5.0625,3.5 0,2.9585 2.1874677,4.0034 3.5,4 1.3125323,0 3.449081,-1.0004 3.5,-4 0.04059,-2.3912 -0.815272,-3.3528 -1.5,-3.5 -0.085591,-0.018 -0.2403018,-0.011 -0.4375,0 z m 0,1.875 c 0,0 0.4382857,5.1337 -2.25,3.125 -2.9893599,-2.2336 2.25,-3.125 2.25,-3.125 z" + style="fill:#ee5050;fill-opacity:1;stroke:url(#radialGradient3058);stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" /> + </g> + </g> +</svg> diff --git a/loleaflet/images/paste.svg b/loleaflet/images/paste.svg new file mode 100644 index 000000000..f467d70ea --- /dev/null +++ b/loleaflet/images/paste.svg @@ -0,0 +1,464 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<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:xlink="http://www.w3.org/1999/xlink" + version="1.1" + width="32" + height="32" + id="svg5018"> + <defs + id="defs5020"> + <linearGradient + id="linearGradient4087"> + <stop + id="stop4089" + style="stop-color:#ffffff;stop-opacity:1" + offset="0" /> + <stop + id="stop4091" + style="stop-color:#ffffff;stop-opacity:0.23529412" + offset="0.51153916" /> + <stop + id="stop4093" + style="stop-color:#ffffff;stop-opacity:0.15686275" + offset="0.58522105" /> + <stop + id="stop4095" + style="stop-color:#ffffff;stop-opacity:0.39215687" + offset="1" /> + </linearGradient> + <linearGradient + x1="27.974298" + y1="36.127529" + x2="27.974298" + y2="-1.1839229" + id="linearGradient3162" + xlink:href="#linearGradient3242-7-3-8-0-4-58-06" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0.39222363,0,0,-0.36562471,5.8278194,26.163568)" /> + <radialGradient + cx="24.837126" + cy="36.421127" + r="15.644737" + fx="24.837126" + fy="36.421127" + id="radialGradient3173" + xlink:href="#linearGradient8662" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(-0.38351555,0,0,-0.25567694,23.275669,32.384178)" /> + <linearGradient + id="linearGradient8662"> + <stop + id="stop8664" + style="stop-color:#000000;stop-opacity:1" + offset="0" /> + <stop + id="stop8666" + style="stop-color:#000000;stop-opacity:0" + offset="1" /> + </linearGradient> + <linearGradient + x1="302.85715" + y1="366.64789" + x2="302.85715" + y2="609.50507" + id="linearGradient3175" + xlink:href="#linearGradient5048-9" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0.0352071,0,0,0.0082353,-0.724852,26.980547)" /> + <linearGradient + id="linearGradient5048-9"> + <stop + id="stop5050-3" + style="stop-color:#000000;stop-opacity:0" + offset="0" /> + <stop + id="stop5056-7" + style="stop-color:#000000;stop-opacity:1" + offset="0.5" /> + <stop + id="stop5052-4" + style="stop-color:#000000;stop-opacity:0" + offset="1" /> + </linearGradient> + <radialGradient + cx="605.71429" + cy="486.64789" + r="117.14286" + fx="605.71429" + fy="486.64789" + id="radialGradient3177" + xlink:href="#linearGradient5060-2" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(-0.01204859,0,0,0.0082353,10.761206,26.980564)" /> + <linearGradient + id="linearGradient5060-2"> + <stop + id="stop5062-5" + style="stop-color:#000000;stop-opacity:1" + offset="0" /> + <stop + id="stop5064-4" + style="stop-color:#000000;stop-opacity:0" + offset="1" /> + </linearGradient> + <radialGradient + cx="605.71429" + cy="486.64789" + r="117.14286" + fx="605.71429" + fy="486.64789" + id="radialGradient3179" + xlink:href="#linearGradient5060-2" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0.01204859,0,0,0.0082353,13.238793,26.980564)" /> + <linearGradient + x1="25.132275" + y1="0.98520643" + x2="25.132275" + y2="47.013336" + id="linearGradient3181" + xlink:href="#linearGradient3600-4-4" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0.48571543,0,0,0.45629666,0.3428289,8.3488617)" /> + <linearGradient + id="linearGradient3600-4-4"> + <stop + id="stop3602-7-3" + style="stop-color:#f4f4f4;stop-opacity:1" + offset="0" /> + <stop + id="stop3604-6-0" + style="stop-color:#dbdbdb;stop-opacity:1" + offset="1" /> + </linearGradient> + <linearGradient + x1="23.99999" + y1="5.5641499" + x2="23.99999" + y2="43" + id="linearGradient3185" + xlink:href="#linearGradient3977-8" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0.40540511,0,0,0.51351351,2.2696871,7.6756805)" /> + <linearGradient + id="linearGradient3977-8"> + <stop + id="stop3979-4" + style="stop-color:#ffffff;stop-opacity:1" + offset="0" /> + <stop + id="stop3981-3" + style="stop-color:#ffffff;stop-opacity:0.23529412" + offset="0.03626217" /> + <stop + id="stop3983-1" + style="stop-color:#ffffff;stop-opacity:0.15686275" + offset="0.95056331" /> + <stop + id="stop3985-4" + style="stop-color:#ffffff;stop-opacity:0.39215687" + offset="1" /> + </linearGradient> + <linearGradient + gradientTransform="matrix(0,-0.39571558,0.42801014,0,7.4033107,31.903618)" + gradientUnits="userSpaceOnUse" + xlink:href="#linearGradient4087" + id="linearGradient3855" + y2="15.991243" + x2="20.576487" + y1="15.41246" + x1="45.243652" /> + <linearGradient + id="linearGradient3242-7-3-8-0-4-58-06"> + <stop + offset="0" + style="stop-color:#cdf87e;stop-opacity:1" + id="stop3244-5-8-5-6-4-3-8" /> + <stop + offset="0.26238" + style="stop-color:#a2e34f;stop-opacity:1" + id="stop3246-9-5-1-5-3-0-7" /> + <stop + offset="0.66093999" + style="stop-color:#68b723;stop-opacity:1" + id="stop3248-7-2-0-7-5-35-9" /> + <stop + offset="1" + style="stop-color:#1d7e0d;stop-opacity:1" + id="stop3250-8-2-8-5-6-40-4" /> + </linearGradient> + <linearGradient + y2="609.50507" + x2="302.85715" + y1="366.64789" + x1="302.85715" + gradientTransform="matrix(0.04576928,0,0,0.00823529,1.457689,36.980548)" + gradientUnits="userSpaceOnUse" + id="linearGradient4480" + xlink:href="#linearGradient5048-9" /> + <radialGradient + r="117.14286" + fy="486.64789" + fx="605.71429" + cy="486.64789" + cx="605.71429" + gradientTransform="matrix(-0.01566318,0,0,0.00823529,16.389579,36.980565)" + gradientUnits="userSpaceOnUse" + id="radialGradient4482" + xlink:href="#linearGradient8662" /> + <radialGradient + r="117.14286" + fy="486.64789" + fx="605.71429" + cy="486.64789" + cx="605.71429" + gradientTransform="matrix(0.01566318,0,0,0.00823529,19.610446,36.980565)" + gradientUnits="userSpaceOnUse" + id="radialGradient4484" + xlink:href="#linearGradient8662" /> + <linearGradient + y2="-39.125" + x2="26" + y1="-13.625" + x1="25.5" + gradientTransform="matrix(0.66666676,0,0,0.75000006,-2.8333348,1.8915702)" + gradientUnits="userSpaceOnUse" + id="linearGradient5021" + xlink:href="#linearGradient5772-1" /> + <linearGradient + id="linearGradient5772-1"> + <stop + style="stop-color:#e2b369;stop-opacity:1" + offset="0" + id="stop5774-8" /> + <stop + style="stop-color:#c79b55;stop-opacity:1" + offset="1" + id="stop5776-7" /> + </linearGradient> + <linearGradient + y2="-40.204414" + x2="14.388891" + y1="-8.8407707" + x1="14.388891" + gradientTransform="matrix(0.64285684,0,0,0.73333321,-2.2499974,1.483231)" + gradientUnits="userSpaceOnUse" + id="linearGradient5025" + xlink:href="#linearGradient4455" /> + <linearGradient + id="linearGradient4455"> + <stop + offset="0" + style="stop-color:#ffffff;stop-opacity:1" + id="stop4457" /> + <stop + offset="0.06249999" + style="stop-color:#ffffff;stop-opacity:0.23529412" + id="stop4459" /> + <stop + offset="0.96279675" + style="stop-color:#ffffff;stop-opacity:0.15686275" + id="stop4461" /> + <stop + offset="1" + style="stop-color:#ffffff;stop-opacity:0.39215687" + id="stop4463" /> + </linearGradient> + <linearGradient + y2="13.999999" + x2="25" + y1="3.999999" + x1="25" + gradientTransform="translate(-9,-4.016568)" + gradientUnits="userSpaceOnUse" + id="linearGradient4997" + xlink:href="#radialGradient4536" /> + <radialGradient + cx="23.896" + cy="3.99" + r="20.396999" + id="radialGradient4536" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0,1.2316483,-1.625754,0,18.486966,-28.721977)"> + <stop + id="stop4538" + style="stop-color:#ffffff;stop-opacity:1" + offset="0" /> + <stop + id="stop4540" + style="stop-color:#dddddd;stop-opacity:1" + offset="0.06562372" /> + <stop + id="stop4542" + style="stop-color:#abacae;stop-opacity:1" + offset="0.66093999" /> + <stop + id="stop4544" + style="stop-color:#89898b;stop-opacity:1" + offset="1" /> + </radialGradient> + <linearGradient + y2="8" + x2="24.498007" + y1="3.9980428" + x1="24.498007" + gradientTransform="translate(-9,-2.016568)" + gradientUnits="userSpaceOnUse" + id="linearGradient5001" + xlink:href="#linearGradient5071-3-1-8" /> + <linearGradient + id="linearGradient5071-3-1-8"> + <stop + id="stop5073-3-6-8" + offset="0" + style="stop-color:#ffffff;stop-opacity:1;" /> + <stop + id="stop5075-6-9-9" + offset="1" + style="stop-color:#ffffff;stop-opacity:0;" /> + </linearGradient> + <linearGradient + gradientTransform="matrix(0.60000001,0,0,0.80000004,1.1999999,-0.3165692)" + gradientUnits="userSpaceOnUse" + y2="7" + x2="20" + y1="3" + x1="20" + id="linearGradient4365" + xlink:href="#linearGradient5071-3-1-8" /> + </defs> + <metadata + id="metadata5023"> + <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 + id="g4351"> + <rect + y="-28.483431" + x="3.5" + width="20" + transform="scale(1,-1)" + style="color:#000000;display:block;overflow:visible;visibility:visible;fill:url(#linearGradient5021);fill-opacity:1;fill-rule:nonzero;stroke:#66430b;stroke-width:0.99999994;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.49803922;marker:none;enable-background:accumulate" + ry="1.5" + rx="1.5" + id="rect4613" + height="24" /> + <rect + y="-27.483429" + x="4.5" + width="18" + transform="scale(1,-1)" + style="color:#000000;display:block;overflow:visible;visibility:visible;opacity:0.5;fill:none;stroke:url(#linearGradient5025);stroke-width:0.99999994;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker:none;enable-background:accumulate" + ry="0.49999997" + rx="0.5" + id="rect5786" + height="21.999998" /> + <path + style="color:#000000;display:block;overflow:visible;visibility:visible;fill:url(#linearGradient4997);fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.34509804;marker:none;enable-background:accumulate" + id="path5584" + d="m 18.5,7.483431 c 0.97227,0.04419 1,-1 1,-1 l -2,-2 7e-5,-1 c 0,0 -0.0304,-1.955806 -2,-2 l -4,0.03108 c -2.0963,0 -2.00906,2.001117 -2.00906,2.001117 l 0.009,0.967803 -2,2 c 0,0 0.11613,0.955805 0.99999,0.999999 z" /> + <path + style="color:#000000;display:inline;overflow:visible;visibility:visible;fill:url(#linearGradient5001);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;marker:none;enable-background:accumulate" + id="path5377" + d="m 11,5.983432 0,-2 c -0.0394,-0.631556 0.20798,-1.033615 1,-1 l 3,0 c 0.46307,0.07386 0.94201,0.11598 1,1 l 0,2 -1,-2 -3,0 z" /> + <path + style="opacity:0.4;fill:none;fill-rule:evenodd;stroke:#ffffff;stroke-width:1px;stroke-linecap:round;stroke-linejoin:miter;stroke-opacity:1" + d="m 8.507121,6.483431 10,0" + id="path4353" /> + <rect + style="opacity:0.4;fill:none;fill-opacity:1;stroke:url(#linearGradient4365);stroke-width:1;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + id="rect4357" + width="6" + height="4" + x="10.5" + y="2.4834309" + rx="1" + ry="1" /> + <path + id="path4453" + d="m 9.507121,5.483431 8,0" + style="opacity:0.1;fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:round;stroke-linejoin:miter;stroke-opacity:1" /> + <path + style="opacity:0.05;fill:none;fill-rule:evenodd;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:round;stroke-opacity:1" + d="m 11.5,27.983431 0,-19.5 c 0,0 0,-0.9375 1,-1 l 10.5,0" + id="path4465" /> + </g> + <g + transform="translate(-2,-12.016569)" + id="g4489"> + <rect + style="display:inline;overflow:visible;visibility:visible;opacity:0.15;fill:url(#linearGradient4480);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;marker:none" + id="rect4474" + y="40" + x="6.9500027" + height="2" + width="22.100021" /> + <path + style="display:inline;overflow:visible;visibility:visible;opacity:0.15;fill:url(#radialGradient4482);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;marker:none" + id="path4476" + d="m 6.950002,40.000086 c 0,0 0,1.99989 0,1.99989 C 6.143387,42.003776 5,41.551902 5,40.999902 c 0,-0.552 0.900121,-0.999816 1.950002,-0.999816 z" /> + <path + style="display:inline;overflow:visible;visibility:visible;opacity:0.15;fill:url(#radialGradient4484);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;marker:none" + id="path4478" + d="m 29.050024,40.000086 c 0,0 0,1.99989 0,1.99989 0.806614,0.0038 1.950002,-0.448074 1.950002,-1.000074 0,-0.552 -0.900122,-0.999816 -1.950002,-0.999816 z" /> + </g> + <g + id="layer1-8" + transform="translate(9.0000004,-1)"> + <rect + style="display:inline;overflow:visible;visibility:visible;opacity:0.15;fill:url(#linearGradient3175);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;marker:none" + id="rect2879-0" + y="30" + x="3.5000007" + height="2" + width="16.999998" /> + <path + style="display:inline;overflow:visible;visibility:visible;opacity:0.15;fill:url(#radialGradient3177);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;marker:none" + id="path2881-6" + d="m 3.4999999,30.000085 c 0,0 0,1.999891 0,1.999891 C 2.8795275,32.003776 2,31.551901 2,30.999901 2,30.447902 2.6924,30.000085 3.4999999,30.000085 Z" /> + <path + style="display:inline;overflow:visible;visibility:visible;opacity:0.15;fill:url(#radialGradient3179);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:1;marker:none" + id="path2883-8" + d="m 20.5,30.000085 c 0,0 0,1.999891 0,1.999891 0.620472,0.0038 1.5,-0.448075 1.5,-1.000075 0,-0.551999 -0.692402,-0.999816 -1.5,-0.999816 z" /> + <path + style="display:inline;fill:url(#linearGradient3181);fill-opacity:1;stroke:#000000;stroke-width:0.99992186;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:0.34509804" + id="path4160-3-9" + d="m 3.4999601,9.4999569 c 3.8955809,0 17.0000589,0.00136 17.0000589,0.00136 l 2.1e-5,20.9987161 c 0,0 -11.3333862,0 -17.0000799,0 0,-7.000018 0,-14.000035 0,-21.0000538 z" /> + <path + style="fill:none;stroke:url(#linearGradient3185);stroke-width:1;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + id="rect6741-1-2" + d="m 19.5,29.5 -15.0000004,0 0,-19 L 19.5,10.5 Z" /> + </g> + <g + id="g4345"> + <path + d="m 7.750245,23.072131 a 6,4.0000002 0 1 1 12,0 6,4.0000002 0 0 1 -12,0 z" + id="path3501" + style="display:inline;overflow:visible;visibility:visible;opacity:0.14117647;fill:url(#radialGradient3173);fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:1;marker:none" /> + <path + d="m 11.832248,12.017552 c -4.9802216,3.367056 -2.0511186,9.550728 3.5,9.5 l 0,3.000485 7,-5 -7,-5 0,2.976351 c -3.580248,0.139062 -5.5595156,-3.12742 -3,-5.476836 z" + id="path3503" + style="display:block;overflow:visible;visibility:visible;fill:url(#linearGradient3162);fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.96392483;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:7;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker:none" /> + <path + d="m 10.875586,13.759279 c -1.7568516,2.058862 -0.225017,7.434574 5.395063,6.699241 l 0.0616,2.197396 4.369328,-3.137879 -4.369328,-3.064428 0,2.059765 c -6.167442,0.329165 -5.981488,-3.921804 -5.456662,-4.754095 z" + id="path3505" + style="color:#000000;clip-rule:nonzero;display:block;overflow:visible;visibility:visible;opacity:0.8;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill:none;fill-opacity:1;fill-rule:nonzero;stroke:url(#linearGradient3855);stroke-width:0.96400005;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:7;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker:none;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" /> + <path + d="m 11.832248,12.017552 c -4.9802216,3.367056 -2.0511186,9.550728 3.5,9.5 l 0,3.000485 6.999999,-5 -6.999999,-5 0,2.976351 c -3.580248,0.139062 -5.5595156,-3.12742 -3,-5.476836 z" + id="path3503-4" + style="color:#000000;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:0.5;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;fill:none;fill-opacity:1;fill-rule:nonzero;stroke:#0f5a00;stroke-width:1;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker:none;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate" /> + </g> +</svg> diff --git a/loleaflet/src/control/Control.MobileInput.js b/loleaflet/src/control/Control.MobileInput.js new file mode 100644 index 000000000..65351edaa --- /dev/null +++ b/loleaflet/src/control/Control.MobileInput.js @@ -0,0 +1,252 @@ +/* -*- js-indent-level: 8 -*- */ +/* + * L.Control.MobileInput. + */ +L.Control.MobileInput = L.Control.extend({ + options: { + position: 'bottomleft' + }, + + initialize: function (options) { + L.setOptions(this, options); + }, + + onAdd: function () { + this._initLayout(); + return this._container; + }, + + onGotFocus: function () { + this._map._docLayer._updateCursorPos(); + }, + + onLostFocus: function () { + this._textArea.value = ''; + this._container.style.visibility = 'hidden'; + this._map.removeLayer(this._map._docLayer._cursorMarker); + }, + + focus: function(focus) { + if (this._map._permission !== 'edit') { + return; + } + + if (focus === false) { + this._textArea.blur(); + this._container.style.visibility = 'hidden'; + } else { + this._container.style.marginLeft = (this._map.getSize().x - this._container.offsetWidth) / 2 + 'px'; + this._container.style.visibility = ''; + this._textArea.focus(); + } + }, + + select: function() { + this._textArea.select(); + }, + + getValue: function() { + return this._textArea.value; + }, + + setValue: function(val) { + this._textArea.value = val; + }, + + activeElement: function () { + return this._textArea; + }, + + _initLayout: function () { + var tagTd = 'td', + constOff = 'off', + stopEvents = 'touchstart touchmove touchend mousedown mousemove mouseout mouseover mouseup mousewheel click scroll', + container = this._container = L.DomUtil.create('table', 'loleaflet-mobile-table'); + container.style.visibility = 'hidden'; + + var tbody = L.DomUtil.create('tbody', '', container), + tr = L.DomUtil.create('tr', '', tbody), + td = L.DomUtil.create(tagTd, '', tr); + this._textArea = L.DomUtil.create('input', 'loleaflet-mobile-input', td); + this._textArea.setAttribute('type', 'text'); + this._textArea.setAttribute('autocorrect', constOff); + this._textArea.setAttribute('autocapitalize', constOff); + this._textArea.setAttribute('autocomplete', constOff); + this._textArea.setAttribute('spellcheck', 'false'); + L.DomEvent.on(this._textArea, stopEvents, L.DomEvent.stopPropagation) + .on(this._textArea, 'keydown keypress keyup', this.onKeyEvents, this) + .on(this._textArea, 'compositionstart compositionupdate compositionend textInput', this.onIMEEvents, this) + .on(this._textArea, 'cut', this.onNativeCut, this) + .on(this._textArea, 'copy', this.onNativeCopy, this) + .on(this._textArea, 'paste', this.onNativePaste, this) + .on(this._textArea, 'focus', this.onGotFocus, this) + .on(this._textArea, 'blur', this.onLostFocus, this); + + var cut = L.DomUtil.create(tagTd, 'loleaflet-mobile-button loleaflet-mobile-cut', tr); + L.DomEvent.on(cut, stopEvents, L.DomEvent.stopPropagation) + .on(cut, 'mousedown', L.DomEvent.preventDefault) + .on(cut, 'mouseup', this.onInternalCut, this); + var copy = L.DomUtil.create(tagTd, 'loleaflet-mobile-button loleaflet-mobile-copy', tr); + L.DomEvent.on(copy, stopEvents, L.DomEvent.stopPropagation) + .on(copy, 'mousedown', L.DomEvent.preventDefault) + .on(copy, 'mouseup', this.onInternalCopy, this); + var paste = L.DomUtil.create(tagTd, 'loleaflet-mobile-button loleaflet-mobile-paste', tr); + L.DomEvent.on(paste, stopEvents, L.DomEvent.stopPropagation) + .on(paste, 'mousedown', L.DomEvent.preventDefault) + .on(paste, 'mouseup', this.onInternalPaste, this); + this._map.on('mousedown', this.onClick, this); + }, + + onClick: function () { + this._textArea.value = ''; + }, + + onKeyEvents: function (e) { + var keyCode = e.keyCode, + charCode = e.charCode, + handler = this._map.keyboard, + docLayer = this._map._docLayer, + unoKeyCode = handler._toUNOKeyCode(keyCode); + + this._keyHandled = this._keyHandled || false; + docLayer._resetPreFetching(); + if (handler._ignoreKeyEvent({originalEvent: e})) { + // key ignored + } + else if (e.type === 'keydown') { + this._keyHandled = false; + if (handler.handleOnKeyDownKeys[keyCode] && charCode === 0) { + docLayer._postKeyboardEvent('input', charCode, unoKeyCode); + } + } + else if ((e.type === 'keypress') && (!handler.handleOnKeyDownKeys[keyCode] || charCode !== 0)) { + if (charCode === keyCode && charCode !== 13) { + // Chrome sets keyCode = charCode for printable keys + // while LO requires it to be 0 + keyCode = 0; + unoKeyCode = handler._toUNOKeyCode(keyCode); + } + + docLayer._postKeyboardEvent('input', charCode, unoKeyCode); + this._keyHandled = true; + } + else if (e.type === 'keyup') { + docLayer._postKeyboardEvent('up', charCode, unoKeyCode); + this._keyHandled = true; + } + L.DomEvent.stopPropagation(e); + }, + + onIMEEvents: function (e) { + var map = this._map; + if (e.type === 'compositionstart' || e.type === 'compositionupdate') { + this._isComposing = true; // we are starting composing with IME + var txt = ''; + for (var i = 0; i < e.data.length; i++) { + txt += e.data[i]; + } + if (txt) { + map._docLayer._postCompositionEvent(0, 'input', txt); + } + } + + if (e.type === 'compositionend') { + this._isComposing = false; // stop of composing with IME + // get the composited char codes + // clear the input now - best to do this ASAP so the input + // is clear for the next word + //map._clipboardContainer.setValue(''); + // Set all keycodes to zero + map._docLayer._postCompositionEvent(0, 'end', ''); + } + + if (e.type === 'textInput' && !this._keyHandled) { + // Hack for making space and spell-check text insert work + // in Chrome (on Andorid) or Chrome with IME. + // + // Chrome (Android) IME triggers keyup/keydown input with + // code 229 when hitting space (as with all composiiton events) + // with addition to 'textinput' event, in which we only see that + // space was entered. Similar situation is also when inserting + // a soft-keyboard spell-check item - it is visible only with + // 'textinput' event (no composition event is fired). + // To make this work we need to insert textinput.data here.. + // + // TODO: Maybe make sure this is only triggered when keydown has + // 229 code. Also we need to detect that composition was overriden + // (part or whole word deleted) with the spell-checked word. (for + // example: enter 'tar' and with spell-check correct that to 'rat') + var data = e.data; + for (var idx = 0; idx < data.length; idx++) { + map._docLayer._postKeyboardEvent('input', data[idx].charCodeAt(), 0); + } + } + L.DomEvent.stopPropagation(e); + }, + + onNativeCut: function (e) { + this._map._socket.sendMessage('uno .uno:Cut'); + L.DomEvent.stopPropagation(e); + }, + + onNativeCopy: function (e) { + this._map._socket.sendMessage('uno .uno:Copy'); + L.DomEvent.stopPropagation(e); + }, + + onNativePaste: function (e) { + if (e.clipboardData) { // Standard + this._map._docLayer._dataTransferToDocument(e.clipboardData, /* preferInternal = */ true); + } + else if (window.clipboardData) { // IE 11 + this._map._docLayer._dataTransferToDocument(window.clipboardData, /* preferInternal = */ true); + } + L.DomEvent.preventDefault(e); + L.DomEvent.stopPropagation(e); + }, + + onInternalCut: function (e) { + if (this._map._docLayer._selectionTextContent) { + this._textArea.value = this._map._docLayer._selectionTextContent; + this._textArea.select(); + this._textArea.setSelectionRange(0, this._textArea.value.length); + try { + document.execCommand('cut'); + } + catch (err) { + console.log(err); + } + this._textArea.value = ''; + } + this._map._socket.sendMessage('uno .uno:Cut'); + L.DomEvent.preventDefault(e); + L.DomEvent.stopPropagation(e); + }, + + onInternalCopy: function (e) { + if (this._map._docLayer._selectionTextContent) { + this._textArea.value = this._map._docLayer._selectionTextContent; + this._textArea.select(); + this._textArea.setSelectionRange(0, this._textArea.value.length); + try { + document.execCommand('copy'); + } + catch (err) { + console.log(err); + } + } + this._map._socket.sendMessage('uno .uno:Copy'); + L.DomEvent.preventDefault(e); + L.DomEvent.stopPropagation(e); + }, + + onInternalPaste: function (e) { + this._map._socket.sendMessage('uno .uno:Paste'); + L.DomEvent.preventDefault(e); + L.DomEvent.stopPropagation(e); + } +}); + +L.control.mobileInput = function (options) { + return new L.Control.MobileInput(options); +}; diff --git a/loleaflet/src/map/Map.js b/loleaflet/src/map/Map.js index 66493ec2e..ca842afc5 100644 --- a/loleaflet/src/map/Map.js +++ b/loleaflet/src/map/Map.js @@ -88,8 +88,12 @@ L.Map = L.Evented.extend({ this._socket = L.socket(this); this._progressBar = L.progressOverlay(this.getCenter(), L.point(150, 25)); - this._clipboardContainer = L.clipboardContainer(); - this.addLayer(this._clipboardContainer); + if (L.Browser.mobile) { + this._clipboardContainer = L.control.mobileInput().addTo(this); + } else { + this._clipboardContainer = L.clipboardContainer(); + this.addLayer(this._clipboardContainer); + } // When all these conditions are met, fire statusindicator:initializationcomplete this.initConditions = { _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits