m4dc4p / mg-todo

A simple language for defining todo lists, using the Mg (or MGrammar) language, from Microsoft's Oslo platform.

This URL has Read+Write access

mg-todo / TodoPlugin / ToDoCommands.py
b59eb54d » Justin Bailey 2008-11-06 Got ToDo plugin working 1 #----------------------------------------------------------------
2 # Copyright (c) Microsoft Corporation. All rights reserved.
3 #----------------------------------------------------------------
4
5 import sys
6 import System
7 import Microsoft
8 import Common
9
10 @Metadata.ImportSingleValue('{Microsoft.Intellipad}Core')
11 def Initialize(value):
12 global Core
13 Core = value
14 Common.Initialize(Core)
15
16 @Metadata.CommandExecuted('{Microsoft.Intellipad}BufferView', '{Microsoft.Intellipad}SetToDoMode', 'Ctrl+Shift+G')
17 def SetToDoMode(target, sender, args):
18 sender.Mode = Core.ComponentDomain.GetBoundValue[System.Object]('{Microsoft.Intellipad}ToDoMode')
19