Giter Site home page Giter Site logo

blackberry / bes10-cascades Goto Github PK

View Code? Open in Web Editor NEW
5.0 5.0 26.0 24.45 MB

Cascades-based Samples for the Enterprise; BlackBerry 10 client and BES10 server

JavaScript 42.70% C++ 50.14% TypeScript 4.55% Erlang 0.05% Prolog 0.08% C 0.37% Shell 0.06% ASP 0.89% C# 1.16%

bes10-cascades's People

Contributors

bthornton32 avatar hjung avatar pelegri avatar sleonard42 avatar timwindsor avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

bes10-cascades's Issues

10.3.1 mousedown can block mouseup, click

The mousedown event will block the mouseup and click events from firing properly if the dom is modified during a mousedown handler. I first noticed this while using the Angular Material framework. You can see an example of this for yourself and log the events in the web inspector at https://material.angularjs.org/0.11.0/#/demo/material.components.button. Notice that clicking on any button with your finger will only fire the touchstart, touchend, mouseout and mousedown events (in that order.) This causes unwanted behaviour and seems to block the click event until you 're-click' the button.

Using the trackpad on the BlackBerry Classic and clicking on a button does trigger the proper events (mousedown, touchstart, mouseup, touchend in that order.)

I reduced this to a small test (http://codepen.io/mckenzielong/pen/MayWwy for running example):

  <body>
    <button id="test-button">Block mousedown</button>
    <div></div>
  </body>
var testButton = document.getElementById("test-button");
testButton.addEventListener("mousedown", function () {
  console.log("Mousedown fired");
  setTimeout(function () {
    console.log("async timeout complete.");
  }, 1000);
  var node = document.createElement("p"); 
    var textnode = document.createTextNode("Water");
    node.appendChild(textnode)
    document.getElementsByTagName("div")[0].appendChild(node);
}, false)

testButton.addEventListener("click", function () {
  console.log("Click fired.");
}, false)

testButton.addEventListener("mouseup", function () {
  console.log("Mouseup fired.");
}, false)

Expected behaviour: click the button, click fired and mouse up fired messages should be printed to the console.
Current behaviour: click and mouseup fire every second button click.

ServerNotify

In the method sendAlert() I think the header is wrong:
HttpWReq.Headers.Add("ContentType", "text/plain");

I think it should be
HttpWReq.Headers.Add("Content-Type", "text/plain");

I get an error on my bb device when receiving a push message:
Missing Content-type header for push

EDIT. I receive an error after changing ContentType to Content-Type:
Error: System.ArgumentException: The 'Content-Type' header must be modified using the appropriate property or method.
Parameter name: name
at System.Net.WebHeaderCollection.ThrowOnRestrictedHeader(String headerName)
at System.Net.WebHeaderCollection.Add(String name, String value)

ServerNotifyService - 10.2 Channel is not being created

There is either a bug or a lot of unnecessary code in the 10.2.1 Client headless service -

The channel is not being created due to line 52 (service.cpp).
m_shouldChannelBeCreated = false;

This means that the pushService is not being registered on line 179.

Either line 52 should be set to true, OR the functions createChannelCompleted and createSessionCompleted are redundant and can be completely removed. I suspect line 52 should be set to true.

Also, following the instructions to import the app and compile it does not lead to a .bar files being created. It creates .so files.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.