<?xml version="1.0" encoding="utf-8" ?>
<CodeSnippets xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet">
  <CodeSnippet Format="1.0.0">
    <Header>
      <Title>WinJS.Promise</Title>
      <Shortcut>wp</Shortcut>
      <Description>Define a new WinJS Promise</Description>
      <Author>Jeremie Corpinot</Author>
      <SnippetTypes>
        <!-- snippet types -->
        <SnippetType>Expansion</SnippetType>
      </SnippetTypes>
    </Header>
    <Snippet>
      <Declarations>
        <Literal>
          <ID>var</ID>
          <ToolTip>Promise literal</ToolTip>
          <Default>promise</Default>
        </Literal>
        <Literal>
          <ID>body</ID>
          <ToolTip>Promise's body</ToolTip>
          <Default>// body</Default>
        </Literal>
      </Declarations>
      <Code Language="javascript">
        <![CDATA[var $var$ = new WinJS.Promise(function (completeDispatch, errorDispatch, progressDispatch) {
            $body$
        });$end$
        ]]>
      </Code>
    </Snippet>
  </CodeSnippet>
</CodeSnippets>