diff --git a/sflphone-gtk/configure.ac b/sflphone-gtk/configure.ac index a1fc282d70ae2470414a07d962e6887dc61117e1..38500dda9548612c1e5e33346fae835d709534ab 100644 --- a/sflphone-gtk/configure.ac +++ b/sflphone-gtk/configure.ac @@ -15,7 +15,7 @@ AC_ARG_WITH(debug, [with_debug=no] ) if test "x$with_debug" = "xfull" -o "x$with_debug" = "xyes"; then - CFLAGS="$CFLAGS -g -DDEBUG" + CFLAGS="$CFLAGS -g -DDEBUG -Wall -Werror " fi AC_PROG_CC diff --git a/sflphone-gtk/pixmaps/Makefile.am b/sflphone-gtk/pixmaps/Makefile.am index e9dd98ea6784b1bb221c633353cd7f040070c6b7..2f1775b8b96ebd2c8dc0585eed55bf586d3575df 100644 --- a/sflphone-gtk/pixmaps/Makefile.am +++ b/sflphone-gtk/pixmaps/Makefile.am @@ -1,3 +1,3 @@ pixmapsdir = $(datadir)/pixmaps -pixmaps_DATA = sflphone.png accept.svg current.svg transfert.svg hang_up.svg hold.svg unhold.svg refuse.svg call.svg ring.svg dial.svg +pixmaps_DATA = sflphone.png accept.svg current.svg transfert.svg hang_up.svg hold.svg unhold.svg refuse.svg call.svg ring.svg dial.svg mic.svg speaker.svg EXTRA_DIST = $(pixmaps_DATA) diff --git a/sflphone-gtk/pixmaps/dial.svg b/sflphone-gtk/pixmaps/dial.svg new file mode 100644 index 0000000000000000000000000000000000000000..f7e490dfb66df7253280e5a97064c6986d82a9e2 --- /dev/null +++ b/sflphone-gtk/pixmaps/dial.svg @@ -0,0 +1,546 @@ +<?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://web.resource.org/cc/" + 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="24" + height="24" + id="svg2" + sodipodi:version="0.32" + inkscape:version="0.45" + version="1.0" + sodipodi:docbase="/home/plbeaudoin/SFLPhone/sflphone/sflphone-gtk/pixmaps" + sodipodi:docname="dial.svg" + inkscape:output_extension="org.inkscape.output.svg.inkscape" + sodipodi:modified="true"> + <defs + id="defs4"> + <linearGradient + id="linearGradient4045"> + <stop + style="stop-color:#ffffff;stop-opacity:0" + offset="0" + id="stop4047" /> + <stop + style="stop-color:#fcfbcb;stop-opacity:0.69469029;" + offset="1" + id="stop4049" /> + </linearGradient> + <linearGradient + id="linearGradient4269"> + <stop + style="stop-color:#1db000;stop-opacity:1;" + offset="0" + id="stop4271" /> + <stop + style="stop-color:#1db000;stop-opacity:0;" + offset="1" + id="stop4273" /> + </linearGradient> + <linearGradient + id="linearGradient4183"> + <stop + id="stop4185" + offset="0" + style="stop-color:#1db000;stop-opacity:1;" /> + <stop + id="stop4187" + offset="1" + style="stop-color:#0f5f00;stop-opacity:1;" /> + </linearGradient> + <linearGradient + id="linearGradient4167"> + <stop + style="stop-color:#80000e;stop-opacity:1;" + offset="0" + id="stop4169" /> + <stop + style="stop-color:#b00014;stop-opacity:0;" + offset="1" + id="stop4171" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4183" + id="linearGradient4181" + x1="10.57493" + y1="12.115559" + x2="-0.68574232" + y2="12.115559" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(1.262691,-1.100752)" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4183" + id="linearGradient4195" + x1="31.692968" + y1="11.264216" + x2="23.888865" + y2="13.35532" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(-0.947018,-0.885198)" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4183" + id="linearGradient4203" + x1="15.647213" + y1="2.7028866" + x2="14.013638" + y2="10.576721" + gradientUnits="userSpaceOnUse" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4269" + id="linearGradient4256" + x1="7.8517423" + y1="15.912388" + x2="7.1114841" + y2="11.597325" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(0.426158,-2.762136)" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4269" + id="linearGradient4260" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(-1,0,0,1,32.04188,-2.86473)" + x1="2.0651877" + y1="12.625902" + x2="6.8378897" + y2="13.920053" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4183" + id="linearGradient2224" + x1="16.826796" + y1="6.7288713" + x2="27.5625" + y2="22.512505" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0.875025,0,0,0.875025,0.666703,0.177907)" /> + <linearGradient + gradientTransform="matrix(1.62913,0,0,-1.62913,-10.06608,39.71987)" + gradientUnits="userSpaceOnUse" + y2="6.6770978" + x2="15.806232" + y1="22.874208" + x1="15.630395" + id="linearGradient4275" + xlink:href="#linearGradient4269" + inkscape:collect="always" /> + <linearGradient + y2="13.920053" + x2="6.8378897" + y1="12.625902" + x1="2.0651877" + gradientTransform="matrix(-1,0,0,1,32.04188,-2.86473)" + gradientUnits="userSpaceOnUse" + id="linearGradient1388" + xlink:href="#linearGradient4269" + inkscape:collect="always" /> + <linearGradient + gradientTransform="translate(0.426158,-2.762136)" + gradientUnits="userSpaceOnUse" + y2="13.920053" + x2="6.8378897" + y1="12.625902" + x1="2.0651877" + id="linearGradient1386" + xlink:href="#linearGradient4269" + inkscape:collect="always" /> + <linearGradient + gradientUnits="userSpaceOnUse" + y2="10.576721" + x2="14.013638" + y1="2.7028866" + x1="15.647213" + id="linearGradient1384" + xlink:href="#linearGradient4183" + inkscape:collect="always" /> + <linearGradient + gradientTransform="translate(-0.947018,-0.885198)" + gradientUnits="userSpaceOnUse" + y2="12.535715" + x2="31.31678" + y1="12.535715" + x1="24.397505" + id="linearGradient1382" + xlink:href="#linearGradient4183" + inkscape:collect="always" /> + <linearGradient + gradientTransform="translate(1.262691,-1.100752)" + gradientUnits="userSpaceOnUse" + y2="12.825893" + x2="7.9239235" + y1="12.825893" + x1="1.0046476" + id="linearGradient1380" + xlink:href="#linearGradient4183" + inkscape:collect="always" /> + <linearGradient + id="linearGradient1374"> + <stop + id="stop1376" + offset="0" + style="stop-color:#80000e;stop-opacity:1;" /> + <stop + id="stop1378" + offset="1" + style="stop-color:#b00014;stop-opacity:0;" /> + </linearGradient> + <linearGradient + id="linearGradient1368"> + <stop + style="stop-color:#26b000;stop-opacity:1;" + offset="0" + id="stop1370" /> + <stop + style="stop-color:#145f00;stop-opacity:1;" + offset="1" + id="stop1372" /> + </linearGradient> + <linearGradient + id="linearGradient1362"> + <stop + id="stop1364" + offset="0" + style="stop-color:#26b000;stop-opacity:1;" /> + <stop + id="stop1366" + offset="1" + style="stop-color:#26b000;stop-opacity:0;" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4183" + id="linearGradient1406" + gradientUnits="userSpaceOnUse" + x1="15.647213" + y1="2.7028866" + x2="14.013638" + y2="10.576721" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4183" + id="linearGradient1408" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(1.262691,-1.100752)" + x1="10.57493" + y1="12.115559" + x2="-0.68574232" + y2="12.115559" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4183" + id="linearGradient1410" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(-0.947018,-0.885198)" + x1="31.692968" + y1="11.264216" + x2="23.888865" + y2="13.35532" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4269" + id="linearGradient1412" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(0.426158,-2.762136)" + x1="7.8517423" + y1="15.912388" + x2="7.1114841" + y2="11.597325" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4269" + id="linearGradient1414" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(-1,0,0,1,32.04188,-2.86473)" + x1="2.0651877" + y1="12.625902" + x2="6.8378897" + y2="13.920053" /> + <radialGradient + inkscape:collect="always" + xlink:href="#linearGradient4045" + id="radialGradient3208" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0.418975,0,0,0.418975,11.20548,5.727248)" + spreadMethod="reflect" + cx="19.285715" + cy="9.8571424" + fx="19.285715" + fy="9.8571424" + r="10.885714" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient1368" + id="linearGradient3280" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(0,-3.0304576)" + x1="3.9194174" + y1="7.8426361" + x2="6.5609155" + y2="14.340417" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient1368" + id="linearGradient3282" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(6.2851708,-3.030458)" + x1="3.9194174" + y1="7.8426361" + x2="6.5609155" + y2="14.340417" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient1368" + id="linearGradient3284" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(12.57034,-3.030458)" + x1="3.9194174" + y1="7.8426361" + x2="6.5609155" + y2="14.340417" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient1368" + id="linearGradient3292" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(5.8366603,5.1770313)" + x1="3.9194174" + y1="7.8426361" + x2="6.5609155" + y2="14.340417" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient1368" + id="linearGradient3294" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(12.121831,5.1770309)" + x1="3.9194174" + y1="7.8426361" + x2="6.5609155" + y2="14.340417" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient1368" + id="linearGradient3296" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(18.407,5.1770309)" + x1="3.9194174" + y1="7.8426361" + x2="6.5609155" + y2="14.340417" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient1368" + id="linearGradient3298" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(0,-3.0304576)" + x1="3.9194174" + y1="7.8426361" + x2="6.5609155" + y2="14.340417" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient1368" + id="linearGradient3300" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(6.2851708,-3.030458)" + x1="3.9194174" + y1="7.8426361" + x2="6.5609155" + y2="14.340417" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient1368" + id="linearGradient3302" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(12.57034,-3.030458)" + x1="3.9194174" + y1="7.8426361" + x2="6.5609155" + y2="14.340417" /> + </defs> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="7.919596" + inkscape:cx="33.634789" + inkscape:cy="18.879033" + inkscape:document-units="px" + inkscape:current-layer="layer1" + width="32px" + height="32px" + showguides="true" + inkscape:guide-bbox="true" + inkscape:window-width="1014" + inkscape:window-height="691" + inkscape:window-x="901" + inkscape:window-y="49" /> + <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" /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Calque 1" + inkscape:groupmode="layer" + id="layer1"> + <g + id="g3259" + transform="matrix(0.9652036,0,0,0.9652036,-1.6371275,-0.5352586)"> + <rect + ry="0.73531199" + rx="0.73531199" + y="5.3121786" + x="3.661803" + height="3.914341" + width="3.914341" + id="rect2210" + style="opacity:1;fill:url(#linearGradient3298);fill-opacity:1;stroke:#137300;stroke-width:0.5;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + <rect + ry="0.73531199" + rx="0.73531199" + y="5.3121786" + x="9.9469738" + height="3.914341" + width="3.914341" + id="rect3191" + style="opacity:1;fill:url(#linearGradient3300);fill-opacity:1;stroke:#137300;stroke-width:0.5;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + <rect + ry="0.73531199" + rx="0.73531199" + y="5.3121786" + x="16.232143" + height="3.914341" + width="3.914341" + id="rect3195" + style="opacity:1;fill:url(#linearGradient3302);fill-opacity:1;stroke:#137300;stroke-width:0.5;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </g> + <g + id="g3222" + transform="matrix(0.9652036,0,0,0.9652036,-7.2433958,-2.1004447)" + style="opacity:1"> + <rect + ry="0.73531199" + rx="0.73531199" + y="13.519668" + x="9.4984636" + height="3.914341" + width="3.914341" + id="rect3210" + style="opacity:1;fill:url(#linearGradient3292);fill-opacity:1;stroke:#137300;stroke-width:0.5;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + <rect + ry="0.73531199" + rx="0.73531199" + y="13.519668" + x="15.783634" + height="3.914341" + width="3.914341" + id="rect3212" + style="opacity:1;fill:url(#linearGradient3294);fill-opacity:1;stroke:#137300;stroke-width:0.5;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + <rect + ry="0.73531199" + rx="0.73531199" + y="13.519668" + x="22.068804" + height="3.914341" + width="3.914341" + id="rect3214" + style="opacity:1;fill:url(#linearGradient3296);fill-opacity:1;stroke:#137300;stroke-width:0.5;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </g> + <g + id="g3264" + transform="matrix(0.9652036,0,0,0.9652036,-1.6234791,12.178165)" + style="opacity:1"> + <rect + ry="0.73531199" + rx="0.73531199" + y="5.3121786" + x="3.661803" + height="3.914341" + width="3.914341" + id="rect3266" + style="opacity:1;fill:url(#linearGradient3280);fill-opacity:1;stroke:#137300;stroke-width:0.5;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + <rect + ry="0.73531199" + rx="0.73531199" + y="5.3121786" + x="9.9469738" + height="3.914341" + width="3.914341" + id="rect3268" + style="opacity:1;fill:url(#linearGradient3282);fill-opacity:1;stroke:#137300;stroke-width:0.5;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + <rect + ry="0.73531199" + rx="0.73531199" + y="5.3121786" + x="16.232143" + height="3.914341" + width="3.914341" + id="rect3270" + style="opacity:1;fill:url(#linearGradient3284);fill-opacity:1;stroke:#137300;stroke-width:0.5;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </g> + <g + id="g3199" + transform="translate(-0.3156731,-1.2626907)"> + <path + transform="matrix(0.723409,0,0,0.723409,4.2981133,0.64261)" + d="M 27.321429 9.8571424 A 8.0357141 8.0357141 0 1 1 11.250001,9.8571424 A 8.0357141 8.0357141 0 1 1 27.321429 9.8571424 z" + sodipodi:ry="8.0357141" + sodipodi:rx="8.0357141" + sodipodi:cy="9.8571424" + sodipodi:cx="19.285715" + id="path3162" + style="fill:url(#radialGradient3208);fill-opacity:1;stroke:none;stroke-width:5.69999981;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1" + sodipodi:type="arc" /> + <path + sodipodi:nodetypes="cc" + id="path2257" + d="M 18.249576,5.2432362 L 18.249576,1.880704" + style="fill:none;fill-opacity:0.75;fill-rule:evenodd;stroke:#2a6f1d;stroke-width:0.51589537px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:0.49408282" /> + <path + sodipodi:nodetypes="cc" + id="path2259" + d="M 20.1824,6.380202 L 23.094437,4.6989359" + style="fill:none;fill-opacity:0.75;fill-rule:evenodd;stroke:#2a6f1d;stroke-width:0.51589537px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:0.49408282" /> + <path + sodipodi:nodetypes="cc" + id="path2261" + d="M 20.1824,8.8683213 L 23.094437,10.549588" + style="fill:none;fill-opacity:0.75;fill-rule:evenodd;stroke:#2a6f1d;stroke-width:0.51589537px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:0.49408282" /> + <path + sodipodi:nodetypes="cc" + id="path2263" + d="M 18.249576,10.005288 L 18.249576,13.36782" + style="fill:none;fill-opacity:0.75;fill-rule:evenodd;stroke:#2a6f1d;stroke-width:0.51589537px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:0.49408282" /> + <path + sodipodi:nodetypes="cc" + id="path2265" + d="M 16.332464,8.868322 L 13.420426,10.549587" + style="fill:none;fill-opacity:0.75;fill-rule:evenodd;stroke:#2a6f1d;stroke-width:0.51589537px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:0.49408282" /> + <path + sodipodi:nodetypes="cc" + id="path2267" + d="M 16.332464,6.3802018 L 13.420427,4.698936" + style="fill:none;fill-opacity:0.75;fill-rule:evenodd;stroke:#2a6f1d;stroke-width:0.51589537px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:0.49408282" /> + </g> + </g> +</svg> diff --git a/sflphone-gtk/pixmaps/mic.svg b/sflphone-gtk/pixmaps/mic.svg new file mode 100644 index 0000000000000000000000000000000000000000..ec1ba1afbc794eb580d59abad311f01cabe4facc --- /dev/null +++ b/sflphone-gtk/pixmaps/mic.svg @@ -0,0 +1,370 @@ +<?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://web.resource.org/cc/" + 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="16" + height="16" + id="svg2" + sodipodi:version="0.32" + inkscape:version="0.45" + version="1.0" + sodipodi:docbase="/home/plbeaudoin/SFLPhone/sflphone/sflphone-gtk/pixmaps" + sodipodi:docname="mic.svg" + inkscape:output_extension="org.inkscape.output.svg.inkscape" + sodipodi:modified="true"> + <defs + id="defs4"> + <linearGradient + id="linearGradient3370"> + <stop + style="stop-color:#d7d7d7;stop-opacity:1;" + offset="0" + id="stop3372" /> + <stop + style="stop-color:#7c7c7c;stop-opacity:1;" + offset="1" + id="stop3374" /> + </linearGradient> + <linearGradient + id="linearGradient3362"> + <stop + style="stop-color:#000000;stop-opacity:1;" + offset="0" + id="stop3364" /> + <stop + style="stop-color:#ffffff;stop-opacity:1;" + offset="1" + id="stop3366" /> + </linearGradient> + <linearGradient + id="linearGradient4045"> + <stop + style="stop-color:#ffffff;stop-opacity:0" + offset="0" + id="stop4047" /> + <stop + style="stop-color:#fcfbcb;stop-opacity:1" + offset="1" + id="stop4049" /> + </linearGradient> + <linearGradient + id="linearGradient4269"> + <stop + style="stop-color:#1db000;stop-opacity:1;" + offset="0" + id="stop4271" /> + <stop + style="stop-color:#1db000;stop-opacity:0;" + offset="1" + id="stop4273" /> + </linearGradient> + <linearGradient + id="linearGradient4183"> + <stop + id="stop4185" + offset="0" + style="stop-color:#1db000;stop-opacity:1;" /> + <stop + id="stop4187" + offset="1" + style="stop-color:#0f5f00;stop-opacity:1;" /> + </linearGradient> + <linearGradient + id="linearGradient4167"> + <stop + style="stop-color:#80000e;stop-opacity:1;" + offset="0" + id="stop4169" /> + <stop + style="stop-color:#b00014;stop-opacity:0;" + offset="1" + id="stop4171" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4183" + id="linearGradient2224" + x1="16.826796" + y1="6.7288713" + x2="27.5625" + y2="22.512505" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0.875025,0,0,0.875025,0.666703,0.177907)" /> + <linearGradient + gradientTransform="matrix(1.62913,0,0,-1.62913,-10.06608,39.71987)" + gradientUnits="userSpaceOnUse" + y2="6.6770978" + x2="15.806232" + y1="22.874208" + x1="15.630395" + id="linearGradient4275" + xlink:href="#linearGradient4269" + inkscape:collect="always" /> + <linearGradient + y2="13.920053" + x2="6.8378897" + y1="12.625902" + x1="2.0651877" + gradientTransform="matrix(-1,0,0,1,32.04188,-2.86473)" + gradientUnits="userSpaceOnUse" + id="linearGradient1388" + xlink:href="#linearGradient4269" + inkscape:collect="always" /> + <linearGradient + gradientTransform="translate(0.426158,-2.762136)" + gradientUnits="userSpaceOnUse" + y2="13.920053" + x2="6.8378897" + y1="12.625902" + x1="2.0651877" + id="linearGradient1386" + xlink:href="#linearGradient4269" + inkscape:collect="always" /> + <linearGradient + gradientUnits="userSpaceOnUse" + y2="10.576721" + x2="14.013638" + y1="2.7028866" + x1="15.647213" + id="linearGradient1384" + xlink:href="#linearGradient4183" + inkscape:collect="always" /> + <linearGradient + gradientTransform="translate(-0.947018,-0.885198)" + gradientUnits="userSpaceOnUse" + y2="12.535715" + x2="31.31678" + y1="12.535715" + x1="24.397505" + id="linearGradient1382" + xlink:href="#linearGradient4183" + inkscape:collect="always" /> + <linearGradient + gradientTransform="translate(1.262691,-1.100752)" + gradientUnits="userSpaceOnUse" + y2="12.825893" + x2="7.9239235" + y1="12.825893" + x1="1.0046476" + id="linearGradient1380" + xlink:href="#linearGradient4183" + inkscape:collect="always" /> + <linearGradient + id="linearGradient1374"> + <stop + id="stop1376" + offset="0" + style="stop-color:#80000e;stop-opacity:1;" /> + <stop + id="stop1378" + offset="1" + style="stop-color:#b00014;stop-opacity:0;" /> + </linearGradient> + <linearGradient + id="linearGradient1368"> + <stop + style="stop-color:#26b000;stop-opacity:1;" + offset="0" + id="stop1370" /> + <stop + style="stop-color:#145f00;stop-opacity:1;" + offset="1" + id="stop1372" /> + </linearGradient> + <linearGradient + id="linearGradient1362"> + <stop + id="stop1364" + offset="0" + style="stop-color:#26b000;stop-opacity:1;" /> + <stop + id="stop1366" + offset="1" + style="stop-color:#26b000;stop-opacity:0;" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4183" + id="linearGradient1406" + gradientUnits="userSpaceOnUse" + x1="15.647213" + y1="2.7028866" + x2="14.013638" + y2="10.576721" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4183" + id="linearGradient1408" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(1.262691,-1.100752)" + x1="10.57493" + y1="12.115559" + x2="-0.68574232" + y2="12.115559" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4183" + id="linearGradient1410" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(-0.947018,-0.885198)" + x1="31.692968" + y1="11.264216" + x2="23.888865" + y2="13.35532" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4269" + id="linearGradient1412" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(0.426158,-2.762136)" + x1="7.8517423" + y1="15.912388" + x2="7.1114841" + y2="11.597325" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4269" + id="linearGradient1414" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(-1,0,0,1,32.04188,-2.86473)" + x1="2.0651877" + y1="12.625902" + x2="6.8378897" + y2="13.920053" /> + <radialGradient + inkscape:collect="always" + xlink:href="#linearGradient4045" + id="radialGradient4051" + cx="19.285715" + cy="9.8571424" + fx="19.285715" + fy="9.8571424" + r="10.885714" + gradientUnits="userSpaceOnUse" + spreadMethod="reflect" + gradientTransform="matrix(0.418975,0,0,0.418975,11.20548,5.727248)" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient3362" + id="linearGradient3368" + x1="16.037382" + y1="3.6340783" + x2="0.9781428" + y2="5.2185812" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0.7869324,0.7869324,-0.7869324,0.7869324,-2.5317345,-1.0086642)" /> + <radialGradient + inkscape:collect="always" + xlink:href="#linearGradient3370" + id="radialGradient3392" + cx="5.5446553" + cy="6.5377574" + fx="5.5446553" + fy="6.5377574" + r="3.7829957" + gradientUnits="userSpaceOnUse" + spreadMethod="pad" + gradientTransform="matrix(0.6570643,0.4203728,-0.5183425,0.810196,5.2902577,-1.0899297)" /> + </defs> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="1" + inkscape:cx="24.480574" + inkscape:cy="2.8150254" + inkscape:document-units="px" + inkscape:current-layer="layer1" + width="16px" + height="16px" + showguides="true" + inkscape:guide-bbox="true" + inkscape:window-width="1014" + inkscape:window-height="691" + inkscape:window-x="336" + inkscape:window-y="282"> + <sodipodi:guide + orientation="vertical" + position="24.821428" + id="guide3146" /> + </sodipodi:namedview> + <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" /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Calque 1" + inkscape:groupmode="layer" + id="layer1"> + <path + style="fill:url(#linearGradient3368);fill-opacity:1;stroke:#1d1d1d;stroke-width:1.11289036;stroke-miterlimit:4;stroke-dashoffset:0;stroke-opacity:1" + d="M 6.568759,4.9630825 C 7.2693093,6.8053873 8.4265615,8.0680324 10.145908,8.5402313 C 10.269766,8.6640898 10.269766,8.8635147 10.145907,8.9873732 L 3.3591104,14.57972 C 3.2352519,14.703578 3.035827,14.703579 2.9119685,14.579721 C 1.9658464,14.102742 1.1190897,13.352509 0.66979388,12.47807 C 0.54593545,12.354211 0.54593521,12.154785 0.66979373,12.030927 L 6.1216164,4.9630825 C 6.245475,4.839224 6.4449005,4.8392241 6.568759,4.9630825 z " + id="rect2382" + sodipodi:nodetypes="ccccccccc" /> + <path + sodipodi:type="arc" + style="opacity:1;fill:url(#radialGradient3392);fill-opacity:1;stroke:#4c4c4c;stroke-width:1;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + id="path2231" + sodipodi:cx="7.2604713" + sodipodi:cy="7.9187799" + sodipodi:rx="3.2829957" + sodipodi:ry="3.2829957" + d="M 10.543467 7.9187799 A 3.2829957 3.2829957 0 1 1 3.9774756,7.9187799 A 3.2829957 3.2829957 0 1 1 10.543467 7.9187799 z" + transform="matrix(1.1871826,0,0,1.1871826,1.6577923,-4.7200553)" /> + <g + id="g3398" + transform="matrix(1.0416412,0,0,1.0416412,-0.3396375,-0.3598217)"> + <rect + ry="0.82081318" + rx="0.82081318" + inkscape:r_cy="true" + inkscape:r_cx="true" + y="8.6409912" + x="8.1562767" + height="7.0576959" + width="7.4291534" + id="rect1686" + style="color:#000000;fill:#a40000;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:0.37145764;stroke-linecap:square;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible" /> + <g + inkscape:r_cy="true" + inkscape:r_cx="true" + transform="matrix(0.4225522,0,0,0.4225522,6.497738,-3.4645944)" + id="g2254"> + <path + style="opacity:1;color:#000000;fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#ffffff;stroke-width:2.56729817;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible" + d="M 8,32 L 18,42" + id="path1377" + inkscape:r_cx="true" + inkscape:r_cy="true" /> + <path + inkscape:r_cy="true" + inkscape:r_cx="true" + id="path2252" + d="M 18,32 L 8,42" + style="opacity:1;color:#000000;fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#ffffff;stroke-width:2.56729817;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible" /> + </g> + </g> + <path + style="fill:none;fill-opacity:1;stroke:#1d1d1d;stroke-width:1.05088782;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" + d="M 4.3165626,13.206731 C 3.3222944,12.70548 2.4324481,11.917069 1.9602886,10.998132" + id="path3394" + sodipodi:nodetypes="cc" /> + </g> +</svg> diff --git a/sflphone-gtk/pixmaps/speaker.svg b/sflphone-gtk/pixmaps/speaker.svg new file mode 100644 index 0000000000000000000000000000000000000000..346399f613cebecc0bb773ed3cbd6a5a9b3be9c2 --- /dev/null +++ b/sflphone-gtk/pixmaps/speaker.svg @@ -0,0 +1,418 @@ +<?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://web.resource.org/cc/" + 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="16" + height="16" + id="svg2" + sodipodi:version="0.32" + inkscape:version="0.45" + version="1.0" + sodipodi:docbase="/home/plbeaudoin/SFLPhone/sflphone/sflphone-gtk/pixmaps" + sodipodi:docname="speaker.svg" + inkscape:output_extension="org.inkscape.output.svg.inkscape" + sodipodi:modified="true"> + <defs + id="defs4"> + <linearGradient + inkscape:collect="always" + id="linearGradient3417"> + <stop + style="stop-color:#000000;stop-opacity:1;" + offset="0" + id="stop3419" /> + <stop + style="stop-color:#000000;stop-opacity:0;" + offset="1" + id="stop3421" /> + </linearGradient> + <linearGradient + id="linearGradient3370"> + <stop + style="stop-color:#d7d7d7;stop-opacity:1;" + offset="0" + id="stop3372" /> + <stop + style="stop-color:#7c7c7c;stop-opacity:1;" + offset="1" + id="stop3374" /> + </linearGradient> + <linearGradient + id="linearGradient3362"> + <stop + style="stop-color:#000000;stop-opacity:1;" + offset="0" + id="stop3364" /> + <stop + style="stop-color:#ffffff;stop-opacity:1;" + offset="1" + id="stop3366" /> + </linearGradient> + <linearGradient + id="linearGradient4045"> + <stop + style="stop-color:#ffffff;stop-opacity:0" + offset="0" + id="stop4047" /> + <stop + style="stop-color:#fcfbcb;stop-opacity:1" + offset="1" + id="stop4049" /> + </linearGradient> + <linearGradient + id="linearGradient4269"> + <stop + style="stop-color:#1db000;stop-opacity:1;" + offset="0" + id="stop4271" /> + <stop + style="stop-color:#1db000;stop-opacity:0;" + offset="1" + id="stop4273" /> + </linearGradient> + <linearGradient + id="linearGradient4183"> + <stop + id="stop4185" + offset="0" + style="stop-color:#1db000;stop-opacity:1;" /> + <stop + id="stop4187" + offset="1" + style="stop-color:#0f5f00;stop-opacity:1;" /> + </linearGradient> + <linearGradient + id="linearGradient4167"> + <stop + style="stop-color:#80000e;stop-opacity:1;" + offset="0" + id="stop4169" /> + <stop + style="stop-color:#b00014;stop-opacity:0;" + offset="1" + id="stop4171" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4183" + id="linearGradient2224" + x1="16.826796" + y1="6.7288713" + x2="27.5625" + y2="22.512505" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0.875025,0,0,0.875025,0.666703,0.177907)" /> + <linearGradient + gradientTransform="matrix(1.62913,0,0,-1.62913,-10.06608,39.71987)" + gradientUnits="userSpaceOnUse" + y2="6.6770978" + x2="15.806232" + y1="22.874208" + x1="15.630395" + id="linearGradient4275" + xlink:href="#linearGradient4269" + inkscape:collect="always" /> + <linearGradient + y2="13.920053" + x2="6.8378897" + y1="12.625902" + x1="2.0651877" + gradientTransform="matrix(-1,0,0,1,32.04188,-2.86473)" + gradientUnits="userSpaceOnUse" + id="linearGradient1388" + xlink:href="#linearGradient4269" + inkscape:collect="always" /> + <linearGradient + gradientTransform="translate(0.426158,-2.762136)" + gradientUnits="userSpaceOnUse" + y2="13.920053" + x2="6.8378897" + y1="12.625902" + x1="2.0651877" + id="linearGradient1386" + xlink:href="#linearGradient4269" + inkscape:collect="always" /> + <linearGradient + gradientUnits="userSpaceOnUse" + y2="10.576721" + x2="14.013638" + y1="2.7028866" + x1="15.647213" + id="linearGradient1384" + xlink:href="#linearGradient4183" + inkscape:collect="always" /> + <linearGradient + gradientTransform="translate(-0.947018,-0.885198)" + gradientUnits="userSpaceOnUse" + y2="12.535715" + x2="31.31678" + y1="12.535715" + x1="24.397505" + id="linearGradient1382" + xlink:href="#linearGradient4183" + inkscape:collect="always" /> + <linearGradient + gradientTransform="translate(1.262691,-1.100752)" + gradientUnits="userSpaceOnUse" + y2="12.825893" + x2="7.9239235" + y1="12.825893" + x1="1.0046476" + id="linearGradient1380" + xlink:href="#linearGradient4183" + inkscape:collect="always" /> + <linearGradient + id="linearGradient1374"> + <stop + id="stop1376" + offset="0" + style="stop-color:#80000e;stop-opacity:1;" /> + <stop + id="stop1378" + offset="1" + style="stop-color:#b00014;stop-opacity:0;" /> + </linearGradient> + <linearGradient + id="linearGradient1368"> + <stop + style="stop-color:#26b000;stop-opacity:1;" + offset="0" + id="stop1370" /> + <stop + style="stop-color:#145f00;stop-opacity:1;" + offset="1" + id="stop1372" /> + </linearGradient> + <linearGradient + id="linearGradient1362"> + <stop + id="stop1364" + offset="0" + style="stop-color:#26b000;stop-opacity:1;" /> + <stop + id="stop1366" + offset="1" + style="stop-color:#26b000;stop-opacity:0;" /> + </linearGradient> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4183" + id="linearGradient1406" + gradientUnits="userSpaceOnUse" + x1="15.647213" + y1="2.7028866" + x2="14.013638" + y2="10.576721" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4183" + id="linearGradient1408" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(1.262691,-1.100752)" + x1="10.57493" + y1="12.115559" + x2="-0.68574232" + y2="12.115559" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4183" + id="linearGradient1410" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(-0.947018,-0.885198)" + x1="31.692968" + y1="11.264216" + x2="23.888865" + y2="13.35532" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4269" + id="linearGradient1412" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(0.426158,-2.762136)" + x1="7.8517423" + y1="15.912388" + x2="7.1114841" + y2="11.597325" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient4269" + id="linearGradient1414" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(-1,0,0,1,32.04188,-2.86473)" + x1="2.0651877" + y1="12.625902" + x2="6.8378897" + y2="13.920053" /> + <radialGradient + inkscape:collect="always" + xlink:href="#linearGradient4045" + id="radialGradient4051" + cx="19.285715" + cy="9.8571424" + fx="19.285715" + fy="9.8571424" + r="10.885714" + gradientUnits="userSpaceOnUse" + spreadMethod="reflect" + gradientTransform="matrix(0.418975,0,0,0.418975,11.20548,5.727248)" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient3362" + id="linearGradient3368" + x1="16.037382" + y1="3.6340783" + x2="0.9781428" + y2="5.2185812" + gradientUnits="userSpaceOnUse" + gradientTransform="matrix(0.7869324,0.7869324,-0.7869324,0.7869324,-2.5317345,-1.0086642)" /> + <radialGradient + inkscape:collect="always" + xlink:href="#linearGradient3370" + id="radialGradient3392" + cx="5.5446553" + cy="6.5377574" + fx="5.5446553" + fy="6.5377574" + r="3.7829957" + gradientUnits="userSpaceOnUse" + spreadMethod="pad" + gradientTransform="matrix(0.6570643,0.4203728,-0.5183425,0.810196,5.2902577,-1.0899297)" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient3370" + id="linearGradient3415" + x1="2.3125" + y1="4.3125" + x2="3.8125" + y2="11.78125" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(0,8.349934e-2)" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient3417" + id="linearGradient3423" + x1="8.2358475" + y1="15.55225" + x2="4.424221" + y2="3.4272494" + gradientUnits="userSpaceOnUse" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient3417" + id="linearGradient3429" + gradientUnits="userSpaceOnUse" + x1="8.2358475" + y1="15.55225" + x2="4.424221" + y2="3.4272494" /> + <linearGradient + inkscape:collect="always" + xlink:href="#linearGradient3370" + id="linearGradient3431" + gradientUnits="userSpaceOnUse" + gradientTransform="translate(0,8.349934e-2)" + x1="2.3125" + y1="4.3125" + x2="3.8125" + y2="11.78125" /> + </defs> + <sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="2" + inkscape:cx="34.606991" + inkscape:cy="-23.98573" + inkscape:document-units="px" + inkscape:current-layer="layer1" + width="16px" + height="16px" + showguides="true" + inkscape:guide-bbox="true" + inkscape:window-width="1014" + inkscape:window-height="691" + inkscape:window-x="336" + inkscape:window-y="282"> + <sodipodi:guide + orientation="vertical" + position="24.821428" + id="guide3146" /> + </sodipodi:namedview> + <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" /> + </cc:Work> + </rdf:RDF> + </metadata> + <g + inkscape:label="Calque 1" + inkscape:groupmode="layer" + id="layer1"> + <g + id="g3425" + transform="matrix(0.8938767,0,0,0.8938767,-0.7849478,0.2391309)" + style="stroke:#3a3a3a;stroke-opacity:1"> + <path + id="path3406" + d="M 8.2992212,14.492981 C 6.403097,12.241903 4.5069721,9.9908266 2.6108471,7.7397495 C 4.5069721,5.4886726 6.4030966,3.2375952 8.2992208,0.98651768 C 8.2992208,5.4886717 8.2992212,9.9908266 8.2992212,14.492981 z " + style="opacity:1;fill:url(#linearGradient3429);fill-opacity:1;stroke:#3a3a3a;stroke-width:1;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + <rect + ry="0.23693162" + rx="0.23693162" + y="4.8959994" + x="1.9375" + height="5.6875" + width="3" + id="rect3404" + style="opacity:1;fill:url(#linearGradient3431);fill-opacity:1;stroke:#3a3a3a;stroke-width:1;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1" /> + </g> + <g + id="g3398" + transform="matrix(1.0416412,0,0,1.0416412,-0.3396375,-0.3598217)"> + <rect + ry="0.82081318" + rx="0.82081318" + inkscape:r_cy="true" + inkscape:r_cx="true" + y="8.6409912" + x="8.1562767" + height="7.0576959" + width="7.4291534" + id="rect1686" + style="color:#000000;fill:#a40000;fill-opacity:1;fill-rule:evenodd;stroke:none;stroke-width:0.37145764;stroke-linecap:square;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible" /> + <g + inkscape:r_cy="true" + inkscape:r_cx="true" + transform="matrix(0.4225522,0,0,0.4225522,6.497738,-3.4645944)" + id="g2254"> + <path + style="opacity:1;color:#000000;fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#ffffff;stroke-width:2.56729817;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible" + d="M 8,32 L 18,42" + id="path1377" + inkscape:r_cx="true" + inkscape:r_cy="true" /> + <path + inkscape:r_cy="true" + inkscape:r_cx="true" + id="path2252" + d="M 18,32 L 8,42" + style="opacity:1;color:#000000;fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#ffffff;stroke-width:2.56729817;stroke-linecap:round;stroke-linejoin:round;marker:none;marker-start:none;marker-mid:none;marker-end:none;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;visibility:visible;display:inline;overflow:visible" /> + </g> + </g> + </g> +</svg> diff --git a/sflphone-gtk/src/Makefile.am b/sflphone-gtk/src/Makefile.am index 885b48f2ca37c8ce207a169bde434ab587fd4687..a14e740eff60fa59e50acc9d5e3cf45a8c76fa66 100644 --- a/sflphone-gtk/src/Makefile.am +++ b/sflphone-gtk/src/Makefile.am @@ -13,11 +13,12 @@ sflphone_gtk_SOURCES = \ configwindow.c \ accountlist.c \ accountwindow.c \ - marshaller.c + marshaller.c \ + sliders.c noinst_HEADERS = actions.h dbus.h mainwindow.h calllist.h dialpad.h \ callmanager-glue.h menus.h calltree.h screen.h configwindow.h \ - accountlist.h accountwindow.h marshaller.h + accountlist.h accountwindow.h marshaller.h sliders.h EXTRA_DIST = marshaller.list sflphone_gtk_LDADD = $(DEPS_LIBS) diff --git a/sflphone-gtk/src/accountlist.c b/sflphone-gtk/src/accountlist.c index 544429eeeeaf1f4b1b869241b145d13ec6c7892a..7aa9a1bd2fe4fda1bd717019f797d1ec491c8bcd 100644 --- a/sflphone-gtk/src/accountlist.c +++ b/sflphone-gtk/src/accountlist.c @@ -18,6 +18,7 @@ */ #include <accountlist.h> +#include <string.h> GQueue * accountQueue; diff --git a/sflphone-gtk/src/accountwindow.c b/sflphone-gtk/src/accountwindow.c index f66604190be7bd673802d75d864bc7f998003693..714b7eade3c51ffae7963ec27342301fa7046695 100644 --- a/sflphone-gtk/src/accountwindow.c +++ b/sflphone-gtk/src/accountwindow.c @@ -20,6 +20,8 @@ #include <config.h> #include <mainwindow.h> #include <accountlist.h> +#include <string.h> +#include <dbus.h> #include <gtk/gtk.h> /** Local variables */ diff --git a/sflphone-gtk/src/actions.c b/sflphone-gtk/src/actions.c index d312529d8c83370c3f13ab45dc540db743cadd9a..d5f762bdf5d446433997c25959cc50a1a0f4f7b8 100644 --- a/sflphone-gtk/src/actions.c +++ b/sflphone-gtk/src/actions.c @@ -21,6 +21,10 @@ #include <string.h> #include <actions.h> +#include <mainwindow.h> +#include <calltree.h> +#include <screen.h> +#include <dbus.h> #include <accountlist.h> /** @@ -311,7 +315,7 @@ sflphone_place_call ( call_t * c ) void sflphone_remove_account ( account_t * a ) { - dbus_remove_account (a); + dbus_remove_account (a->accountID); } diff --git a/sflphone-gtk/src/actions.h b/sflphone-gtk/src/actions.h index 9d0bec94426807bc8ca4eaf094dd8e5a937524b0..89fd60d197f16e8aae190852194438a93568b0e2 100644 --- a/sflphone-gtk/src/actions.h +++ b/sflphone-gtk/src/actions.h @@ -21,6 +21,7 @@ #define __ACTIONS_H__ #include <calllist.h> +#include <accountlist.h> /** * Initialize lists and configurations @@ -42,6 +43,10 @@ void sflphone_hold ( call_t * c); void sflphone_ringing(call_t * c ); +void sflphone_current ( call_t * c); + +void sflphone_remove_account ( account_t * a ); + void sflphone_unhold ( call_t * c); /* signals */ diff --git a/sflphone-gtk/src/calllist.c b/sflphone-gtk/src/calllist.c index 32e5dea0ce02a929d3c82a9a56707fe4e678b4c3..1291f9c5f1dfc129da7cf26cb3deb7ceef043635 100644 --- a/sflphone-gtk/src/calllist.c +++ b/sflphone-gtk/src/calllist.c @@ -19,6 +19,8 @@ #include <calllist.h> +#include <string.h> + GQueue * callQueue; /* GCompareFunc to compare a callID (gchar* and a call_t) */ diff --git a/sflphone-gtk/src/calltree.c b/sflphone-gtk/src/calltree.c index 74ae0bc4b31630cd9130b8ba883e15023d5aeb62..b09ed975206d581713277135dbcb461bd5245f30 100644 --- a/sflphone-gtk/src/calltree.c +++ b/sflphone-gtk/src/calltree.c @@ -20,6 +20,7 @@ #include <gtk/gtk.h> #include <calltree.h> #include <calllist.h> +#include <dbus.h> GtkListStore * store; GtkWidget *view; @@ -48,6 +49,9 @@ call_button( GtkWidget *widget, gpointer data ) case CALL_STATE_INCOMING: dbus_accept (selectedCall); break; + default: + g_error("Should not happen!"); + break; } } } @@ -71,6 +75,9 @@ hang_up( GtkWidget *widget, gpointer data ) case CALL_STATE_INCOMING: dbus_refuse (selectedCall); break; + default: + g_error("Should not happen!"); + break; } } } @@ -88,6 +95,9 @@ hold( GtkWidget *widget, gpointer data ) case CALL_STATE_CURRENT: dbus_hold (selectedCall); break; + default: + g_error("Should not happen!"); + break; } } } @@ -105,18 +115,6 @@ transfert( GtkWidget *widget, gpointer data ) } } -/** - * Refuse incoming call - */ -static void -refuse( GtkWidget *widget, gpointer data ) -{ - if(selectedCall) - { - dbus_refuse(selectedCall); - } -} - /** * Unhold call */ @@ -130,6 +128,9 @@ unhold( GtkWidget *widget, gpointer data ) case CALL_STATE_HOLD: dbus_unhold (selectedCall); break; + default: + g_error("Should not happen!"); + break; } } } @@ -197,19 +198,6 @@ selected(GtkTreeSelection *sel, GtkTreeModel *model) update_buttons(); } -/** - * Accept incoming call - */ -static void -accept( GtkWidget *widget, gpointer data ) -{ - if(selectedCall) - { - dbus_accept(selectedCall); - } -} - - GtkWidget * create_call_tree (){ @@ -217,17 +205,15 @@ create_call_tree (){ GtkWidget *sw; GtkWidget *hbox; GtkWidget *image; - GtkWidget *bbox; GtkCellRenderer *rend; GtkTreeViewColumn *col; GtkTreeSelection *sel; - GtkTargetEntry te[2] = {{"text/uri-list", 0, 1},{"STRING", 0, 2}}; - + ret = gtk_vbox_new(FALSE, 10); gtk_container_set_border_width (GTK_CONTAINER (ret), 0); sw = gtk_scrolled_window_new( NULL, NULL); - gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(sw), GTK_POLICY_NEVER, GTK_POLICY_ALWAYS); + gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(sw), GTK_POLICY_NEVER, GTK_POLICY_AUTOMATIC); gtk_scrolled_window_set_shadow_type(GTK_SCROLLED_WINDOW(sw), GTK_SHADOW_IN); store = gtk_list_store_new (3, diff --git a/sflphone-gtk/src/calltree.h b/sflphone-gtk/src/calltree.h index 655d856a05db15d493b401ea7ff254af5aabc2bb..26a3ed01dd149c2817ba8cd94d70b5480b9dc72e 100644 --- a/sflphone-gtk/src/calltree.h +++ b/sflphone-gtk/src/calltree.h @@ -21,9 +21,12 @@ #define __CALLTREE_H__ #include <gtk/gtk.h> +#include <calllist.h> GtkWidget * create_call_tree(); -void update_call_tree (); +void update_call_tree_add (call_t * c); +void update_call_tree (call_t * c); +void update_call_tree_remove (call_t * c); #endif diff --git a/sflphone-gtk/src/configwindow.c b/sflphone-gtk/src/configwindow.c index 793be9befcf0f8b632a462f7b9e4f9e51db534f3..3e9f5e4a71e79d15d1b35ae745d981f10effdb21 100644 --- a/sflphone-gtk/src/configwindow.c +++ b/sflphone-gtk/src/configwindow.c @@ -20,6 +20,9 @@ #include <config.h> #include <mainwindow.h> #include <accountlist.h> +#include <accountwindow.h> +#include <actions.h> + #include <gtk/gtk.h> /** Local variables */ @@ -110,7 +113,7 @@ select_account(GtkTreeSelection *sel, GtkTreeModel *model) /*TODO Set to TRUE when removeAccount is implemented */ gtk_widget_set_sensitive( GTK_WIDGET(deleteButton), FALSE); } - g_printf("select"); + g_print("select"); } @@ -123,13 +126,10 @@ create_accounts_tab() GtkWidget *sw; GtkWidget *view; GtkWidget *bbox; - GtkWidget *button; GtkCellRenderer *rend; GtkTreeViewColumn *col; GtkTreeSelection *sel; - GtkTreeRowReference *rowref; GtkWidget *label; - GtkTargetEntry te[3] = {{"text/plain", 0, 0},{"text/plain", 0, 1},{"text/plain", 0, 2}}; selectedAccount = NULL; diff --git a/sflphone-gtk/src/dbus.c b/sflphone-gtk/src/dbus.c index fdaa8b1f6bd3bb1146e44e9814c14d0b69863a13..9c3e53bfbe7f35921aff11fa8307dc896d610bf3 100644 --- a/sflphone-gtk/src/dbus.c +++ b/sflphone-gtk/src/dbus.c @@ -23,7 +23,11 @@ #include <accountlist.h> #include <marshaller.h> #include <mainwindow.h> +#include <sliders.h> +#include <dbus.h> +#include <actions.h> +#include <string.h> #include <dbus/dbus-glib.h> DBusGConnection * connection; @@ -47,6 +51,17 @@ incoming_call_cb (DBusGProxy *proxy, sflphone_incoming_call (c); } + +static void +volume_changed_cb (DBusGProxy *proxy, + const gchar* device, + const gdouble value, + void * foo ) +{ + g_print ("Volume of %s changed to %f. \n",device, value); + set_slider(device, value); +} + static void voice_mail_cb (DBusGProxy *proxy, const gchar* accountID, @@ -152,8 +167,8 @@ dbus_connect () /* Register a marshaller for STRING,STRING */ dbus_g_object_register_marshaller(g_cclosure_user_marshal_VOID__STRING_STRING, G_TYPE_NONE, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_INVALID); - dbus_g_proxy_add_signal (callManagerProxy, "callStateChanged", - G_TYPE_STRING, G_TYPE_STRING, G_TYPE_INVALID); + dbus_g_proxy_add_signal (callManagerProxy, + "callStateChanged", G_TYPE_STRING, G_TYPE_STRING, G_TYPE_INVALID); dbus_g_proxy_connect_signal (callManagerProxy, "callStateChanged", G_CALLBACK(call_state_cb), NULL, NULL); @@ -169,6 +184,12 @@ dbus_connect () dbus_g_proxy_connect_signal (callManagerProxy, "incomingMessage", G_CALLBACK(incoming_message_cb), NULL, NULL); + dbus_g_object_register_marshaller(g_cclosure_user_marshal_VOID__STRING_DOUBLE, + G_TYPE_NONE, G_TYPE_STRING, G_TYPE_DOUBLE, G_TYPE_INVALID); + dbus_g_proxy_add_signal (callManagerProxy, + "volumeChanged", G_TYPE_STRING, G_TYPE_DOUBLE, G_TYPE_INVALID); + dbus_g_proxy_connect_signal (callManagerProxy, + "volumeChanged", G_CALLBACK(volume_changed_cb), NULL, NULL); configurationManagerProxy = dbus_g_proxy_new_for_name_owner (connection, "org.sflphone.SFLPhone", @@ -377,7 +398,6 @@ void dbus_remove_account(gchar * accountID) { GError *error = NULL; - char ** array; org_sflphone_SFLPhone_ConfigurationManager_remove_account ( configurationManagerProxy, accountID, @@ -416,3 +436,53 @@ dbus_set_account_details(account_t *a) } } + +void +dbus_set_volume(const gchar * device, gdouble value) +{ + GError *error = NULL; + org_sflphone_SFLPhone_CallManager_set_volume( + callManagerProxy, + device, + value, + &error); + + if (error) + { + g_printerr ("Failed to call set_volume() on callManagerProxy: %s\n", + error->message); + g_error_free (error); + } + else + { + g_print ("DBus called set_volume() on callManagerProxy\n"); + + } +} + + +gdouble +dbus_get_volume(const gchar * device) +{ + gdouble value; + GError *error = NULL; + + org_sflphone_SFLPhone_CallManager_get_volume( + callManagerProxy, + device, + &value, + &error); + + if (error) + { + g_printerr ("Failed to call get_volume() on callManagerProxy: %s\n", + error->message); + g_error_free (error); + } + else + { + g_print ("DBus called get_volume(%s) on callManagerProxy, got %f\n", device, value); + + } + return value; +} diff --git a/sflphone-gtk/src/dbus.h b/sflphone-gtk/src/dbus.h index 8d1b9253e5b998eeb20198d3454f5edb668d6181..2545765e9d2bda783288084aca25fba2ef591d7b 100644 --- a/sflphone-gtk/src/dbus.h +++ b/sflphone-gtk/src/dbus.h @@ -25,7 +25,7 @@ #include <calllist.h> /** @return TRUE if connection succeeded, FALSE otherwise */ -void dbus_connect (); +gboolean dbus_connect (); void dbus_clean (); /* CallManager */ @@ -42,5 +42,7 @@ gchar ** dbus_account_list(); GHashTable * dbus_account_details(gchar * accountID); void dbus_set_account_details(account_t *a); void dbus_remove_account(gchar * accountID); +void dbus_set_volume(const gchar * device, gdouble value); +gdouble dbus_get_volume(const gchar * device); #endif diff --git a/sflphone-gtk/src/dialpad.c b/sflphone-gtk/src/dialpad.c index 272368bf2accf6878b8c1b6d57e70a43f1868436..7c82739ca0ebdc48d130266e18a6a31d6c3d4067 100644 --- a/sflphone-gtk/src/dialpad.c +++ b/sflphone-gtk/src/dialpad.c @@ -18,6 +18,7 @@ */ #include <dialpad.h> +#include <actions.h> /** * button pressed event diff --git a/sflphone-gtk/src/main.c b/sflphone-gtk/src/main.c index b4de656bf1e74ff85841ba6124a0f6565a7d50e1..fa6272b5469cbdda3c96f3fda68bd07c7fad5ab5 100644 --- a/sflphone-gtk/src/main.c +++ b/sflphone-gtk/src/main.c @@ -21,6 +21,7 @@ #include <calllist.h> #include <dbus.h> #include <mainwindow.h> +#include <actions.h> #include <gtk/gtk.h> diff --git a/sflphone-gtk/src/mainwindow.c b/sflphone-gtk/src/mainwindow.c index f056d563c48a78800dd9a842473d1927820a6230..8883598d7dbcd3dd64483e0ae7981e859e3505be 100644 --- a/sflphone-gtk/src/mainwindow.c +++ b/sflphone-gtk/src/mainwindow.c @@ -20,20 +20,22 @@ #include <config.h> #include <actions.h> #include <calllist.h> +#include <calltree.h> #include <dialpad.h> #include <menus.h> #include <screen.h> -#include <calltree.h> +#include <sliders.h> #include <gtk/gtk.h> /** Local variables */ GtkAccelGroup * accelGroup = NULL; -GtkWidget * window = NULL; -GtkWidget *subvbox = NULL; -GtkWidget * dialpad = NULL; +GtkWidget * window = NULL; +GtkWidget * subvbox = NULL; +GtkWidget * dialpad = NULL; gboolean showDialpad = FALSE; // true if the dialpad have been showned + /** * Terminate the main loop. */ @@ -92,7 +94,10 @@ on_key_released (GtkWidget *widget, // If a modifier key is pressed, it's a shortcut, pass along if(event->state & GDK_CONTROL_MASK || event->state & GDK_SHIFT_MASK || - event->state & GDK_MOD1_MASK ) + event->state & GDK_MOD1_MASK || + event->keyval == 65361 || // left arrow + event->keyval == 65363 // right arrow + ) return FALSE; sflphone_keypad(event->keyval, event->string); return TRUE; @@ -102,13 +107,12 @@ void create_main_window () { GtkWidget *button; - GtkWidget *hbox; GtkWidget *vbox; window = gtk_window_new (GTK_WINDOW_TOPLEVEL); gtk_container_set_border_width (GTK_CONTAINER (window), 0); gtk_window_set_title (GTK_WINDOW (window), PACKAGE); - gtk_window_set_default_size (GTK_WINDOW (window), 250, 250); + //gtk_window_set_default_size (GTK_WINDOW (window), 250, 250); gtk_window_set_default_icon_from_file (PIXMAPS_DIR "/sflphone.png", NULL); @@ -140,15 +144,15 @@ create_main_window () button = create_screen(); gtk_box_pack_start (GTK_BOX (subvbox), button, FALSE /*expand*/, TRUE /*fill*/, 0 /*padding*/); - button = gtk_hscale_new_with_range(0, 100, 2); - gtk_scale_set_draw_value(button, FALSE); - gtk_box_pack_start (GTK_BOX (subvbox), button, FALSE /*expand*/, TRUE /*fill*/, 0 /*padding*/); - button = gtk_hscale_new_with_range(0, 100, 2); - gtk_scale_set_draw_value(button, FALSE); - gtk_box_pack_start (GTK_BOX (subvbox), button, FALSE /*expand*/, TRUE /*fill*/, 0 /*padding*/); + gtk_box_pack_start (GTK_BOX (subvbox), create_call_tree(), TRUE /*expand*/, TRUE /*fill*/, 0 /*padding*/); + button = create_slider("speaker"); + gtk_box_pack_start (GTK_BOX (subvbox), button, FALSE /*expand*/, TRUE /*fill*/, 0 /*padding*/); + button = create_slider("mic"); + gtk_box_pack_start (GTK_BOX (subvbox), button, FALSE /*expand*/, TRUE /*fill*/, 0 /*padding*/); + /* Status bar */ gtk_box_pack_start (GTK_BOX (vbox), gtk_statusbar_new(), FALSE /*expand*/, TRUE /*fill*/, 0 /*padding*/); @@ -216,8 +220,3 @@ main_window_dialpad(gboolean show){ } - - - - - diff --git a/sflphone-gtk/src/mainwindow.h b/sflphone-gtk/src/mainwindow.h index 46094bf627822fcdcf2139eb39a9c27f93330058..49bb69913a06dbb72b97bcf0158308ea3dcc0270 100644 --- a/sflphone-gtk/src/mainwindow.h +++ b/sflphone-gtk/src/mainwindow.h @@ -27,7 +27,7 @@ GtkWidget * get_main_window(); void create_main_window ( ); -void main_window_ask_quit() ; +gboolean main_window_ask_quit() ; /** * Shows the dialpad on the mainwindow * @param show TRUE if you want to show the dialpad, FALSE to hide it diff --git a/sflphone-gtk/src/marshaller.c b/sflphone-gtk/src/marshaller.c index 876679b381d6b0cc01f9ee8810522d9b3fad32f0..a996993767e6930b4e787c6ce8f5a372e8bc74e8 100644 --- a/sflphone-gtk/src/marshaller.c +++ b/sflphone-gtk/src/marshaller.c @@ -160,3 +160,40 @@ g_cclosure_user_marshal_VOID__STRING_INT (GClosure *closure, data2); } +/* VOID:STRING,DOUBLE (marshaller.list:4) */ +void +g_cclosure_user_marshal_VOID__STRING_DOUBLE (GClosure *closure, + GValue *return_value, + guint n_param_values, + const GValue *param_values, + gpointer invocation_hint, + gpointer marshal_data) +{ + typedef void (*GMarshalFunc_VOID__STRING_DOUBLE) (gpointer data1, + gpointer arg_1, + gdouble arg_2, + gpointer data2); + register GMarshalFunc_VOID__STRING_DOUBLE callback; + register GCClosure *cc = (GCClosure*) closure; + register gpointer data1, data2; + + g_return_if_fail (n_param_values == 3); + + if (G_CCLOSURE_SWAP_DATA (closure)) + { + data1 = closure->data; + data2 = g_value_peek_pointer (param_values + 0); + } + else + { + data1 = g_value_peek_pointer (param_values + 0); + data2 = closure->data; + } + callback = (GMarshalFunc_VOID__STRING_DOUBLE) (marshal_data ? marshal_data : cc->callback); + + callback (data1, + g_marshal_value_peek_string (param_values + 1), + g_marshal_value_peek_double (param_values + 2), + data2); +} + diff --git a/sflphone-gtk/src/marshaller.h b/sflphone-gtk/src/marshaller.h index 924c97257f9e466c3c1ef5ed1f3564762289a622..1315de63a25b6661ac5bc34a8744300c9d116c87 100644 --- a/sflphone-gtk/src/marshaller.h +++ b/sflphone-gtk/src/marshaller.h @@ -30,6 +30,14 @@ extern void g_cclosure_user_marshal_VOID__STRING_INT (GClosure *closure, gpointer invocation_hint, gpointer marshal_data); +/* VOID:STRING,DOUBLE (marshaller.list:4) */ +extern void g_cclosure_user_marshal_VOID__STRING_DOUBLE (GClosure *closure, + GValue *return_value, + guint n_param_values, + const GValue *param_values, + gpointer invocation_hint, + gpointer marshal_data); + G_END_DECLS #endif /* __g_cclosure_user_marshal_MARSHAL_H__ */ diff --git a/sflphone-gtk/src/marshaller.list b/sflphone-gtk/src/marshaller.list index c6d168f95eb45d4cc900da72611714af88be3638..96908bb36e155492e9f4891007af73081550d545 100644 --- a/sflphone-gtk/src/marshaller.list +++ b/sflphone-gtk/src/marshaller.list @@ -1,3 +1,4 @@ VOID:STRING,STRING,STRING VOID:STRING,STRING VOID:STRING,INT +VOID:STRING,DOUBLE diff --git a/sflphone-gtk/src/menus.c b/sflphone-gtk/src/menus.c index 94a25067a5456af758fabfc5750c5f18d0b45035..69a257a3d14d32c68b5876696ff11face00278b4 100644 --- a/sflphone-gtk/src/menus.c +++ b/sflphone-gtk/src/menus.c @@ -20,6 +20,7 @@ #include <menus.h> #include <config.h> #include <calllist.h> +#include <actions.h> #include <mainwindow.h> #include <configwindow.h> /* ----------------------------------------------------------------- */ @@ -183,7 +184,7 @@ create_view_menu() menu = gtk_menu_new (); - menu_items = gtk_check_menu_item_new_with_mnemonic ("Show _Dialpad"); + menu_items = gtk_check_menu_item_new_with_mnemonic ("_Dialpad"); gtk_menu_shell_append (GTK_MENU_SHELL (menu), menu_items); g_signal_connect(G_OBJECT (menu_items), "toggled", G_CALLBACK (view_dial_pad), diff --git a/sflphone-gtk/src/screen.c b/sflphone-gtk/src/screen.c index 592e093042ef6b2b1155d092e66e05364080568f..59f1c1ad96f6b123350ef5c700e281ca2dde7adf 100644 --- a/sflphone-gtk/src/screen.c +++ b/sflphone-gtk/src/screen.c @@ -32,7 +32,6 @@ create_screen() GtkWidget * event; GtkWidget * sw; GtkWidget *subvbox; - GtkWidget *image; GdkColor color; gdk_color_parse ("white", &color); diff --git a/sflphone-gtk/src/sliders.c b/sflphone-gtk/src/sliders.c new file mode 100644 index 0000000000000000000000000000000000000000..3eac70a491a9606592e2f5e6cc6d51cfa18f5d0b --- /dev/null +++ b/sflphone-gtk/src/sliders.c @@ -0,0 +1,185 @@ +/* + * Copyright (C) 2007 Savoir-Faire Linux inc. + * Author: Pierre-Luc Beaudoin <pierre-luc.beaudoin@savoirfairelinux.com> + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + */ + +#include <sliders.h> +#include <dbus.h> +#include <string.h> + +gdouble speakerValue; +gdouble micValue; + +GtkWidget * speakerSlider; +GtkWidget * micSlider; +GtkWidget * micMuteButton; +GtkWidget * speakerMuteButton; + +guint speakerToggledConnId; //The button toggled signal connection ID +guint micToggledConnId; //The button toggled signal connection ID + +guint speakerMovedConnId; //The slider_moved signal connection ID +guint micMovedConnId; //The slider_moved signal connection ID + +void slider_moved(GtkRange *range, + gchar * device){ + gdouble value = gtk_range_get_value(range); + g_print("Volume changed for %s: %f\n ",device, value); + dbus_set_volume(device, value); +} + +static void +mute_cb( GtkWidget *widget, gchar* device ) +{ + if(gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON(widget))) + { // Save value + g_print("Save"); + if(strcmp(device, "speaker") == 0) + { + speakerValue = gtk_range_get_value(GTK_RANGE(speakerSlider)); + } + else if (strcmp(device, "mic")== 0) + { + micValue = gtk_range_get_value(GTK_RANGE(micSlider)); + } + dbus_set_volume(device, 0); + } + else + { //Restore value + g_print("Restore"); + if(strcmp(device, "speaker") == 0) + { + dbus_set_volume(device, speakerValue); + } + else if (strcmp(device, "mic")== 0) + { + dbus_set_volume(device, micValue); + } + } + +} + +/** This function updates the sliders without sending the value to the server. + * This behavior prevents an infinite loop when receiving an updated volume from + * the server. + * @param device The device slider to update {speaker, mic} + * @param value The value to set [0, 1.0] + */ +void +set_slider(const gchar * device, gdouble value) +{ + GtkWidget * slider; + GtkWidget * mute; + guint * movedConnId; + guint * toggledConnId; + if(strcmp(device, "speaker") == 0) + { + slider = speakerSlider; + mute = speakerMuteButton; + movedConnId = &speakerMovedConnId; + toggledConnId = &speakerToggledConnId; + } + else if (strcmp(device, "mic")== 0) + { + slider = micSlider; + mute = micMuteButton; + movedConnId = &micMovedConnId; + toggledConnId = &micToggledConnId; + } + gtk_signal_handler_block(GTK_OBJECT(slider),*movedConnId); + gtk_range_set_value(GTK_RANGE(slider), value); + gtk_signal_handler_unblock(slider, *movedConnId); + + gtk_signal_handler_block(GTK_OBJECT(mute),*toggledConnId); + gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(mute), (value == 0 ? TRUE: FALSE)); + gtk_signal_handler_unblock(mute, *toggledConnId); +} + +/** Generates the speaker slider and mute button */ +GtkWidget * +create_slider(const gchar * device) +{ + GtkWidget * ret; + GtkWidget * slider; + GtkWidget * button; + GtkWidget * image; + //GtkIconTheme * icon_theme; + //GdkPixbuf * pixbuf = NULL; + //GError * error = NULL; + guint * movedConnId = NULL; + guint * toggledConnId = NULL; + + if(strcmp(device, "speaker") == 0) + { + movedConnId = &speakerMovedConnId; + toggledConnId = &speakerToggledConnId; + image = gtk_image_new_from_file( PIXMAPS_DIR "/speaker.svg"); + //icon_theme = gtk_icon_theme_get_default (); + //pixbuf = gtk_icon_theme_load_icon (icon_theme, + // "audio-volume-muted", /* icon name */ + // 16, /* size */ + // 0, /* flags */ + // &error); + //image = gtk_image_new_from_pixbuf(pixbuf); + } + else if (strcmp(device, "mic") == 0) + { + movedConnId = &micMovedConnId; + toggledConnId = &micToggledConnId; + image = gtk_image_new_from_file( PIXMAPS_DIR "/mic.svg"); + } + + + ret = gtk_hbox_new ( FALSE /*homogeneous*/, 5 /*spacing*/); + + button = gtk_toggle_button_new(); + gtk_box_pack_start (GTK_BOX (ret), button, FALSE /*expand*/, TRUE /*fill*/, 0 /*padding*/); + *toggledConnId = g_signal_connect (G_OBJECT (button), "toggled", + G_CALLBACK (mute_cb), (gpointer)device); + + if (image) + { + gtk_button_set_image(GTK_BUTTON(button), image); + } + else + { + g_warning ("Couldn't load icon"); + } + + slider = gtk_hscale_new_with_range(0, 1, 0.05); + gtk_scale_set_draw_value(GTK_SCALE(slider), FALSE); + //gtk_range_set_update_policy(GTK_RANGE(slider), GTK_UPDATE_DELAYED); + *movedConnId = g_signal_connect (G_OBJECT (slider), "value_changed", + G_CALLBACK (slider_moved), (gpointer)device); + gtk_box_pack_start (GTK_BOX (ret), slider, TRUE /*expand*/, TRUE /*fill*/, 0 /*padding*/); + + if(strcmp(device, "speaker") == 0) + { + speakerSlider = slider; + speakerMuteButton = button; + } + else if (strcmp(device, "mic") == 0) + { + micSlider = slider; + micMuteButton = button; + } + + set_slider(device, dbus_get_volume(device)); + + return ret; +} + diff --git a/sflphone-gtk/src/sliders.h b/sflphone-gtk/src/sliders.h new file mode 100644 index 0000000000000000000000000000000000000000..f2436c4a721b693a0c4d1a2d985e2854a87b4598 --- /dev/null +++ b/sflphone-gtk/src/sliders.h @@ -0,0 +1,31 @@ +/* + * Copyright (C) 2007 Savoir-Faire Linux inc. + * Author: Pierre-Luc Beaudoin <pierre-luc.beaudoin@savoirfairelinux.com> + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + */ + +#ifndef __SLIDERS_H__ +#define __SLIDERS_H__ + +#include <gtk/gtk.h> + +GtkWidget * create_mic_slider(); + +GtkWidget * create_slider(const gchar * device); + +void set_slider(const gchar * device, gdouble value); + +#endif diff --git a/src/dbus/callmanager.cpp b/src/dbus/callmanager.cpp index 37cc4643913d00d8bb9b1461e0cbe74de619c963..cb199c37cf0bb8787a09f231d4ab8091a68e7aa3 100644 --- a/src/dbus/callmanager.cpp +++ b/src/dbus/callmanager.cpp @@ -90,18 +90,31 @@ void CallManager::setVolume( const ::DBus::String& device, const ::DBus::Double & value ) { _debug("CallManager::setVolume received\n"); - //TODO - Manager::instance().setSpkrVolume(value); - Manager::instance().setMicVolume(value); + if(device == "speaker") + { + Manager::instance().setSpkrVolume((int)(value*100.0)); + } + else if (device == "mic") + { + Manager::instance().setMicVolume((int)(value*100.0)); + } + volumeChanged(device, value); } ::DBus::Double CallManager::getVolume( const ::DBus::String& device ) { _debug("CallManager::getVolume received\n"); - //TODO - Manager::instance().getSpkrVolume(); - Manager::instance().getMicVolume(); + if(device == "speaker") + { + _debug("Current speaker = %d\n", Manager::instance().getSpkrVolume()); + return Manager::instance().getSpkrVolume()/100.0; + } + else if (device == "mic") + { + _debug("Current mic = %d\n", Manager::instance().getMicVolume()); + return Manager::instance().getMicVolume()/100.0; + } return 0; } @@ -117,7 +130,7 @@ CallManager::getCallDetails( const ::DBus::String& callID ) CallManager::getCurrentCallID( ) { _debug("CallManager::getCurrentCallID received\n"); - return "test"; + return getCurrentCallId(); }