clip - Dave's Blog

Search
My timeline on Mastodon

Application Content URI Rule effects

2017 Jun 30, 3:01

Previously I described Application Content URI Rules (ACUR) parsing and ACUR ordering. This post describes what you get from putting a URI in ACUR.

URIs in the ACUR gain the following which is otherwise unavailable:

  • Geoloc API usage
  • Audio and video capture API usage
  • Pointer lock API usage
  • Web notifications API usage
  • IndexedDB API usage
  • Clipboard API usage
  • window.external.notify access from within webview
  • window.close the primary window
  • Top level navigation in the primary window
  • Cross origin XHR and fetch to ms-appx(-web) scheme URIs
  • Cross origin dirtied canvas read access if dirtied by ms-appx(-web) scheme URIs
  • Cross origin text track for video element for tracks from ms-appx(-web) scheme URIs

URIs in the ACUR that also have full WinRT access additionally gain the following:

  • Cross origin XHR and fetch
  • Cross origin dirtied canvas read access
  • Cross origin text track for video element
  • Local audio and video WinRT plugins work with media elements
PermalinkCommentsapplication-content-uri-rules coding javascript programming windows-store

Tweet from Jen Gentleman šŸŒŗ

2016 Nov 4, 8:39
If you ever see a dialog box in this style & need to record what it said, instead of typing it out, just CTRL+C āž”šŸ“‹
PermalinkComments

laughingsquid: Live Band Performs ā€˜Mario Kartā€™ Song as Man...

2015 May 27, 3:11


laughingsquid:

Live Band Performs ā€˜Mario Kartā€™ Song as Man Races Down the Video Game Track

PermalinkComments

laughingsquid: A Real Hedgehog Scurries Along to Music From the...

2015 Apr 23, 1:17


laughingsquid:

A Real Hedgehog Scurries Along to Music From the ā€˜Sonic the Hedgehogā€™ Video Game While Collecting Golden Rings

PermalinkComments

Retweet of ChromiumDev

2015 Apr 14, 7:29
Now in Chrome 43, document.execCommand() gives you programmatic access to copy and cut content to the clipboard! http://updates.html5rocks.com/2015/04/cut-and-copy-commands ā€¦
PermalinkComments

RIP CadburdyShe died yesterday. Besides the normal grief its...

2015 Apr 8, 2:43


RIP Cadburdy

She died yesterday. Besides the normal grief its strange being the adult and dealing with a deceased pet.

PermalinkComments

laughingsquid:Researcher Cracks His Knuckles in Only One Hand...

2015 Mar 24, 12:01


laughingsquid:

Researcher Cracks His Knuckles in Only One Hand for Over 60 Years to See if He Would Get Arthritis

PermalinkComments

laughingsquid:Photo-Editing Professionals React With Surprise...

2015 Mar 17, 3:05


laughingsquid:

Photo-Editing Professionals React With Surprise and Frustration as They Attempt to Use Photoshop 1.0 From 1990

PermalinkComments

laughingsquid:A Fun Offbeat Parody of the ā€˜Jurassic Worldā€™...

2015 Feb 17, 5:53


laughingsquid:

A Fun Offbeat Parody of the ā€˜Jurassic Worldā€™ Teaser Trailer Featuring Raptors on Motorcycles

PermalinkComments

Shout Text Windows 8 App Development Notes

2013 Jun 27, 1:00

My first app for Windows 8 was Shout Text. You type into Shout Text, and your text is scaled up as large as possible while still fitting on the screen, as you type. It is the closest thing to a Hello World app as you'll find on the Windows Store that doesn't contain that phrase (by default) and I approached it as the simplest app I could make to learn about Windows modern app development and Windows Store app submission.

I rely on WinJS's default layout to use CSS transforms to scale up the user's text as they type. And they are typing into a simple content editable div.

The app was too simple for me to even consider using ads or charging for it which I learned more about in future apps.

The first interesting issue I ran into was that copying from and then pasting into the content editable div resulted in duplicates of the containing div with copied CSS appearing recursively inside of the content editable div. To fix this I had to catch the paste operation and remove the HTML data from the clipboard to ensure only the plain text data is pasted:

        function onPaste() {
var text;

if (window.clipboardData) {
text = window.clipboardData.getData("Text").toString();
window.clipboardData.clearData("Html");
window.clipboardData.setData("Text", util.normalizeContentEditableText(text));
}
}
shoutText.addEventListener("beforepaste", function () { return false; }, false);
shoutText.addEventListener("paste", onPaste, false);

I additionally found an issue in IE in which applying a CSS transform to a content editable div that has focus doesn't move the screen position of the user input caret - the text is scaled up or down but the caret remains the same size and in the same place on the screen. To fix this I made the following hack to reapply the current cursor position and text selection which resets the screen position of the user input caret.

        function resetCaret() {
setTimeout(function () {
var cursorPos = document.selection.createRange().duplicate();
cursorPos.select();
}, 200);
}

