Skip to content

Instantly share code, notes, and snippets.

@BrandonLive
Created August 19, 2014 19:07
Show Gist options
  • Save BrandonLive/22a3b7a3ce0ae66fc1fc to your computer and use it in GitHub Desktop.
Save BrandonLive/22a3b7a3ce0ae66fc1fc to your computer and use it in GitHub Desktop.
DManipReproApp
body {
height: 100%;
}
.scrollViewer {
height: 100%;
width: 100%;
overflow:auto;
}
.content {
width: 200%;
height: 300%;
background: linear-gradient(to bottom, black, #000040 40%, #000040 60%, black);
}
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title>DManipReproApp.WindowsPhone</title>
<!-- WinJS references -->
<!-- At runtime, ui-themed.css resolves to ui-themed.light.css or ui-themed.dark.css
based on the user’s theme setting. This is part of the MRT resource loading functionality. -->
<link href="/css/ui-themed.css" rel="stylesheet" />
<script src="//Microsoft.Phone.WinJS.2.1/js/base.js"></script>
<script src="//Microsoft.Phone.WinJS.2.1/js/ui.js"></script>
<!-- DManipReproApp.Phone references -->
<link href="/css/default.css" rel="stylesheet" />
<script src="/js/default.js"></script>
</head>
<body class="phone">
<div class="scrollViewer">
<div class="content">
<h2>Pan to see DManip go boom.</h2>
<p>If it doesn't repro, kill the app and try again. 99% repro here.</p>
</div>
</div>
</body>
</html>
// For an introduction to the Blank template, see the following documentation:
// http://go.microsoft.com/fwlink/?LinkID=392286
(function () {
"use strict";
var app = WinJS.Application;
var activation = Windows.ApplicationModel.Activation;
app.onactivated = function (args) {
if (args.detail.kind === activation.ActivationKind.launch) {
args.setPromise(WinJS.UI.processAll());
var spin = function () {
var then = Date.now() + 500;
while (Date.now() < then) {
// Nothing!
}
};
// To make the repro easier, we simulate a real app
// doing interesting work on the UI thread during startup
spin();
setInterval(spin, 500);
// It also repros even if you yield for 2.5 seconds and then spin
//setTimeout(function () {
// setInterval(spin, 500);
//}, 2000);
// But interestingly, it doesn't repro on my 1520 if I yield for 5.5 seconds first
//setTimeout(function () {
// setInterval(spin, 500);
//}, 5000);
}
};
app.oncheckpoint = function (args) {
};
app.start();
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment