diff options
-rw-r--r-- | lib/ManaTools/Module/Hosts.pm | 10 | ||||
-rwxr-xr-x | scripts/manahost | 11 |
2 files changed, 9 insertions, 12 deletions
diff --git a/lib/ManaTools/Module/Hosts.pm b/lib/ManaTools/Module/Hosts.pm index 2fc61271..4e8abcda 100644 --- a/lib/ManaTools/Module/Hosts.pm +++ b/lib/ManaTools/Module/Hosts.pm @@ -41,9 +41,16 @@ has '+icon' => ( ); has '+name' => ( - default => "Hostmanager", + lazy => 1, + builder => '_nameInitializer', ); +sub _nameInitializer { + my $self = shift; + + return ($self->loc->N("manahost - manage hosts definitions")); +} + =head1 VERSION Version 1.0.0 @@ -397,7 +404,6 @@ sub _manageHostsDialog { my $appIcon = yui::YUI::app()->applicationIcon(); ## set new title to get it in dialog my $newTitle = $self->loc->N("Manage hosts definitions"); - yui::YUI::app()->setApplicationTitle($newTitle); my $factory = yui::YUI::widgetFactory; my $optional = yui::YUI::optionalWidgetFactory; diff --git a/scripts/manahost b/scripts/manahost index b773f1f9..47479890 100755 --- a/scripts/manahost +++ b/scripts/manahost @@ -23,16 +23,7 @@ use ManaTools::Module::Hosts; use yui; -my $wm_icon = "/usr/lib/libDrakX/icons/IC-Dhost-48.png"; -my $wm_name = "Manage hosts definitions"; - -yui::YUI::app()->setApplicationTitle($wm_name); -yui::YUI::app()->setApplicationIcon($wm_icon); - -my $hostMan = ManaTools::Module::Hosts->new({ - icon => $wm_icon, - name => $wm_name - }); +my $hostMan = ManaTools::Module::Hosts->new(); $hostMan->start(); 1; |