1: <?php
2:
3: namespace Mapbender\CoreBundle\Element;
4:
5: use Mapbender\CoreBundle\Component\Element;
6:
7: 8: 9: 10: 11: 12: 13:
14: class extends Element
15: {
16:
17: 18: 19:
20: public static function getClassTitle()
21: {
22: return 'Spatial Reference System Selector';
23: }
24:
25: 26: 27:
28: public static function getClassDescription()
29: {
30: return "The spatial reference system selector changes the map's
31: spatial reference system.";
32: }
33:
34: 35: 36:
37: public static function getClassTags()
38: {
39: return array('spatial', 'reference', 'system', 'selector');
40: }
41:
42: 43: 44:
45: public static function getType()
46: {
47: return 'Mapbender\CoreBundle\Element\Type\SrsSelectorAdminType';
48: }
49:
50: 51: 52:
53: public function getAssets()
54: {
55: return array(
56: 'js' => array(
57: 'mapbender.element.srsselector.js',
58: '@FOMCoreBundle/Resources/public/js/frontend/components.js',
59: 'proj4js/proj4js-compressed.js'),
60: 'css' => array()
61: );
62: }
63:
64: 65: 66:
67: public static function getDefaultConfiguration()
68: {
69: return array(
70: "tooltip" => "SRS Selector",
71: 'label' => false,
72: "target" => null);
73: }
74:
75: 76: 77:
78: public function getWidgetName()
79: {
80: return 'mapbender.mbSrsSelector';
81: }
82:
83: 84: 85:
86: public function render()
87: {
88: return $this->container->get('templating')
89: ->render('MapbenderCoreBundle:Element:srsselector.html.twig',
90: array(
91: 'id' => $this->getId(),
92: "title" => $this->getTitle(),
93: 'configuration' => $this->getConfiguration()));
94: }
95:
96: 97: 98:
99: public static function getFormTemplate()
100: {
101: return 'MapbenderManagerBundle:Element:srsselector.html.twig';
102: }
103:
104: }