@@ -30,7 +30,8 @@ |
||
| 30 | 30 | /** |
| 31 | 31 | * @param Components\IControl $confirmationDialogFactory |
| 32 | 32 | */ |
| 33 | - public function injectConfirmationDialog(Components\IControl $confirmationDialogFactory) { |
|
| 33 | + public function injectConfirmationDialog(Components\IControl $confirmationDialogFactory) |
|
| 34 | + { |
|
| 34 | 35 | $this->confirmationDialogFactory = $confirmationDialogFactory; |
| 35 | 36 | } |
| 36 | 37 | } |
@@ -69,7 +69,7 @@ |
||
| 69 | 69 | */ |
| 70 | 70 | public static function register(Nette\Configurator $config, $extensionName = 'confirmationDialog') |
| 71 | 71 | { |
| 72 | - $config->onCompile[] = function (Nette\Configurator $config, Nette\DI\Compiler $compiler) use ($extensionName) { |
|
| 72 | + $config->onCompile[] = function(Nette\Configurator $config, Nette\DI\Compiler $compiler) use ($extensionName) { |
|
| 73 | 73 | $compiler->addExtension($extensionName, new ConfirmationDialogExtension()); |
| 74 | 74 | }; |
| 75 | 75 | } |
@@ -31,8 +31,8 @@ discard block |
||
| 31 | 31 | */ |
| 32 | 32 | abstract class BaseControl extends Application\UI\Control |
| 33 | 33 | { |
| 34 | - const TEMPLATE_LAYOUT = 'layout'; |
|
| 35 | - const TEMPLATE_CONFIRMER = 'template'; |
|
| 34 | + const TEMPLATE_LAYOUT = 'layout'; |
|
| 35 | + const TEMPLATE_CONFIRMER = 'template'; |
|
| 36 | 36 | |
| 37 | 37 | /** |
| 38 | 38 | * @var null|string |
@@ -80,11 +80,11 @@ discard block |
||
| 80 | 80 | $dir = dirname($this->getReflection()->getFileName()); |
| 81 | 81 | |
| 82 | 82 | // ...check if extension template is used |
| 83 | - if (is_file($dir . DIRECTORY_SEPARATOR .'template'. DIRECTORY_SEPARATOR . $templateFile)) { |
|
| 83 | + if (is_file($dir . DIRECTORY_SEPARATOR . 'template' . DIRECTORY_SEPARATOR . $templateFile)) { |
|
| 84 | 84 | $templateFile = $dir . DIRECTORY_SEPARATOR . 'template' . DIRECTORY_SEPARATOR . $templateFile; |
| 85 | 85 | |
| 86 | - } else if (is_file($dir . DIRECTORY_SEPARATOR .'template'. DIRECTORY_SEPARATOR . $templateFile .'.latte')) { |
|
| 87 | - $templateFile = $dir . DIRECTORY_SEPARATOR .'template'. DIRECTORY_SEPARATOR . $templateFile .'.latte'; |
|
| 86 | + } else if (is_file($dir . DIRECTORY_SEPARATOR . 'template' . DIRECTORY_SEPARATOR . $templateFile . '.latte')) { |
|
| 87 | + $templateFile = $dir . DIRECTORY_SEPARATOR . 'template' . DIRECTORY_SEPARATOR . $templateFile . '.latte'; |
|
| 88 | 88 | |
| 89 | 89 | } else { |
| 90 | 90 | // ...if not throw exception |
@@ -183,7 +183,7 @@ |
||
| 183 | 183 | $template->name = $this->name; |
| 184 | 184 | $template->class = $this->cssClass; |
| 185 | 185 | $template->icon = $this->getIcon(); |
| 186 | - $template->question = $this->getQuestion(); |
|
| 186 | + $template->question = $this->getQuestion(); |
|
| 187 | 187 | $template->heading = $this->getHeading(); |
| 188 | 188 | $template->useAjax = $this->useAjax; |
| 189 | 189 | |
@@ -14,4 +14,6 @@ |
||
| 14 | 14 | |
| 15 | 15 | namespace IPub\ConfirmationDialog\Exceptions; |
| 16 | 16 | |
| 17 | -interface IException {} |
|
| 18 | 17 | \ No newline at end of file |
| 18 | +interface IException |
|
| 19 | +{ |
|
| 20 | +} |
|
| 19 | 21 | \ No newline at end of file |
@@ -14,4 +14,6 @@ |
||
| 14 | 14 | |
| 15 | 15 | namespace IPub\ConfirmationDialog\Exceptions; |
| 16 | 16 | |
| 17 | -class InvalidArgumentException extends \Exception implements IException {} |
|
| 18 | 17 | \ No newline at end of file |
| 18 | +class InvalidArgumentException extends \Exception implements IException |
|
| 19 | +{ |
|
| 20 | +} |
|
| 19 | 21 | \ No newline at end of file |
@@ -14,4 +14,6 @@ |
||
| 14 | 14 | |
| 15 | 15 | namespace IPub\ConfirmationDialog\Exceptions; |
| 16 | 16 | |
| 17 | -class InvalidStateException extends \Exception implements IException {} |
|
| 18 | 17 | \ No newline at end of file |
| 18 | +class InvalidStateException extends \Exception implements IException |
|
| 19 | +{ |
|
| 20 | +} |
|
| 19 | 21 | \ No newline at end of file |
@@ -14,4 +14,6 @@ |
||
| 14 | 14 | |
| 15 | 15 | namespace IPub\ConfirmationDialog\Exceptions; |
| 16 | 16 | |
| 17 | -class IOException extends \RuntimeException implements IException {} |
|
| 18 | 17 | \ No newline at end of file |
| 18 | +class IOException extends \RuntimeException implements IException |
|
| 19 | +{ |
|
| 20 | +} |
|
| 19 | 21 | \ No newline at end of file |
@@ -14,4 +14,6 @@ |
||
| 14 | 14 | |
| 15 | 15 | namespace IPub\ConfirmationDialog\Exceptions; |
| 16 | 16 | |
| 17 | -class FileNotFoundException extends IOException implements IException {} |
|
| 18 | 17 | \ No newline at end of file |
| 18 | +class FileNotFoundException extends IOException implements IException |
|
| 19 | +{ |
|
| 20 | +} |
|
| 19 | 21 | \ No newline at end of file |