]> gerrit.simantics Code Review - simantics/platform.git/blob - bundles/org.simantics.editors.win32/src/org/simantics/editors/win32/ole/WordDefinition.java
Migrated source code from Simantics SVN
[simantics/platform.git] / bundles / org.simantics.editors.win32 / src / org / simantics / editors / win32 / ole / WordDefinition.java
1 /*******************************************************************************\r
2  * Copyright (c) 2007, 2010 Association for Decentralized Information Management\r
3  * in Industry THTH ry.\r
4  * All rights reserved. This program and the accompanying materials\r
5  * are made available under the terms of the Eclipse Public License v1.0\r
6  * which accompanies this distribution, and is available at\r
7  * http://www.eclipse.org/legal/epl-v10.html\r
8  *\r
9  * Contributors:\r
10  *     VTT Technical Research Centre of Finland - initial API and implementation\r
11  *******************************************************************************/\r
12 package org.simantics.editors.win32.ole;\r
13 \r
14 import org.eclipse.swt.ole.win32.OleAutomation;\r
15 import org.eclipse.swt.ole.win32.OleClientSite;\r
16 import org.eclipse.swt.ole.win32.OleFrame;\r
17 \r
18 /**\r
19  * Word documents\r
20  * \r
21  * @author Marko Luukkainen <marko.luukkainen@vtt.fi>\r
22  *\r
23  */\r
24 public class WordDefinition implements EditorDefinition{\r
25 \r
26         @Override\r
27         public OleController createController(OleFrame frame, OleClientSite site, OleAutomation auto) {\r
28                 return null;\r
29         }\r
30         \r
31         @Override\r
32         public String getProgID() {\r
33                 return null; //"Word.Document"\r
34         }\r
35         \r
36         @Override\r
37         public boolean supportSuffix(String suffix) {\r
38                 return suffix.equals("doc") || suffix.equals("docx");   \r
39         }\r
40         \r
41         @Override\r
42         public boolean useBrowser() {\r
43                 return false;\r
44         }\r
45         \r
46         @Override\r
47         public boolean useFileInput() {\r
48                 return true;\r
49         }\r
50 }\r