@@ -115,8 +115,8 @@ public function macroLink(MacroNode $node, PhpWriter $writer)
115115 {
116116 $ node ->modifiers = preg_replace ('#\|safeurl\s*(?=\||\z)#i ' , '' , $ node ->modifiers );
117117 return $ writer ->using ($ node )
118- ->write ('echo %escape(%modify( '
119- . ($ node ->name === 'plink ' ? '$this->global->uiPresenter ' : '$this->global->uiControl ' )
118+ ->write ('echo %escape(%modify($this->global->uiControl '
119+ . ($ node ->name === 'plink ' ? '->getPresenter() ' : '' )
120120 . '->link(%node.word, %node.array?))) '
121121 );
122122 }
@@ -131,8 +131,8 @@ public function macroIfCurrent(MacroNode $node, PhpWriter $writer)
131131 throw new CompileException ('Modifiers are not allowed in ' . $ node ->getNotation ());
132132 }
133133 return $ writer ->write ($ node ->args
134- ? 'if ($this->global->uiPresenter ->isLinkCurrent(%node.word, %node.array?)) { '
135- : 'if ($this->global->uiPresenter ->getLastCreatedRequestFlag("current")) { '
134+ ? 'if ($this->global->uiControl->getPresenter() ->isLinkCurrent(%node.word, %node.array?)) { '
135+ : 'if ($this->global->uiControl->getPresenter() ->getLastCreatedRequestFlag("current")) { '
136136 );
137137 }
138138
@@ -145,6 +145,6 @@ public function macroExtends(MacroNode $node, PhpWriter $writer)
145145 if ($ node ->modifiers || $ node ->parentNode || $ node ->args !== 'auto ' ) {
146146 return $ this ->extends = false ;
147147 }
148- $ this ->extends = $ writer ->write ('$this->parentName = $this->global->uiPresenter ->findLayoutTemplateFile(); ' );
148+ $ this ->extends = $ writer ->write ('$this->parentName = $this->global->uiControl->getPresenter() ->findLayoutTemplateFile(); ' );
149149 }
150150}
0 commit comments