allow to set target in mime-registry: need target _self (instead default _blank) for directories opened in filemanager

This commit is contained in:
Ralf Becker 2012-03-28 13:01:37 +00:00
parent 2630a39651
commit 2f62d7e3b5
3 changed files with 8 additions and 1 deletions

View File

@ -282,6 +282,7 @@ class filemanager_hooks
egw_vfs::DIR_MIME_TYPE => array(
'menuaction' => 'filemanager.filemanager_ui.index',
'mime_id' => 'path',
'mime_target' => '_self',
),
),
);

View File

@ -75,6 +75,7 @@
* 'mime_url' => 'url',
* 'menuaction' => 'app.class.method', // method to call
* 'mime_popup' => '400x300', // optional size of popup
* 'mime_target' => '_self', // optional target, default _blank
* // other get-parameters to set in url
* ),
* // further mime types supported ...
@ -560,7 +561,7 @@ class egw_link extends solink
{
if (self::DEBUG)
{
echo "<p>egw_link::unlink('$link_id','$app','$id','$owner','$app2','$id2')</p>\n";
echo "<p>egw_link::unlink('$link_id','$app',".array2string($id).",'$owner','$app2','$id2', $hold_for_purge)</p>\n";
}
if ($link_id < 0) // vfs-link?
{

View File

@ -69,6 +69,11 @@ egw.extend('open', egw.MODULE_WND_LOCAL, function(_egw, _wnd) {
popup = url.mime_popup;
delete url.mime_popup;
}
if(typeof url.mime_target != 'undefined')
{
target = url.mime_target;
delete url.mime_target;
}
params = url;
url = '/index.php';
}