1 //------------------------------------------------------------------------------
2 // emNetwalkFpPlugin.cpp
3 //
4 // Copyright (C) 2010 Oliver Hamann.
5 //
6 // Homepage: http://eaglemode.sourceforge.net/
7 //
8 // This program is free software: you can redistribute it and/or modify it under
9 // the terms of the GNU General Public License version 3 as published by the
10 // Free Software Foundation.
11 //
12 // This program is distributed in the hope that it will be useful, but WITHOUT
13 // ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
14 // FOR A PARTICULAR PURPOSE. See the GNU General Public License version 3 for
15 // more details.
16 //
17 // You should have received a copy of the GNU General Public License version 3
18 // along with this program. If not, see <http://www.gnu.org/licenses/>.
19 //------------------------------------------------------------------------------
20 
21 #include <emCore/emFpPlugin.h>
22 #include <emNetwalk/emNetwalkPanel.h>
23 
24 
25 extern "C" {
emNetwalkFpPluginFunc(emPanel::ParentArg parent,const emString & name,const emString & path,emFpPlugin * plugin,emString * errorBuf)26 	emPanel * emNetwalkFpPluginFunc(
27 		emPanel::ParentArg parent, const emString & name,
28 		const emString & path, emFpPlugin * plugin,
29 		emString * errorBuf
30 	)
31 	{
32 		if (plugin->Properties.GetCount()) {
33 			*errorBuf="emNetwalkFpPlugin: No properties allowed.";
34 			return NULL;
35 		}
36 		return new emNetwalkPanel(
37 			parent,name,
38 			emNetwalkModel::Acquire(parent.GetRootContext(),path)
39 		);
40 	}
41 }
42