This commit is contained in:
Shish 2009-01-15 23:01:30 -08:00
parent 53ff09ece2
commit 873e3c3911

View file

@ -10,8 +10,8 @@ class LinkImage implements Extension {
public function receive_event(Event $event) {
if(is_null($this->theme)) $this->theme = get_theme_object($this);
if(($event instanceof DisplayingImageEvent)) {
global $config;
$data_href = get_base_href();
global $config;
$data_href = get_base_href();
$event->page->add_header("<link rel='stylesheet' href='$data_href/ext/link_image/_style.css' type='text/css'>",0);
$this->theme->links_block($event->page,$this->data($event->image));
@ -21,11 +21,11 @@ class LinkImage implements Extension {
$sb->add_text_option("ext_link-img_text-link_format", "Text Link Format: ");
$event->panel->add_block($sb);
}
if($event instanceof InitExtEvent) {
global $config;
//just set default if empty.
if($event instanceof InitExtEvent) {
global $config;
//just set default if empty.
$config->set_default_string("ext_link-img_text-link_format",
'$title - $id ($ext $size $filesize)');
'$title - $id ($ext $size $filesize)');
}
}
private function data($image) {