shoutText.attachEvent("onresize", function () { resetCaret(); }, true);
PermalinkCommentsdevelopment html javascript shout-text technical windows windows-store

Clippy.JS - Add Clippy and friends to any website (smore.com)

2012 May 29, 6:15

A great JS API to add Clippy or other agents to your website!  Make them talk, dance, gesture, etc

PermalinkCommentshumor microsoft js javascript web

Another Comedy Bang Bang preview clip this time with Zach...

2012 Apr 18, 6:02


Another Comedy Bang Bang preview clip this time with Zach Galifianakis.

PermalinkCommentszach-galifianakis comedy-bang-bang video humor preview scott-aukerman tv clip

Star Trek: TNG Season 8 illustration has us longing for more [Star Trek]

2012 Mar 5, 3:17

Fictional plot summaries of TNG S8 episodes.    Like:

  • Qā€™s back: heā€™s wearing scuba gear and needs Picardā€™s help dumping his girlfriend. Barclay accidentally locks himself outside the ship.
  • Geordie and Data nurse a space bird back to health, and are sad when they have to release it. Picard is trapped in a turbolift with a baby.
  • Starfleet sends a cantankerous admiral to boss around Picard during delicate peace talks. Data seems to have mastered bragging.
  • Rikerā€™s ex-girlfriend arrives and dies, leaving behind a pile of glowing dust and a mystery. Picard is trapped on a turbolift with a horse.
  • A planet of suspicious docents abduct Riker for their museum of amazing men. Geordi and Data are too excited to sleep at their sleepover.
  • Picard is trapped inside a sentient turbolift. A clip show highlights the most memorable ā€œPicard is trapped on a turboliftā€ moments.
PermalinkCommentshumor twitter tng tv

(via Hello, A Remix of Lionel Richieā€™s ā€œHelloā€ Made Using Film...

2012 Jan 17, 9:51


(via Hello, A Remix of Lionel Richieā€™s ā€œHelloā€ Made Using Film Clips)

PermalinkCommentshumor music video film remix mashup hello

clip.exe - Useful tool I didn't know shipped with Windows

2011 May 26, 11:00

When you run clip.exe, whatever comes into its standard input is put onto the clipboard. So when you need to move the result of something in your command window somewhere else you can pipe the result into clip.exe. Then you won't have to worry about the irritating way cmd.exe does block copy/pasting and you avoid having to manually fixup line breaks in wrapped lines. For instance, you can put the contents of a script into the clipboard with:

more cdo.cmd | clip

I've got a lot of stuff dumped in my bin folder that I sync across all my PCs so I didn't realize that clip.exe is a part of standard Windows installs.

Nice for avoiding the block copy in cmd.exe but I'd prefer to have the contents sort of tee'd into the clipboard and standard output. So TeeClip.ps1:

$input | tee -var teeclipout | clip;
$teeclipout;
PermalinkCommentspowershell clip tool clipboard cli technical windows tee

YouTube Deal Turns Copyright Videos Into Revenue - NYTimes.com

2010 Sep 4, 7:40"In the past, Lions Gate, which owns the rights to the ā€œMad Menā€ clip, might have requested that TomR35ā€™s version be taken down. But it has decided to leave clips like this up, and in return, YouTube runs ads with the video and splits the revenue with Lions Gate."PermalinkCommentsad advertising copyright economics google internet tv video youtube article

Great Job, Internet!: Arrested Development as an action movie? Better than no AD movie at all... | Film | The A.V. Club Blog | The A.V. Club

2010 Jul 6, 2:10Parody Arrested Development movie trailer using clips from the show to look like an action film.
PermalinkCommentshumor video arrested-development movie parody

Amazon Kindle: Most Highlighted Passages of All Time

2010 May 3, 7:27Amazon has the most highlighted passages of Kindle users. Of course Dan Brown is all over that. But in 94th place of most highlighted is a passage from the 'Kindle Shortcuts' book on how to highlight passages: "Go to top Notes and Clippings (Kindle 2) To create a highlight: use the 5-way controller to highlight the content you want to clip and then press the 5-way to save your selection... Highlighted by 319 Kindle users"PermalinkCommentshumor highlight amazon kindle technical meta

Spaced - Full Episodes and Clips streaming online for free - Hulu

2010 Mar 9, 12:09Simon Pegg and Nick Frost (I know them from Shaun of the Dead and Hot Fuzz) were in this british comedy in the late 90s Spaced. A decade later its still pretty funny.
PermalinkCommentsspaced british humor tv hulu simon-pegg

Developing on a Device | Android Developers

2009 Dec 26, 7:11Wow, that was easy to setup. After installing the driver Eclipse just asks me if I want to debug on my phone or my virtual device.PermalinkCommentstechnical reference android programming development cellphone g1 documentation google
Older Entries Creative Commons License Some rights reserved.