GitHub Sale: sign up for any paid plan this week and pay nothing until January 1, 2009!  [ hide ]

public
Description: Midgard Components Framework 3rd generation
Homepage: http://www.midgard-project.org
Clone URL: git://github.com/bergie/midcom.git
Added localization library.
Arttu Manninen (author)
Thu Apr 10 08:56:42 -0700 2008
commit  8139a846b69e871e1263764ef2afbb76a3c760bf
tree    ad276da35ce4efd2bfbc856f1fec068f1886e5dc
parent  70ba20eb1040bf53edf0371b03406d0901cec66e
...
3
4
5
 
6
7
8
...
3
4
5
6
7
8
9
0
@@ -3,6 +3,7 @@ services_authorization: midcom_core_services_authorization_simple
0
 services_templating: midcom_core_services_templating_midgard
0
 services_sessioning: midcom_core_services_sessioning_midgard
0
 services_uimessages: midcom_core_services_uimessages_midgard
0
+services_l10n: midcom_core_services_l10n_gettext
0
 cache_directory: __MIDGARDCACHE__/midgard
0
 enable_benchmark: false
0
 enable_included_list: false
...
20
21
22
 
23
24
25
...
82
83
84
 
 
 
 
85
86
87
...
20
21
22
23
24
25
26
...
83
84
85
86
87
88
89
90
91
92
0
@@ -20,6 +20,7 @@ class midcom_core_midcom
0
     public $componentloader;
0
     public $dispatcher;
0
     public $templating;
0
+ public $l10n;
0
 
0
     // Helpers
0
     public $navigation;
0
@@ -82,6 +83,10 @@ class midcom_core_midcom
0
         
0
         // Load the navigation helper
0
         //$this->navigation = new midcom_core_helpers_navigation();
0
+
0
+ // Load the localization
0
+ $services_l10n_implementation = $this->configuration->get('services_l10n');
0
+ $this->l10n = new $services_l10n_implementation();
0
 
0
         // Load the head helper
0
         $this->head = new midcom_core_helpers_head
...
16
17
18
19
 
20
21
22
...
28
29
30
31
 
32
33
 
34
35
 
36
37
38
...
87
88
89
90
 
91
92
93
...
95
96
97
98
 
99
100
101
102
103
 
104
105
106
...
110
111
112
113
 
114
115
116
...
16
17
18
 
19
20
21
22
...
28
29
30
 
31
32
 
33
34
 
35
36
37
38
...
87
88
89
 
90
91
92
93
...
95
96
97
 
98
99
100
101
102
 
103
104
105
106
...
110
111
112
 
113
114
115
116
0
@@ -16,7 +16,7 @@ interface midcom_core_services_uimessages
0
     /**
0
      * @param &$configuration Configuration for the current uimessage type
0
      */
0
- public function __construct(&$configuration=array());
0
+ public function __construct(&$configuration = array());
0
     
0
     public function add($data);
0
     
0
@@ -28,11 +28,11 @@ interface midcom_core_services_uimessages
0
     
0
     public function has_messages();
0
     
0
- public function render($key=null);
0
+ public function render($key = null);
0
     
0
- public function render_as($type='comet', $key=null);
0
+ public function render_as($type = 'comet', $key = null);
0
 
0
- public function supports($type='comet');
0
+ public function supports($type = 'comet');
0
 }
0
 
0
 /**
0
@@ -87,7 +87,7 @@ class midcom_core_services_uimessages_baseclass
0
 
0
     public function can_view($user=null)
0
     {
0
- if ($_MIDCOM->context->mimetype == 'text/html')
0
+ if ($_MIDCOM->context->mimetype === 'text/html')
0
         {
0
             return true;
0
         }
0
@@ -95,12 +95,12 @@ class midcom_core_services_uimessages_baseclass
0
         return false;
0
     }
0
 
0
- public function render($key=null)
0
+ public function render($key = null)
0
     {
0
         return $this->implementation->render($key);
0
     }
0
     
0
- public function render_as($type='comet', $key=null)
0
+ public function render_as($type = 'comet', $key = null)
0
     {
0
         if ($this->supports($type))
0
         {
0
@@ -110,7 +110,7 @@ class midcom_core_services_uimessages_baseclass
0
         return false;
0
     }
0
     
0
- public function supports($type='comet')
0
+ public function supports($type = 'comet')
0
     {
0
         if ($this->implementation->supports($type))
0
         {

Comments

    No one has commented yet.