<div dir="ltr"><div>Hi Erik, how are you?</div><div><br></div><div>I already use that plugin (vibration) but it doesn&#39;t seem to work under the onNotification handler (I had already tested it before I send the previous message).</div>
<div><br></div><div>Anyway: it should  be triggered only when the notification arrives at the device, otherwise it&#39;s useless I think.</div><div><br></div><div>Thank you</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">
On Wed, Mar 19, 2014 at 4:43 PM, Erik Jan de Wit <span dir="ltr">&lt;<a href="mailto:edewit@redhat.com" target="_blank">edewit@redhat.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="word-wrap:break-word">Hi Miguel,<div><br></div><div>You could install a cordova plugin for that <a href="https://github.com/apache/cordova-plugin-vibration" target="_blank">https://github.com/apache/cordova-plugin-vibration</a> or <span style="background-color:rgb(0,0,0);font-family:&#39;Andale Mono&#39;"><font color="#ebebeb">org.apache.cordova.vibration</font></span> then put this in the onNotification handler:</div>
<div><pre style="font-family:Consolas,&#39;Liberation Mono&#39;,Courier,monospace;font-size:13px;margin-top:15px;margin-bottom:15px;background-color:rgb(248,248,248);border:1px solid rgb(221,221,221);line-height:19px;overflow:auto;padding:6px 10px;border-top-left-radius:3px;border-top-right-radius:3px;border-bottom-right-radius:3px;border-bottom-left-radius:3px;word-wrap:normal;color:rgb(51,51,51)">
<code style="font-family:Consolas,&#39;Liberation Mono&#39;,Courier,monospace;font-size:12px;margin:0px;border:none;background-color:transparent;border-top-left-radius:3px;border-top-right-radius:3px;border-bottom-right-radius:3px;border-bottom-left-radius:3px;display:inline;vertical-align:middle;line-height:inherit;padding:0px;word-wrap:normal">navigator.notification.vibrate(time)</code></pre>
</div><div><div><blockquote type="cite"><div dir="ltr"><div><br><div>if (e.coldstart) {</div><div><span style="white-space:pre-wrap">                </span> </div>
<div><span style="white-space:pre-wrap">                </span>} else {</div><div><span style="white-space:pre-wrap">                </span>   </div><div><span style="white-space:pre-wrap">                </span>}</div></div></div></blockquote></div><br></div><div>
This is android specific, it’s set to true when the application was not active not even in the background and the system started the app to respond to the notification.</div><div><br></div><div>Hope that helps,</div><div>
<span style="white-space:pre-wrap">        </span>Erik Jan</div></div><br>_______________________________________________<br>
aerogear-dev mailing list<br>
<a href="mailto:aerogear-dev@lists.jboss.org">aerogear-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/aerogear-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/aerogear-dev</a><br></blockquote></div><br></div>