Index: trunk/kernel/include/debugger.php
===================================================================
diff -u -r817 -r820
--- trunk/kernel/include/debugger.php (.../debugger.php) (revision 817)
+++ trunk/kernel/include/debugger.php (.../debugger.php) (revision 820)
@@ -27,7 +27,7 @@
switch($Data['debug_type'])
{
case 'error':
- $fileLink = $this->getFileLink($Data['file']);
+ $fileLink = $this->getFileLink($Data['file'],$Data['line']);
$ret = ''.$this->getErrorNameByCode($Data['no']).': '.$Data['str'];
$ret .= ' in '.$fileLink.' on line '.$Data['line'].'';
return $ret;
@@ -47,7 +47,7 @@
{
$traceRec =& $trace[$i];
$argsID = 'trace_args_'.$dataIndex.'_'.$i;
- $ret .= 'Function: '.$this->getFileLink($traceRec['file'],$traceRec['class'].$traceRec['type'].$traceRec['function']).'';
+ $ret .= 'Function: '.$this->getFileLink($traceRec['file'],$traceRec['line'],$traceRec['class'].$traceRec['type'].$traceRec['function']).'';
$ret .= ' in '.basename($traceRec['file']).' on line '.$traceRec['line'].'
';
// ensure parameter value is not longer then 200 symbols
@@ -72,10 +72,10 @@
}
}
- function getFileLink($file, $title = '')
+ function getFileLink($file, $lineno = 1, $title = '')
{
if(!$title) $title = $file;
- return ''.$title.'';
+ return ''.$title.'';
}
function getLocalFile($remoteFile)
@@ -201,14 +201,15 @@
return $ret;
}
- function editFile($FileName)
+ function editFile($fileName,$lineNo)
{
- var $EditorPath = '';
- if($EditorPath)
+ var $editorPath = '';
+ if($editorPath)
{
var $obj = new ActiveXObject("LaunchinIE.Launch");
- //alert('lauching: ['+$EditorPath+' '+$FileName+']');
- $obj.LaunchApplication($EditorPath+' '+$FileName);
+ $editorPath = $editorPath.replace('%F',$fileName);
+ $editorPath = $editorPath.replace('%L',$lineNo);
+ $obj.LaunchApplication($editorPath);
}
else
{