<html>
<head>
<meta name="generator" content="Windows Mail 17.5.9600.20856">
<style type="text/css"><!--html { font-family: "Color Emoji", "Calibri", "Segoe UI", "Meiryo", "Microsoft YaHei UI", "Microsoft JhengHei UI", "Malgun Gothic", "sans-serif"; }--></style><style data-externalstyle="true"><!--
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph {
margin-top:0in;
margin-right:0in;
margin-bottom:0in;
margin-left:.5in;
margin-bottom:.0001pt;
}
p.MsoNormal, li.MsoNormal, div.MsoNormal {
margin:0in;
margin-bottom:.0001pt;
}
p.MsoListParagraphCxSpFirst, li.MsoListParagraphCxSpFirst, div.MsoListParagraphCxSpFirst, 
p.MsoListParagraphCxSpMiddle, li.MsoListParagraphCxSpMiddle, div.MsoListParagraphCxSpMiddle, 
p.MsoListParagraphCxSpLast, li.MsoListParagraphCxSpLast, div.MsoListParagraphCxSpLast {
margin-top:0in;
margin-right:0in;
margin-bottom:0in;
margin-left:.5in;
margin-bottom:.0001pt;
line-height:115%;
}
--></style></head>
<body dir="ltr">
<div data-externalstyle="false" dir="ltr" style="font-family: 'Calibri', 'Segoe UI', 'Meiryo', 'Microsoft YaHei UI', 'Microsoft JhengHei UI', 'Malgun Gothic', 'sans-serif';font-size:12pt;"><div>You check it first. Implementation may vary in different OSes<br></div><div data-signatureblock="true"><div><br></div><div>Sent from Windows Mail</div><div><br></div></div><div style="padding-top: 5px; border-top-color: rgb(229, 229, 229); border-top-width: 1px; border-top-style: solid;"><div><font face=" 'Calibri', 'Segoe UI', 'Meiryo', 'Microsoft YaHei UI', 'Microsoft JhengHei UI', 'Malgun Gothic', 'sans-serif'" style='line-height: 15pt; letter-spacing: 0.02em; font-family: "Calibri", "Segoe UI", "Meiryo", "Microsoft YaHei UI", "Microsoft JhengHei UI", "Malgun Gothic", "sans-serif"; font-size: 12pt;'><b>From:</b> <a href="mailto:thomas@tanghus.net" target="_parent">Thomas Tanghus</a><br><b>Sent:</b> ‎Friday‎, ‎June‎ ‎12‎, ‎2015 ‎3‎:‎10‎ ‎PM<br><b>To:</b> <a href="mailto:devel@lists.sailfishos.org" target="_parent">devel@lists.sailfishos.org</a></font></div></div><div><br></div><div dir=""><div id="readingPaneBodyContent">On Friday 12 June 2015 02:21:10 coderusinbox@gmail.com wrote:<br>> Please use SoundEffect class for that:<br><br>I did that originally, but on request I have added the option to select a <br>custom sound file, and I don't wanna limit users to wav files.<br><br>Also the SoundEffect docs says:<br><br>"If low latency is not important, consider using the MediaPlayer or Audio <br>types instead, since they support a wider variety of media formats and are <br>less resource intensive."<br><br>> > On Tuesday 03 February 2015 23:13:44 Luis Manuel Ramos Da Costa wrote:<br>> > >         Audio {<br>> > >         <br>> > >             id      : whipSound<br>> > >             loops   : Audio.Infinite<br>> > >             source:"qrc:/sounds/resources/sounds/whipSound.flac"<br>> > >         <br>> > >         }<br>> > <br>> > That can teach me to read the ml regularly ;)<br>> > <br>> > The loops property isn't documented in the documentation in the SDK, so I<br>> > <br>> > made  an ugly hack to emulate it:<br>> >    Audio {<br>> >    <br>> >         id: alarm;<br>> >         source: Qt.resolvedUrl(selectedSound);<br>> >         <br>> >         property bool forceStopped: false;<br>> >         <br>> >         function forceStop() {<br>> >         <br>> >             forceStopped = true;<br>> >             stop();<br>> >         <br>> >         }<br>> >         <br>> >         onStopped: {<br>> >         <br>> >             if(loopSound && !forceStopped) {<br>> >             <br>> >                 play();<br>> >             <br>> >             } else {<br>> >             <br>> >                 forceStopped = false;<br>> >             <br>> >             }<br>> >         <br>> >         }<br>> >     <br>> >     }> <br><br>-- <br>Med venlig hilsen / Best regards<br><br>Thomas Tanghus<br></div></div></div>
</body>
</html>